Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

MFH: - Made build system less major version dependant to ease MFB/MFH

  • Loading branch information...
commit 8684e7495f625e962f73a91350463df46a8cfe05 1 parent 68b8235
authored
60  Makefile.global
@@ -13,22 +13,22 @@ all: $(all_targets)
13 13
 	
14 14
 build-modules: $(PHP_MODULES)
15 15
 
16  
-libphp5.la: $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS)
  16
+libphp$(PHP_MAJOR_VERSION).la: $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS)
17 17
 	$(LIBTOOL) --mode=link $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -rpath $(phptempdir) $(EXTRA_LDFLAGS) $(LDFLAGS) $(PHP_RPATHS) $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@
18  
-	-@$(LIBTOOL) --silent --mode=install cp libphp5.la $(phptempdir)/libphp5.la >/dev/null 2>&1
  18
+	-@$(LIBTOOL) --silent --mode=install cp $@ $(phptempdir)/$@ >/dev/null 2>&1
19 19
 
20  
-libs/libphp5.bundle: $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS)
21  
-	$(CC) $(MH_BUNDLE_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) $(LDFLAGS) $(EXTRA_LDFLAGS) $(PHP_GLOBAL_OBJS:.lo=.o) $(PHP_SAPI_OBJS:.lo=.o) $(PHP_FRAMEWORKS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@ && cp $@ libs/libphp5.so
  20
+libs/libphp$(PHP_MAJOR_VERSION).bundle: $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS)
  21
