Well, I have only used the apxs DSO style build previously and did not
notice that for linking modperl statically into httpd (apaci style)
there are small problems due to the AIX specifix .exp file business. The
following patch fixes this, in particular it adds the mod_perl.exp file
as an export file while httpd is linked to export the extra symbols from
modperl needed by libapreq and Embperl. It also adds logic to
Apache::src to find the httpd.exp if modperl is not a DSO.

While doing that I noticed that mod_include if built as DSO for PERL_SSI
needs to reference the perl symbols but the build procedure does only
reference the httpd.exp file and not the perl.exp file, so this will not
work yet. I had to use a config like this:

perl Makefile.PL EVERYTHING=1 DO_HTTPD=1 USE_APACI=1 \
        APACI_ARGS="--enable-module=most --enable-shared=max --disable-shared=perl 
--disable-shared=include"

I also tested the build procedure using the apxs tool like this:

perl Makefile.PL USE_APXS=1 EVERYTHING=1 WITH_APXS=/usr/local/apache/bin/apxs

this still works but has the problem of the memory leak at server
restart.

-- 
Jens-Uwe Mager

HELIOS Software GmbH
Steinriede 3
30827 Garbsen
Germany

Phone:          +49 5131 709320
FAX:            +49 5131 709325
Internet:       [EMAIL PROTECTED]
Index: apaci/mod_perl.config.sh
===================================================================
RCS file: /home/cvspublic/modperl/apaci/mod_perl.config.sh,v
retrieving revision 1.18
diff -u -d -r1.18 mod_perl.config.sh
--- apaci/mod_perl.config.sh    2000/03/31 05:16:05     1.18
+++ apaci/mod_perl.config.sh    2000/08/23 22:29:50
@@ -147,6 +147,13 @@
 print $ldopts;
 EOT
 perl_libs="`$perl_interp $tmpfile2 $perl_libperl`"
+if test $build_type = OBJ
+then
+       case "$os_version" in
+           aix*)  perl_libs="$perl_libs -bE:\$(SRCDIR)/modules/perl/mod_perl.exp" ;;
+           * )    ;;
+       esac
+fi
 perl_inc="`$perl_interp -MConfig -e 'print "$Config{archlibexp}/CORE"'`"
 perl_privlibexp="`$perl_interp -MConfig -e 'print $Config{privlibexp}'`"
 perl_archlibexp="`$perl_interp -MConfig -e 'print $Config{archlibexp}'`"
Index: lib/Apache/src.pm
===================================================================
RCS file: /home/cvspublic/modperl/lib/Apache/src.pm,v
retrieving revision 1.26
diff -u -d -r1.26 src.pm
--- lib/Apache/src.pm   2000/06/05 18:16:33     1.26
+++ lib/Apache/src.pm   2000/08/23 22:29:51
@@ -258,7 +258,12 @@
            push @ldflags, "-bI:" . $file;
        }
        my $httpdexp = $self->apxs("-q" => 'LIBEXECDIR') . "/httpd.exp";
-       push @ldflags, "-bI:$httpdexp" if -e $httpdexp;
+       if (-e $httpdexp) {
+               push @ldflags, "-bI:$httpdexp";
+       } else {
+               $httpdexp = $self->dir . "/support/httpd.exp";
+               push @ldflags, "-bI:$httpdexp" if -e $httpdexp;
+       }
     }
     return join(' ', @ldflags);
 }

Reply via email to