From 640b9a14a5a3369c5cfe2bb5e9b4fd11a2aebf5a Mon Sep 17 00:00:00 2001 From: jkh Date: Tue, 4 Oct 1994 04:10:06 +0000 Subject: p2c - Pascal to C translator. By Jean-Marc Zucconi. Submitted by: jmz --- lang/p2c/Makefile | 12 ++++++++++++ lang/p2c/pkg-comment | 1 + lang/p2c/pkg-descr | 21 +++++++++++++++++++++ lang/p2c/pkg-plist | 16 ++++++++++++++++ lang/p2c/scripts/configure | 21 +++++++++++++++++++++ 5 files changed, 71 insertions(+) create mode 100644 lang/p2c/Makefile create mode 100644 lang/p2c/pkg-comment create mode 100644 lang/p2c/pkg-descr create mode 100644 lang/p2c/pkg-plist create mode 100644 lang/p2c/scripts/configure (limited to 'lang') diff --git a/lang/p2c/Makefile b/lang/p2c/Makefile new file mode 100644 index 000000000000..329565bb433c --- /dev/null +++ b/lang/p2c/Makefile @@ -0,0 +1,12 @@ +DISTNAME= p2c-1.21alpha-07.Dec.93 +DISTFILES= p2c-1.21alpha2.tar.gz +MASTER_SITES= ftp://src.doc.ic.ac.uk/gnu/hurd/ + +pre-install: + @mkdir -p /usr/local/lib + @mkdir -p /usr/local/man/man1 + @mkdir -p /usr/local/include/p2c + @cp ${WRKSRC}/src/p2cc.man /usr/local/man/man1/p2cc.1 + +.include + diff --git a/lang/p2c/pkg-comment b/lang/p2c/pkg-comment new file mode 100644 index 000000000000..aeb3c53ca218 --- /dev/null +++ b/lang/p2c/pkg-comment @@ -0,0 +1 @@ +p2c - Pascal to C translator, version 1.21alpha-07.Dec.93 diff --git a/lang/p2c/pkg-descr b/lang/p2c/pkg-descr new file mode 100644 index 000000000000..17a91b234b78 --- /dev/null +++ b/lang/p2c/pkg-descr @@ -0,0 +1,21 @@ +P2c is a tool for translating Pascal programs into C. The input +consists of a set of source files in any of the following Pascal +dialects: HP Pascal, Turbo/UCSD Pascal, DEC VAX Pascal, Oregon +Software Pascal/2, Macintosh Programmer's Workshop Pascal, +Sun/Berkeley Pascal, Texas Instruments Pascal, Apollo Domain Pascal. +Modula-2 syntax is also supported. Output is a set of .c and .h files +that comprise an equivalent program in any of several dialects of +C. Output code may be kept machine- and dialectindependent, or it may +be targeted to a specific machine and compiler. Most reasonable Pascal +programs are converted into fully functional C which will compile and +run with no further modifications, although p2c sometimes chooses to +generate readable code at the expense of absolute generality. P2c +endeavors to insert notes and warning messages into the output code to +point out areas which may require human intervention. Output code is +arranged to be readable and efficient, and to make use of C idioms +wherever possible. The main goal of the translation is to produce C +files which are pleasant and "natural" enough to be acceptable as the +new source files for a program. In a pinch, p2c will also serve as an +ad hoc Pascal compiler. The p2cc script makes it easy to use p2c as a +compiler. + diff --git a/lang/p2c/pkg-plist b/lang/p2c/pkg-plist new file mode 100644 index 000000000000..ea9796f35e06 --- /dev/null +++ b/lang/p2c/pkg-plist @@ -0,0 +1,16 @@ +@cd /usr/local +@owner bin +@mode 755 +bin/p2c +bin/p2cc +@mode 644 +lib/libp2c.a +man/man1/p2c.1 +man/man1/p2cc.1 +include/p2c/p2c.h +lib/p2c/p2crc +lib/p2c/loc.p2crc +lib/p2c/system.imp +lib/p2c/system.m2 +lib/p2c/turbo.imp +lib/p2c/string.pas diff --git a/lang/p2c/scripts/configure b/lang/p2c/scripts/configure new file mode 100644 index 000000000000..5ff74d5135f5 --- /dev/null +++ b/lang/p2c/scripts/configure @@ -0,0 +1,21 @@ +#!/bin/sh + +if [ $# != 3 ]; then exit 1; fi + +cat >>$3/Makefile < $3/src/p2cc.perl || exit 1; + +cat >>$3/src/Makefile <