X-Git-Url: https://review.fuel-infra.org/gitweb?a=blobdiff_plain;f=cirros-testvm%2Fsrc-cirros%2Fbuildroot-2015.05%2Fpackage%2Fphp%2F0002-no-iconv-search.patch;fp=cirros-testvm%2Fsrc-cirros%2Fbuildroot-2015.05%2Fpackage%2Fphp%2F0002-no-iconv-search.patch;h=322395379db838147847f59e14d9e72db1a693a2;hb=b0a0f15dfaa205161a7fcb20cf1b8cd4948c2ef3;hp=0000000000000000000000000000000000000000;hpb=c6ac3cd55ee2da956195eee393b0882105dfad4e;p=packages%2Ftrusty%2Fcirros-testvm.git diff --git a/cirros-testvm/src-cirros/buildroot-2015.05/package/php/0002-no-iconv-search.patch b/cirros-testvm/src-cirros/buildroot-2015.05/package/php/0002-no-iconv-search.patch new file mode 100644 index 0000000..3223953 --- /dev/null +++ b/cirros-testvm/src-cirros/buildroot-2015.05/package/php/0002-no-iconv-search.patch @@ -0,0 +1,55 @@ +Tweak PHP_SETUP_ICONV from aclocal/acinclude.m4 to not +PHP_ADD_INCLUDE $ICONV_DIR/include since the tests use +test instead of AC_TRY_LINK to find headers which is bad, +specially when adding /usr and /usr/local to the mix. +Do basically the same with ext/iconv/config.m4 by tweaking +PHP_ICONV_H_PATH which, again, uses test and absolute paths. + +Signed-off-by: Gustavo Zacarias +[Gustavo: convert to nice m4 instead of patching configure] + +diff -Nura php-5.6.8.orig/acinclude.m4 php-5.6.8/acinclude.m4 +--- php-5.6.8.orig/acinclude.m4 2015-05-18 20:06:48.557099001 +0200 ++++ php-5.6.8/acinclude.m4 2015-05-18 20:07:33.177099001 +0200 +@@ -2470,7 +2470,7 @@ + dnl + if test "$found_iconv" = "no"; then + +- for i in $PHP_ICONV /usr/local /usr; do ++ for i in $PHP_ICONV; do + if test -r $i/include/giconv.h; then + AC_DEFINE(HAVE_GICONV_H, 1, [ ]) + ICONV_DIR=$i +diff -Nura php-5.6.7.orig/ext/iconv/config.m4 php-5.6.7/ext/iconv/config.m4 +--- php-5.6.7.orig/ext/iconv/config.m4 2015-04-08 11:08:11.184847544 -0300 ++++ php-5.6.7/ext/iconv/config.m4 2015-04-08 11:39:07.823608030 -0300 +@@ -14,28 +14,8 @@ + ]) + + if test "$iconv_avail" != "no"; then +- if test -z "$ICONV_DIR"; then +- for i in /usr/local /usr; do +- if test -f "$i/include/iconv.h" || test -f "$i/include/giconv.h"; then +- PHP_ICONV_PREFIX="$i" +- break +- fi +- done +- if test -z "$PHP_ICONV_PREFIX"; then +- PHP_ICONV_PREFIX="/usr" +- fi +- else +- PHP_ICONV_PREFIX="$ICONV_DIR" +- fi + +- CFLAGS="-I$PHP_ICONV_PREFIX/include $CFLAGS" +- LDFLAGS="-L$PHP_ICONV_PREFIX/$PHP_LIBDIR $LDFLAGS" +- +- if test -r "$PHP_ICONV_PREFIX/include/giconv.h"; then +- PHP_ICONV_H_PATH="$PHP_ICONV_PREFIX/include/giconv.h" +- else +- PHP_ICONV_H_PATH="$PHP_ICONV_PREFIX/include/iconv.h" +- fi ++ PHP_ICONV_H_PATH="iconv.h" + + AC_MSG_CHECKING([if iconv is glibc's]) + AC_TRY_LINK([#include ],[gnu_get_libc_version();],