[PHP-DEV] Libtool problem with current build process

2001-07-09 Thread Jason Greene

Sascha + Everyone,

There is a current build problem with libtool where we pass -prefer-non-pic or 
-prefer-pic during mode=link.
Since this is not a valid mode=link option it gets passed to the linker as an option. 
On some platforms (Sun CC),
this cuases an error and aborts. I started to take a look at making a fix, but the 
build system is quite large, and
since I don't feel like breaking, I decided to just email my progress, and see what 
else should be accounted for.

This tiny patch is part of some changes that I think should be made. This changes the 
standard_libtool_flag,
which just gets added to CFLAGS, to using a compile_libtool_flag, and exporting it out 
so that all the other pieces
of the system can use it.

Thanks,
-Jason


===
RCS file: /repository/php4/configure.in,v
retrieving revision 1.258
diff -u -r1.258 configure.in
--- configure.in 2001/07/04 10:10:29 1.258
+++ configure.in 2001/07/09 21:58:22
@@ -658,7 +658,8 @@
 
 case $php_build_target in
 program|static)
-standard_libtool_flag='-prefer-non-pic -static'
+compile_libtool_flag='-prefer-non-pic'
+standard_libtool_flage='--static'
 if test $lib_build_shared != yes; then
 enable_shared=no
 fi
@@ -667,7 +668,7 @@
 ;;
 shared)
 enable_static=no
-standard_libtool_flag=-prefer-pic
+compile_libtool_flag=-prefer-pic
 EXTRA_LDFLAGS=$EXTRA_LDFLAGS -avoid-version
 ;;
 esac
@@ -824,6 +825,7 @@
 PHP_SUBST(localstatedir)
 PHP_SUBST(datadir)
 PHP_SUBST(sysconfdir)
+PHP_SUBST(compile_libtool_flag)
 
 PHP_SUBST(AWK)
 PHP_SUBST(CC)



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] Libtool problem with current build process

2001-07-09 Thread Sascha Schumann

On Mon, 9 Jul 2001, Jason Greene wrote:

 Sascha + Everyone,

 There is a current build problem with libtool where we pass
 -prefer-non-pic or -prefer-pic during mode=link.  Since this is
 not a valid mode=link option it gets passed to the linker as an
 option. On some platforms (Sun CC), this cuases an error and
 aborts. I started to take a look at making a fix, but the build
 system is quite large, and since I don't feel like breaking, I
 decided to just email my progress, and see what else should be
 accounted for.

 This tiny patch is part of some changes that I think should be
 made. This changes the standard_libtool_flag, which just gets
 added to CFLAGS, to using a compile_libtool_flag, and exporting
 it out so that all the other pieces of the system can use it.

The main problem here is that we need to add the -prefer*pic
options to CFLAGS, or otherwise it won't get used by the
automake Makefiles.  I'd be happy to hear a solution for that
which does not involve throwing out automake as I personally
don't have the time for that currently.

- Sascha Experience IRCG
  http://schumann.cx/http://schumann.cx/ircg


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]