summaryrefslogtreecommitdiff
path: root/shells
diff options
context:
space:
mode:
authorDavid E. O'Brien <obrien@FreeBSD.org>2009-03-11 07:40:54 +0000
committerDavid E. O'Brien <obrien@FreeBSD.org>2009-03-11 07:40:54 +0000
commit20c29710fafe7b8b04a1ef79eab4aa5f4223acb9 (patch)
tree822c8efca688bc6ee68085a4586068854082d953 /shells
parent- Update to 0.9.8 (diff)
Resurrect the 'bash3' port as a holder of the legacy BASH version 3.x.
Notes
Notes: svn path=/head/; revision=229864
Diffstat (limited to 'shells')
-rw-r--r--shells/bash3/Makefile136
-rw-r--r--shells/bash3/distinfo149
-rw-r--r--shells/bash3/files/patch-config-top.h24
-rw-r--r--shells/bash3/files/patch-doc::Makefile.in18
-rw-r--r--shells/bash3/files/patch-doc::bash.120
-rw-r--r--shells/bash3/files/patch-doc::bashref.texi28
-rw-r--r--shells/bash3/files/patch-lib::readline::display.c24
-rw-r--r--shells/bash3/files/xpatch-colonbreakswords179
-rw-r--r--shells/bash3/files/xpatch-implicitcd99
-rw-r--r--shells/bash3/pkg-deinstall33
-rw-r--r--shells/bash3/pkg-descr7
-rw-r--r--shells/bash3/pkg-install27
-rw-r--r--shells/bash3/pkg-plist84
13 files changed, 828 insertions, 0 deletions
diff --git a/shells/bash3/Makefile b/shells/bash3/Makefile
new file mode 100644
index 000000000000..8cf4684c6b33
--- /dev/null
+++ b/shells/bash3/Makefile
@@ -0,0 +1,136 @@
+# ex:ts=8
+# New ports collection makefile for: bash3
+# Date created: 30 Jul 2004
+# Whom: Oliver Eikemeier
+#
+# $FreeBSD$
+#
+
+PORTNAME= bash
+PATCHLEVEL= 48
+PORTVERSION= 3.2.${PATCHLEVEL:S/^0//g}
+PORTREVISION?= 1
+CATEGORIES= shells
+MASTER_SITES= ${MASTER_SITE_GNU:S/$/:bash/} \
+ ftp://ftp.cwru.edu/pub/%SUBDIR%/:faq
+MASTER_SITE_SUBDIR= ${PORTNAME}/:bash,faq
+DISTNAME= ${PORTNAME}-${PORTVERSION:R}
+DISTFILES= ${DISTNAME}${EXTRACT_SUFX}:bash
+DIST_SUBDIR= ${PORTNAME}
+EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX}
+
+PATCH_SITES= ${MASTER_SITE_GNU} \
+ ftp://ftp.cwru.edu/pub/%SUBDIR%/
+PATCH_SITE_SUBDIR= ${PORTNAME}/${DISTNAME}-patches/
+PATCHFILES!= /usr/bin/jot -s " " -w \
+ ${PORTNAME}${PORTVERSION:R:S/.//g}-%03d \
+ ${PATCHLEVEL} 1 ${PATCHLEVEL}
+
+MAINTAINER= obrien@FreeBSD.org
+COMMENT= The GNU Project's Bourne Again SHell
+
+IGNOREFILES= FAQ
+CONFLICTS= bash-[0-24-9].*
+
+.if !defined(WITHOUT_IMPLICITCD)
+EXTRA_PATCHES+= ${PATCHDIR}/xpatch-implicitcd
+.endif
+
+.if !defined(WITHOUT_COLONBREAKSWORDS)
+EXTRA_PATCHES+= ${PATCHDIR}/xpatch-colonbreakswords
+.endif
+
+MAN1= bash.1 bashbug.1
+INFO= bash
+
+GNU_CONFIGURE= yes
+
+.if !defined(NOPORTDOCS)
+.if !defined(WITH_INCLUDED_FAQ)
+DISTFILES+= FAQ:faq
+.endif
+PORTDOCS= FAQ INTRO CHANGES COMPAT NEWS POSIX RBASH
+.endif
+
+CONFIGURE_ARGS= --without-bash-malloc \
+ --disable-rpath \
+ --enable-disabled-builtins
+
+.if defined(WITH_STATIC_BASH) || defined(NO_DYNAMICROOT) || (defined(NOSHARED) && ${NOSHARED:L} != "no")
+.if !defined(WITHOUT_NLS)
+WITHOUT_NLS=yes
+.endif
+CONFIGURE_ARGS+= --enable-static-link
+PKGNAMESUFFIX= -static
+CONFLICTS+= bash-[0-9]*
+.else
+CONFIGURE_ARGS+= --enable-static-link=no
+CONFLICTS+= bash-static-[0-9]*
+.endif
+
+.if defined(WITHOUT_HELP)
+CONFIGURE_ARGS+= --disable-help-builtin
+PLIST_SUB+= HELP="@comment "
+.elif defined(WITH_INTEGRATED_HELPFILES)
+PLIST_SUB+= HELP="@comment "
+.else
+CONFIGURE_ARGS+= --enable-separate-helpfiles
+PLIST_SUB+= HELP=""
+.endif
+
+.if defined(WITHOUT_NLS)
+CONFIGURE_ARGS+= --disable-nls
+PLIST_SUB+= NLS="@comment "
+.else
+USE_GETTEXT= yes
+PLIST_SUB+= NLS=""
+.endif
+
+CPPFLAGS+= ${PTHREAD_CFLAGS} \
+ -I${LOCALBASE}/include
+LDFLAGS+= -L${LOCALBASE}/lib
+
+CONFIGURE_ENV= CPPFLAGS="${CPPFLAGS}" \
+ LDFLAGS="${LDFLAGS}" \
+ YACC="${YACC}"
+
+.include <bsd.port.pre.mk>
+
+post-patch:
+ @${REINPLACE_CMD} -e "s|%%PREFIX%%|${PREFIX}|g" ${WRKSRC}/doc/bash.1
+
+post-configure:
+ @${FIND} ${WRKSRC} -name Makefile -print0 | ${XARGS} -0 \
+ ${REINPLACE_CMD} -e "s|^DESTDIR *=|& ${DESTDIR}|"
+
+pre-build:
+ @${ECHO_CMD} $$((${PORTREVISION}-1)) > ${WRKSRC}/.build
+
+pre-install:
+ @${SETENV} PKG_PREFIX="${PREFIX}" \
+ ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
+
+post-install:
+ @cd ${PREFIX}/bin ; ${LN} -sf bash rbash
+.if !defined(NOPORTDOCS)
+ @${MKDIR} ${DOCSDIR}
+.if !defined(WITH_INCLUDED_FAQ)
+ @${INSTALL_DATA} ${DISTDIR}/${DIST_SUBDIR}/FAQ \
+ ${WRKSRC}/doc/INTRO ${DOCSDIR}
+.else
+ @${INSTALL_DATA} ${WRKSRC}/doc/FAQ \
+ ${WRKSRC}/doc/INTRO ${DOCSDIR}
+.endif
+ @for d in ${PORTDOCS:NFAQ:NINTRO}; do \
+ ${INSTALL_DATA} ${WRKSRC}/$${d} ${DOCSDIR}; \
+ done
+.endif
+ @${SETENV} PKG_PREFIX="${PREFIX}" PKG_DESTDIR="${DESTDIR}" \
+ ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
+
+cklatest:
+ -ncftpls \
+ ftp://ftp.cwru.edu/pub/${PORTNAME}/${PORTNAME}-${PORTVERSION:C/\.[0-9a-z]*$//}-patches/ \
+ | ${TAIL}
+
+.include <bsd.port.post.mk>
diff --git a/shells/bash3/distinfo b/shells/bash3/distinfo
new file mode 100644
index 000000000000..f1097eb03733
--- /dev/null
+++ b/shells/bash3/distinfo
@@ -0,0 +1,149 @@
+MD5 (bash/bash-3.2.tar.gz) = 00bfa16d58e034e3c2aa27f390390d30
+SHA256 (bash/bash-3.2.tar.gz) = 26c99025b59e30779300b68adb764f824974d267a4d7cc1b347d14a2393f9fb4
+SIZE (bash/bash-3.2.tar.gz) = 2529838
+MD5 (bash/bash32-001) = d8e10c754f477e3f3a581af566b89301
+SHA256 (bash/bash32-001) = beda60ce6186fafa36cd0a98db9ced42cff68daee4342cca73167fb0f2f43eaa
+SIZE (bash/bash32-001) = 1539
+MD5 (bash/bash32-002) = d38a5288b2f0ea6c9ac76b66cc74ef7d
+SHA256 (bash/bash32-002) = a0ca49a3c47678ad074c990bdc871fcec680749b7f04f2def6527f04c589c40a
+SIZE (bash/bash32-002) = 1524
+MD5 (bash/bash32-003) = 0b90d37911827d8cb95f3b4353cc225e
+SHA256 (bash/bash32-003) = 7ec9e5e7e402e43b12bfd3a9237f4f171029fc7f58e59335abf3ccb455a5a84d
+SIZE (bash/bash32-003) = 4599
+MD5 (bash/bash32-004) = 8062f3a59631f58d78b180d83759b68a
+SHA256 (bash/bash32-004) = 3de0938673637089c3b0f0f355de377bb2be2d3fca68053dda267ca11b5998f2
+SIZE (bash/bash32-004) = 2585
+MD5 (bash/bash32-005) = 585b5943fadf0875ced243b245adde58
+SHA256 (bash/bash32-005) = e7fecdecb12320cd6fe9aca83fab1828b76aeb5313b991883764cb9139d845b7
+SIZE (bash/bash32-005) = 5910
+MD5 (bash/bash32-006) = 1d5732e01ea938aeed42f3def131fa4d
+SHA256 (bash/bash32-006) = 8f14f81ced32bc057bc10abf6842f4a5ac172816631f2b87a5a3be4f01c0847d
+SIZE (bash/bash32-006) = 1298
+MD5 (bash/bash32-007) = dcd0cc5d801607827f7c851e72b0eabc
+SHA256 (bash/bash32-007) = 6863a712e5a68eccfb77162a9f947ffd80af648f0124c38f795ebba2be12eff8
+SIZE (bash/bash32-007) = 1375
+MD5 (bash/bash32-008) = bb3c7dd11198c0ab93d0e960bebf6256
+SHA256 (bash/bash32-008) = ccf303b4d199d89d5efc659235f8a645376e86d294260dda4becbb61ec06667b
+SIZE (bash/bash32-008) = 1302
+MD5 (bash/bash32-009) = 434a6f29b0ca5f1ab784b2437ae8eaed
+SHA256 (bash/bash32-009) = ef30c579419106b4b4a2d0064ef7e57ceee6cdf657f4ccd7b89c8e4fd70560d8
+SIZE (bash/bash32-009) = 1882
+MD5 (bash/bash32-010) = 2efff04dd246fcf63bd4b99f77c9a081
+SHA256 (bash/bash32-010) = bb7df9fefe88d62ee371353edf62402a667cffba6ea202aa1c8b220308a0c612
+SIZE (bash/bash32-010) = 6293
+MD5 (bash/bash32-011) = 1dd104342f6920dfaf5efb3131e922e0
+SHA256 (bash/bash32-011) = 85bf656cfc49b1447b061341a4b1cb93ba89a41d8d1699a65aa971d1853ba472
+SIZE (bash/bash32-011) = 4776
+MD5 (bash/bash32-012) = 4f24b696ab78bdfae4f9cb7eb59b835d
+SHA256 (bash/bash32-012) = 45ef4ad98f2f218aa3acec15842ae1b833769c1dbe2f90c9bba00bbe4949fc43
+SIZE (bash/bash32-012) = 2555
+MD5 (bash/bash32-013) = 7c40addbf1187a26ae1c8373ed383442
+SHA256 (bash/bash32-013) = 9fbf893c383f45d25e5bc5c9eae8d2b349521f288945b3bd21c781784b81f693
+SIZE (bash/bash32-013) = 1852
+MD5 (bash/bash32-014) = 28e88c9f8679e99ac590d4a4a8227c56
+SHA256 (bash/bash32-014) = 62bb1a4d70f6f7938ca70a6aa7fe6f4b377ab5f450c7756b22b41de3bbd98ed6
+SIZE (bash/bash32-014) = 8141
+MD5 (bash/bash32-015) = 7c17d29675bd0d49470f162774385f80
+SHA256 (bash/bash32-015) = de40425e83628eb7431f39340ac09b42b5fcf484a565352851961b3e917d8771
+SIZE (bash/bash32-015) = 2293
+MD5 (bash/bash32-016) = a1edaa98b4449fe2205fa75448b7b105
+SHA256 (bash/bash32-016) = 7abf66bbba3ebd6b6428190f3ebca59abdc0bfa3957f1a725489de7391c2d9f1
+SIZE (bash/bash32-016) = 1620
+MD5 (bash/bash32-017) = 889ed119bbf9d363660b9a0127f35efa
+SHA256 (bash/bash32-017) = 951aa2a07b38db8eea8e7368d3ac36af60af7f5ade455215006229ce3815dfe0
+SIZE (bash/bash32-017) = 2611
+MD5 (bash/bash32-018) = a7d3f85fa687d2c1b5a134839f6d395d
+SHA256 (bash/bash32-018) = c85e2bca6084a79774adbf801698c62905662836334e54355b77fbf1c529074c
+SIZE (bash/bash32-018) = 2433
+MD5 (bash/bash32-019) = f0399da4007e46fc5820ce25d07425b9
+SHA256 (bash/bash32-019) = d83f1d740cb103be444589dcd9da61c2802815e8c256a01cfa7e484c50a9eb85
+SIZE (bash/bash32-019) = 8618
+MD5 (bash/bash32-020) = b76602281c3104d904fd064510fe0c21
+SHA256 (bash/bash32-020) = 3e66a1d05566d5501c2f868d3c94b8d71821a21d0daf9baaf594369697793013
+SIZE (bash/bash32-020) = 5182
+MD5 (bash/bash32-021) = 923374ae4403c92820f711e62e1d01a5
+SHA256 (bash/bash32-021) = a5e54704e6867c969a3e60556a5fbacedecca7404c3ddbe8180a92b6898a2a58
+SIZE (bash/bash32-021) = 1814
+MD5 (bash/bash32-022) = c82d3bd14e373878b2a680dce18d1596
+SHA256 (bash/bash32-022) = 057e03d593b858637056c0458b168e9c012db914727abba964afcaf377f2c5a4
+SIZE (bash/bash32-022) = 3034
+MD5 (bash/bash32-023) = 987c949a77b4b0ffe4a2597141e77635
+SHA256 (bash/bash32-023) = 869466d80807cde59c0eab9a39ef1909be4d5e8698ea1e3daa530ad59baaa97a
+SIZE (bash/bash32-023) = 1321
+MD5 (bash/bash32-024) = 5a2b976e761ab83f0fc7daae11451b86
+SHA256 (bash/bash32-024) = d13c59fa6b182f79bbf9ba35f72085aeb755f9785985eaf9f4a55d58045fe327
+SIZE (bash/bash32-024) = 3228
+MD5 (bash/bash32-025) = 08668dc2825f65eced9cac6b09ce1b45
+SHA256 (bash/bash32-025) = abfc1e1db3af956d4e71deb6a1ea9de1164c49fca4020b2546df3aa56f08cebe
+SIZE (bash/bash32-025) = 1935
+MD5 (bash/bash32-026) = f35b2b217f088ff009f956894550d41d
+SHA256 (bash/bash32-026) = 07985caacd6c150cf89c51965bd18db2c89a9f32f7a2aa946757007409c292b9
+SIZE (bash/bash32-026) = 2438
+MD5 (bash/bash32-027) = b5ff2b9610c61290f773c4b02cc1a37d
+SHA256 (bash/bash32-027) = 79647e3af94db8c2e636a293ee5b2f12516560b12aac0d4568a125d36cd21ddf
+SIZE (bash/bash32-027) = 2690
+MD5 (bash/bash32-028) = 016f5b56c93404d32aea09385f0fc13e
+SHA256 (bash/bash32-028) = 37289390175097c23efac5cb00d66b8b87e41fc37398064d11ac00de0e9934b0
+SIZE (bash/bash32-028) = 1750
+MD5 (bash/bash32-029) = a81420626d4d88d0dce2ffac0ac56341
+SHA256 (bash/bash32-029) = 1f4e543171bd66bc28b197938811028ea70e9e406be2529326d2a586844b98e7
+SIZE (bash/bash32-029) = 1330
+MD5 (bash/bash32-030) = 11f91baf970c132949f9072ee93f2ea6
+SHA256 (bash/bash32-030) = 5ed6ca19787f2285e0c080056f65a137e053387380b3d8f6133812dd8f824afb
+SIZE (bash/bash32-030) = 1558
+MD5 (bash/bash32-031) = f6bbc1e8ec0246740731c728ef476191
+SHA256 (bash/bash32-031) = 81ddc8f45e3272dd0e463fab87b58058be28d9c867674f3f53432dbd25cdfa48
+SIZE (bash/bash32-031) = 1961
+MD5 (bash/bash32-032) = 8180ec936770579bce69f0816c2dd878
+SHA256 (bash/bash32-032) = 926a9115e5c885ff9f2ef8abc6c3c552652afc370ebf65a87f41ec6810bdb569
+SIZE (bash/bash32-032) = 1304
+MD5 (bash/bash32-033) = 3cec33c3711860c4c6b7614afeec7870
+SHA256 (bash/bash32-033) = 9d7abee640dafbcdc6b75544015f3ffb5ed5aed2747465ec1412e959d3966740
+SIZE (bash/bash32-033) = 2181
+MD5 (bash/bash32-034) = 7bc6c5b5f38b7027152f8db0458a2e14
+SHA256 (bash/bash32-034) = adc52e3427b606fe9649980b01c5b2b18f0509c4dd6d59a84f85b6a2989f9f8e
+SIZE (bash/bash32-034) = 1866
+MD5 (bash/bash32-035) = a2db61fe90e39371d0e6cd2285ec9208
+SHA256 (bash/bash32-035) = d3d906b23fce195d5d6f0db8969fa5264e80a98b5460008d6a05e4156ca73953
+SIZE (bash/bash32-035) = 4805
+MD5 (bash/bash32-036) = 95c70c7ae9de5bd3659c86284be7fb76
+SHA256 (bash/bash32-036) = bdb24d65d1170234379fe587f5dc8b990c5e0c2d61c394bb8c81b91c1c64ce23
+SIZE (bash/bash32-036) = 1264
+MD5 (bash/bash32-037) = 62b876a3d7cd192cc8db2476fbb6b7b9
+SHA256 (bash/bash32-037) = 9688a352c0fb23d2ce6e685ce39cda1c49f4aa7819bde2508ff8c90003f484df
+SIZE (bash/bash32-037) = 3227
+MD5 (bash/bash32-038) = aca3afc341bd3e5a0d8a3b4ca40dbb3f
+SHA256 (bash/bash32-038) = 0e3649531c3a5675743980ecf5ff5fcbca2801afe4dca7fb4b250aae7ac3b782
+SIZE (bash/bash32-038) = 2412
+MD5 (bash/bash32-039) = e240c34f979b64bcb83c5f6567110bb1
+SHA256 (bash/bash32-039) = 46d427fd5b1509ec7dd980c07efd88634fde61cf07ab221dcbde9e1021bd2817
+SIZE (bash/bash32-039) = 5034
+MD5 (bash/bash32-040) = 06e6df263398807fa032707fb7b77b5f
+SHA256 (bash/bash32-040) = c9e0387eb4a2904126864d24de0699cdb6070789e1c02287a3b81ea96bf945aa
+SIZE (bash/bash32-040) = 1403
+MD5 (bash/bash32-041) = 373ae081d658dc85bc1058c4759d6669
+SHA256 (bash/bash32-041) = cc551fa57d613efea30ab2404fe724793a3d10f012b030e611d2c6449e463bcd
+SIZE (bash/bash32-041) = 4446
+MD5 (bash/bash32-042) = 9c9ebc6bfc33a0215277ee17a276eb5a
+SHA256 (bash/bash32-042) = fd0df54d03034e104b6377f249624bda0271aa874190a46e9d41fc49ad3caaef
+SIZE (bash/bash32-042) = 1209
+MD5 (bash/bash32-043) = b87fb9ea16a64ca41b6676e9a7eb7a33
+SHA256 (bash/bash32-043) = 43df7d2d7d61d3a8f0e14bc86d4f55b6d2e64829ba0829a78f5214d186087af7
+SIZE (bash/bash32-043) = 1658
+MD5 (bash/bash32-044) = 07e0229ce5879bfbd26a8146070fd366
+SHA256 (bash/bash32-044) = 204b5ecaaa5de334c3cfbce6dfd8a9d3770b09024ab4724d86080fbf501ded69
+SIZE (bash/bash32-044) = 5565
+MD5 (bash/bash32-045) = 1ad07965a8a93f3556ee1ab18b97cde2
+SHA256 (bash/bash32-045) = 3250e6c6d5d6884e31beaa2f521d2a1af9c2f701a4c0e67a7cd011b6ad8f082b
+SIZE (bash/bash32-045) = 1338
+MD5 (bash/bash32-046) = f7b1e19fcad54c2286bc0ed614aad9bf
+SHA256 (bash/bash32-046) = fc829e92fa951c34368d83272d746f5c0ed345a7ad037f93322347eed00a1e1f
+SIZE (bash/bash32-046) = 1275
+MD5 (bash/bash32-047) = 550690766de770116c34dbdf74e59184
+SHA256 (bash/bash32-047) = 623d4a958d2b022a15929a4de7403766ff07b295a185987b4d1e6cf3b70ea106
+SIZE (bash/bash32-047) = 1981
+MD5 (bash/bash32-048) = 4cc593e7b789b23b37a5397e092d3954
+SHA256 (bash/bash32-048) = 74cb56764274f393676f68738eb22a3ed8fa388c0487feeadf0d78a45b549749
+SIZE (bash/bash32-048) = 1948
+MD5 (bash/FAQ) = IGNORE
+SHA256 (bash/FAQ) = IGNORE
diff --git a/shells/bash3/files/patch-config-top.h b/shells/bash3/files/patch-config-top.h
new file mode 100644
index 000000000000..d315346bdf6f
--- /dev/null
+++ b/shells/bash3/files/patch-config-top.h
@@ -0,0 +1,24 @@
+--- config-top.h.orig Wed Dec 28 19:52:23 2005
++++ config-top.h Wed Dec 28 19:54:12 2005
+@@ -52,18 +52,18 @@
+ /* The default value of the PATH variable. */
+ #ifndef DEFAULT_PATH_VALUE
+ #define DEFAULT_PATH_VALUE \
+- "/usr/gnu/bin:/usr/local/bin:/bin:/usr/bin:."
++ "/sbin:/bin:/usr/sbin:/usr/bin:/usr/games:%%LOCALBASE%%/sbin:%%LOCALBASE%%/bin"
+ #endif
+
+ /* The value for PATH when invoking `command -p'. This is only used when
+ the Posix.2 confstr () function, or CS_PATH define are not present. */
+ #ifndef STANDARD_UTILS_PATH
+ #define STANDARD_UTILS_PATH \
+- "/bin:/usr/bin:/sbin:/usr/sbin:/etc:/usr/etc"
++ "/sbin:/bin:/usr/sbin:/usr/bin:/usr/games"
+ #endif
+
+ /* Default primary and secondary prompt strings. */
+-#define PPROMPT "\\s-\\v\\$ "
++#define PPROMPT "[\\u@\\h \\w]\\$ "
+ #define SPROMPT "> "
+
+ /* Undefine this if you don't want the ksh-compatible behavior of reprinting
diff --git a/shells/bash3/files/patch-doc::Makefile.in b/shells/bash3/files/patch-doc::Makefile.in
new file mode 100644
index 000000000000..4bd0159a793e
--- /dev/null
+++ b/shells/bash3/files/patch-doc::Makefile.in
@@ -0,0 +1,18 @@
+--- doc/Makefile.in.orig Wed Dec 28 20:00:02 2005
++++ doc/Makefile.in Wed Dec 28 20:00:58 2005
+@@ -161,14 +161,11 @@
+ bashref.dvi: $(BASHREF_FILES) $(HSUSER) $(RLUSER)
+ ${SET_TEXINPUTS} $(TEXI2DVI) $(srcdir)/bashref.texi
+
+-bashref.info: $(BASHREF_FILES) $(HSUSER) $(RLUSER)
++bash.info: $(BASHREF_FILES) $(HSUSER) $(RLUSER)
+ $(MAKEINFO) --no-split -I$(TEXINPUTDIR) $(srcdir)/bashref.texi
+
+ bashref.html: $(BASHREF_FILES) $(HSUSER) $(RLUSER)
+ $(TEXI2HTML) -menu -monolithic -I $(TEXINPUTDIR) $(srcdir)/bashref.texi
+-
+-bash.info: bashref.info
+- ${SHELL} ${INFOPOST} < $(srcdir)/bashref.info > $@ ; \
+
+ bash.txt: bash.1
+ bash.ps: bash.1
diff --git a/shells/bash3/files/patch-doc::bash.1 b/shells/bash3/files/patch-doc::bash.1
new file mode 100644
index 000000000000..7aad7f51aa2f
--- /dev/null
+++ b/shells/bash3/files/patch-doc::bash.1
@@ -0,0 +1,20 @@
+--- doc/bash.1.orig Wed Dec 28 19:44:28 2005
++++ doc/bash.1 Wed Dec 28 20:03:12 2005
+@@ -1897,7 +1897,7 @@
+ .SM
+ .B PROMPTING
+ below) and used as the primary prompt string. The default value is
+-``\fB\es\-\ev\e$ \fP''.
++``\fB\eu\@\eh\e$ \fP''.
+ .TP
+ .B PS2
+ The value of this parameter is expanded as with
+@@ -8784,7 +8784,7 @@
+ .SH FILES
+ .PD 0
+ .TP
+-.FN /bin/bash
++.FN %%PREFIX%%/bin/bash
+ The \fBbash\fP executable
+ .TP
+ .FN /etc/profile
diff --git a/shells/bash3/files/patch-doc::bashref.texi b/shells/bash3/files/patch-doc::bashref.texi
new file mode 100644
index 000000000000..add4d9b2944b
--- /dev/null
+++ b/shells/bash3/files/patch-doc::bashref.texi
@@ -0,0 +1,28 @@
+--- doc/bashref.texi.orig Wed Dec 28 19:44:28 2005
++++ doc/bashref.texi Wed Dec 28 20:09:16 2005
+@@ -1,6 +1,6 @@
+ \input texinfo.tex @c -*- texinfo -*-
+ @c %**start of header
+-@setfilename bashref.info
++@setfilename bash.info
+ @settitle Bash Reference Manual
+ @c %**end of header
+
+@@ -10,7 +10,7 @@
+
+ @copying
+ This text is a brief description of the features that are present in
+-the Bash shell (version @value{VERSION}, @value{UPDATED}).
++the Bash shell (version @value{VERSION}, @value{UPDATED})
+
+ This is Edition @value{EDITION}, last updated @value{UPDATED},
+ of @cite{The GNU Bash Reference Manual},
+@@ -4277,7 +4277,7 @@
+
+
+ @item PS1
+-The primary prompt string. The default value is @samp{\s-\v\$ }.
++The primary prompt string. The default value is @samp{[\u@@\h \w]\$ }.
+ @xref{Printing a Prompt}, for the complete list of escape
+ sequences that are expanded before @env{PS1} is displayed.
+
diff --git a/shells/bash3/files/patch-lib::readline::display.c b/shells/bash3/files/patch-lib::readline::display.c
new file mode 100644
index 000000000000..53d0b4f4249a
--- /dev/null
+++ b/shells/bash3/files/patch-lib::readline::display.c
@@ -0,0 +1,24 @@
+#
+# Fix handling of `read -e' while PS1 is set longer than the screen width
+#
+# http://lists.gnu.org/archive/html/bug-bash/2004-11/msg00220.html
+# http://lists.gnu.org/archive/html/bug-bash/2004-11/msg00266.html
+#
+--- lib/readline/display.c.orig Wed Nov 30 17:05:02 2005
++++ lib/readline/display.c Wed Dec 28 20:13:15 2005
+@@ -594,11 +594,10 @@
+
+ /* inv_lbreaks[i] is where line i starts in the buffer. */
+ inv_lbreaks[newlines = 0] = 0;
+-#if 0
+- lpos = out - wrap_offset;
+-#else
+- lpos = prompt_physical_chars + modmark;
+-#endif
++ if (local_prompt)
++ lpos = prompt_physical_chars + modmark;
++ else
++ lpos = 0;
+
+ #if defined (HANDLE_MULTIBYTE)
+ memset (_rl_wrapped_line, 0, vis_lbsize);
diff --git a/shells/bash3/files/xpatch-colonbreakswords b/shells/bash3/files/xpatch-colonbreakswords
new file mode 100644
index 000000000000..cd565ca232dd
--- /dev/null
+++ b/shells/bash3/files/xpatch-colonbreakswords
@@ -0,0 +1,179 @@
+#
+# new shopt `colonbreakswords'
+# http://lists.gnu.org/archive/html/bug-bash/2004-10/msg00190.html
+#
+--- bashline.c.orig Sat Nov 5 18:07:02 2005
++++ bashline.c Wed Dec 28 19:44:28 2005
+@@ -212,6 +212,11 @@
+ host list. */
+ int perform_hostname_completion = 1;
+
++/* If non-zero, we do hostname completion, breaking words at `@' and
++ trying to complete the stuff after the `@' from our own internal
++ host list. */
++int colon_is_wordbreak = 1;
++
+ /* If non-zero, we don't do command completion on an empty line. */
+ int no_empty_command_completion;
+
+@@ -222,7 +227,8 @@
+
+ static char *bash_completer_word_break_characters = " \t\n\"'@><=;|&(:";
+ static char *bash_nohostname_word_break_characters = " \t\n\"'><=;|&(:";
+-/* )) */
++static char *bash_nocolon_word_break_characters = " \t\n\"'@><=;|&(";
++/* ))) */
+
+ static rl_hook_func_t *old_rl_startup_hook = (rl_hook_func_t *)NULL;
+
+@@ -325,6 +331,80 @@
+ return (old_value);
+ }
+
++/* When this function returns, rl_completer_word_break_characters points to
++ dynamically allocated memory. */
++int
++enable_colon_wordbreak (on_or_off)
++ int on_or_off;
++{
++ int old_value;
++ char *at, *nv, *nval;
++
++ old_value = colon_is_wordbreak;
++
++ if (on_or_off)
++ {
++ colon_is_wordbreak = 1;
++ rl_filename_quote_characters = " \t\n\\\"'@<>=;|&()#$`?*[!:{"; /*}*/
++ }
++ else
++ {
++ colon_is_wordbreak = 0;
++ rl_filename_quote_characters = " \t\n\\\"'@<>=;|&()#$`?*[!{"; /*}*/
++ }
++
++ /* Now we need to figure out how to appropriately modify and assign
++ rl_completer_word_break_characters depending on whether we want
++ the colon to be a word break or not. */
++
++ /* If this is the first time this has been called
++ (bash_readline_initialized == 0), use the sames values as before, but
++ allocate new memory for rl_completer_word_break_characters. */
++
++ if (bash_readline_initialized == 0 &&
++ (rl_completer_word_break_characters == 0 ||
++ rl_completer_word_break_characters == rl_basic_word_break_characters))
++ {
++ if (on_or_off)
++ rl_completer_word_break_characters = savestring (bash_completer_word_break_characters);
++ else
++ rl_completer_word_break_characters = savestring (bash_nocolon_word_break_characters);
++ }
++ else
++ {
++ /* See if we have anything to do. */
++ at = strchr (rl_completer_word_break_characters, ':');
++ if ((at == 0 && on_or_off == 0) || (at != 0 && on_or_off != 0))
++ return old_value;
++
++ /* We have something to do. Do it. */
++ nval = (char *)xmalloc (strlen (rl_completer_word_break_characters) + 1 + on_or_off);
++
++ if (on_or_off == 0)
++ {
++ /* Turn it off -- just remove `:' from word break chars. We want
++ to remove all occurrences of `:' from the char list, so we loop
++ rather than just copy the rest of the list over AT. */
++ for (nv = nval, at = rl_completer_word_break_characters; *at; )
++ if (*at != ':')
++ *nv++ = *at++;
++ else
++ at++;
++ *nv = '\0';
++ }
++ else
++ {
++ nval[0] = ':';
++ strcpy (nval + 1, rl_completer_word_break_characters);
++ }
++
++ free (rl_completer_word_break_characters);
++ rl_completer_word_break_characters = nval;
++ }
++
++ return (old_value);
++}
++
+ /* Called once from parse.y if we are going to use readline. */
+ void
+ initialize_readline ()
+@@ -485,8 +565,12 @@
+ completion is enabled. */
+ enable_hostname_completion (perform_hostname_completion);
+
++ /* This sets rl_completer_word_break_characters and rl_filename_quote_characters
++ to the appropriate values, depending on whether or not a colon
++ should break completion words or not. */
++ enable_colon_wordbreak (colon_is_wordbreak);
++
+ /* characters that need to be quoted when appearing in filenames. */
+- rl_filename_quote_characters = " \t\n\\\"'@<>=;|&()#$`?*[!:{"; /*}*/
+ rl_filename_quoting_function = bash_quote_filename;
+ rl_filename_dequoting_function = bash_dequote_filename;
+ rl_char_is_quoted_p = char_is_quoted;
+--- builtins/shopt.def.orig Wed Dec 28 19:38:09 2005
++++ builtins/shopt.def Wed Dec 28 19:44:28 2005
+@@ -83,6 +83,8 @@
+ extern int hist_verify, history_reediting, perform_hostname_completion;
+ extern int no_empty_command_completion;
+ extern int force_fignore;
++extern int colon_is_wordbreak;
++extern int enable_colon_wordbreak __P((int));
+ extern int enable_hostname_completion __P((int));
+ #endif
+
+@@ -121,6 +123,9 @@
+ { "checkwinsize", &check_window_size, (shopt_set_func_t *)NULL },
+ #if defined (HISTORY)
+ { "cmdhist", &command_oriented_history, (shopt_set_func_t *)NULL },
++#endif
++#if defined (READLINE)
++ { "colonbreakswords", &colon_is_wordbreak, enable_colon_wordbreak },
+ #endif
+ { "dotglob", &glob_dot_filenames, (shopt_set_func_t *)NULL },
+ { "execfail", &no_exit_on_failed_exec, (shopt_set_func_t *)NULL },
+--- doc/bash.1.orig Wed Dec 28 19:38:09 2005
++++ doc/bash.1 Wed Dec 28 19:44:28 2005
+@@ -7972,6 +7972,18 @@
+ command in the same history entry. This allows
+ easy re-editing of multi-line commands.
+ .TP 8
++.B colonbreakswords
++If set, and
++.B readline
++is being used, \fBbash\fP will treat \fB:\fP as
++separating word being completed (see
++.B Completing
++under
++.SM
++.B READLINE
++above).
++This is enabled by default.
++.TP 8
+ .B dotglob
+ If set,
+ .B bash
+--- doc/bashref.texi.orig Wed Dec 28 19:38:09 2005
++++ doc/bashref.texi Wed Dec 28 19:44:28 2005
+@@ -3598,6 +3598,11 @@
+ command in the same history entry. This allows
+ easy re-editing of multi-line commands.
+
++@item colonbreakswords
++If set, and Readline is being used, Bash will treat @samp{:} as
++separating word being completed (@pxref{Commands For Completion}).
++This option is enabled by default.
++
+ @item dotglob
+ If set, Bash includes filenames beginning with a `.' in
+ the results of filename expansion.
diff --git a/shells/bash3/files/xpatch-implicitcd b/shells/bash3/files/xpatch-implicitcd
new file mode 100644
index 000000000000..4d7efb6a00e1
--- /dev/null
+++ b/shells/bash3/files/xpatch-implicitcd
@@ -0,0 +1,99 @@
+#
+# new shopt `implicitcd'
+# http://lists.gnu.org/archive/html/bug-bash/2004-09/msg00024.html
+#
+--- execute_cmd.c.orig Sat Nov 5 17:37:21 2005
++++ execute_cmd.c Wed Dec 28 19:38:09 2005
+@@ -190,6 +190,9 @@
+ /* The line number that the currently executing function starts on. */
+ static int function_line_number;
+
++/* add an implicit `cd' if the command is the name of a directory */
++int implicitcd = 0;
++
+ /* Set to 1 if fd 0 was the subject of redirection to a subshell. Global
+ so that reader_loop can set it to zero before executing a command. */
+ int stdin_redir;
+@@ -2913,6 +2916,20 @@
+ this_command_name = words->word->word;
+
+ QUIT;
++
++ if (implicitcd && interactive_shell && words->next == NULL && func == 0 && builtin == 0)
++ {
++ struct stat finfo;
++
++ if ((stat (words->word->word, &finfo) == 0) && (S_ISDIR (finfo.st_mode)))
++ {
++ this_command_name = "cd";
++ last_shell_builtin = this_shell_builtin;
++ this_shell_builtin = builtin_address (this_command_name);
++ result = (*this_shell_builtin) (words);
++ goto return_result;
++ }
++ }
+
+ /* This command could be a shell builtin or a user-defined function.
+ We have already found special builtins by this time, so we do not
+--- builtins/shopt.def.orig Sat Feb 19 19:25:03 2005
++++ builtins/shopt.def Wed Dec 28 19:38:09 2005
+@@ -66,6 +66,7 @@
+ extern int check_window_size;
+ extern int glob_ignore_case, match_ignore_case;
+ extern int hup_on_exit;
++extern int implicitcd;
+ extern int xpg_echo;
+ extern int gnu_error_format;
+
+@@ -145,6 +146,7 @@
+ { "hostcomplete", &perform_hostname_completion, enable_hostname_completion },
+ #endif
+ { "huponexit", &hup_on_exit, (shopt_set_func_t *)NULL },
++ { "implicitcd", &implicitcd, (shopt_set_func_t *)NULL },
+ { "interactive_comments", &interactive_comments, set_shellopts_after_change },
+ #if defined (HISTORY)
+ { "lithist", &literal_history, (shopt_set_func_t *)NULL },
+@@ -253,6 +255,7 @@
+ cdable_vars = mail_warning = 0;
+ no_exit_on_failed_exec = print_shift_error = 0;
+ check_hashed_filenames = cdspelling = expand_aliases = check_window_size = 0;
++ implicitcd = 0;
+
+ source_uses_path = promptvars = 1;
+
+--- doc/bash.1.orig Wed Oct 12 12:40:52 2005
++++ doc/bash.1 Wed Dec 28 19:38:09 2005
+@@ -8090,6 +8090,15 @@
+ .B SIGHUP
+ to all jobs when an interactive login shell exits.
+ .TP 8
++.B implicitcd
++If this is set, a directory name typed as a command is treated as a
++request to change to that directory.
++This behavior is inhibited in non-interactive mode or for command
++strings with more than one word.
++Changing directory takes precedence over executing a like-named
++command, but it is done after alias substitutions.
++Tilde and variable expansions work as expected.
++.TP 8
+ .B interactive_comments
+ If set, allow a word beginning with
+ .B #
+--- doc/bashref.texi.orig Mon Oct 3 16:07:21 2005
++++ doc/bashref.texi Wed Dec 28 19:38:09 2005
+@@ -3697,6 +3697,15 @@
+ If set, Bash will send @code{SIGHUP} to all jobs when an interactive
+ login shell exits (@pxref{Signals}).
+
++@item implicitcd
++If this is set, a directory name typed as a command is treated as a
++request to change to that directory.
++This behavior is inhibited in non-interactive mode or for command
++strings with more than one word.
++Changing directory takes precedence over executing a like-named
++command, but it is done after alias substitutions.
++Tilde and variable expansions work as expected.
++
+ @item interactive_comments
+ Allow a word beginning with @samp{#}
+ to cause that word and all remaining characters on that
diff --git a/shells/bash3/pkg-deinstall b/shells/bash3/pkg-deinstall
new file mode 100644
index 000000000000..9552db126262
--- /dev/null
+++ b/shells/bash3/pkg-deinstall
@@ -0,0 +1,33 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+BASH="$(echo ${PKG_PREFIX-/usr/local}/bin/bash | /usr/bin/sed -e 's|//|/|g')"
+RBASH="$(echo ${PKG_PREFIX-/usr/local}/bin/rbash | /usr/bin/sed -e 's|//|/|g')"
+SHELLS="${PKG_DESTDIR-}/etc/shells"
+
+case $2 in
+DEINSTALL)
+ if grep -qs "^$BASH\$" "$SHELLS"; then
+ if [ `id -u` -eq 0 ]; then
+ TMPSHELLS=`mktemp -t shells`
+ grep -v "^$BASH\$" "$SHELLS" > "$TMPSHELLS"
+ cat "$TMPSHELLS" > "$SHELLS"
+ rm "$TMPSHELLS"
+ else
+ echo "Not root, please remove $BASH from $SHELLS manually"
+ fi
+ fi
+ if grep -qs "^$RBASH\$" "$SHELLS"; then
+ if [ `id -u` -eq 0 ]; then
+ TMPSHELLS=`mktemp -t shells`
+ grep -v "^$RBASH\$" "$SHELLS" > "$TMPSHELLS"
+ cat "$TMPSHELLS" > "$SHELLS"
+ rm "$TMPSHELLS"
+ else
+ echo "Not root, please remove $RBASH from $SHELLS manually"
+ fi
+ fi
+ ;;
+esac
diff --git a/shells/bash3/pkg-descr b/shells/bash3/pkg-descr
new file mode 100644
index 000000000000..03f1dc88912b
--- /dev/null
+++ b/shells/bash3/pkg-descr
@@ -0,0 +1,7 @@
+This is GNU Bash, version 3.0. Bash is the GNU Project's Bourne
+Again SHell, a complete implementation of the POSIX.2 shell spec,
+but also with interactive command line editing, job control on
+architectures that support it, csh-like features such as history
+substitution and brace expansion, and a slew of other features.
+
+WWW: http://cnswww.cns.cwru.edu/~chet/bash/bashtop.html
diff --git a/shells/bash3/pkg-install b/shells/bash3/pkg-install
new file mode 100644
index 000000000000..99417b66ba6e
--- /dev/null
+++ b/shells/bash3/pkg-install
@@ -0,0 +1,27 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+BASH="$(echo ${PKG_PREFIX-/usr/local}/bin/bash | /usr/bin/sed -e 's|//|/|g')"
+RBASH="$(echo ${PKG_PREFIX-/usr/local}/bin/rbash | /usr/bin/sed -e 's|//|/|g')"
+SHELLS="/etc/shells"
+
+case $2 in
+POST-INSTALL)
+ if [ -d "${SHELLS%/*}" ] && ! grep -qs "^$BASH\$" "$SHELLS"; then
+ if [ `id -u` -eq 0 ]; then
+ echo "$BASH" >> "$SHELLS"
+ else
+ echo "Not root, please add $BASH to $SHELLS manually"
+ fi
+ fi
+ if [ -d "${SHELLS%/*}" ] && ! grep -qs "^$RBASH\$" "$SHELLS"; then
+ if [ `id -u` -eq 0 ]; then
+ echo "$RBASH" >> "$SHELLS"
+ else
+ echo "Not root, please add $RBASH to $SHELLS manually"
+ fi
+ fi
+ ;;
+esac
diff --git a/shells/bash3/pkg-plist b/shells/bash3/pkg-plist
new file mode 100644
index 000000000000..07644dcd01e0
--- /dev/null
+++ b/shells/bash3/pkg-plist
@@ -0,0 +1,84 @@
+@comment $FreeBSD$
+bin/bash
+bin/rbash
+bin/bashbug
+%%NLS%%share/locale/en@boldquot/LC_MESSAGES/bash.mo
+%%NLS%%share/locale/en@quot/LC_MESSAGES/bash.mo
+%%NLS%%share/locale/ru/LC_MESSAGES/bash.mo
+%%HELP%%%%DATADIR%%/alias
+%%HELP%%%%DATADIR%%/arith
+%%HELP%%%%DATADIR%%/arith_for
+%%HELP%%%%DATADIR%%/bg
+%%HELP%%%%DATADIR%%/bind
+%%HELP%%%%DATADIR%%/break
+%%HELP%%%%DATADIR%%/builtin
+%%HELP%%%%DATADIR%%/caller
+%%HELP%%%%DATADIR%%/case
+%%HELP%%%%DATADIR%%/cd
+%%HELP%%%%DATADIR%%/colon
+%%HELP%%%%DATADIR%%/command
+%%HELP%%%%DATADIR%%/compgen
+%%HELP%%%%DATADIR%%/complete
+%%HELP%%%%DATADIR%%/conditional
+%%HELP%%%%DATADIR%%/continue
+%%HELP%%%%DATADIR%%/declare
+%%HELP%%%%DATADIR%%/dirs
+%%HELP%%%%DATADIR%%/disown
+%%HELP%%%%DATADIR%%/dot
+%%HELP%%%%DATADIR%%/echo
+%%HELP%%%%DATADIR%%/enable
+%%HELP%%%%DATADIR%%/eval
+%%HELP%%%%DATADIR%%/exec
+%%HELP%%%%DATADIR%%/exit
+%%HELP%%%%DATADIR%%/export
+%%HELP%%%%DATADIR%%/false
+%%HELP%%%%DATADIR%%/fc
+%%HELP%%%%DATADIR%%/fg
+%%HELP%%%%DATADIR%%/fg_percent
+%%HELP%%%%DATADIR%%/for
+%%HELP%%%%DATADIR%%/function
+%%HELP%%%%DATADIR%%/getopts
+%%HELP%%%%DATADIR%%/grouping_braces
+%%HELP%%%%DATADIR%%/hash
+%%HELP%%%%DATADIR%%/help
+%%HELP%%%%DATADIR%%/history
+%%HELP%%%%DATADIR%%/if
+%%HELP%%%%DATADIR%%/jobs
+%%HELP%%%%DATADIR%%/kill
+%%HELP%%%%DATADIR%%/let
+%%HELP%%%%DATADIR%%/local
+%%HELP%%%%DATADIR%%/logout
+%%HELP%%%%DATADIR%%/popd
+%%HELP%%%%DATADIR%%/printf
+%%HELP%%%%DATADIR%%/pushd
+%%HELP%%%%DATADIR%%/pwd
+%%HELP%%%%DATADIR%%/read
+%%HELP%%%%DATADIR%%/readonly
+%%HELP%%%%DATADIR%%/return
+%%HELP%%%%DATADIR%%/select
+%%HELP%%%%DATADIR%%/set
+%%HELP%%%%DATADIR%%/shift
+%%HELP%%%%DATADIR%%/shopt
+%%HELP%%%%DATADIR%%/source
+%%HELP%%%%DATADIR%%/suspend
+%%HELP%%%%DATADIR%%/test
+%%HELP%%%%DATADIR%%/test_bracket
+%%HELP%%%%DATADIR%%/time
+%%HELP%%%%DATADIR%%/times
+%%HELP%%%%DATADIR%%/trap
+%%HELP%%%%DATADIR%%/true
+%%HELP%%%%DATADIR%%/type
+%%HELP%%%%DATADIR%%/typeset
+%%HELP%%%%DATADIR%%/ulimit
+%%HELP%%%%DATADIR%%/umask
+%%HELP%%%%DATADIR%%/unalias
+%%HELP%%%%DATADIR%%/unset
+%%HELP%%%%DATADIR%%/until
+%%HELP%%%%DATADIR%%/variable_help
+%%HELP%%%%DATADIR%%/wait
+%%HELP%%%%DATADIR%%/while
+%%HELP%%@dirrm %%DATADIR%%
+%%NLS%%@dirrmtry share/locale/en@boldquot/LC_MESSAGES
+%%NLS%%@dirrmtry share/locale/en@boldquot
+%%NLS%%@dirrmtry share/locale/en@quot/LC_MESSAGES
+%%NLS%%@dirrmtry share/locale/en@quot