- #
- # ksh93.cygport
- #
- # Copyright (C) 2024, Roland Mainz <roland.mainz@nrubsig.org>
- #
- # This file is free software; I give unlimited permission to copy and/or
- # distribute it, with or without modifications, as long as this notice is
- # preserved.
- #
- NAME=ksh
- LICENSE="Eclipse Public License - v 2.0"
- HOMEPAGE="https://github.com/ksh93/ksh"
- VERSION=1.0.8
- RELEASE=0
- PKG_NAMES="ksh ksh_devel"
- ksh_SUMMARY="The AT&T Korn Shell"
- ksh_DESCRIPTION="Original version of the AT&T AST Korn Shell 93."
- ksh_CATEGORY="Base Shells"
- ksh_CONTENTS=" \
- bin/ksh.exe \
- bin/ksh93.exe \
- bin/rksh.exe \
- bin/rksh93.exe \
- etc/ksh.kshrc \
- usr/share/doc/ksh \
- usr/share/man/man1 \
- "
- ksh_devel_SUMMARY="Development files for AT&T ksh"
- ksh_devel_DESCRIPTION="This package contains development headers for AT&T ksh"
- ksh_devel_CATEGORY="Devel"
- ksh_devel_CONTENTS="usr/share/ksh \
- bin/shcomp.exe \
- "
- SRC_URI="https://github.com/ksh93/ksh/archive/refs/tags/v1.0.8.zip"
- PATCH_URI_BASE=""
- BUILD_REQUIRES=" \
- bash \
- coreutils \
- bison \
- gcc-g++ \
- libiconv-devel \
- libintl-devel \
- libncurses-devel \
- make \
- sed \
- texinfo \
- "
- CPPFLAGS=
- CYGCONF_ARGS=
- DIFF_EXCLUDES=
- DOCS=
- src_compile()
- {
- cd ${S}
- sed -i -r 's/mkfifo.+?(-m [[:digit:]]+)/mkfifo /g' ./src/cmd/INIT/package.sh ./bin/package
- if [[ "$ARCH" == 'i686' ]] ; then
- export SHELL=/bin/bash HOSTTYPE="cygwin.i386"; \
- /bin/bash ./bin/package make \
- CC="/usr/bin/cc -std=gnu17" CCFLAGS="-Os -g" SHELL="$SHELL" HOSTTYPE="$HOSTTYPE"
- elif [[ "$ARCH" == 'x86_64' ]] ; then
- export SHELL=/bin/bash HOSTTYPE="cygwin.i386-64"; \
- /bin/bash ./bin/package make \
- CC="/usr/bin/cc -std=gnu17" CCFLAGS="-Os -g" SHELL="$SHELL" HOSTTYPE="$HOSTTYPE"
- else
- # unsupported arch!
- false
- fi
- printf '# /etc/ksh.kshrc+~/.kshrc are sourced only for interactive shells\n' >${S}/etc_ksh_kshrc
- }
- #
- # install ksh, rksh, shcomp
- #
- src_install()
- {
- ls -lad ${B}
- ls -lad ${D}
- ls -lad ${S}
- /usr/bin/install -D -m0755 ${S}/arch/cygwin.i386-64/bin/ksh.exe ${D}/bin/ksh.exe
- ln ${D}/bin/ksh.exe ${D}/bin/rksh.exe
- ln ${D}/bin/ksh.exe ${D}/bin/ksh93.exe
- ln ${D}/bin/ksh.exe ${D}/bin/rksh93.exe
- /usr/bin/install -D -m0755 ${S}/arch/cygwin.i386-64/bin/ksh.exe ${D}/bin/shcomp.exe
- /usr/bin/install -D -m0644 ${S}/arch/cygwin.i386-64/man/man1/sh.1 ${D}/usr/share/man/man1/ksh.1
- /usr/bin/install -D -m0644 ${S}/etc_ksh_kshrc ${D}/etc/ksh.kshrc
- for i in ${S}/src/cmd/ksh93/tests/* ; do
- /usr/bin/install -D -m0644 $i ${D}/usr/share/ksh/tests/$(basename "$i")
- done
- }
- CYGWIN_MAINTAINER=Roland%20Mainz
- CYGWIN_MAINTAINER_EMAIL=roland.mainz@nrubsig.org
- CYGWIN_CO_MAINTAINER=Cedric%20Blancher
- CYGWIN_CO_MAINTAINER_EMAIL=cedric.blancher@gmail.com
- # EOF.
ksh93.cygport prototype
Posted by Anonymous on Sun 4th Feb 2024 14:28
raw | new post
view followups (newest first): ksh93.cygport prototype by Anonymous
modification of post by Anonymous (view diff)
Submit a correction or amendment below (click here to make a fresh posting)
After submitting an amendment, you'll be able to view the differences between the old and new posts easily.