| Register | FAQ | Calendar | Search | Today's Posts | Mark Forums Read |
|
#1
|
| I am trying to build php-5.2.6 on aix 6.1 using gcc 4.2.2 and cannot get it to generate libphp5.so. Is there a way I can convert the .a and ..la files to a .so? Thanks |
|
#2
|
| Mike Klein > I am trying to build php-5.2.6 on aix 6.1 using gcc 4.2.2 and cannot > get it to generate libphp5.so. Is there a way I can convert the .a and > .la files to a .so? Are you sure that you need that? On AIX, a *.a file may well be a shared library and can be used for dynamic linking. What is the result of "ar -t libphp5.a"? Yours, Laurenz Albe |
|
#3
|
| Laurenz Albe wrote: > Mike Klein >> I am trying to build php-5.2.6 on aix 6.1 using gcc 4.2.2 and cannot >> get it to generate libphp5.so. Is there a way I can convert the .a and >> .la files to a .so? > > Are you sure that you need that? > > On AIX, a *.a file may well be a shared library and can be used for > dynamic linking. > > What is the result of "ar -t libphp5.a"? My experience of late has been with 5.2.4. It's entirely likely that the build _is_ generating a .so file, and it's probably in the .libs directly. however, the php build process is so mangled that it doesn't properly manage the .a/.la targets, and fails miserably when you attempt to install. In addition, the makefile has some problems when it builds an export list and requires hand modification. My environment required this mod: BUILD_CLI = nm -pBC $$(echo $(PHP_GLOBAL_OBJS) $(PHP_CLI_OBJS) | sed 's:\([A-Za-z0-9_]*\)\.lo:.libs/\1.o:g') | grep ' [BD] ' | cut -c14- | sort -u >> php.sym && $(LIBTOOL) --mode=link $(CC) -export-dynamic $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) $(EXTRA_LDFLAGS_PROGRAM) $(LDFLAGS) -Wl,-brtl -Wl,-bE hp.sym $(PHP_RPATHS) $(PHP_GLOBAL_OBJS)$(PHP_CLI_OBJS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $(SAPI_CLI_PATH) With this modification I can get a .libs/libphp5.so build, which I then manually put into apache2/modules. I could start a rant about libtool's obfuscation, but I won't. It would also be nice if the configure command knew how to build Makefiles that didn't contain lines that were umpteen-million characters long and non-human readable. OK, sorry, that _was_ a rant. As for libphp5.a, it's probably not going to help on AIX because most programs don't understand how to dynamically load an archive member (an AIX-specific feature). And the php module is only useful in Apache/et. al., so it must be a module, not an archive. |
|
#4
|
| Gary R. Hook schrieb: > I could start a rant about libtool's obfuscation, but I won't. It would > also be nice if the configure command knew how to build Makefiles that > didn't contain lines that were umpteen-million characters long and > non-human readable. > > OK, sorry, that _was_ a rant. > This is simply the truth. libtool makes complicated things even more complicated. It is a good performance benchmark for the shell, as libtoolized make spent much CPU cycles in the shell than within the C/C++ compiler. -- Uli Link |
![]() |
| Thread Tools | |
| Display Modes | |