]> git.pld-linux.org Git - packages/php.git/blobdiff - fix-test-run.patch
- fix test building
[packages/php.git] / fix-test-run.patch
index 2231d77977dc3288c23d9f95a8fa3a1b68e181b8..627341f96f5075c3ac30c7195fb0a6450b56375c 100644 (file)
        else \
                echo "ERROR: Cannot run tests without CLI sapi."; \
        fi
+--- php-5.3.2/Makefile.global  2010-03-16 16:31:36.972576955 +0200
++++ php-5.3.2/Makefile.global  2010-03-16 16:31:36.972576955 +0200
+@@ -296,7 +296,7 @@
+       fi
+ PHP_TEST_SETTINGS = -d 'open_basedir=' -d 'output_buffering=0' -d 'memory_limit=-1' -d 'safe_mode=0'
+-PHP_TEST_SHARED_SYSTEM_EXTENSIONS = pcre
++PHP_TEST_SHARED_SYSTEM_EXTENSIONS =
+ PHP_TEST_SHARED_EXTENSIONS =  ` \
+       if test "x$(PHP_MODULES)" != "x"; then \
+               for i in $(PHP_MODULES)""; do \
+--- php-5.3.2/Makefile.gcov    2010-03-16 16:31:36.972576955 +0200
++++ php-5.3.2/Makefile.gcov    2010-03-16 16:31:36.972576955 +0200
+@@ -376,11 +376,25 @@
+       @echo "Running test suite"
+       @find . -name \*.gcda -o -name \*.da -o -name \*.bbg? | xargs rm -f
+       -@if test ! -z "$(PHP_EXECUTABLE)" && test -x "$(PHP_EXECUTABLE)"; then \
++              INI_FILE=`$(PHP_EXECUTABLE) -d 'display_errors=stderr' -r 'echo php_ini_loaded_file();' 2> /dev/null`; \
++              if test "$$INI_FILE"; then \
++                      $(EGREP) -h -v $(PHP_DEPRECATED_DIRECTIVES_REGEX) "$$INI_FILE" > $(top_builddir)/tmp-php.ini; \
++              else \
++                      echo > $(top_builddir)/tmp-php.ini; \
++              fi; \
++              INI_SCANNED_PATH=`$(PHP_EXECUTABLE) -d 'display_errors=stderr' -r '$$a = explode(",\n", trim(php_ini_scanned_files())); echo $$a[0];' 2> /dev/null`; \
++              if test "$$INI_SCANNED_PATH"; then \
++                      INI_SCANNED_PATH=`$(top_srcdir)/build/shtool path -d $$INI_SCANNED_PATH`; \
++                      $(EGREP) -h -v $(PHP_DEPRECATED_DIRECTIVES_REGEX) "$$INI_SCANNED_PATH"/*.ini >> $(top_builddir)/tmp-php.ini; \
++              fi; \
+               NO_INTERACTION=1 \
+               TEST_PHP_EXECUTABLE=$(PHP_EXECUTABLE) \
+               TEST_PHP_SRCDIR=$(top_srcdir) \
+               CC="$(CC)" \
+-                      $(PHP_EXECUTABLE) -d 'open_basedir=' -d 'safe_mode=0' -d 'output_buffering=0' -d 'memory_limit=-1' $(top_srcdir)/run-tests.php -d 'extension_dir=modules/' -d `( . $(PHP_MODULES) ; echo extension=$$dlname)` tests/; \
++                      $(PHP_EXECUTABLE) -n -c $(top_builddir)/tmp-php.ini \
++                      -d extension_dir=$(top_builddir)/modules/ -d 'extension=$(EXTENSION_DIR)/pcre.$(SHLIB_DL_SUFFIX_NAME)' \
++                      $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -n -c $(top_builddir)/tmp-php.ini \
++                      -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(RUN_TESTS_SETTINGS) $(TESTS); \
+       elif test ! -z "$(SAPI_CLI_PATH)" && test -x "$(SAPI_CLI_PATH)"; then \
+               NO_INTERACTION=1 \
+               TEST_PHP_EXECUTABLE=$(top_builddir)/$(SAPI_CLI_PATH) \
This page took 0.064955 seconds and 4 git commands to generate.