aboutsummaryrefslogtreecommitdiff
path: root/lang/pcc
diff options
context:
space:
mode:
authorKurt Jaeger <pi@FreeBSD.org>2016-06-13 19:53:48 +0000
committerKurt Jaeger <pi@FreeBSD.org>2016-06-13 19:53:48 +0000
commit697a609b23a042d483fc9a1759676244bba2df08 (patch)
tree709ff8055ec6f8d8240548b2cf69152b618eec45 /lang/pcc
parent6befa538a2267fa431c576b7fb7de0a4fbabf365 (diff)
downloadports-697a609b23a042d483fc9a1759676244bba2df08.tar.gz
ports-697a609b23a042d483fc9a1759676244bba2df08.zip
lang/pcc: 1.0.0 -> 1.1.0
- Add RUN_DEPENDS on devel/pcc-libs port on the same version - Adapt PLIST_FILES - Add THREADS option to "Enable Thread-local storage (TLS)" - Add new patch for ${WRKSRC}/cc/cc/cc.c file, related to inverted MULTIARCH_PATH define check - Replace some static patches with sed patches - Remove unneeded patches for this version PR: 196642 Submitted by: Sender Ghost <lightside@gmx.com> Approved by: joel (maintainer)
Notes
Notes: svn path=/head/; revision=416864
Diffstat (limited to 'lang/pcc')
-rw-r--r--lang/pcc/Makefile39
-rw-r--r--lang/pcc/distinfo4
-rw-r--r--lang/pcc/files/ccconfig.h55
-rw-r--r--lang/pcc/files/f77config.h55
-rw-r--r--lang/pcc/files/patch-cc_cc_cc.c11
-rw-r--r--lang/pcc/files/patch-cccc-Makefile.in13
-rw-r--r--lang/pcc/files/patch-configure11
7 files changed, 40 insertions, 148 deletions
diff --git a/lang/pcc/Makefile b/lang/pcc/Makefile
index 7a9667a1c579..63c228d30703 100644
--- a/lang/pcc/Makefile
+++ b/lang/pcc/Makefile
@@ -2,7 +2,7 @@
# $FreeBSD$
PORTNAME= pcc
-PORTVERSION= 1.0.0
+PORTVERSION= 1.1.0
CATEGORIES= lang
MASTER_SITES= ftp://pcc.ludd.ltu.se/pub/pcc-releases/ \
http://pcc.ludd.ltu.se/ftp/pub/pcc-releases/ \
@@ -11,29 +11,44 @@ MASTER_SITES= ftp://pcc.ludd.ltu.se/pub/pcc-releases/ \
MAINTAINER= joel@FreeBSD.org
COMMENT= Portable C Compiler
+LICENSE= BSDCOMPATIBLE BSD2CLAUSE BSD3CLAUSE
+LICENSE_COMB= multi
+LICENSE_NAME_BSDCOMPATIBLE= BSD-style compatible licenses
+LICENSE_TEXT_BSDCOMPATIBLE= The license: BSDCOMPATIBLE (${LICENSE_NAME_BSDCOMPATIBLE}),\
+ please read from the web: http://pcc.ludd.ltu.se/licenses/
+LICENSE_PERMS_BSDCOMPATIBLE= dist-mirror dist-sell pkg-mirror pkg-sell auto-accept
+
+RUN_DEPENDS= pcc-libs>=${PORTVERSION}:devel/pcc-libs
+
ONLY_FOR_ARCHS= i386 amd64
USES= gmake tar:tgz
GNU_CONFIGURE= yes
CONFIGURE_ENV= YACC=${YACC}
-PLIST_FILES= bin/pcc libexec/ccom libexec/cpp \
+PLIST_FILES= bin/pcc bin/pcpp \
+ libexec/ccom libexec/cxxcom libexec/cpp \
man/man1/ccom.1.gz man/man1/cpp.1.gz \
man/man1/pcc.1.gz
MAKE_JOBS_UNSAFE= yes
-# Fix -jX builds: use -C switch instead of cd'ing and add missing dependency
+OPTIONS_DEFINE= THREADS
+OPTIONS_DEFAULT= THREADS
+THREADS_DESC= Enable Thread-local storage (TLS)
+THREADS_CONFIGURE_ENABLE= tls
+
+.include <bsd.port.pre.mk>
post-patch:
- @${FIND} ${WRKSRC} -name Makefile.in | ${XARGS} ${REINPLACE_CMD} -E \
- 's/cd (.+)(;| &&) (\$$[{(]MAKE[})][^$$]*)( \$$\(MFLAGS\))?/\3 -C \1/'
- @${ECHO_CMD} 'builtins.o: pass1.h' >> ${WRKSRC}/cc/ccom/Makefile.in
-
-pre-configure:
- ${MKDIR} ${WRKSRC}/os/freebsd
- ${CP} ${FILESDIR}/*.h ${WRKSRC}/os/freebsd
- ${REINPLACE_CMD} -e "s,%%OSVERMAJOR%%,${OSREL:R}," \
+ # Don't make empty directories, which created by devel/pcc-libs port
+ @${REINPLACE_CMD} -e '/mkdir -p.*PCC.*DIR/d' \
+ ${WRKSRC}/cc/cc/Makefile.in
+.if ${OPSYS} == FreeBSD
+ @${REINPLACE_CMD} -e '/targmach=amd64/s/x86_64/amd64/' \
+ ${WRKSRC}/configure
+ @${REINPLACE_CMD} -e 's,\" MKS(TARGOSVER),${OSREL:R}\",' \
${WRKSRC}/os/freebsd/ccconfig.h
+.endif
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
diff --git a/lang/pcc/distinfo b/lang/pcc/distinfo
index 630de5ec0cf0..11ace1d19a32 100644
--- a/lang/pcc/distinfo
+++ b/lang/pcc/distinfo
@@ -1,2 +1,2 @@
-SHA256 (pcc-1.0.0.tgz) = 5802dbba46d6ea3f9badaa55b9044a0416bb410020c24a5c2a8a2eaaf41156cb
-SIZE (pcc-1.0.0.tgz) = 652308
+SHA256 (pcc-1.1.0.tgz) = d9e3fed84c767dcddefb6b1f854d5da8921f3f65d8bd02997743412f41474d64
+SIZE (pcc-1.1.0.tgz) = 848427
diff --git a/lang/pcc/files/ccconfig.h b/lang/pcc/files/ccconfig.h
deleted file mode 100644
index 0dafa8f839d3..000000000000
--- a/lang/pcc/files/ccconfig.h
+++ /dev/null
@@ -1,55 +0,0 @@
-/* $FreeBSD$ */
-/* $Id: ccconfig.h,v 1.2 2004/12/02 21:32:25 ragge Exp $ */
-
-/*
- * Copyright (c) 2007 David O'Brien
- * Copyright (c) 2004 Anders Magnusson (ragge@ludd.luth.se).
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- * 3. The name of the author may not be used to endorse or promote products
- * derived from this software without specific prior written permission
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-/*
- * Various settings that controls how the C compiler works.
- */
-
-/* common cpp predefines */
-#define CPPADD { "-D__FreeBSD__=%%OSVERMAJOR%%", "-D__ELF__", "-D__unix__=1", "-D__unix=1", "-D__STDC__=1", NULL, }
-#define DYNLINKER { "-dynamic-linker", "/libexec/ld-elf.so.1", NULL }
-#define CRT0FILE "/usr/lib/crt1.o"
-#define STARTFILES { "/usr/lib/crti.o", "/usr/lib/crtbegin.o", NULL }
-#define ENDFILES { "/usr/lib/crtend.o", "/usr/lib/crtn.o", NULL }
-#define STARTLABEL "_start"
-
-/*
- * XXX multitargets ?
- */
-#if defined(mach_i386) || defined(mach_x86)
-#define CPPMDADD { "-D__i386__", "-D__i386", NULL, }
-#elif defined(mach_amd64)
-#define CPPMDADD { "-D__x86_64__", NULL, }
-#else
-#error defines for arch missing
-#endif
-
-#define STABS
diff --git a/lang/pcc/files/f77config.h b/lang/pcc/files/f77config.h
deleted file mode 100644
index 0367d78e431d..000000000000
--- a/lang/pcc/files/f77config.h
+++ /dev/null
@@ -1,55 +0,0 @@
-/* $FreeBSD$ */
-/* $Id: f77config.h,v 1.1 2005/04/17 20:22:18 ragge Exp $ */
-
-/*
- * Copyright (c) 2004 Anders Magnusson (ragge@ludd.luth.se).
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- * 3. The name of the author may not be used to endorse or promote products
- * derived from this software without specific prior written permission
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-/*
- * Various settings that controls how the f77 compiler works.
- */
-
-#if 0
-/* common cpp predefines */
-#define CPPADD { "-D__FreeBSD__", "-D__ELF__", NULL, }
-#define DYNLINKER { "-dynamic-linker", "/libexec/ld-elf.so.1", NULL }
-#define CRT0FILE "/usr/lib/crt0.o"
-#define STARTFILES { "/usr/lib/crti.o", "/usr/lib/crtbegin.o", NULL }
-#define ENDFILES { "/usr/lib/crtend.o", "/usr/lib/crtn.o", NULL }
-#endif
-#define PASS1NAME "/usr/lib/f77pass1"
-#define PASS2NAME "/lib/f1"
-#define PASS2OPT "/lib/c2"
-#define NOFLPASS2 "/lib/fc1"
-
-#define ASMNAME "/usr/bin/as"
-#define LDNAME "/usr/bin/ld"
-#define FOOTNAME "/usr/lib/crt0.o"
-#define PROFFOOT "/usr/lib/mcrt0.o"
-#define NOFLFOOT "/usr/lib/fcrt0.o"
-#define NOFLPROFFOOT "/usr/lib/fmcrt0.o"
-#define LIBLIST { "-lF77", "-lI77", "-lm", "-lc", "-l", NULL };
-
diff --git a/lang/pcc/files/patch-cc_cc_cc.c b/lang/pcc/files/patch-cc_cc_cc.c
new file mode 100644
index 000000000000..0c47ef06f44f
--- /dev/null
+++ b/lang/pcc/files/patch-cc_cc_cc.c
@@ -0,0 +1,11 @@
+--- cc/cc/cc.c.orig 2014-12-06 09:52:55 UTC
++++ cc/cc/cc.c
+@@ -206,7 +206,7 @@ char *cppmdadd[] = CPPMDADD;
+ #define PCCLIBDIR NULL
+ #endif
+ #ifndef DEFLIBDIRS /* default library search paths */
+-#ifdef MULTIARCH_PATH
++#ifndef MULTIARCH_PATH
+ #define DEFLIBDIRS { "/usr/lib/", 0 }
+ #else
+ #define DEFLIBDIRS { "/usr/lib/", "/usr/lib/" MULTIARCH_PATH "/", 0 }
diff --git a/lang/pcc/files/patch-cccc-Makefile.in b/lang/pcc/files/patch-cccc-Makefile.in
deleted file mode 100644
index f52adfb01bd2..000000000000
--- a/lang/pcc/files/patch-cccc-Makefile.in
+++ /dev/null
@@ -1,13 +0,0 @@
-Index: cc/cc/Makefile.in
-@@ -59,8 +59,9 @@
- fi
- test -z "${DESTDIR}$(mandir)/man1" || mkdir -p "${DESTDIR}$(mandir)/man1"
- ${INSTALL} $(srcdir)/cc.1 ${DESTDIR}${mandir}/man1/${DEST}.1
-- test -z "${DESTDIR}$(PCCINCDIR)" || mkdir -p "${DESTDIR}$(PCCINCDIR)"
-- test -z "${DESTDIR}$(PCCLIBDIR)" || mkdir -p "${DESTDIR}$(PCCLIBDIR)"
-+ # Don't make unused empty directories for no reason.
-+ #test -z "${DESTDIR}$(PCCINCDIR)" || mkdir -p "${DESTDIR}$(PCCINCDIR)"
-+ #test -z "${DESTDIR}$(PCCLIBDIR)" || mkdir -p "${DESTDIR}$(PCCLIBDIR)"
-
- clean:
- /bin/rm -f $(OBJS) ${DEST}
diff --git a/lang/pcc/files/patch-configure b/lang/pcc/files/patch-configure
deleted file mode 100644
index 36da158c7122..000000000000
--- a/lang/pcc/files/patch-configure
+++ /dev/null
@@ -1,11 +0,0 @@
---- configure.orig 2010-10-31 18:20:51.000000000 +0000
-+++ configure 2010-11-07 15:22:25.000000000 +0000
-@@ -1960,7 +1960,7 @@
- esac
- case "$target_cpu" in
- i386) targmach=i386 ;;
-- x86_64) targmach=amd64 ;;
-+ amd64) targmach=amd64 ;;
- esac
- ;;
-