From owner-freebsd-hackers Wed Oct 22 02:47:49 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id CAA19917 for hackers-outgoing; Wed, 22 Oct 1997 02:47:49 -0700 (PDT) (envelope-from owner-freebsd-hackers) Received: from seagull.cdrom.com (cracauer@seagull.cdrom.com [204.216.27.14]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id CAA19910 for ; Wed, 22 Oct 1997 02:47:47 -0700 (PDT) (envelope-from cracauer@seagull.cdrom.com) Received: (from cracauer@localhost) by seagull.cdrom.com (8.8.6/8.6.6) id CAA24135 ; Wed, 22 Oct 1997 02:46:25 -0700 (PDT) Message-ID: <19971022114622.61668@cons.org> Date: Wed, 22 Oct 1997 11:46:22 +0200 From: Martin Cracauer To: Jaye Mathisen Cc: hackers@FreeBSD.ORG Subject: Re: Is there any way to build a completely static system? References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.81 In-Reply-To: ; from Jaye Mathisen on Mon, Oct 20, 1997 at 01:44:14PM -0700 Sender: owner-freebsd-hackers@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk In , Jaye Mathisen wrote: > I mean no .so's, nothing. Just the necessare .a's, and all binaries > statically linked... > > Getting the binaries statically linked is easy, but I was hoping NOSHARED > would stop building the .so's for /usr/lib, but it seems to anyway. Look into /usr/share/mk/bsd.lib.mk Around line 115 (in 2.2.2) you find .if !defined(NOPIC) .if defined(SHLIB_MAJOR) && defined(SHLIB_MINOR) _LIBS+=lib${LIB}.so.${SHLIB_MAJOR}.${SHLIB_MINOR} .endif .if defined(INSTALL_PIC_ARCHIVE) _LIBS+=lib${LIB}_pic.a .endif .endif Although it is intended for per-library settings, I looks like globally setting option NOPIC would do what you want. If not, just delete the LIBS+= lines in bsd.lib.mk. Please let me know if it works. Martin -- %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Martin Cracauer http://www.cons.org/cracauer/ BSD User Group Hamburg/Germany http://www.bsdhh.org/