From owner-freebsd-current Sat Jun 29 15:47:52 2002 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A87BA37B400 for ; Sat, 29 Jun 2002 15:47:47 -0700 (PDT) Received: from shale.csir.co.za (shale.csir.co.za [146.64.46.5]) by mx1.FreeBSD.org (Postfix) with ESMTP id B2BF343E09 for ; Sat, 29 Jun 2002 15:47:41 -0700 (PDT) (envelope-from reg@shale.csir.co.za) Received: (from reg@localhost) by shale.csir.co.za (8.11.6/8.11.6) id g5TMki792801; Sun, 30 Jun 2002 00:46:44 +0200 (SAT) (envelope-from reg) Date: Sun, 30 Jun 2002 00:46:44 +0200 From: Jeremy Lea To: Sheldon Hearn Cc: Szilveszter Adam , current@FreeBSD.ORG, taguchi@tohoku.iij.ad.jp Subject: Re: What's the right way to build XFree86-4 now? Message-ID: <20020630004644.A92462@shale.csir.co.za> References: <20020626112557.GA958@starjuice.net> <40690.1025103465@axl.seasidesoftware.co.za> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <40690.1025103465@axl.seasidesoftware.co.za>; from sheldonh@starjuice.net on Wed, Jun 26, 2002 at 04:57:45PM +0200 Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi, On Wed, Jun 26, 2002 at 04:57:45PM +0200, Sheldon Hearn wrote: > Note that this isn't quite right, because the linking gets done with > cc as a front-end, not c++. But the job gets done, all the same, > and I'm not writing a SharedDepCplusplusLibraryTarget rule myself. > :-) How about: --- config/cf/bsdLib.rules.orig Sun Jun 30 00:30:05 2002 +++ config/cf/bsdLib.rules Sun Jun 30 00:31:06 2002 @@ -306,6 +306,34 @@ #endif /* SharedDepLibraryTarget */ +/* + * SharedDepCplusplusLibraryTarget - generate rules to create a shared library. + */ +#ifndef SharedDepCplusplusLibraryTarget +#define SharedDepCplusplusLibraryTarget(libname,rev,deplist,solist,down,up) @@\ +AllTarget(Concat(lib,libname.so.rev)) @@\ + @@\ +Concat(lib,libname.so.rev): deplist @@\ + $(RM) $@~ @@\ + @SONAME=`echo $@ | sed 's/\.[^\.]*$$//'`; set -x; \ @@\ + (cd down; $(CXX) -o up/$@~ $(SHLIBLDFLAGS) -Wl,-soname,$$SONAME solist $(REQUIREDLIBS) BaseShLibReqs); \ @@\ + $(RM) $$SONAME; $(LN) $@ $$SONAME; \ @@\ + LinkBuildSonameLibrary($$SONAME) @@\ + $(RM) $@ @@\ + $(MV) $@~ $@ @@\ + $(RM) Concat(lib,libname.so) @@\ + $(LN) $@ Concat(lib,libname.so) @@\ + LinkBuildLibrary($@) @@\ + LinkBuildLibrary(Concat(lib,libname.so)) @@\ + @@\ +clean:: @@\ + @SONAME=`echo Concat(lib,libname.so.rev) | sed 's/\.[^\.]*$$//'`; \ @@\ + set -x; $(RM) $$SONAME @@\ + $(RM) Concat(lib,libname.so) @@\ + $(RM) Concat(lib,libname.so.rev) + +#endif /* SharedDepCplusplusLibraryTarget */ + #ifndef SharedDepModuleTarget #define SharedDepModuleTarget(name,deps,solist) @@\ AllTarget(name) @@\ Just copied from the SharedDepLibraryTarget above it, and replaced the CC with CXX... I built libGLU.so.1 with this, and it seemed to fix the glxinfo linking problem. I'm currently testing... Regards, -Jeremy -- FreeBSD - Because the best things in life are free... http://www.freebsd.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message