+	$(CC) $(MH_BUNDLE_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) $(LDFLAGS) $(EXTRA_LDFLAGS) $(PHP_GLOBAL_OBJS:.lo=.o) $(PHP_SAPI_OBJS:.lo=.o) $(PHP_FRAMEWORKS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@ && cp $@ libs/libphp$(PHP_MAJOR_VERSION).so
22 22
 
23 23
 install: $(all_targets) $(install_targets)
24 24
 
25 25
 install-sapi: $(OVERALL_TARGET)
26 26
 	@echo "Installing PHP SAPI module:       $(PHP_SAPI)"
27 27
 	-@$(mkinstalldirs) $(INSTALL_ROOT)$(bindir)
28  
-	-@if test ! -r $(phptempdir)/libphp5.$(SHLIB_DL_SUFFIX_NAME); then \
  28
+	-@if test ! -r $(phptempdir)/libphp$(PHP_MAJOR_VERSION).$(SHLIB_DL_SUFFIX_NAME); then \
29 29
 		for i in 0.0.0 0.0 0; do \
30  
-			if test -r $(phptempdir)/libphp5.$(SHLIB_DL_SUFFIX_NAME).$$i; then \
31  
-				$(LN_S) $(phptempdir)/libphp5.$(SHLIB_DL_SUFFIX_NAME).$$i $(phptempdir)/libphp5.$(SHLIB_DL_SUFFIX_NAME); \
  30
+			if test -r $(phptempdir)/libphp$(PHP_MAJOR_VERSION).$(SHLIB_DL_SUFFIX_NAME).$$i; then \
  31
+				$(LN_S) $(phptempdir)/libphp$(PHP_MAJOR_VERSION).$(SHLIB_DL_SUFFIX_NAME).$$i $(phptempdir)/libphp$(PHP_MAJOR_VERSION).$(SHLIB_DL_SUFFIX_NAME); \
32 32
 				break; \
33 33
 			fi; \
34 34
 		done; \
@@ -66,11 +66,9 @@ install-headers:
66 66
 			fi \
67 67
 		done; \
68 68
 	fi
69  
-	
70  
-install-su: install-pear
71 69
 
72  
-PHP_TEST_SETTINGS = -d 'open_basedir=' -d 'safe_mode=0' -d 'output_buffering=0' -d 'memory_limit=-1'
73  
-PHP_TEST_SHARED_EXTENSIONS = ` \
  70
+PHP_TEST_SETTINGS = -d 'open_basedir=' -d 'output_buffering=0' -d 'memory_limit=-1'
  71
+PHP_TEST_SHARED_EXTENSIONS =  ` \
74 72
 	if test "$(PHP_MODULES)"; then \
75 73
 		for i in $(PHP_MODULES); do \
76 74
 			. $$i; $(top_srcdir)/build/shtool echo -n -- " -d extension=$$dlname"; \
@@ -82,7 +80,7 @@ test: all
82 80
 		TEST_PHP_EXECUTABLE=$(PHP_EXECUTABLE) \
83 81
 		TEST_PHP_SRCDIR=$(top_srcdir) \
84 82
 		CC="$(CC)" \
85  
-			$(PHP_EXECUTABLE) $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -d extension_dir=modules/ $(PHP_TEST_SHARED_EXTENSIONS) tests/; \
  83
+			$(PHP_EXECUTABLE) $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -U -d extension_dir=modules/ $(PHP_TEST_SHARED_EXTENSIONS) tests/; \
86 84
 	elif test ! -z "$(SAPI_CLI_PATH)" && test -x "$(SAPI_CLI_PATH)"; then \
87 85
 		INI_FILE=`$(top_builddir)/$(SAPI_CLI_PATH) -r 'echo php_ini_loaded_file();'`; \
88 86
 		if test "$$INI_FILE"; then \
@@ -93,7 +91,39 @@ test: all
93 91
 		TEST_PHP_EXECUTABLE=$(top_builddir)/$(SAPI_CLI_PATH) \
94 92
 		TEST_PHP_SRCDIR=$(top_srcdir) \
95 93
 		CC="$(CC)" \
96  
-			$(top_builddir)/$(SAPI_CLI_PATH) $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -c $(top_builddir)/tmp-php.ini -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(TESTS); \
  94
+			$(top_builddir)/$(SAPI_CLI_PATH) $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -c $(top_builddir)/tmp-php.ini -U -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(TESTS); \
  95
+	else \
  96
+		echo "ERROR: Cannot run tests without CLI sapi."; \
  97
+	fi
  98
+
  99
+utest: all
  100
+	-@if test ! -z "$(SAPI_CLI_PATH)" && test -x "$(SAPI_CLI_PATH)"; then \
  101
+		INI_FILE=`$(top_builddir)/$(SAPI_CLI_PATH) -r 'echo php_ini_loaded_file();'`; \
  102
+		if test "$$INI_FILE"; then \
  103
+			$(EGREP) -v '^extension[\t\ ]*=' "$$INI_FILE" > $(top_builddir)/tmp-php.ini; \
  104
+		else \
  105
+			echo > $(top_builddir)/tmp-php.ini; \
  106
+		fi; \
  107
+		TEST_PHP_EXECUTABLE=$(top_builddir)/$(SAPI_CLI_PATH) \
  108
+		TEST_PHP_SRCDIR=$(top_srcdir) \
  109
+		CC="$(CC)" \
  110
+			$(top_builddir)/$(SAPI_CLI_PATH) $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -c $(top_builddir)/tmp-php.ini -u -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(TESTS); \
  111
+	else \
  112
+		echo "ERROR: Cannot run tests without CLI sapi."; \
  113
+	fi
  114
+
  115
+ntest: all
  116
+	-@if test ! -z "$(SAPI_CLI_PATH)" && test -x "$(SAPI_CLI_PATH)"; then \
  117
+		INI_FILE=`$(top_builddir)/$(SAPI_CLI_PATH) -r 'echo php_ini_loaded_file();'`; \
  118
+		if test "$$INI_FILE"; then \
  119
+			$(EGREP) -v '^extension[\t\ ]*=' "$$INI_FILE" > $(top_builddir)/tmp-php.ini; \
  120
+		else \
  121
+			echo > $(top_builddir)/tmp-php.ini; \
  122
+		fi; \
  123
+		TEST_PHP_EXECUTABLE=$(top_builddir)/$(SAPI_CLI_PATH) \
  124
+		TEST_PHP_SRCDIR=$(top_srcdir) \
  125
+		CC="$(CC)" \
  126
+			$(top_builddir)/$(SAPI_CLI_PATH) $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -c $(top_builddir)/tmp-php.ini -N -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(TESTS); \
97 127
 	else \
98 128
 		echo "ERROR: Cannot run tests without CLI sapi."; \
99 129
 	fi
@@ -104,10 +134,10 @@ clean:
104 134
 	find . -name \*.la -o -name \*.a | xargs rm -f 
105 135
 	find . -name \*.so | xargs rm -f
106 136
 	find . -name .libs -a -type d|xargs rm -rf
107  
-	rm -f libphp5.la $(SAPI_CLI_PATH) $(OVERALL_TARGET) modules/* libs/*
  137
+	rm -f libphp$(PHP_MAJOR_VERSION).la $(SAPI_CLI_PATH) $(OVERALL_TARGET) modules/* libs/*
108 138
 
109 139
 distclean: clean
110  
-	rm -f config.cache config.log config.status Makefile.objects Makefile.fragments libtool main/php_config.h stamp-h php5.spec sapi/apache/libphp5.module buildmk.stamp
  140
+	rm -f config.cache config.log config.status Makefile.objects Makefile.fragments libtool main/php_config.h stamp-h php5.spec sapi/apache/libphp$(PHP_MAJOR_VERSION).module buildmk.stamp
111 141
 	$(EGREP) define'.*include/php' $(top_srcdir)/configure | $(SED) 's/.*>//'|xargs rm -f
112 142
 	find . -name Makefile | xargs rm -f
113 143
 
102  acinclude.m4
@@ -773,7 +773,7 @@ dnl PHP_BUILD_SHARED
773 773
 dnl
774 774
 AC_DEFUN([PHP_BUILD_SHARED],[
775 775
   PHP_BUILD_PROGRAM
776  
-  OVERALL_TARGET=libphp5.la
  776
+  OVERALL_TARGET=libphp[]$PHP_MAJOR_VERSION[.la]
777 777
   php_build_target=shared
778 778
   
779 779
   php_c_pre=$shared_c_pre
@@ -790,7 +790,7 @@ dnl PHP_BUILD_STATIC
790 790
 dnl
791 791
 AC_DEFUN([PHP_BUILD_STATIC],[
792 792
   PHP_BUILD_PROGRAM
793  
-  OVERALL_TARGET=libphp5.la
  793
+  OVERALL_TARGET=libphp[]$PHP_MAJOR_VERSION[.la]
794 794
   php_build_target=static
795 795
 ])
796 796
 
@@ -799,7 +799,7 @@ dnl PHP_BUILD_BUNDLE
799 799
 dnl
800 800
 AC_DEFUN([PHP_BUILD_BUNDLE],[
801 801
   PHP_BUILD_PROGRAM
802  
-  OVERALL_TARGET=libs/libphp5.bundle
  802
+  OVERALL_TARGET=libs/libphp[]$PHP_MAJOR_VERSION[.bundle]
803 803
   php_build_target=static
804 804
 ])
805 805
 
@@ -1026,7 +1026,14 @@ dnl -------------------------------------------------------------------------
1026 1026
 dnl Checks for structures, typedefs, broken functions, etc.
1027 1027
 dnl -------------------------------------------------------------------------
1028 1028
 
1029  
-dnl Internal helper macro
  1029
+dnl Internal helper macros
  1030
+dnl
  1031
+dnl _PHP_DEF_HAVE_FILE(what, filename)
  1032
+AC_DEFUN([_PHP_DEF_HAVE_FILE], [
  1033
+  php_def_have_what=HAVE_[]`echo $1 | tr 'abcdefghijklmnopqrstuvwxyz-' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_' `
  1034
+  echo "#define $php_def_have_what 1" >> $2
  1035
+])
  1036
+dnl
1030 1037
 dnl _PHP_CHECK_SIZEOF(type, cross-value, extra-headers [, found-action [, not-found-action]])
1031 1038
 dnl
1032 1039
 AC_DEFUN([_PHP_CHECK_SIZEOF], [
@@ -1085,6 +1092,21 @@ AC_DEFUN(PHP_CHECK_SIZEOF, [
1085 1092
 ])
1086 1093
 
1087 1094
 dnl
  1095
+dnl PHP_CHECK_TYPES(type-list, include-file [, extra-headers])
  1096
+dnl
  1097
+AC_DEFUN([PHP_CHECK_TYPES], [
  1098
+  for php_typename in $1; do
  1099
+    AC_MSG_CHECKING([whether $php_typename exists])
  1100
+    _PHP_CHECK_SIZEOF($php_typename, 0, $3, [
  1101
+      _PHP_DEF_HAVE_FILE($php_typename, $2)
  1102
+      AC_MSG_RESULT([yes])
  1103
+    ], [
  1104
+      AC_MSG_RESULT([no])
  1105
+    ])
  1106
+  done
  1107
+])
  1108
+
  1109
+dnl
1088 1110
 dnl PHP_CHECK_IN_ADDR_T
1089 1111
 dnl
1090 1112
 AC_DEFUN([PHP_CHECK_IN_ADDR_T], [
@@ -2062,11 +2084,14 @@ dnl
2062 2084
 dnl Search for (f)lex and check it's version
2063 2085
 dnl
2064 2086
 AC_DEFUN([PHP_PROG_LEX], [
2065  
-  # we only support certain flex versions
  2087
+dnl we only support certain flex versions
2066 2088
   flex_version_list="2.5.4"
2067 2089
    
2068 2090
   AC_PROG_LEX
2069 2091
   if test "$LEX" = "flex"; then
  2092
+dnl AC_DECL_YYTEXT is obsolete since autoconf 2.50 and merged into AC_PROG_LEX
  2093
+dnl this is what causes that annoying "PHP_PROG_LEX is expanded from" warning with autoconf 2.50+
  2094
+dnl it should be removed once we drop support of autoconf 2.13 (if ever)
2070 2095
     AC_DECL_YYTEXT
2071 2096
     :
2072 2097
   fi
@@ -2120,17 +2145,17 @@ AC_DEFUN([PHP_PROG_RE2C],[
2120 2145
   AC_CHECK_PROG(RE2C, re2c, re2c)
2121 2146
   if test -n "$RE2C"; then
2122 2147
     AC_CACHE_CHECK([for re2c version], php_cv_re2c_version, [
2123  
-      re2c_vernum=`echo "" | re2c --vernum 2>/dev/null`
2124  
-      if test -z "$re2c_vernum" || test "$re2c_vernum" -lt "911"; then
  2148
+      re2c_vernum=`re2c --vernum 2>/dev/null`
  2149
+      if test -z "$re2c_vernum" || test "$re2c_vernum" -lt "1200"; then
2125 2150
         php_cv_re2c_version=invalid
2126 2151
       else
2127  
-        php_cv_re2c_version="`echo "" | re2c --version | cut -d ' ' -f 2  2>/dev/null` (ok)"
  2152
+        php_cv_re2c_version="`re2c --version | cut -d ' ' -f 2  2>/dev/null` (ok)"
2128 2153
       fi 
2129 2154
     ])
2130 2155
   fi
2131 2156
   case $php_cv_re2c_version in
2132 2157
     ""|invalid[)]
2133  
-      AC_MSG_WARN([You will need re2c 0.9.11 or later if you want to regenerate PHP parsers.])
  2158
+      AC_MSG_WARN([You will need re2c 0.12.0 or later if you want to regenerate PHP parsers.])
2134 2159
       RE2C="exit 0;"
2135 2160
       ;;
2136 2161
   esac
@@ -2142,6 +2167,57 @@ dnl Common setup macros: PHP_SETUP_<what>
2142 2167
 dnl -------------------------------------------------------------------------
2143 2168
 
2144 2169
 dnl
  2170
+dnl PHP_SETUP_ICU([shared-add])
  2171
+dnl
  2172
+dnl Common setup macro for ICU
  2173
+dnl
  2174
+AC_DEFUN([PHP_SETUP_ICU],[
  2175
+  PHP_ARG_WITH(icu-dir,,
  2176
+  [  --with-icu-dir=DIR      Specify where ICU libraries and headers can be found], DEFAULT, no)
  2177
+
  2178
+  if test "$PHP_ICU_DIR" = "no"; then
  2179
+    PHP_ICU_DIR=DEFAULT
  2180
+  fi
  2181
+
  2182
+  if test "$PHP_ICU_DIR" = "DEFAULT"; then
  2183
+    dnl Try to find icu-config
  2184
+    AC_PATH_PROG(ICU_CONFIG, icu-config, no, [$PATH:/usr/local/bin])
  2185
+  else
  2186
+    ICU_CONFIG="$PHP_ICU_DIR/bin/icu-config"
  2187
+  fi
  2188
+
  2189
+  AC_MSG_CHECKING([for location of ICU headers and libraries])
  2190
+
  2191
+  dnl Trust icu-config to know better what the install prefix is..
  2192
+  icu_install_prefix=`$ICU_CONFIG --prefix 2> /dev/null`
  2193
+  if test "$?" != "0" || test -z "$icu_install_prefix"; then
  2194
+    AC_MSG_RESULT([not found])
  2195
+    AC_MSG_ERROR([Unable to detect ICU prefix or $ICU_CONFIG failed. Please verify ICU install prefix and make sure icu-config works.])
  2196
+  else
  2197
+    AC_MSG_RESULT([$icu_install_prefix])
  2198
+
  2199
+    dnl Check ICU version
  2200
+    AC_MSG_CHECKING([for ICU 3.4 or greater])
  2201
+    icu_version_full=`$ICU_CONFIG --version`
  2202
+    ac_IFS=$IFS
  2203
+    IFS="."
  2204
+    set $icu_version_full
  2205
+    IFS=$ac_IFS
  2206
+    icu_version=`expr [$]1 \* 1000 + [$]2`
  2207
+    AC_MSG_RESULT([found $icu_version_full])
  2208
+
  2209
+    if test "$icu_version" -lt "3004"; then
  2210
+      AC_MSG_ERROR([ICU version 3.4 or later is required])
  2211
+    fi
  2212
+
  2213
+    ICU_INCS=`$ICU_CONFIG --cppflags-searchpath`
  2214
+    ICU_LIBS=`$ICU_CONFIG --ldflags --ldflags-icuio`
  2215
+    PHP_EVAL_INCLINE($ICU_INCS)
  2216
+    PHP_EVAL_LIBLINE($ICU_LIBS, $1)
  2217
+  fi
  2218
+])
  2219
+
  2220
+dnl
2145 2221
 dnl PHP_SETUP_KERBEROS(shared-add [, action-found [, action-not-found]])
2146 2222
 dnl
2147 2223
 dnl Common setup macro for kerberos
@@ -2620,11 +2696,17 @@ AC_DEFUN([PHP_CHECK_CONFIGURE_OPTIONS],[
2620 2696
       with-tsrm-pth | with-tsrm-st | with-tsrm-pthreads[)];;
2621 2697
 
2622 2698
       # Allow certain Zend options
2623  
-      with-zend-vm | enable-maintainer-zts | enable-inline-optimization | enable-zend-multibyte[)];;
  2699
+      with-zend-vm | enable-maintainer-zts | enable-inline-optimization[)];;
2624 2700
 
2625 2701
       # All the rest must be set using the PHP_ARG_* macros
2626 2702
       # PHP_ARG_* macros set php_enable_<arg_name> or php_with_<arg_name>
2627 2703
       *[)]
  2704
+        # Options that exist before PHP 6
  2705
+        if test "$PHP_MAJOR_VERSION" -lt "6"; then
  2706
+          case $arg_name in
  2707
+            enable-zend-multibyte[)] continue;;
  2708
+          esac 
  2709
+        fi
2628 2710
         is_arg_set=php_[]`echo [$]arg_name | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ-' 'abcdefghijklmnopqrstuvwxyz_'`
2629 2711
         if eval test -z "\$$is_arg_set"; then
2630 2712
           PHP_UNKNOWN_CONFIGURE_OPTIONS="$PHP_UNKNOWN_CONFIGURE_OPTIONS
4  buildconf
... ...
@@ -1,8 +1,8 @@
1 1
 #!/bin/sh
2 2
 # $Id$
3 3
 
4  
-eval `grep '^EXTRA_VERSION=' configure.in`
5  
-case "$EXTRA_VERSION" in
  4
+eval `grep '^PHP_EXTRA_VERSION=' configure.in`
  5
+case "$PHP_EXTRA_VERSION" in
6 6
   *-dev)
7 7
     dev=1
8 8
     ;;
34  configure.in
@@ -39,12 +39,18 @@ PHP_CANONICAL_HOST_TARGET
39 39
 
40 40
 AC_CONFIG_HEADER(main/php_config.h)
41 41
 
42  
-MAJOR_VERSION=5
43  
-MINOR_VERSION=2
44  
-RELEASE_VERSION=4
45  
-EXTRA_VERSION="-dev"
46  
-PHP_VERSION="$MAJOR_VERSION.$MINOR_VERSION.$RELEASE_VERSION$EXTRA_VERSION"
47  
-PHP_VERSION_ID=`expr [$]MAJOR_VERSION \* 10000 + [$]MINOR_VERSION \* 100 + [$]RELEASE_VERSION`
  42
+PHP_MAJOR_VERSION=5
  43
+PHP_MINOR_VERSION=2
  44
+PHP_RELEASE_VERSION=4
  45
+PHP_EXTRA_VERSION="-dev"
  46
+PHP_VERSION="$PHP_MAJOR_VERSION.$PHP_MINOR_VERSION.$PHP_RELEASE_VERSION$PHP_EXTRA_VERSION"
  47
+PHP_VERSION_ID=`expr [$]PHP_MAJOR_VERSION \* 10000 + [$]PHP_MINOR_VERSION \* 100 + [$]PHP_RELEASE_VERSION`
  48
+
  49
+dnl Allow version values to be used in Makefile
  50
+PHP_SUBST(PHP_MAJOR_VERSION)
  51
+PHP_SUBST(PHP_MINOR_VERSION)
  52
+PHP_SUBST(PHP_RELEASE_VERSION)
  53
+PHP_SUBST(PHP_EXTRA_VERSION)
48 54
 
49 55
 dnl Define where extension directories are located in the configure context
50 56
 AC_DEFUN([PHP_EXT_BUILDDIR],[ext/$1])dnl
@@ -57,10 +63,10 @@ dnl -------------------------------------------------------------------------
57 63
 
58 64
 echo "/* automatically generated by configure */" > php_version.h.new
59 65
 echo "/* edit configure.in to change version number */" >> php_version.h.new
60  
-echo "#define PHP_MAJOR_VERSION $MAJOR_VERSION" >> php_version.h.new
61  
-echo "#define PHP_MINOR_VERSION $MINOR_VERSION" >> php_version.h.new
62  
-echo "#define PHP_RELEASE_VERSION $RELEASE_VERSION" >> php_version.h.new
63  
-echo "#define PHP_EXTRA_VERSION \"$EXTRA_VERSION\"" >> php_version.h.new
  66
+echo "#define PHP_MAJOR_VERSION $PHP_MAJOR_VERSION" >> php_version.h.new
  67
+echo "#define PHP_MINOR_VERSION $PHP_MINOR_VERSION" >> php_version.h.new
  68
+echo "#define PHP_RELEASE_VERSION $PHP_RELEASE_VERSION" >> php_version.h.new
  69
+echo "#define PHP_EXTRA_VERSION \"$PHP_EXTRA_VERSION\"" >> php_version.h.new
64 70
 echo "#define PHP_VERSION \"$PHP_VERSION\"" >> php_version.h.new
65 71
 echo "#define PHP_VERSION_ID $PHP_VERSION_ID" >> php_version.h.new
66 72
 cmp php_version.h.new $srcdir/main/php_version.h >/dev/null 2>&1
@@ -188,7 +194,7 @@ case $host_alias in
188 194
     PHP_ADD_SOURCES(/main, internal_functions.c,,PHP_GLOBAL_OBJS)
189 195
     PHP_ADD_SOURCES(win32, sendmail.c, -I$CFLAGS, PHP_GLOBAL_OBJS)
190 196
     PHP5LIB_SHARED_LIBADD=\$\(EXTRA_LIBS\)
191  
-    EXTENSION_DIR=sys:/php$MAJOR_VERSION/ext
  197
+    EXTENSION_DIR=sys:/php$PHP_MAJOR_VERSION/ext
192 198
     PHP_SUBST(PHP5LIB_SHARED_LIBADD)
193 199
     PHP_SHARED_MODULE(php5lib, PHP_GLOBAL_OBJS, netware)
194 200
     ;;
@@ -240,9 +246,9 @@ dnl SAPI configuration.
240 246
 dnl -------------------------------------------------------------------------
241 247
 
242 248
 dnl paths to the targets are relative to the build directory
243  
-SAPI_SHARED=libs/libphp5.$SHLIB_DL_SUFFIX_NAME
244  
-SAPI_STATIC=libs/libphp5.a
245  
-SAPI_LIBTOOL=libphp5.la
  249
+SAPI_SHARED=libs/libphp[]$PHP_MAJOR_VERSION[.]$SHLIB_DL_SUFFIX_NAME
  250
+SAPI_STATIC=libs/libphp[]$PHP_MAJOR_VERSION[.a]
  251
+SAPI_LIBTOOL=libphp[]$PHP_MAJOR_VERSION[.la]
246 252
 
247 253
 PHP_CONFIGURE_PART(Configuring SAPI modules)
248 254
 
10  run-tests.php
@@ -401,12 +401,14 @@ function write_information($show_html)
401 401
 				case '--version':
402 402
 					echo '$Revision$'."\n";
403 403
 					exit(1);
  404
+
  405
+				case 'u':
  406
+				case 'U':
  407
+					// Allow using u or U for forward compatibility
  408
+					break;
  409
+					
404 410
 				default:
405 411
 					echo "Illegal switch '$switch' specified!\n";
406  
-					if ($switch == 'u' || $switch == 'U') {
407  
-						break;
408  
-					}
409  
-					// break
410 412
 				case 'h':
411 413
 				case '-help':
412 414
 				case '--help':
10  win32/build/confutils.js
@@ -17,7 +17,7 @@
17 17
   +----------------------------------------------------------------------+
18 18
 */
19 19
 
20  
-// $Id: confutils.js,v 1.60.2.1.2.7 2007-07-21 11:24:53 derick Exp $
  20
+// $Id: confutils.js,v 1.60.2.1.2.8 2007-07-26 22:45:59 jani Exp $
21 21
 
22 22
 var STDOUT = WScript.StdOut;
23 23
 var STDERR = WScript.StdErr;
@@ -53,18 +53,18 @@ function get_version_numbers()
53 53
 {
54 54
 	var cin = file_get_contents("configure.in");
55 55
 	
56  
-	if (cin.match(new RegExp("MAJOR_VERSION=(\\d+)"))) {
  56
+	if (cin.match(new RegExp("PHP_MAJOR_VERSION=(\\d+)"))) {
57 57
 		PHP_VERSION = RegExp.$1;
58 58
 	}
59  
-	if (cin.match(new RegExp("MINOR_VERSION=(\\d+)"))) {
  59
+	if (cin.match(new RegExp("PHP_MINOR_VERSION=(\\d+)"))) {
60 60
 		PHP_MINOR_VERSION = RegExp.$1;
61 61
 	}
62  
-	if (cin.match(new RegExp("RELEASE_VERSION=(\\d+)"))) {
  62
+	if (cin.match(new RegExp("PHP_RELEASE_VERSION=(\\d+)"))) {
63 63
 		PHP_RELEASE_VERSION = RegExp.$1;
64 64
 	}
65 65
 	PHP_VERSION_STRING = PHP_VERSION + "." + PHP_MINOR_VERSION + "." + PHP_RELEASE_VERSION;
66 66
 
67  
-	if (cin.match(new RegExp("EXTRA_VERSION=\"([^\"]+)\""))) {
  67
+	if (cin.match(new RegExp("PHP_EXTRA_VERSION=\"([^\"]+)\""))) {
68 68
 		PHP_EXTRA_VERSION = RegExp.$1;
69 69
 		if (PHP_EXTRA_VERSION.length) {
70 70
 			PHP_VERSION_STRING += PHP_EXTRA_VERSION;

0 notes on commit 8684e74

Please sign in to comment.
Something went wrong with that request. Please try again.