]> granicus.if.org Git - php/commitdiff
- Fix for passing of shared extensions to run-tests.php
authorfoobar <sniper@php.net>
Wed, 6 Jun 2007 18:27:54 +0000 (18:27 +0000)
committerfoobar <sniper@php.net>
Wed, 6 Jun 2007 18:27:54 +0000 (18:27 +0000)
Makefile.global

index 42097cb86ffbfd00bff2bb618f11729fa84b1885..ddd8c4744dfca72643089a2c915f9f177d37dc73 100644 (file)
@@ -66,38 +66,41 @@ install-headers:
                        fi \
                done; \
        fi
+       
+PHP_TEST_SHARED_EXTENSIONS=`(for i in $(PHP_MODULES); do . $$i ; echo -n "-d extension=$$dlname "; done)`
+PHP_TEST_SETTINGS=-d 'open_basedir=' -d 'output_buffering=0' -d 'memory_limit=-1'
 
-test: all 
+test: all
        -@if test ! -z "$(PHP_EXECUTABLE)" && test -x "$(PHP_EXECUTABLE)"; then \
                TEST_PHP_EXECUTABLE=$(PHP_EXECUTABLE) \
                TEST_PHP_SRCDIR=$(top_srcdir) \
                CC="$(CC)" \
-                       $(PHP_EXECUTABLE) -d 'open_basedir=' -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) $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -U -d extension_dir=modules/ $(PHP_TEST_SHARED_EXTENSIONS) tests/; \
        elif test ! -z "$(SAPI_CLI_PATH)" && test -x "$(SAPI_CLI_PATH)"; then \
                TEST_PHP_EXECUTABLE=$(top_builddir)/$(SAPI_CLI_PATH) \
                TEST_PHP_SRCDIR=$(top_srcdir) \
                CC="$(CC)" \
-                       $(top_builddir)/$(SAPI_CLI_PATH) -d 'open_basedir=' -d 'output_buffering=0' -d 'memory_limit=-1' $(top_srcdir)/run-tests.php -U $(TESTS); \
+                       $(top_builddir)/$(SAPI_CLI_PATH) $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -U -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(TESTS); \
        else \
                echo "ERROR: Cannot run tests without CLI sapi."; \
        fi
 
 utest: all
-       -@if test -x $(SAPI_CLI_PATH) && test ! -z $(SAPI_CLI_PATH); then \
+       -@if test ! -z "$(SAPI_CLI_PATH)" && test -x "$(SAPI_CLI_PATH)"; then \
                TEST_PHP_EXECUTABLE=$(top_builddir)/$(SAPI_CLI_PATH) \
                TEST_PHP_SRCDIR=$(top_srcdir) \
                CC="$(CC)" \
-                       $(top_builddir)/$(SAPI_CLI_PATH) -d 'open_basedir=' -d 'output_buffering=0' -d 'memory_limit=-1' $(top_srcdir)/run-tests.php -u $(TESTS); \
+                       $(top_builddir)/$(SAPI_CLI_PATH) $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -u -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(TESTS); \
        else \
                echo "ERROR: Cannot run tests without CLI sapi."; \
        fi
 
 ntest: all
-       -@if test -x $(SAPI_CLI_PATH) && test ! -z $(SAPI_CLI_PATH); then \
+       -@if test ! -z "$(SAPI_CLI_PATH)" && test -x "$(SAPI_CLI_PATH)"; then \
                TEST_PHP_EXECUTABLE=$(top_builddir)/$(SAPI_CLI_PATH) \
                TEST_PHP_SRCDIR=$(top_srcdir) \
                CC="$(CC)" \
-                       $(top_builddir)/$(SAPI_CLI_PATH) -d 'open_basedir=' -d 'output_buffering=0' -d 'memory_limit=-1' $(top_srcdir)/run-tests.php -N $(TESTS); \
+                       $(top_builddir)/$(SAPI_CLI_PATH) $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -N -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(TESTS); \
        else \
                echo "ERROR: Cannot run tests without CLI sapi."; \
        fi