On Thu, Jan 15, 2004 at 05:16:35PM +0000, Patrick Welche wrote:
> On Thu, Jan 15, 2004 at 03:24:37PM +0000, Joe Orton wrote:
> > On Thu, Jan 15, 2004 at 03:04:37PM +0000, Patrick Welche wrote:
> > > modules.o(.data+0x4): undefined reference to `authn_file_module'
> > > ...
> > > 
> > > Have any of you seen this? My first encounter with this starts at:
> > > 
> > > http://mail.gnu.org/archive/html/libtool/2003-11/msg00120.html
> > 
> > If you remove the "-module" from MOD_LINK in build/rules.mk{,in} as Gary
> > suggests, then rebuild everything, does that help?  It clearly shouldn't
> > be there in the first place.
> 
> Then I get
> 
> /usr/src/local/httpd-2.0/srclib/apr/libtool --silent --mode=link gcc -g -O2 -pthread 
>    -L/usr/src/local/httpd-2.0/srclib/apr-util/xml/expat/lib   -o mod_authn_file.la 
> mod_authn_file.lo
> libtool: link: libtool library `mod_authn_file.la' must begin with `lib'
> 
> (I remember being stumped here before.. :( )

Yeah, you have to switch to using static convenience libraries...  Can
you try the attached patch (requires a full re-./buildconf etc)?

joe

Index: acinclude.m4
===================================================================
RCS file: /home/cvs/httpd-2.0/acinclude.m4,v
retrieving revision 1.148
diff -u -r1.148 acinclude.m4
--- acinclude.m4        9 Jan 2004 12:03:09 -0000       1.148
+++ acinclude.m4        15 Jan 2004 17:18:48 -0000
@@ -170,7 +170,7 @@
 
   if test -z "$module_standalone"; then
     if test -z "$2"; then
-      libname="mod_$1.la"
+      libname="lib$1.la"
       BUILTIN_LIBS="$BUILTIN_LIBS $modpath_current/$libname"
       modpath_static="$modpath_static $libname"
       cat >>$modpath_current/modules.mk<<EOF
Index: build/rules.mk.in
===================================================================
RCS file: /home/cvs/httpd-2.0/build/rules.mk.in,v
retrieving revision 1.15
diff -u -r1.15 rules.mk.in
--- build/rules.mk.in   15 Jan 2004 12:52:13 -0000      1.15
+++ build/rules.mk.in   15 Jan 2004 17:18:48 -0000
@@ -82,8 +82,10 @@
 # Link-related commands
 
 LINK     = $(LIBTOOL) --mode=link $(CC) $(ALL_CFLAGS) $(LT_LDFLAGS) $(ALL_LDFLAGS) -o 
$@
+# Link a shared module .la:
 SH_LINK  = $(SH_LIBTOOL) --mode=link $(CC) $(ALL_CFLAGS) $(LT_LDFLAGS) $(ALL_LDFLAGS) 
$(SH_LDFLAGS) $(CORE_IMPLIB) $(SH_LIBS) -o $@
-MOD_LINK = $(LIBTOOL) --mode=link $(CC) $(ALL_CFLAGS) -module $(LT_LDFLAGS) 
$(ALL_LDFLAGS) -o $@
+# Link a static module .la:
+MOD_LINK = $(LIBTOOL) --mode=link $(CC) -static $(ALL_CFLAGS) $(LT_LDFLAGS) 
$(ALL_LDFLAGS) -o $@
 
 # Cross compile commands
 
Index: build/special.mk
===================================================================
RCS file: /home/cvs/httpd-2.0/build/special.mk,v
retrieving revision 1.22
diff -u -r1.22 special.mk
--- build/special.mk    1 Jan 2004 13:26:16 -0000       1.22
+++ build/special.mk    15 Jan 2004 17:18:48 -0000
@@ -62,9 +62,9 @@
 INSTALL_TARGETS = install-modules
 
 install-modules:
-       @test -d $(DESTDIR)$(libexecdir) || $(MKINSTALLDIRS) $(DESTDIR)$(libexecdir);
+       @test -d $(DESTDIR)$(libexecdir) || $(MKINSTALLDIRS) $(DESTDIR)$(libexecdir)
        @builtin='$(BUILTIN_LIBS)'; \
-       has_mod_so=`echo $$builtin|sed 's/^.*mod_so.*$$/has_mod_so/'`; \
+       has_mod_so=`echo $$builtin|sed 's/^.*libso.*$$/has_mod_so/'`; \
        if [ "x$$has_mod_so" = "xhas_mod_so" ]; then \
                list='$(shared)'; \
                for i in $$list; do \

Reply via email to