ports/59872: bash2 should permit the user to install dynamically linked, like the base system shells.

Michael Edenfield kutulu at kutulu.org
Mon Dec 1 18:00:43 UTC 2003


>Number:         59872
>Category:       ports
>Synopsis:       bash2 should permit the user to install dynamically linked, like the base system shells.
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Mon Dec 01 10:00:37 PST 2003
>Closed-Date:
>Last-Modified:
>Originator:     Michael Edenfield
>Release:        FreeBSD 5.1-CURRENT i386
>Organization:
>Environment:
System: FreeBSD wombat.localnet 5.1-CURRENT FreeBSD 5.1-CURRENT #7: Sun Aug 24 21:35:57 EDT 2003 root at wombat.localnet:/usr/obj/usr/src/sys/ATHLON i386

>Description:

The bash2 port current only allows static linking for the port.  Since the base
system now defaults to a dynamic /bin/sh it makes sense for other shells
installed by ports to permit dynamic linking.

>How-To-Repeat:
>Fix:

Below are two options.

Option 1 tracks the user's selection of wether or not /bin/sh is dynamic and 
defaults /usr/local/bin/bash to the same option.  The user is permitted to
specify that bash be dynamic or static to override this.  I opted to use
a more global make variable, so the user can specify WITH_*_SHELLS in
make.conf and have it apply to any shell ports, which would need
similar patches, but would present a more consistant shell behavior.

--- option1.patch begins here ---
diff -urN bash2.orig/Makefile bash2/Makefile
--- bash2.orig/Makefile	Mon May 19 17:33:35 2003
+++ bash2/Makefile	Mon Dec  1 12:37:39 2003
@@ -34,7 +34,9 @@
 WRKSRC=		${WRKDIR}/bash-${PORTVERSION:C/\....$//}
 GNU_CONFIGURE=	Yes
 CONFIGURE_ARGS=	--with-installed-readline
+.if (defined(NO_DYNAMICROOT) && !defined(WITH_DYNAMIC_SHELLS)) || defined(WITH_STATIC_SHELLS)
 CONFIGURE_ENV=	LDFLAGS=-static
+.endif
 MAN1=		bash.1 bashbug.1
 
 .if defined(WITH_NET_REDIRECTIONS)
--- option1.patch ends here ---


Option 2 leaves the port essentiall as it exists today, but gives the user the
option to specifically override the static defaults.  Since the maintainer
prefers the port remain static, this option may be more palatable.  It also
avoids the debate surrounding DYNAMICROOT completely.

--- option2.patch begins here ---
diff -urN bash2.orig/Makefile bash2/Makefile
--- bash2.orig/Makefile	Mon May 19 17:33:35 2003
+++ bash2/Makefile	Mon Dec  1 12:40:50 2003
@@ -34,7 +34,9 @@
 WRKSRC=		${WRKDIR}/bash-${PORTVERSION:C/\....$//}
 GNU_CONFIGURE=	Yes
 CONFIGURE_ARGS=	--with-installed-readline
+.if !defined(WITH_DYNAMIC_SHELLS)
 CONFIGURE_ENV=	LDFLAGS=-static
+.endif
 MAN1=		bash.1 bashbug.1
 
 .if defined(WITH_NET_REDIRECTIONS)
--- option2.patch ends here ---

>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list