63 lines
2.3 KiB
Text
63 lines
2.3 KiB
Text
$NetBSD: patch-al,v 1.5 2011/01/13 13:52:53 wiz Exp $
|
|
|
|
--- ext/gd/config.m4.orig 2007-07-03 17:25:43.000000000 +0000
|
|
+++ ext/gd/config.m4
|
|
@@ -48,18 +48,7 @@ dnl Checks for the configure options
|
|
dnl
|
|
|
|
AC_DEFUN([PHP_GD_ZLIB],[
|
|
- if test "$PHP_ZLIB_DIR" != "no" && test "$PHP_ZLIB_DIR" != "yes"; then
|
|
- if test -f "$PHP_ZLIB_DIR/include/zlib/zlib.h"; then
|
|
- PHP_ZLIB_DIR="$PHP_ZLIB_DIR"
|
|
- PHP_ZLIB_INCDIR="$PHP_ZLIB_DIR/include/zlib"
|
|
- elif test -f "$PHP_ZLIB_DIR/include/zlib.h"; then
|
|
- PHP_ZLIB_DIR="$PHP_ZLIB_DIR"
|
|
- PHP_ZLIB_INCDIR="$PHP_ZLIB_DIR/include"
|
|
- else
|
|
- AC_MSG_ERROR([Can't find zlib headers under "$PHP_ZLIB_DIR"])
|
|
- fi
|
|
- else
|
|
- for i in /usr/local /usr; do
|
|
+ for i in "$PHP_ZLIB_DIR" /usr/local /usr; do
|
|
if test -f "$i/include/zlib/zlib.h"; then
|
|
PHP_ZLIB_DIR="$i"
|
|
PHP_ZLIB_INCDIR="$i/include/zlib"
|
|
@@ -68,7 +57,6 @@ AC_DEFUN([PHP_GD_ZLIB],[
|
|
PHP_ZLIB_INCDIR="$i/include"
|
|
fi
|
|
done
|
|
- fi
|
|
])
|
|
|
|
AC_DEFUN([PHP_GD_JPEG],[
|
|
@@ -100,11 +88,11 @@ AC_DEFUN([PHP_GD_PNG],[
|
|
if test "$PHP_PNG_DIR" != "no"; then
|
|
|
|
for i in $PHP_PNG_DIR /usr/local /usr; do
|
|
- test -f $i/$PHP_LIBDIR/libpng.$SHLIB_SUFFIX_NAME || test -f $i/$PHP_LIBDIR/libpng.a && GD_PNG_DIR=$i && break
|
|
+ test -f $i/$PHP_LIBDIR/libpng15.$SHLIB_SUFFIX_NAME || test -f $i/$PHP_LIBDIR/libpng15.a && GD_PNG_DIR=$i && break
|
|
done
|
|
|
|
if test -z "$GD_PNG_DIR"; then
|
|
- AC_MSG_ERROR([libpng.(a|so) not found.])
|
|
+ AC_MSG_ERROR([libpng15.(a|so) not found.])
|
|
fi
|
|
|
|
if test "$PHP_ZLIB_DIR" = "no"; then
|
|
@@ -115,13 +103,13 @@ AC_DEFUN([PHP_GD_PNG],[
|
|
AC_MSG_ERROR([png.h not found.])
|
|
fi
|
|
|
|
- PHP_CHECK_LIBRARY(png,png_write_image,
|
|
+ PHP_CHECK_LIBRARY(png15,png_write_image,
|
|
[
|
|
PHP_ADD_INCLUDE($GD_PNG_DIR/include)
|
|
PHP_ADD_LIBRARY_WITH_PATH(z, $PHP_ZLIB_DIR/$PHP_LIBDIR, GD_SHARED_LIBADD)
|
|
- PHP_ADD_LIBRARY_WITH_PATH(png, $GD_PNG_DIR/$PHP_LIBDIR, GD_SHARED_LIBADD)
|
|
+ PHP_ADD_LIBRARY_WITH_PATH(png15, $GD_PNG_DIR/$PHP_LIBDIR, GD_SHARED_LIBADD)
|
|
],[
|
|
- AC_MSG_ERROR([Problem with libpng.(a|so) or libz.(a|so). Please check config.log for more information.])
|
|
+ AC_MSG_ERROR([Problem with libpng15.(a|so) or libz.(a|so). Please check config.log for more information.])
|
|
],[
|
|
-L$PHP_ZLIB_DIR/$PHP_LIBDIR -lz -L$GD_PNG_DIR/$PHP_LIBDIR
|
|
])
|