From owner-freebsd-ports@FreeBSD.ORG Wed Apr 19 17:35:43 2006 Return-Path: X-Original-To: freebsd-ports@freebsd.org Delivered-To: freebsd-ports@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 28C4D16A401 for ; Wed, 19 Apr 2006 17:35:43 +0000 (UTC) (envelope-from ler@lerctr.org) Received: from thebighonker.lerctr.org (thebighonker.lerctr.org [192.147.25.65]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8DAD443D49 for ; Wed, 19 Apr 2006 17:35:42 +0000 (GMT) (envelope-from ler@lerctr.org) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=lerami; d=lerctr.org; b=j7PEWtKAGsP22XbZHJ6QK7UPEsrYhKsLDby4vrCMO0KDuvUmNoxvBkXYO2hF9KRvU6BOkbidfPKXjvHfASYGSW2mUF4T4paIVR88ujIKqX8BYAXAKl4zXhvZ64yFmdPySI0GL7CxM2Djem3TbYIu/LeWM7xkWqh39eh2W4FdiHk=; Received: from 64-132-13-2.gen.twtelecom.net ([64.132.13.2]:49223 helo=LROSENMAC8010P) by thebighonker.lerctr.org with esmtpsa (TLSv1:RC4-MD5:128) (Exim 4.61 (FreeBSD)) (envelope-from ) id 1FWGaa-00041I-Hu; Wed, 19 Apr 2006 12:35:42 -0500 From: "Larry Rosenman" To: "'Kris Kennaway'" Date: Wed, 19 Apr 2006 12:35:07 -0500 Message-ID: <023e01c663d7$9a10d270$0202fea9@aus.pervasive.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2869 Thread-Index: AcZj1029SSuy70a8QRyErMGzU2WneQAABZjg In-Reply-To: <20060419173254.GB70979@xor.obsecurity.org> X-Spam-Score: -4.4 (----) X-LERCTR-Spam-Score: -4.4 (----) X-Spam-Report: (-4.4 points, 5.0 required) ALL_TRUSTED=-1.8 BAYES_00=-2.599 DK_POLICY_SIGNALL=0.001 X-LERCTR-Spam-Report: (-4.4 points, 5.0 required) ALL_TRUSTED=-1.8 BAYES_00=-2.599 DK_POLICY_SIGNALL=0.001 DomainKey-Status: no signature Cc: freebsd-ports@freebsd.org Subject: RE: -fPIC for a port that is just a library on amd64? 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: Wed, 19 Apr 2006 17:35:43 -0000 Kris Kennaway wrote: > On Wed, Apr 19, 2006 at 09:52:38AM -0500, Larry Rosenman wrote: >> What's the best way to get a port to add -fPIC to the compile for a >> port that generates just an archive library (textproc/libxdiff)? >> >> I was able to force the issue with CFLAGS=-fPIC make;CFLAGS=-fpic >> make install, but it would be nice if the port could do it >> automagically. > > It would be nice if the software was already correct so it happened > automatically :-) > >> The issue is that the pecl-xdiff extension uses this library and >> wants to be a shared object. > > If it's only compiling a shared library object (not static object or > other binaries), then adding CFLAGS+= -fPIC to the port makefile is > acceptable. Better, add it to the software makefile and contribute > your patch back upstream. > > Kris It's just compiling a static object (a libxdiff.a). I just submitted a patch to the port that if ${MACHINE} == amd64 I do the CFLAGS+= -fPIC but I'm not sure that's acceptable to you folks on portmgr. I have a port (pecl-xdiff) that needs to have the .a have the -fPIC :( LER -- Larry Rosenman http://www.lerctr.org/~ler Phone: +1 512-248-2683 E-Mail: ler@lerctr.org US Mail: 430 Valona Loop, Round Rock, TX 78681-3893