summaryrefslogtreecommitdiff
path: root/shells/ksh93/Makefile
diff options
context:
space:
mode:
authorpin <pin@pkgsrc.org>2022-07-03 20:57:38 +0000
committerpin <pin@pkgsrc.org>2022-07-03 20:57:38 +0000
commite7a71fb626faecfc3f66888fb76567a5d78c60e0 (patch)
tree69c20e323eb62fdd4f852e82b122d2850c0c9d90 /shells/ksh93/Makefile
parent5960aab56f1d4e2f83a6e62a6deda183d3b120dd (diff)
downloadpkgsrc-e7a71fb626faecfc3f66888fb76567a5d78c60e0.tar.gz
shells/ksh93: import package
Packaged in wip by Paolo Vincenzo Olivo. Between 2017 and 2020 there was an ultimately unsuccessful attempt to breathe new life into the KornShell by extensively refactoring the last unstable AST beta version (93v-). While that ksh2020 effort is now abandoned and still has many critical bugs, it also had a lot of bugs fixed. More importantly, the AST issue tracker now contains a lot of documentation on how to fix those bugs, which made it possible to backport many of them to the last stable release instead. This ksh 93u+m reboot now incorporates many of these bugfixes, plus patches from OpenSUSE, Red Hat, and Solaris, as well as many new fixes from the community (1, 2). Though there are many bugs left to fix, we are confident at this point that 93u+m is already the least buggy version of ksh93 ever released. As of late 2021, distributions such as Debian and Slackware have begun to package it as their default version of ksh93.
Diffstat (limited to 'shells/ksh93/Makefile')
-rw-r--r--shells/ksh93/Makefile51
1 files changed, 51 insertions, 0 deletions
diff --git a/shells/ksh93/Makefile b/shells/ksh93/Makefile
new file mode 100644
index 00000000000..73c0e18bcee
--- /dev/null
+++ b/shells/ksh93/Makefile
@@ -0,0 +1,51 @@
+# $NetBSD: Makefile,v 1.1 2022/07/03 20:57:38 pin Exp $
+
+DISTNAME= v1.0.0-beta.2
+PKGVER= ${DISTNAME:S,^v,,:S,-beta,,}
+PKGNAME= ${GITHUB_PROJECT}93-${PKGVER}
+CATEGORIES= shells
+MASTER_SITES= ${MASTER_SITE_GITHUB:=ksh93/}
+GITHUB_PROJECT= ksh
+GITHUB_TAG= ${DISTNAME}
+
+MAINTAINER= vms@retrobsd.ddns.net
+HOMEPAGE= https://github.com/ksh93/ksh/
+COMMENT= Actively developed fork of AT&T KornShell 93u+
+LICENSE= epl-v1.0
+
+CONFLICTS+= ast-ksh-[0-9]* static-ast-ksh-[0-9]*
+
+USE_LANGUAGES= c
+FORTIFY_SUPPORTED= no
+
+KSH= ${TOOLS_PATH.ksh:Q}
+
+MAKEFLAGS+= CC=${CC:Q} SHELL=${KSH}
+MAKEFLAGS+= CCFLAGS=${CFLAGS:M*:Q}
+
+CFLAGS.SunOS+= -std=c11 -D__EXTENSIONS__
+
+PKG_SHELL= bin/ksh93
+
+INSTALLATION_DIRS= bin ${PKGMANDIR}/man1
+
+WRKSRC= ${WRKDIR}/ksh-${DISTNAME:S,^v,,}
+
+do-build:
+ cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} \
+ ${KSH} ./bin/package make ${MAKEFLAGS}
+
+do-install:
+ set -e; \
+ arch=`${WRKSRC}/bin/package host`; \
+ ${INSTALL_PROGRAM} ${WRKSRC}/arch/"$${arch}"/bin/ksh \
+ ${DESTDIR}${PREFIX}/bin/ksh93
+
+ ${INSTALL_MAN} ${WRKSRC}/src/cmd/ksh93/sh.1 \
+ ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1/ksh93.1
+
+do-test:
+ cd ${WRKSRC} && ${SETENV} SHELL=${KSH} \
+ ${KSH} ./bin/package test
+
+.include "../../mk/bsd.pkg.mk"