libapreq-1.1 SEGV's on AIX

2003-05-30 Thread Steven M. Carter

I've seen other posts mentioning this, but no solutions.  I am trying to
compile libapreq-1., on AIX 5.1, with perl-5.8.0 compiled with gcc 3.3. 
GCC 3.3 was the only thing that I could get to compile perl on AIX
without failing any tests.  When I try to compile libapreq-1.1, I get:

rm -f ../blib/arch/auto/Apache/Request/Request.so
LD_RUN_PATH=/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/Request/../blib/arch/auto/libapreq
 gcc  -Wl,-bhalt:4 -Wl,-bM:SRE -Wl,-bI:/opt/public/perl/lib/5.8.0/aix/CORE/perl.exp 
-Wl,-bE:Request.exp -Wl,-bnoentry -lc Request.o 
-bI:/.../dce.ccs.ornl.gov/fs/.rw/prod/rs_aix51/usr/local/perl/lib/site_perl/5.8.0/aix/auto/Apache/mod_perl.exp
 -o ../blib/arch/auto/Apache/Request/Request.so   
-L/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/Request/../blib/arch/auto/libapreq
 -lapreq  
gcc: `-b' must come at the start of the command line
make[1]: *** [../blib/arch/auto/Apache/Request/Request.so] Error 1
make[1]: Leaving directory
`/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/Request'
make: *** [subdirs] Error 2

I fix this by adding '-Wl,' before the '-bI:'.  I assume this is because
I compiled with gcc and it needs the '-Wl,' directive.

Then I get a bunch of undefined symbols so I add
'-Wl,-bI:.../apache/libexec/httpd.exp'.  This takes care of the
problem and everything compiles cleanly.

However, the make test fails:

make[1]: Entering directory
`/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/c'
make[1]: Leaving directory
`/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/c'
make[1]: Entering directory
`/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/Request'
make[1]: Leaving directory
`/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/Request'
make[1]: Entering directory
`/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/Cookie'
make[1]: Leaving directory
`/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/Cookie'
t/httpd -f `pwd`/t/httpd.conf
make: *** [start_httpd] Segmentation fault (core dumped)

I've tried different compilers with libapreq and perl, and I've tried
mod_perl built in and as a DSO.  All seem to lead me to the same place. 
I can run simple perl scripts under mod_perl, but non that use libapreq.

Here are the particulars of my perl:

Summary of my perl5 (revision 5.0 version 8 subversion 0) configuration:
  Platform:
osname=aix, osvers=5.1.0.0, archname=aix
uname='aix cheetah1617 1 5 000fd42f4c00 '
config_args='-des -Dcc=gcc -Dprefix=/opt/public/perl -Dlibpth=/lib
/usr/lib /usr/ccs/lib -Dlocincpth=/opt/public/gnu/include -Uloclibpth
-Uinstallusrbinperl'
hint=recommended, useposix=true, d_sigaction=define
usethreads=undef use5005threads=undef useithreads=undef
usemultiplicity=undef
useperlio=define d_sfio=undef uselargefiles=define usesocks=undef
use64bitint=undef use64bitall=undef uselongdouble=undef
usemymalloc=n, bincompat5005=undef
  Compiler:
cc='gcc', ccflags ='-D_ALL_SOURCE -D_ANSI_C_SOURCE -D_POSIX_SOURCE
-DUSE_NATIVE_DLOPEN -fno-strict-aliasing -D_LARGE_FILES',
optimize='-O',
cppflags='-D_ALL_SOURCE -D_ANSI_C_SOURCE -D_POSIX_SOURCE
-DUSE_NATIVE_DLOPEN -fno-strict-aliasing'
ccversion='', gccversion='3.3', gccosandvers='aix5.1.0.0'
intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=4321
d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=8
ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t',
lseeksize=8
alignbytes=8, prototype=define
  Linker and Libraries:
ld='gcc', ldflags =' -Wl,-brtl -Wl,-b32'
libpth=/lib /usr/lib /usr/ccs/lib
libs=-lbind -lnsl -lgdbm -ldbm -ldl -lld -lm -lc -lcrypt -lbsd -lPW
perllibs=-lbind -lnsl -ldl -lld -lm -lc -lcrypt -lbsd -lPW
libc=/lib/libc.a, so=a, useshrplib=false, libperl=libperl.a
gnulibc_version=''
  Dynamic Linking:
dlsrc=dl_aix.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Xlinker
-bE:/opt/public/perl/lib/5.8.0/aix/CORE/perl.exp'
cccdlflags=' ', lddlflags='  -Wl,-bhalt:4 -Wl,-bM:SRE
-Wl,-bI:$(PERL_INC)/perl.exp -Wl,-bE:$(BASEEXT).exp -Wl,-bnoentry -lc'


Characteristics of this binary (from libperl): 
  Compile-time options: USE_LARGE_FILES
  Built under aix
  Compiled at May 27 2003 16:37:44
  @INC:
/opt/public/perl/lib/5.8.0/aix
/opt/public/perl/lib/5.8.0
/opt/public/perl/lib/site_perl/5.8.0/aix
/opt/public/perl/lib/site_perl/5.8.0
/opt/public/perl/lib/site_perl
.

Thanks,

Steven.

-- 
Steven M. Carter [EMAIL PROTECTED]
Oak Ridge National Laboratory



Re: libapreq-1.1 SEGV's on AIX

2003-05-30 Thread Ged Haywood
Hi there,

On Thu, 29 May 2003, Steven M. Carter wrote:

There's a thread here:

http://www.geocrawler.com/archives/3/182/2000/2/0/3376687/

in which Doug MacEachern says:

I don`t expect libapreq (or any of the Apache:: xs modules outside of
the mod_perl dist)  to work under aix. it needs to point at the apache and
mod_perl .exp files to link properly.  I don`t have access to an aix box
at the moment, maybe one of our aix experts can help here?  a patch to
Apache::src would be ideal so all the Apache:: xs modules on cpan can use
it.  the Apache:: xs modules that ship with mod_perl don`t have this
problem because they are all linked static by default.

I have no idea if anything ever came of this.

HTH

73,
Ged.



Re: libapreq-1.1 SEGV's on AIX

2003-05-30 Thread Stas Bekman
[taking this thread to the apreq-dev list, those interested please go there]

Steven M. Carter wrote:
I've seen other posts mentioning this, but no solutions.  I am trying to
compile libapreq-1., on AIX 5.1, with perl-5.8.0 compiled with gcc 3.3. 
GCC 3.3 was the only thing that I could get to compile perl on AIX
without failing any tests.  When I try to compile libapreq-1.1, I get:

rm -f ../blib/arch/auto/Apache/Request/Request.so
LD_RUN_PATH=/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/Request/../blib/arch/auto/libapreq gcc  -Wl,-bhalt:4 -Wl,-bM:SRE -Wl,-bI:/opt/public/perl/lib/5.8.0/aix/CORE/perl.exp -Wl,-bE:Request.exp -Wl,-bnoentry -lc Request.o -bI:/.../dce.ccs.ornl.gov/fs/.rw/prod/rs_aix51/usr/local/perl/lib/site_perl/5.8.0/aix/auto/Apache/mod_perl.exp -o ../blib/arch/auto/Apache/Request/Request.so   -L/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/Request/../blib/arch/auto/libapreq -lapreq  
gcc: `-b' must come at the start of the command line
make[1]: *** [../blib/arch/auto/Apache/Request/Request.so] Error 1
make[1]: Leaving directory
`/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/Request'
make: *** [subdirs] Error 2

I fix this by adding '-Wl,' before the '-bI:'.  I assume this is because
I compiled with gcc and it needs the '-Wl,' directive.
Then I get a bunch of undefined symbols so I add
'-Wl,-bI:.../apache/libexec/httpd.exp'.  This takes care of the
problem and everything compiles cleanly.
However, the make test fails:

make[1]: Entering directory
`/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/c'
make[1]: Leaving directory
`/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/c'
make[1]: Entering directory
`/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/Request'
make[1]: Leaving directory
`/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/Request'
make[1]: Entering directory
`/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/Cookie'
make[1]: Leaving directory
`/.../dce.ccs.ornl.gov/fs/users/u003/scarter/compile/aix_51/libapreq-1.1/Cookie'
t/httpd -f `pwd`/t/httpd.conf
make: *** [start_httpd] Segmentation fault (core dumped)
I've tried different compilers with libapreq and perl, and I've tried
mod_perl built in and as a DSO.  All seem to lead me to the same place. 
I can run simple perl scripts under mod_perl, but non that use libapreq.

Here are the particulars of my perl:

Summary of my perl5 (revision 5.0 version 8 subversion 0) configuration:
  Platform:
osname=aix, osvers=5.1.0.0, archname=aix
uname='aix cheetah1617 1 5 000fd42f4c00 '
config_args='-des -Dcc=gcc -Dprefix=/opt/public/perl -Dlibpth=/lib
/usr/lib /usr/ccs/lib -Dlocincpth=/opt/public/gnu/include -Uloclibpth
-Uinstallusrbinperl'
hint=recommended, useposix=true, d_sigaction=define
usethreads=undef use5005threads=undef useithreads=undef
usemultiplicity=undef
useperlio=define d_sfio=undef uselargefiles=define usesocks=undef
use64bitint=undef use64bitall=undef uselongdouble=undef
usemymalloc=n, bincompat5005=undef
  Compiler:
cc='gcc', ccflags ='-D_ALL_SOURCE -D_ANSI_C_SOURCE -D_POSIX_SOURCE
-DUSE_NATIVE_DLOPEN -fno-strict-aliasing -D_LARGE_FILES',
optimize='-O',
cppflags='-D_ALL_SOURCE -D_ANSI_C_SOURCE -D_POSIX_SOURCE
-DUSE_NATIVE_DLOPEN -fno-strict-aliasing'
ccversion='', gccversion='3.3', gccosandvers='aix5.1.0.0'
intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=4321
d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=8
ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t',
lseeksize=8
alignbytes=8, prototype=define
  Linker and Libraries:
ld='gcc', ldflags =' -Wl,-brtl -Wl,-b32'
libpth=/lib /usr/lib /usr/ccs/lib
libs=-lbind -lnsl -lgdbm -ldbm -ldl -lld -lm -lc -lcrypt -lbsd -lPW
perllibs=-lbind -lnsl -ldl -lld -lm -lc -lcrypt -lbsd -lPW
libc=/lib/libc.a, so=a, useshrplib=false, libperl=libperl.a
gnulibc_version=''
  Dynamic Linking:
dlsrc=dl_aix.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Xlinker
-bE:/opt/public/perl/lib/5.8.0/aix/CORE/perl.exp'
cccdlflags=' ', lddlflags='  -Wl,-bhalt:4 -Wl,-bM:SRE
-Wl,-bI:$(PERL_INC)/perl.exp -Wl,-bE:$(BASEEXT).exp -Wl,-bnoentry -lc'
Characteristics of this binary (from libperl): 
  Compile-time options: USE_LARGE_FILES
  Built under aix
  Compiled at May 27 2003 16:37:44
  @INC:
/opt/public/perl/lib/5.8.0/aix
/opt/public/perl/lib/5.8.0
/opt/public/perl/lib/site_perl/5.8.0/aix
/opt/public/perl/lib/site_perl/5.8.0
/opt/public/perl/lib/site_perl
.

Thanks,

Steven.



--

__
Stas BekmanJAm_pH -- Just Another mod_perl Hacker
http://stason.org/ mod_perl Guide --- http://perl.apache.org
mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com
http://modperlbook.org