File tree Expand file tree Collapse file tree 7 files changed +30
-14
lines changed Expand file tree Collapse file tree 7 files changed +30
-14
lines changed Original file line number Diff line number Diff line change @@ -45,15 +45,15 @@ install-modules: build-modules
45
45
@rm -f modules/*.la >/dev/null 2>&1
46
46
@$(INSTALL) modules/* $(INSTALL_ROOT)$(EXTENSION_DIR)
47
47
48
- install-tester:
49
- @echo "Installing regression tester: $(INSTALL_ROOT)$(PEAR_INSTALLDIR)/"
50
- @$(mkinstalldirs) $(INSTALL_ROOT)$(PEAR_INSTALLDIR)
51
- @$(INSTALL) -m 755 $(top_srcdir)/run-tests.php $(INSTALL_ROOT)$(PEAR_INSTALLDIR)
52
-
53
- install-su: install-pear install-tester
48
+ install-su: install-pear
54
49
55
50
test:
56
- -@if test -x $(SAPI_CLI_PATH) && test ! -z $(SAPI_CLI_PATH); then \
51
+ -@if test ! -z $(PHP_EXECUTABLE) && test -x $(PHP_EXECUTABLE); then \
52
+ TEST_PHP_EXECUTABLE=$(PHP_EXECUTABLE) \
53
+ TEST_PHP_SRCDIR=$(top_srcdir) \
54
+ CC="$(CC)" \
55
+ $(PHP_EXECUTABLE) -d 'extension_dir=modules/' -d 'extension='`basename $(PHP_MODULES) .la`'.so' -d 'open_basedir=' -d 'safe_mode=0' -d 'output_buffering=0' -d 'memory_limit=-1' $(top_srcdir)/run-tests.php tests/; \
56
+ elif test ! -z $(SAPI_CLI_PATH) && test -x $(SAPI_CLI_PATH); then \
57
57
TEST_PHP_EXECUTABLE=$(top_builddir)/$(SAPI_CLI_PATH) \
58
58
TEST_PHP_SRCDIR=$(top_srcdir) \
59
59
CC="$(CC)" \
Original file line number Diff line number Diff line change @@ -1082,8 +1082,8 @@ PHP_SUBST_OLD(php_abs_top_srcdir)
1082
1082
1083
1083
PHP_SUBST(bindir)
1084
1084
PHP_SUBST(exec_prefix)
1085
- PHP_SUBST (program_prefix)
1086
- PHP_SUBST (program_suffix)
1085
+ PHP_SUBST_OLD (program_prefix)
1086
+ PHP_SUBST_OLD (program_suffix)
1087
1087
PHP_SUBST(includedir)
1088
1088
PHP_SUBST(libdir)
1089
1089
PHP_SUBST(mandir)
@@ -1183,7 +1183,7 @@ INLINE_CFLAGS="$INLINE_CFLAGS $standard_libtool_flag"
1183
1183
CXXFLAGS="$CXXFLAGS $standard_libtool_flag"
1184
1184
1185
1185
all_targets='$(OVERALL_TARGET) $(PHP_MODULES) $(PHP_CLI_TARGET)'
1186
- install_targets="$install_modules $install_pear install-build install-headers install-programs install-tester "
1186
+ install_targets="$install_modules $install_pear install-build install-headers install-programs"
1187
1187
1188
1188
case $PHP_SAPI in
1189
1189
cgi)
Original file line number Diff line number Diff line change @@ -13,7 +13,9 @@ BUILD_FILES = \
13
13
build/libtool.m4 \
14
14
Makefile.global \
15
15
acinclude.m4 \
16
- ltmain.sh
16
+ ltmain.sh \
17
+ run-tests.php \
18
+ run-tests-config.php
17
19
18
20
BUILD_FILES_EXEC = \
19
21
build/shtool \
Original file line number Diff line number Diff line change @@ -51,6 +51,10 @@ Extra libraries which PHP was compiled with
51
51
Directory where extensions are searched by default
52
52
.TP
53
53
.PD 0
54
+ .B \-\- php-binary
55
+ Full path to php CLI/CGI binary
56
+ .TP
57
+ .PD 0
54
58
.B \-\- version
55
59
PHP version
56
60
.TP
Original file line number Diff line number Diff line change 1
1
#! /bin/sh
2
2
3
3
prefix=" @prefix@"
4
+ exec_prefix=" @exec_prefix@"
4
5
version=" @PHP_VERSION@"
5
6
includedir=" @includedir@/php"
6
7
includes=" -I$includedir -I$includedir /main -I$includedir /TSRM -I$includedir /Zend"
7
8
ldflags=" @PHP_LDFLAGS@"
8
9
libs=" @EXTRA_LIBS@"
9
10
extension_dir=' @EXTENSION_DIR@'
11
+ program_prefix=" @program_prefix@"
12
+ program_suffix=" @program_suffix@"
13
+ exe_extension=" @EXEEXT@"
14
+ php_binary=" @bindir@/${program_prefix} php${program_suffix}${exe_extension} "
10
15
11
16
case " $1 " in
12
17
--prefix)
@@ -19,10 +24,12 @@ case "$1" in
19
24
echo $libs ;;
20
25
--extension-dir)
21
26
echo $extension_dir ;;
27
+ --php-binary)
28
+ echo $php_binary ;;
22
29
--version)
23
30
echo $version ;;
24
31
* )
25
- echo " Usage: $0 [--prefix|--includes|--ldflags|--libs|--extension-dir|--version]"
32
+ echo " Usage: $0 [--prefix|--includes|--ldflags|--libs|--extension-dir|--php-binary|-- version]"
26
33
exit 1;;
27
34
esac
28
35
Original file line number Diff line number Diff line change @@ -8,11 +8,12 @@ includedir="`eval echo @includedir@`/php"
8
8
builddir=" ` pwd` "
9
9
10
10
FILES_BUILD=" mkdep.awk scan_makefile_in.awk shtool libtool.m4"
11
- FILES=" acinclude.m4 Makefile.global config.sub config.guess ltmain.sh"
11
+ FILES=" acinclude.m4 Makefile.global config.sub config.guess ltmain.sh run-tests*.php "
12
12
CLEAN_FILES=" $FILES *.o *.lo *.la .deps .libs/ build/ include/ modules/ install-sh \
13
13
mkinstalldirs missing config.nice config.sub config.guess configure configure.in \
14
14
aclocal.m4 config.h config.h.in conftest* ltmain.sh libtool config.cache autom4te.cache/ \
15
- config.log config.status Makefile Makefile.fragments Makefile.objects confdefs.h"
15
+ config.log config.status Makefile Makefile.fragments Makefile.objects confdefs.h \
16
+ run-tests*.php"
16
17
17
18
# function declaration
18
19
phpize_usage ()
Original file line number Diff line number Diff line change @@ -18,6 +18,7 @@ AC_DEFUN([PHP_WITH_PHP_CONFIG],[
18
18
prefix=`$PHP_CONFIG --prefix 2>/dev/null`
19
19
INCLUDES=`$PHP_CONFIG --includes 2>/dev/null`
20
20
EXTENSION_DIR=`$PHP_CONFIG --extension-dir`
21
+ PHP_EXECUTABLE=`$PHP_CONFIG --php-binary`
21
22
22
23
if test -z "$prefix"; then
23
24
AC_MSG_ERROR ( Cannot find php-config. Please use -- with-php-config=PATH )
@@ -99,6 +100,7 @@ PHP_SUBST(CPPFLAGS)
99
100
PHP_SUBST(CXX)
100
101
PHP_SUBST(CXXFLAGS)
101
102
PHP_SUBST(EXTENSION_DIR)
103
+ PHP_SUBST(PHP_EXECUTABLE)
102
104
PHP_SUBST(EXTRA_LDFLAGS)
103
105
PHP_SUBST(EXTRA_LIBS)
104
106
PHP_SUBST(INCLUDES)
You can’t perform that action at this time.
0 commit comments