aboutsummaryrefslogtreecommitdiffstats
path: root/lang/lcc/Makefile
diff options
context:
space:
mode:
authorobrien <obrien@FreeBSD.org>1996-12-27 19:09:49 +0800
committerobrien <obrien@FreeBSD.org>1996-12-27 19:09:49 +0800
commitf6949eb19328270d37e7919c2fccb2b4b7835af2 (patch)
tree454eaafa83be88cf5da914b56ea6b258f308437a /lang/lcc/Makefile
parent8fea0992b9e43d5bb3edf7dacfe6cf88d381aaad (diff)
downloadfreebsd-ports-gnome-f6949eb19328270d37e7919c2fccb2b4b7835af2.tar.gz
freebsd-ports-gnome-f6949eb19328270d37e7919c2fccb2b4b7835af2.tar.zst
freebsd-ports-gnome-f6949eb19328270d37e7919c2fccb2b4b7835af2.zip
lcc is the retargetable ANSI C compiler described in the book
`A Retargetable C Compiler: Design and Implementation' (Addison-Wesley, 1995, ISBN 0-8053-1670-1). lcc is a production compiler with a hand crafted lexical analyzer and a hand-coded recursive decent parser. The lexer and parser code is well written and very easy to read (and learn from :-)). lcc compiles much faster than FreeBSD's stock [gcc] compiler. However, it does not under stand FreeBSD's "long long" data type. Contributions by: Soren Schmidt
Diffstat (limited to 'lang/lcc/Makefile')
-rw-r--r--lang/lcc/Makefile52
1 files changed, 52 insertions, 0 deletions
diff --git a/lang/lcc/Makefile b/lang/lcc/Makefile
new file mode 100644
index 000000000000..851823ecae1e
--- /dev/null
+++ b/lang/lcc/Makefile
@@ -0,0 +1,52 @@
+# ex:ts=8
+# Ports collection makefile for: lcc
+# Version required: 3.6
+# Date created: Sat Dec 7, 1996
+# Whom: David O'Brien (obrien@cs.ucdavis.edu)
+#
+# $Id: Makefile,v 1.1.1.1 1996/08/09 04:17:16 asami Exp $
+#
+
+DISTNAME= lcc-3.6
+CATEGORIES= lang
+MASTER_SITES= ftp://ftp.cs.princeton.edu/pub/packages/lcc/
+
+MAINTAINER= obrien@FreeBSD.org
+#origial [and extensive] patches by Soren Schmidt / sos@freebsd.org
+
+MAKEFILE= makefile
+MAKE_FLAGS= BUILDDIR=${LCCBUILDDIR} HOSTFILE=etc/${OPSYS}.c -f
+MAN1= bprint.1 lcc.1
+
+UNAME_M!= uname -m
+LCCBUILDDIR= ${WRKDIR}/${UNAME_M}-${OPSYS}
+LCCDESTDIR= lib/${DISTNAME}/${UNAME_M}-${OPSYS}
+
+pre-configure:
+ @${MKDIR} ${LCCBUILDDIR}
+ @${CP} ${FILESDIR}/${OPSYS}.md ${WRKSRC}/src
+ @sed -e "s:%%PREFIX%%:${PREFIX}:g" \
+ -e "s:%%LCCDESTDIR%%:${LCCDESTDIR}:g" \
+ -e "s:%%VERSION%%:${DISTNAME}:g" \
+ ${FILESDIR}/${OPSYS}.c.in > ${WRKSRC}/etc/${OPSYS}.c
+ @sed -e "s:%%LCCDESTDIR%%:${LCCDESTDIR}:g" \
+ ${PKGDIR}/PLIST.in > ${PKGDIR}/PLIST
+ @sed -e "s:%%OPSYS%%:${OPSYS}:g" \
+ ${WRKSRC}/makefile > ${WRKSRC}/makefile.configured
+ @/bin/mv -f ${WRKSRC}/makefile.configured ${WRKSRC}/makefile
+
+do-install:
+ @(umask 022 ; ${MKDIR} ${PREFIX}/${LCCDESTDIR})
+ @${INSTALL_PROGRAM} ${LCCBUILDDIR}/lcc \
+ ${LCCBUILDDIR}/rcc \
+ ${LCCBUILDDIR}/cpp \
+ ${LCCBUILDDIR}/bprint \
+ ${LCCBUILDDIR}/bbexit.o \
+ ${PREFIX}/${LCCDESTDIR}
+ @/bin/ln -sf ${PREFIX}/${LCCDESTDIR}/lcc ${PREFIX}/bin
+ @/bin/ln -sf ${PREFIX}/${LCCDESTDIR}/bprint ${PREFIX}/bin
+ @${INSTALL_MAN} ${WRKSRC}/doc/lcc.1 ${WRKSRC}/doc/bprint.1 \
+ ${PREFIX}/man/man1
+
+
+.include <bsd.port.mk>