From 061748f3fdeed2d0bf72f3208986a9b4ad58b49b Mon Sep 17 00:00:00 2001 From: Cy Schubert Date: Tue, 28 Jun 2011 19:09:14 +0000 Subject: Bring back this port. --- shells/44bsd-csh/Makefile | 46 ++++++++++++++++++++++++++++++++++ shells/44bsd-csh/distinfo | 2 ++ shells/44bsd-csh/files/patch-proc.c | 50 +++++++++++++++++++++++++++++++++++++ shells/44bsd-csh/pkg-descr | 2 ++ shells/44bsd-csh/pkg-plist | 3 +++ 5 files changed, 103 insertions(+) create mode 100644 shells/44bsd-csh/Makefile create mode 100644 shells/44bsd-csh/distinfo create mode 100644 shells/44bsd-csh/files/patch-proc.c create mode 100644 shells/44bsd-csh/pkg-descr create mode 100644 shells/44bsd-csh/pkg-plist (limited to 'shells') diff --git a/shells/44bsd-csh/Makefile b/shells/44bsd-csh/Makefile new file mode 100644 index 000000000000..3185ecce70f8 --- /dev/null +++ b/shells/44bsd-csh/Makefile @@ -0,0 +1,46 @@ +# ex:ts=8 +# Ports collection makefile for: csh +# Date created: 23 January 2000 +# Whom: David O'Brien +# +# $FreeBSD$ +# +PORTNAME= 44bsd-csh +PORTVERSION= 20001106 +CATEGORIES= shells +MASTER_SITES= ${MASTER_SITE_LOCAL} +MASTER_SITE_SUBDIR= cy + +MAINTAINER= cy@FreeBSD.org +COMMENT= The traditional 4.4BSD /bin/csh C-shell + +USE_BZIP2= yes + +NO_WRKSUBDIR= yes +MAN1= 44bsd-csh.1 +PORTDOCS= paper.ascii.gz +post-extract: + cd ${WRKSRC} ; co RCS/*,v + cd ${WRKSRC}/USD.doc ; co RCS/*,v + +post-build: + cd ${WRKSRC}/USD.doc ; ${MAKE} + +do-install: + ${INSTALL_PROGRAM} ${WRKSRC}/csh ${PREFIX}/bin/44bsd-csh + ${INSTALL_MAN} ${WRKSRC}/csh.1 ${PREFIX}/man/man1/44bsd-csh.1 +.if !defined(NOPORTDOCS) + @${MKDIR} ${DOCSDIR} + @${INSTALL_DATA} ${WRKSRC}/USD.doc/paper.ascii.gz ${DOCSDIR} +.endif + @${ECHO_MSG} "Updating /etc/shells" + @${CP} /etc/shells /etc/shells.bak + @(${GREP} -v ${PREFIX}/bin/44bsd-csh /etc/shells.bak; \ + ${ECHO_CMD} ${PREFIX}/bin/44bsd-csh) > /etc/shells + @${RM} /etc/shells.bak + +tarup: + cd ${WRKSRC} ; rm * USD.doc/* + cd ${WRKSRC} ; ${TAR} cvyf /tmp/${PORTNAME}-${PORTVERSION}${EXTRACT_SUFX} + +.include diff --git a/shells/44bsd-csh/distinfo b/shells/44bsd-csh/distinfo new file mode 100644 index 000000000000..32898dce2054 --- /dev/null +++ b/shells/44bsd-csh/distinfo @@ -0,0 +1,2 @@ +SHA256 (44bsd-csh-20001106.tar.bz2) = 8dafbb6862ab39ac4530106e2a61a5691a8fa7563e8e8564194265bec1d55ff1 +SIZE (44bsd-csh-20001106.tar.bz2) = 160312 diff --git a/shells/44bsd-csh/files/patch-proc.c b/shells/44bsd-csh/files/patch-proc.c new file mode 100644 index 000000000000..d938524ed34f --- /dev/null +++ b/shells/44bsd-csh/files/patch-proc.c @@ -0,0 +1,50 @@ +$FreeBSD$ + +--- proc.c Tue Jun 4 20:07:29 2002 ++++ proc.c Tue Jun 4 20:14:09 2002 +@@ -89,13 +89,13 @@ + int pid; + extern int insource; + int save_errno = errno; +- union wait w; ++ int w; + int jobflags; + struct rusage ru; + + loop: + errno = 0; /* reset, just in case */ +- pid = wait3(&w.w_status, ++ pid = wait3(&w, + (setintr && (intty || insource) ? WNOHANG | WUNTRACED : WNOHANG), &ru); + + if (pid <= 0) { +@@ -117,7 +117,7 @@ + pp->p_flags &= ~(PRUNNING | PSTOPPED | PREPORTED); + if (WIFSTOPPED(w)) { + pp->p_flags |= PSTOPPED; +- pp->p_reason = w.w_stopsig; ++ pp->p_reason = WSTOPSIG(w); + } + else { + if (pp->p_flags & (PTIME | PPTIME) || adrof(STRtime)) +@@ -125,16 +125,16 @@ + + pp->p_rusage = ru; + if (WIFSIGNALED(w)) { +- if (w.w_termsig == SIGINT) ++ if (WTERMSIG(w) == SIGINT) + pp->p_flags |= PINTERRUPTED; + else + pp->p_flags |= PSIGNALED; +- if (w.w_coredump) ++ if (WCOREDUMP(w)) + pp->p_flags |= PDUMPED; +- pp->p_reason = w.w_termsig; ++ pp->p_reason = WTERMSIG(w); + } + else { +- pp->p_reason = w.w_retcode; ++ pp->p_reason = WEXITSTATUS(w); + if (pp->p_reason != 0) + pp->p_flags |= PAEXITED; + else diff --git a/shells/44bsd-csh/pkg-descr b/shells/44bsd-csh/pkg-descr new file mode 100644 index 000000000000..ae3f22251328 --- /dev/null +++ b/shells/44bsd-csh/pkg-descr @@ -0,0 +1,2 @@ +This is the traditional 4.4BSD /bin/csh C-shell, with additional +FreeBSD fixes and updates since 4.4BSD Lite was released. diff --git a/shells/44bsd-csh/pkg-plist b/shells/44bsd-csh/pkg-plist new file mode 100644 index 000000000000..f70d1ad837e2 --- /dev/null +++ b/shells/44bsd-csh/pkg-plist @@ -0,0 +1,3 @@ +bin/44bsd-csh +@exec echo "updating /etc/shells"; cp /etc/shells /etc/shells.bak; (grep -v %D/%F /etc/shells.bak; echo %D/%F) >/etc/shells +@unexec echo "updating /etc/shells"; cp /etc/shells /etc/shells.bak; (grep -v %D/%F /etc/shells.bak) >/etc/shells -- cgit v1.2.3