From owner-freebsd-ports@FreeBSD.ORG Tue Sep 9 08:50:24 2003 Return-Path: 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 18E0316A4C0 for ; Tue, 9 Sep 2003 08:50:24 -0700 (PDT) Received: from Daffy.timing.com (w.timing.com [206.168.13.218]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0066843FE5 for ; Tue, 9 Sep 2003 08:50:21 -0700 (PDT) (envelope-from jhein@timing.com) Received: from gromit.timing.com (gromit.timing.com [206.168.13.209]) by Daffy.timing.com (8.12.8p1/8.12.8) with ESMTP id h89FoKGL023392; Tue, 9 Sep 2003 09:50:20 -0600 (MDT) (envelope-from jhein@timing.com) Received: from gromit.timing.com (localhost [127.0.0.1]) by gromit.timing.com (8.12.6p2/8.12.6) with ESMTP id h89FoJoK034142; Tue, 9 Sep 2003 09:50:19 -0600 (MDT) (envelope-from jhein@gromit.timing.com) Received: (from jhein@localhost) by gromit.timing.com (8.12.6p2/8.12.6/Submit) id h89FoItk034139; Tue, 9 Sep 2003 09:50:18 -0600 (MDT) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <16221.63162.859745.570633@gromit.timing.com> Date: Tue, 9 Sep 2003 09:50:18 -0600 From: John E Hein To: Kris Kennaway In-Reply-To: <20030909153731.GC7136@rot13.obsecurity.org> References: <200309090501.h8951BVQ000324@Elmer.timing.com> <20030909153731.GC7136@rot13.obsecurity.org> X-Mailer: VM 7.03 under Emacs 21.1.1 cc: Octave maintainer Subject: Re: bad link in octave when install package using pkg_add -p X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Sep 2003 15:50:24 -0000 Kris Kennaway wrote at 08:37 -0700 on Sep 9: > > >Description: > > > > If you build a package for math/octave, then try to install > > the package to a non-default location using pkg_add -p (as > > you might if you were building a system under a different > > mount point, like a chroot), the lib/octave sym link will > > point to the wrong place. > > This is not supported. Many ports need to hard-code their > installation prefix within binaries, so there's no way in general to > make this work. I'm not talking about building with a different prefix than that which one runs the package with. Scenario: - build package with PREFIX=/usr/local (default) - install to removable media whose root it mounted at /mnt using pkg_add -p /mnt - remove media; install on different system; run package installed in /usr/local The simple fix suggested works in all cases, by the way. And that sort of sym link usage should almost always be used in preference to linking to an absolute pathname. As to pkg_add -p not being supported... I don't know what the party line is, but we use pkg_add -p all the time in this manner, and it normally works just fine. Are you saying it's deprecated?