cvs: /php4 php4.spec.in /php4 .cvsignore acinclude.m4 configure.in.in /php4/scripts mkextlib.in
| From: | Stig Bakken | Date: | Sat, 24 Jul 1999 19:02:38 +0000 |
| Subject: | cvs: /php4 php4.spec.in /php4 .cvsignore acinclude.m4 configure.in.in /php4/scripts mkextlib.in | ||
| Groups: | php.version4 | ||
| Request: | Send a blank email to php-version4+get-2695@lists.php.net to get a copy of this message | ||
ssb Sat Jul 24 15:02:38 1999 EDT
Added files:
/php4 php4.spec.in
Modified files:
/php4 .cvsignore acinclude.m4 configure.in.in
/php4/scripts mkextlib.in
Log:
added workaround for Solaris PIC weirdness.
added RPM spec file for a future "official" RPM, work-in-progress
Index: php4/.cvsignore
diff -u php4/.cvsignore:1.11 php4/.cvsignore:1.12
--- php4/.cvsignore:1.11 Fri Jul 23 17:24:53 1999
+++ php4/.cvsignore Sat Jul 24 15:02:37 1999
@@ -20,3 +20,4 @@
acconfig.h
internal_functions.c
libtool
+php4.spec
Index: php4/acinclude.m4
diff -u php4/acinclude.m4:1.20 php4/acinclude.m4:1.21
--- php4/acinclude.m4:1.20 Wed Jul 21 17:56:24 1999
+++ php4/acinclude.m4 Sat Jul 24 15:02:37 1999
@@ -1,4 +1,4 @@
-dnl $Id: acinclude.m4,v 1.20 1999/07/21 21:56:24 ssb Exp $
+dnl $Id: acinclude.m4,v 1.21 1999/07/24 19:02:37 ssb Exp $
dnl
dnl This file contains local autoconf functions.
@@ -158,3 +158,27 @@
AC_SUBST(EXTINFO_DEPS)
dnl AC_SUBST(EXT_INCLUDE_CODE)
dnl AC_SUBST(EXT_MODULES_PTRS)
+
+dnl
+dnl Solaris requires main code to be position independent in order
+dnl to let shared objects find symbols. Weird. Ugly.
+dnl
+dnl Must be run after all --with-NN options that let the user
+dnl choose dynamic extensions, and after the gcc test.
+dnl
+AC_DEFUN(PHP_SOLARIS_PIC_WEIRDNESS,[
+ AC_MSG_CHECKING(whether -fPIC is required)
+ if test "$EXT_SHARED" != ""; then
+ os=
uname -sr 2>/dev/null
+ case "$os" in
+ "SunOS 5"*)
+ case "$CC" in
+ gcc*|egcs*) CFLAGS="$CFLAGS -fPIC";;
+ *) CFLAGS="$CFLAGS -fpic";;
+ esac
+ AC_MSG_RESULT(yes);;
+ *)
+ AC_MSG_RESULT(no);;
+ esac
+ fi
+])
Index: php4/configure.in.in
diff -u php4/configure.in.in:1.60 php4/configure.in.in:1.61
--- php4/configure.in.in:1.60 Fri Jul 23 11:29:57 1999
+++ php4/configure.in.in Sat Jul 24 15:02:37 1999
@@ -1,4 +1,4 @@
-dnl $Id: configure.in.in,v 1.60 1999/07/23 15:29:57 ssb Exp $ -*- sh -*-
+dnl $Id: configure.in.in,v 1.61 1999/07/24 19:02:37 ssb Exp $ -*- sh -*-
dnl Process this file with autoconf to produce a configure script.
divert(0)
@@ -29,10 +29,9 @@
if test "$threadsafe" = "yes"; then
(set -x; test -d TSRM || mkdir TSRM; cd TSRM; $cwd/$srcdir/TSRM/configure --cache-file=$cachefile
$@)
fi
+ (set -x; cd $srcdir; sh ltconfig --disable-static --enable-dlopen --cache-file=$cachefile
ltmain.sh)
fi
-(set -x; cd $srcdir; sh ltconfig --disable-static --enable-dlopen --cache-file=$cachefile
ltmain.sh)
-
dnl ## Diversion 1 is the initial checking of OS features, programs,
dnl ## libraries and so on.
@@ -53,8 +52,6 @@
dnl ## This is where the version number is changed from now on!
AM_INIT_AUTOMAKE(php, 4.0b2-dev)
-
-
PHP_VERSION=$VERSION
echo "/* automatically generated by configure */" > php_version.h.new
echo "/* edit configure.in.in to change version number */" >> php_version.h.new
@@ -873,6 +870,9 @@
dnl If we are using gcc add -fpic to make dl() work on some platforms
dnl test -n "$GCC" && CFLAGS="$CFLAGS -fpic"
+dnl add -fPIC option on Solaris if we are building dynamic extensions
+PHP_SOLARIS_PIC_WEIRDNESS
+
AC_SUBST(CFLAGS)
AC_SUBST(PROG_SENDMAIL)
AC_SUBST(CFLAGS_SHLIB)
@@ -889,7 +889,7 @@
PHP_OS=uname
AC_DEFINE_UNQUOTED(PHP_OS,"$PHP_OS")
-AC_OUTPUT(Makefile libphp4.module
+AC_OUTPUT(Makefile libphp4.module php4.spec
scripts/mkextlib regex/Makefile
@@EXT_MAKEFILES@@ build-defs.h, [
], [
Index: php4/scripts/mkextlib.in
diff -u php4/scripts/mkextlib.in:1.2 php4/scripts/mkextlib.in:1.3
--- php4/scripts/mkextlib.in:1.2 Sun Apr 18 14:06:54 1999
+++ php4/scripts/mkextlib.in Sat Jul 24 15:02:38 1999
@@ -14,3 +14,4 @@
done
(set -x; $top_srcdir/scripts/armerge $outfile $ext_libs)
+exit 0