From owner-freebsd-ports@FreeBSD.ORG Thu Apr 15 19:55:56 2010 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CB6141065670; Thu, 15 Apr 2010 19:55:56 +0000 (UTC) (envelope-from gerald@pfeifer.com) Received: from vexpert.dbai.tuwien.ac.at (vexpert.dbai.tuwien.ac.at [128.131.111.2]) by mx1.freebsd.org (Postfix) with ESMTP id 876FB8FC1E; Thu, 15 Apr 2010 19:55:56 +0000 (UTC) Received: from acrux.dbai.tuwien.ac.at (acrux.dbai.tuwien.ac.at [128.131.111.60]) by vexpert.dbai.tuwien.ac.at (Postfix) with ESMTP id 785491E05F; Thu, 15 Apr 2010 21:55:52 +0200 (CEST) Received: by acrux.dbai.tuwien.ac.at (Postfix, from userid 1203) id AD36A1604A; Thu, 15 Apr 2010 21:55:55 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by acrux.dbai.tuwien.ac.at (Postfix) with ESMTP id 9BA5116048; Thu, 15 Apr 2010 21:55:55 +0200 (CEST) Date: Thu, 15 Apr 2010 21:55:55 +0200 (CEST) From: Gerald Pfeifer To: Greg Larkin In-Reply-To: <4BC4B44C.60006@FreeBSD.org> Message-ID: References: <4BC3E384.2090702@FreeBSD.org> <201004130436.AA01277@POLYMER5.scphys.kyoto-u.ac.jp> <4BC4B44C.60006@FreeBSD.org> User-Agent: Alpine 1.99 (LSU 1142 2008-08-13) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Cc: =?ISO-2022-JP?Q?Jouko=5FLumij=1B$BgS=1B=28Jvi?= , Tsurutani Naoki , FreeBSD Ports ML Subject: Re: CFT: print/pdftk port compiled with Java compiler from gcc 4.5 X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Apr 2010 19:55:56 -0000 On Tue, 13 Apr 2010, Greg Larkin wrote: > Ok, I see why there's a problem now. My linker hints were set up in > such a way that /usr/local/lib/gcc45 appeared before /usr/lib, so I > didn't have the libstdc++.so.6 problem. However, that's not a normal > configuration, so we have to fix this another way. > > Gerald, you ran into this problem a while back and posted a question > about it here: > http://www.mail-archive.com/freebsd-ports@freebsd.org/msg23261.html > > There are some other folks with the same problem here (old thread): > http://gcc.gnu.org/ml/gcc/2001-03/msg01069.html > > Did you ever decide on a resolution for this problem? Should I simply > create a wrapper script for pdftk that sets LD_LIBRARY_PATH, or is the > rpath solution better? The way I have addressed this for C, C++ and from what I can tell all relevant Fortran users of USE_GCC= is by setting the following CFLAGS+= -Wl,-rpath=${LOCALBASE}/lib/${_GCC_BUILD_DEPENDS} LDFLAGS+= -Wl,-rpath=${LOCALBASE}/lib/${_GCC_BUILD_DEPENDS} in Mk/bsd.gcc.mk. Apparently pdftk does not use LDFLAGS (and it not using CFLAGS for Java code is somewhat expected). Is there some similar variable we could set for Java code? JFLAG, JAVAFLAGS,...? Or could you inject the use of CFLAGS or LDFLAGS during linking? Gerald