[HPADM] Shared Library compilation

From: Ben Ketteridge (benk@proact.net)
Date: Tue Jan 14 2003 - 08:02:36 EST


Hi,

I am trying to compile the Apple WebObjects adaptor for Apache 1.3.27 on
HPUX 11, using gcc. The compile command is:
gcc -O0 -shared -DSINGLE_THREADED_ADAPTOR -DHPUX11 -DEAPI
-DFORKING_WEBSERVER -DAPACHE -I/opt/apache/include -c <filename>

The link command is:
ld +compat -b *.o -o mod_WebObjects.so

and the resulting file command gives:
mod_WebObjects.so: ELF-64 shared object file - PA-RISC 2.0 (LP64)

but when I install the adaptor in the apache libexec directory (with the
appropriate config changes to httpd.conf) I get the following:
# apachectl configtest
/usr/lib/dld.sl: Bad magic number for shared library:
/opt/apache/libexec/mod_WebObjects.so
/usr/lib/dld.sl: Exec format error
Syntax error on line 4 of /opt/apache/conf/webobjects.conf:
Cannot load /opt/apache/libexec/mod_WebObjects.so into server: Exec format
error

This appears to me to mean that I should be compiling or linking with some
other flag(s) to either get
/opt/apache/libexec/libssl.so: PA-RISC1.1 shared library -not stripped
rather than:
/opt/apache/libexec/mod_WebObjects.so: ELF-64 shared object file - PA-RISC
2.0 (LP64)

Can anyone shed any light on this, please.

Thanks in advance.

Kind Regards
Ben.

Dr Ben Ketteridge
ben.ketteridge@proact.net

PME Product Manager,
ProAct International,
PO Box 100, Denbigh, UK.
Tel: 01745 817161 ext. 330

--
             ---> Please post QUESTIONS and SUMMARIES only!! <---
        To subscribe/unsubscribe to this list, contact majordomo@dutchworks.nl
       Name: hpux-admin@dutchworks.nl     Owner: owner-hpux-admin@dutchworks.nl
 
 Archives:  ftp.dutchworks.nl:/pub/digests/hpux-admin       (FTP, browse only)
            http://www.dutchworks.nl/htbin/hpsysadmin   (Web, browse & search)


This archive was generated by hypermail 2.1.7 : Sat Apr 12 2008 - 11:02:24 EDT