develooper Front page | perl.perl5.porters | Postings from June 2008

Re: [perl #54952] Building 5.6.2 Fails with -Duseshrplib on Leopard

Thread Previous | Thread Next
From:
Andy Dougherty
Date:
June 4, 2008 06:20
Subject:
Re: [perl #54952] Building 5.6.2 Fails with -Duseshrplib on Leopard
Message ID:
Pine.LNX.4.64.0806040854320.5234@fractal.phys.lafayette.edu
On Wed, 4 Jun 2008, Dominic Dunlop wrote:

> On 2008–05–28, at 08:07, David Wheeler (via RT) wrote:
> 
> > I tried to build 5.6.2 on Mac OS X 10.5.2 with this configuration:
> > 
> > sh Configure -des -Duseshrplib -Dprefix=/usr/local/perl-5.6.2
> > 
> > It failed during `make` with these errors: ...
> 
> 
> Just reporting a negative data point: as hints/darwin.sh has been preened
> since 5.6.2 and some of the preening touches on shared libraries, I tried
> dropping that file from the 5.10.0 release into the 5.6.2 source tree, then
> building with your command line. No change in failure symptoms. Damn...

Ah, ok.  Looking at the differences between 5.6.2's Makefile.SH and 
5.10.x's Makefile.SH, it looks like this problem is indeed due to 
how Mac OS handles name resolution.  As I speciulated previously,

> Specifically,
> it looks like it's picking up the version of Perl_ck_glob() from op.o
> (which is inside libperl.dylib) instead of the version in opmini.o,
> which is linked directly to miniperl.  There may be some appropriate
> linker flag we can use to suppress that behavior.  Or, perhaps, we need
> to build miniperl by directly linking against all the objects instead
> of linking against libperl.dylib.

It looks like bleadperl currently tries both of those things on
different platforms.

It looks to me as if this might work.  It simply links miniperl against
the explicit objects, instead of trying to link against libperl.dylib.

--- Makefile.SH.5.6.2	2003-11-09 18:44:12.000000000 -0500
+++ Makefile.SH	2008-06-04 09:16:30.000000000 -0400
@@ -493,9 +493,10 @@
 		;;
 	*)
 		$spitshell >>Makefile <<'!NO!SUBS!'
-miniperl: $& miniperlmain$(OBJ_EXT) $(LIBPERL) opmini$(OBJ_EXT)
+miniperl: $& miniperlmain$(OBJ_EXT) $(obj) opmini$(OBJ_EXT)
 	$(LDLIBPTH) $(CC) $(CLDFLAGS) -o miniperl \
-	    miniperlmain$(OBJ_EXT) opmini$(OBJ_EXT) $(LLIBPERL) $(libs)
+	    `echo $(obj) | sed 's/ op$(OBJ_EXT) / /'` \
+	    miniperlmain$(OBJ_EXT) opmini$(OBJ_EXT) perl$(OBJ_EXT) $(libs)
 	$(LDLIBPTH) ./miniperl -w -Ilib -MExporter -e '<?>' || $(MAKE) minitest
 !NO!SUBS!
 		;;


-- 
    Andy Dougherty		doughera@lafayette.edu

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About