Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 22 Jul 2006 12:44:42 +0200 (CEST)
From:      Martin Wilke <miwi@FreeBSD.org>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/100713: [NEW PORT] shells/mksh: A Korn shell with many additions
Message-ID:  <200607221044.k6MAigMd083017@mwilke.ath.cx>
Resent-Message-ID: <200607221050.k6MAoCU9051128@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         100713
>Category:       ports
>Synopsis:       [NEW PORT] shells/mksh: A Korn shell with many additions
>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:   Sat Jul 22 10:50:12 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     Martin Wilke
>Release:        FreeBSD 7.0-CURRENT i386
>Organization:
>Environment:
System: FreeBSD mwilke.ath.cx 7.0-CURRENT FreeBSD 7.0-CURRENT #157: Tue Jul 18 08:59:45 CEST 2006
>Description:
The MirOS Korn Shell, which contains many additions to the original
Korn shell.

WWW: http://mirbsd.de/mksh

Generated with FreeBSD Port Tools 0.77
>How-To-Repeat:
>Fix:

--- mksh-r27.e.shar begins here ---
# This is a shell archive.  Save it in a file, remove anything before
# this line, and then unpack it by entering "sh file".  Note, it may
# create directories; files and directories will be owned by you and
# have default permissions.
#
# This archive contains:
#
#	mksh
#	mksh/Makefile
#	mksh/distinfo
#	mksh/pkg-deinstall
#	mksh/pkg-descr
#	mksh/pkg-install
#
echo c - mksh
mkdir -p mksh > /dev/null 2>&1
echo x - mksh/Makefile
sed 's/^X//' >mksh/Makefile << 'END-of-mksh/Makefile'
X# Ports collection makefile for:	mksh
X# Date created:				2006-06-24
X# Whom:					Andreas Kohn <andreas@syndrom23.de>
X#
X# $FreeBSD$
X#
X
XPORTNAME=		mksh
XDISTVERSION=		R27e
XCATEGORIES=		shells
XMASTER_SITES=		http://www.mirbsd.org/MirOS/dist/mir/mksh/
XDISTFILES=		${PORTNAME}-${DISTVERSION}.cpio.gz
X
XMAINTAINER=		andreas@syndrom23.de
XCOMMENT=		A Korn shell with many additions
X
XWRKSRC=			${WRKDIR}/${PORTNAME}
X
XMAN1=			mksh.1
XPLIST_FILES=		bin/mksh
X
XOPTIONS=		STATIC_MKSH "Build static mksh" on
X
XPKGINSTALL=		pkg-install
XPKGDEINSTALL=		pkg-deinstall
X
X.include <bsd.port.pre.mk>
X
Xdo-extract:
X	${MKDIR} ${WRKDIR}
X	cd ${WRKDIR} && \
X		${GZCAT} ${DISTDIR}/${DISTFILES} | ${CPIO} -id
X
Xdo-build:
X.if defined(WITH_STATIC_MKSH)
X	cd ${WRKSRC} && CFLAGS="${CFLAGS}" CC="${CC}" LDFLAGS="${LDFLAGS}" CPPFLAGS="${CPPFLAGS}" SHELL=${SH} ${SH} ${WRKSRC}/Build.sh -r
X.else
X	cd ${WRKSRC} && CFLAGS="${CFLAGS}" CC="${CC}" LDFLAGS="${LDFLAGS}" CPPFLAGS="${CPPFLAGS}" SHELL=${SH} ${SH} ${WRKSRC}/Build.sh -d -r
X.endif
X
Xdo-install:
X	${INSTALL_PROGRAM} ${WRKSRC}/mksh ${PREFIX}/bin
X	${INSTALL_MAN} ${WRKSRC}/mksh.1 ${MANPREFIX}/man/man1
X
Xpre-install:
X	@${SETENV} PKG_PREFIX="${PREFIX}" PKG_DESTDIR="${DESTDIR}" \
X		${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
X
Xpost-install:
X	@${SETENV} PKG_PREFIX="${PREFIX}" PKG_DESTDIR="${DESTDIR}" \
X		${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
X
X.include <bsd.port.post.mk>
END-of-mksh/Makefile
echo x - mksh/distinfo
sed 's/^X//' >mksh/distinfo << 'END-of-mksh/distinfo'
XMD5 (mksh-R27e.cpio.gz) = 2eeb5c5fab32cc7a20ca3c7c2c6fda46
XSHA256 (mksh-R27e.cpio.gz) = 3a98c188f906cfa1c29c2e5e521fa6201fc63192e7da861b4c1b3c610ac9cebb
XSIZE (mksh-R27e.cpio.gz) = 229752
END-of-mksh/distinfo
echo x - mksh/pkg-deinstall
sed 's/^X//' >mksh/pkg-deinstall << 'END-of-mksh/pkg-deinstall'
X#!/bin/sh
X#
X# $FreeBSD$
X#
X
XMKSH="${PKG_PREFIX-/usr/local}/bin/mksh"
XSHELLS="${PKG_DESTDIR-}/etc/shells"
X
Xcase $2 in
XDEINSTALL)
X  if grep -qs "^$MKSH\$" "$SHELLS"; then
X    if [ `id -u` -eq 0 ]; then
X      TMPSHELLS=`mktemp -t shells`
X      grep -v "^$MKSH\$" "$SHELLS" > "$TMPSHELLS"
X      cat "$TMPSHELLS" > "$SHELLS"
X      rm "$TMPSHELLS"
X    else
X      echo "Not root, please remove $MKSH from $SHELLS manually"
X    fi
X  fi
X  ;;
Xesac
END-of-mksh/pkg-deinstall
echo x - mksh/pkg-descr
sed 's/^X//' >mksh/pkg-descr << 'END-of-mksh/pkg-descr'
XThe MirOS Korn Shell, which contains many additions to the original
XKorn shell.
X
XWWW: http://mirbsd.de/mksh
END-of-mksh/pkg-descr
echo x - mksh/pkg-install
sed 's/^X//' >mksh/pkg-install << 'END-of-mksh/pkg-install'
X#!/bin/sh
X#
X# $FreeBSD$
X#
X
XMKSH="${PKG_PREFIX-/usr/local}/bin/mksh"
XSHELLS="${PKG_DESTDIR-}/etc/shells"
X
Xcase $2 in
XPOST-INSTALL)
X  if [ -d "${SHELLS%/*}" ] && ! grep -qs "^$MKSH\$" "$SHELLS"; then
X    if [ `id -u` -eq 0 ]; then
X      echo "$MKSH" >> "$SHELLS"
X    else
X      echo "Not root, please add $MKSH to $SHELLS manually"
X    fi
X  fi
X  ;;
Xesac
END-of-mksh/pkg-install
exit
--- mksh-r27.e.shar ends here ---

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



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