blob: c4da5cd835523881e84a7d1d8c5a40ec26dc2edc [file] [log] [blame]
Andrew Geissler82c905d2020-04-13 13:39:40 -05001DESCRIPTION = "TENEX C Shell, an enhanced version of Berkeley csh \
2 The TENEX C Shell is an enhanced version of the Berkeley Unix C shell. \
3 It includes all features of 4.4BSD C shell, plus a command-line editor, \
4 programmable word completion, spelling correction and more."
5
6HOMEPAGE = "http://www.tcsh.org/"
7LICENSE = "BSD-3-Clause"
8LIC_FILES_CHKSUM = "file://Copyright;md5=575cf2715c3bf894e1f79aec1d4eaaf5"
9SECTION = "base"
10DEPENDS = "ncurses virtual/crypt gettext-native"
11SRC_URI = " \
12 https://astron.com/pub/${BPN}/${BP}.tar.gz \
13 file://0001-Enable-system-malloc-on-all-linux.patch \
14 file://0002-Add-debian-csh-scripts.patch \
Andrew Geissler82c905d2020-04-13 13:39:40 -050015"
Andrew Geisslerf103a7f2021-05-07 16:09:40 -050016SRC_URI[md5sum] = "fa2b347fa9ae866eb036e6e4bb85fe1a"
17SRC_URI[sha256sum] = "eb16356243218c32f39e07258d72bf8b21e62ce94bb0e8a95e318b151397e231"
Andrew Geissler82c905d2020-04-13 13:39:40 -050018
19EXTRA_OEMAKE += "CC_FOR_GETHOST='${BUILD_CC}'"
20inherit autotools
21
Patrick Williams213cb262021-08-07 19:21:33 -050022do_compile:prepend() {
Patrick Williams0ca19cc2021-08-16 14:03:13 -050023 oe_runmake CC_FOR_GETHOST='${BUILD_CC}' CFLAGS='${BUILD_CFLAGS}' LDFLAGS='${BUILD_LDFLAGS}' gethost
Andrew Geissler82c905d2020-04-13 13:39:40 -050024}
25
Patrick Williams213cb262021-08-07 19:21:33 -050026do_install:append () {
Andrew Geissler82c905d2020-04-13 13:39:40 -050027 oe_runmake install.man DESTDIR=${D}
28
29 install -d ${D}${base_bindir}
30 ln -s /usr/bin/tcsh ${D}${base_bindir}/tcsh
31 ln -s /usr/bin/tcsh ${D}${base_bindir}/csh
32 install -d ${D}${sysconfdir}/csh/login.d
33 install -m 0644 ${S}/csh.cshrc ${S}/csh.login ${S}/csh.logout ${S}/complete.tcsh ${D}${sysconfdir}
34 install -D -m 0644 ${S}/csh-mode.el ${D}${datadir}/emacs/site-lisp/csh-mode.el
35}
36
Patrick Williams213cb262021-08-07 19:21:33 -050037FILES:${PN} += "${datadir}/emacs/site-lisp/csh-mode.el"
Andrew Geissler82c905d2020-04-13 13:39:40 -050038
39
Patrick Williams213cb262021-08-07 19:21:33 -050040pkg_postinst:${PN} () {
Andrew Geissler82c905d2020-04-13 13:39:40 -050041#!/bin/sh -e
42echo /usr/bin/tcsh >> $D/etc/shells
43echo /usr/bin/csh >> $D/etc/shells
44}