Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 25 May 2005 12:17:21 +0200
From:      Bjoern Koenig <bkoenig@cs.tu-berlin.de>
To:        Valerio Daelli <vdaelli@hotmail.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Statically linked bash
Message-ID:  <429450B1.4010308@cs.tu-berlin.de>
In-Reply-To: <BAY103-F23CDDFADEF19C319461BC6B00E0@phx.gbl>
References:  <BAY103-F23CDDFADEF19C319461BC6B00E0@phx.gbl>

next in thread | previous in thread | raw e-mail | index | archive | help
This is a multi-part message in MIME format.
--------------050709040302040500050501
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 8bit

Hello,

copy the attached patch to /usr/ports/shells/bash and apply it with

   patch -i Makefile-static.patch

It adds some knobs in the style of the port 'shells/bash2'. Build the 
shell with

   make -DWANT_STATIC_BASH -DWITHOUT_NLS install clean

The dependence to libintl and libiconv is the reason why your binary is 
still dynamically linked. WITHOUT_NLS solves it.

Regards Björn

--------------050709040302040500050501
Content-Type: text/x-patch;
 name="Makefile-static.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="Makefile-static.patch"

--- Makefile.orig	Wed May 25 11:51:33 2005
+++ Makefile	Wed May 25 11:54:25 2005
@@ -56,6 +56,12 @@
 			--disable-rpath \
 			--enable-disabled-builtins
 
+.if defined(WANT_STATIC_BASH) || defined(NO_DYNAMICROOT) || (defined(NOSHARED) && ( ${NOSHARED} != "no" && ${NOSHARED} != "NO" ))
+CONFIGURE_ARGS+= --enable-static-link
+.else
+CONFIGURE_ARGS+= --enable-static-link=no
+.endif
+			
 .if defined(WITHOUT_HELP)
 CONFIGURE_ARGS+=	--disable-help-builtin
 PLIST_SUB+=		HELP="@comment "

--------------050709040302040500050501--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?429450B1.4010308>