On Wed, 12 May 2004, Olivier Hill wrote: > Over a year ago, Rasmus and Ilia had a discussion on the list about > building the Apache DSO with non-PIC code. > > My question is, what is the easiest way to build with --prefer-non-pic > using a release tarball? Would it be possible to add a ./configure > option, because right now I'm editing files manually.
Well, the following is what needs to be changed. I have not had the mental energy to figure out the magic incantation to get a configure flag to do this: --- acinclude.m4.orig Tue Nov 11 13:36:31 2003 +++ acinclude.m4 Tue Nov 11 13:35:57 2003 @@ -777,10 +777,10 @@ php_lo=o shared_c_pre='$(LIBTOOL) --mode=compile $(CC)' - shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) -prefer-pic' + shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) -prefer-non-pic' shared_c_post= shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)' - shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) -prefer-pic' + shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) -prefer-non-pic' shared_cxx_post= shared_lo=lo @@ -1166,7 +1166,7 @@ \$(LIBTOOL) --mode=install cp $3/$1.la \$(phplibdir) $3/$1.la: \$($2) \$(translit($1,a-z_-,A-Z__)_SHARED_DEPENDENCIES) - \$(LIBTOOL) --mode=link ifelse($4,,[\$(CC)],[\$(CXX)]) \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) -o \[$]@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$($2) \$(translit($1,a-z_-,A-Z__)_SHARED_LIBADD) + \$(LIBTOOL) --mode=link ifelse($4,,[\$(CC)],[\$(CXX)]) \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) -o \[$]@ -export-dynamic -avoid-version -prefer-non-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$($2) \$(translit($1,a-z_-,A-Z__)_SHARED_LIBADD) EOF ]) Index: configure.in =================================================================== RCS file: /repository/php-src/configure.in,v retrieving revision 1.396.2.61 diff -u -p -w -r1.396.2.61 configure.in --- configure.in 30 Jul 2003 13:20:49 -0000 1.396.2.61 +++ configure.in 4 Aug 2003 20:26:23 -0000 @@ -818,7 +818,7 @@ program|static) ;; shared) enable_static=no - standard_libtool_flag=-prefer-pic + standard_libtool_flag=-prefer-non-pic EXTRA_LDFLAGS="$EXTRA_LDFLAGS -avoid-version -module" ;; esac -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php