diff options
author | Emanuel Haupt <ehaupt@FreeBSD.org> | 2013-11-01 10:29:18 +0000 |
---|---|---|
committer | Emanuel Haupt <ehaupt@FreeBSD.org> | 2013-11-01 10:29:18 +0000 |
commit | 1d8e5e9cd66b23fdad530696e035518ddf0bedd7 (patch) | |
tree | b3fd24084fc628b8d4ca187997ea2eb08bc36f6b /shells | |
parent | 5a61b6cd8d40cf7ceeb285e5e2421217c0326969 (diff) |
Support staging.
Notes
Notes:
svn path=/head/; revision=332349
Diffstat (limited to 'shells')
-rw-r--r-- | shells/bash-devel/Makefile | 17 | ||||
-rw-r--r-- | shells/bash-devel/pkg-deinstall | 33 | ||||
-rw-r--r-- | shells/bash-devel/pkg-install | 27 | ||||
-rw-r--r-- | shells/bash-devel/pkg-plist | 6 | ||||
-rw-r--r-- | shells/bash-static-devel/Makefile | 1 |
5 files changed, 11 insertions, 73 deletions
diff --git a/shells/bash-devel/Makefile b/shells/bash-devel/Makefile index 4284fba32f8e..79bfe1053a2d 100644 --- a/shells/bash-devel/Makefile +++ b/shells/bash-devel/Makefile @@ -33,7 +33,6 @@ HELP_DESC= Enable builtin help USES= bison -NO_STAGE= yes .include <bsd.port.options.mk> .if ${PORT_OPTIONS:MIMPLICITCD} @@ -44,7 +43,6 @@ EXTRA_PATCHES+= ${PATCHDIR}/extrapatch-implicitcd EXTRA_PATCHES+= ${PATCHDIR}/extrapatch-colonbreakswords .endif -MAN1= bash.1 bashbug.1 INFO= bash MAKE_JOBS_UNSAFE= yes @@ -107,22 +105,16 @@ post-configure: 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 + @cd ${STAGEDIR}${PREFIX}/bin ; ${LN} -sf bash rbash .if ${PORT_OPTIONS:MDOCS} - @${MKDIR} ${DOCSDIR} + @${MKDIR} ${STAGEDIR}${DOCSDIR} @${INSTALL_DATA} ${WRKSRC}/doc/FAQ \ - ${WRKSRC}/doc/INTRO ${DOCSDIR} + ${WRKSRC}/doc/INTRO ${STAGEDIR}${DOCSDIR} @for d in ${PORTDOCS:NFAQ:NINTRO}; do \ - ${INSTALL_DATA} ${WRKSRC}/$${d} ${DOCSDIR}; \ + ${INSTALL_DATA} ${WRKSRC}/$${d} ${STAGEDIR}${DOCSDIR}; \ done .endif - @${SETENV} PKG_PREFIX="${PREFIX}" PKG_DESTDIR="${DESTDIR}" \ - ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL regress: build cd ${WRKSRC}; ${SETENV} ${MAKE_ENV} ${MAKE} ${MAKE_ARGS} test @@ -130,6 +122,7 @@ regress: build ckp: ${MAKE} -DPATCH_DEBUG clean patch +# requires ftp/ncftp3 cklatest: @${ECHO} -n "Currently at: " @${MAKE} -V PATCHLEVEL diff --git a/shells/bash-devel/pkg-deinstall b/shells/bash-devel/pkg-deinstall deleted file mode 100644 index 9552db126262..000000000000 --- a/shells/bash-devel/pkg-deinstall +++ /dev/null @@ -1,33 +0,0 @@ -#!/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/bash-devel/pkg-install b/shells/bash-devel/pkg-install deleted file mode 100644 index 99417b66ba6e..000000000000 --- a/shells/bash-devel/pkg-install +++ /dev/null @@ -1,27 +0,0 @@ -#!/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/bash-devel/pkg-plist b/shells/bash-devel/pkg-plist index 259577d23db5..4d32f31aa676 100644 --- a/shells/bash-devel/pkg-plist +++ b/shells/bash-devel/pkg-plist @@ -1,7 +1,13 @@ @comment $FreeBSD$ bin/bash +@exec echo "Updating /etc/shells"; cp /etc/shells /etc/shells.bak; (grep -v %D/%F /etc/shells.bak; echo %D/%F) >/etc/shells; rm -f /etc/shells.bak +@unexec echo "Updating /etc/shells"; cp /etc/shells /etc/shells.bak; (grep -v %D/%F /etc/shells.bak) >/etc/shells; rm -f /etc/shells.bak bin/rbash +@exec cp /etc/shells /etc/shells.bak; (grep -v %D/%F /etc/shells.bak; echo %D/%F) >/etc/shells; rm -f /etc/shells.bak +@unexec cp /etc/shells /etc/shells.bak; (grep -v %D/%F /etc/shells.bak) >/etc/shells; rm -f /etc/shells.bak bin/bashbug +man/man1/bash.1.gz +man/man1/bashbug.1.gz %%NLS%%share/locale/af/LC_MESSAGES/bash.mo %%NLS%%share/locale/bg/LC_MESSAGES/bash.mo %%NLS%%share/locale/ca/LC_MESSAGES/bash.mo diff --git a/shells/bash-static-devel/Makefile b/shells/bash-static-devel/Makefile index 5c68ab81a367..870532816449 100644 --- a/shells/bash-static-devel/Makefile +++ b/shells/bash-static-devel/Makefile @@ -5,5 +5,4 @@ MASTERDIR= ${.CURDIR}/../../shells/bash-devel OPTIONS_SLAVE= STATIC -NO_STAGE= yes .include "${MASTERDIR}/Makefile" |