Upgrade to LLVM GCC release 2.3.
Take maintainership since this needs to be updated with devel/llvm. General Makefile cleanup.
This commit is contained in:
parent
6cd633c412
commit
a64121ee05
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=214718
5 changed files with 52 additions and 71 deletions
|
@ -6,14 +6,13 @@
|
|||
#
|
||||
|
||||
PORTNAME= gcc4
|
||||
PORTVERSION= 2.2
|
||||
PORTREVISION= 1
|
||||
PORTVERSION= 2.3
|
||||
CATEGORIES= lang devel
|
||||
MASTER_SITES= http://llvm.org/releases/${PORTVERSION}/
|
||||
PKGNAMEPREFIX= llvm-
|
||||
DISTNAME= ${PKGNAMEPREFIX}${PORTNAME}.2-${PORTVERSION}.source
|
||||
DISTNAME= ${PKGNAMEPREFIX}gcc-4.2-${PORTVERSION}.source
|
||||
|
||||
MAINTAINER= emil@cs.rmit.edu.au
|
||||
MAINTAINER= brooks@FreeBSD.org
|
||||
COMMENT= A gcc4 frontend for LLVM
|
||||
|
||||
BUILD_DEPENDS= llc:${PORTSDIR}/devel/llvm
|
||||
|
@ -23,23 +22,25 @@ USE_BISON= build
|
|||
USE_GMAKE= yes
|
||||
USE_ICONV= yes
|
||||
USE_PERL5_BUILD=yes
|
||||
ONLY_FOR_ARCHS= i386 amd64
|
||||
|
||||
GCC_VER= 4.2.1
|
||||
WRKSRC= ${WRKDIR}/${DISTNAME}/build
|
||||
TARGLIB= ${PREFIX}/lib/gcc-llvm-${PORTVERSION}
|
||||
WRKSRC= ${WRKDIR}/${DISTNAME:S/gcc-/gcc/}/obj
|
||||
TARGLIB= ${PREFIX}/lib/llvm-gcc-${PORTVERSION}
|
||||
CONFIGURE_SCRIPT= ../configure
|
||||
CONFIGURE_ARGS= --enable-llvm=${LOCALBASE}\
|
||||
--enable-languages=c,c++\
|
||||
--disable-nls\
|
||||
--with-system-zlib\
|
||||
--with-libiconv-prefix=${LOCALBASE}\
|
||||
--program-prefix=llvm-\
|
||||
--libdir=${TARGLIB}\
|
||||
--with-gxx-include-dir=${TARGLIB}/include/c++\
|
||||
--libexecdir=${TARGLIB}\
|
||||
CONFIGURE_ARGS= --enable-llvm=${LOCALBASE} \
|
||||
--enable-languages=c,c++ \
|
||||
--disable-nls \
|
||||
--with-system-zlib \
|
||||
--with-libiconv-prefix=${LOCALBASE} \
|
||||
--program-prefix=llvm- \
|
||||
--libdir=${TARGLIB} \
|
||||
--with-gxx-include-dir=${TARGLIB}/include/c++ \
|
||||
--libexecdir=${TARGLIB} \
|
||||
--infodir=${PREFIX}/llvm-gcc
|
||||
PLIST_SUB= GCC_VER=${GCC_VER}\
|
||||
.if defined(MAINTAINER_MODE)
|
||||
CONFIGURE_ARGS+= --enable-checking
|
||||
.endif
|
||||
PLIST_SUB= GCC_VER=${GCC_VER} \
|
||||
GNU_HOST=${CONFIGURE_TARGET}
|
||||
INFO= llvm-gcc/cpp \
|
||||
llvm-gcc/cppinternals \
|
||||
|
@ -49,21 +50,17 @@ INFO= llvm-gcc/cpp \
|
|||
llvm-gcc/libgomp
|
||||
MAN1= llvm-cpp.1 llvm-g++.1 llvm-gcc.1 llvm-gcov.1
|
||||
|
||||
.include <bsd.port.pre.mk>
|
||||
|
||||
.if ${ARCH} == "amd64"
|
||||
CONFIGURE_TARGET= x86_64-portbld-freebsd${OSREL}
|
||||
CONFIGURE_ARGS+= --disable-shared
|
||||
.endif
|
||||
|
||||
post-extract:
|
||||
@${MKDIR} ${WRKSRC}
|
||||
|
||||
post-patch:
|
||||
@${REINPLACE_CMD} -e 's,LLVMBASEPATH/Release/bin/llc,LLVMBASEPATH/bin/llc,'\
|
||||
${WRKSRC}/../gcc/configure\
|
||||
${WRKSRC}/../libcpp/configure
|
||||
@${REINPLACE_CMD}\
|
||||
-e 's,LLVMBINPATH = .*,LLVMBINPATH = @LLVMBASEPATH@/bin,'\
|
||||
-e 's,LLVMSRCDIR := .*,LLVMSRCDIR = @LLVMBASEPATH@,'\
|
||||
${WRKSRC}/../gcc/Makefile.in
|
||||
|
||||
post-install:
|
||||
${RM} -f ${PREFIX}/man/man7/fsf-funding.7 \
|
||||
${PREFIX}/man/man7/gfdl.7 ${PREFIX}/man/man7/gpl.7
|
||||
# Add target libraries and include files to packaging list.
|
||||
${RM} -f ${WRKDIR}/PLIST.lib
|
||||
.for d in ${TARGLIB:S/^${PREFIX}\///}
|
||||
|
@ -75,13 +72,4 @@ post-install:
|
|||
.endfor
|
||||
cd ${WRKDIR} ; ${SED} -i -e "/PLIST.lib/ r PLIST.lib" ${TMPPLIST}
|
||||
|
||||
.include <bsd.port.pre.mk>
|
||||
|
||||
.if ${ARCH} == "amd64"
|
||||
CONFIGURE_TARGET= x86_64-portbld-freebsd${OSREL}
|
||||
CONFIGURE_ARGS+= --disable-shared
|
||||
.else
|
||||
CONFIGURE_TARGET= ${ARCH}-portbld-freebsd${OSREL}
|
||||
.endif
|
||||
|
||||
.include <bsd.port.post.mk>
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
MD5 (llvm-gcc4.2-2.2.source.tar.gz) = 7591c949eed3efc7a8b802b8f97effcc
|
||||
SHA256 (llvm-gcc4.2-2.2.source.tar.gz) = 77e24456d620f16fb515c2ddd898c922ac80a9cac59faae43098996339b27287
|
||||
SIZE (llvm-gcc4.2-2.2.source.tar.gz) = 49160222
|
||||
MD5 (llvm-gcc-4.2-2.3.source.tar.gz) = 18aa4f8226ddab58af2f12cff135470d
|
||||
SHA256 (llvm-gcc-4.2-2.3.source.tar.gz) = 4a2f571d1c8dd5217aa1f8918e56f5d7e2a0d4cdd0b3cb54aa886247ff550780
|
||||
SIZE (llvm-gcc-4.2-2.3.source.tar.gz) = 49113763
|
||||
|
|
24
lang/llvm-gcc4/files/patch-.._gcc_Makefile.in
Normal file
24
lang/llvm-gcc4/files/patch-.._gcc_Makefile.in
Normal file
|
@ -0,0 +1,24 @@
|
|||
|
||||
$FreeBSD$
|
||||
|
||||
--- ../gcc/Makefile.in.orig
|
||||
+++ ../gcc/Makefile.in
|
||||
@@ -3805,7 +3805,7 @@
|
||||
echo rm -f $(@D)/*
|
||||
$(TEXI2HTML) -I $(abs_docdir) -I $(abs_docdir)/include -o $(@D) $<
|
||||
|
||||
-MANFILES = doc/gcov.1 doc/cpp.1 doc/gcc.1 doc/gfdl.7 doc/gpl.7 doc/fsf-funding.7
|
||||
+MANFILES = doc/gcov.1 doc/cpp.1 doc/gcc.1
|
||||
|
||||
generated-manpages: man
|
||||
|
||||
@@ -4118,9 +4118,6 @@
|
||||
$(DESTDIR)$(man1dir)/$(GCC_INSTALL_NAME)$(man1ext) \
|
||||
$(DESTDIR)$(man1dir)/$(CPP_INSTALL_NAME)$(man1ext) \
|
||||
$(DESTDIR)$(man1dir)/$(GCOV_INSTALL_NAME)$(man1ext) \
|
||||
- $(DESTDIR)$(man7dir)/fsf-funding$(man7ext) \
|
||||
- $(DESTDIR)$(man7dir)/gfdl$(man7ext) \
|
||||
- $(DESTDIR)$(man7dir)/gpl$(man7ext)
|
||||
|
||||
$(DESTDIR)$(man7dir)/%$(man7ext): doc/%.7 installdirs
|
||||
-rm -f $@
|
|
@ -1,18 +0,0 @@
|
|||
Author: asl
|
||||
Date: Wed Sep 26 02:36:55 2007
|
||||
New Revision: 42351
|
||||
|
||||
Log:
|
||||
FreeBSD really supports #pragma pack(push). This fixes PR1702
|
||||
|
||||
==============================================================================
|
||||
--- ../gcc/config/freebsd.h (original)
|
||||
+++ ../gcc/config/freebsd.h Wed Sep 26 02:36:55 2007
|
||||
@@ -85,3 +85,7 @@
|
||||
This enables the test coverage code to use file locking when exiting a
|
||||
program, which avoids race conditions if the program has forked. */
|
||||
#define TARGET_HAS_F_SETLKW
|
||||
+
|
||||
+/* LLVM LOCAL begin */
|
||||
+#define HANDLE_PRAGMA_PACK_PUSH_POP
|
||||
+/* LLVM LOCAL end */
|
|
@ -1,13 +0,0 @@
|
|||
--- ../gcc/config/freebsd-spec.h.orig 2007-12-21 20:20:55.000000000 -0500
|
||||
+++ ../gcc/config/freebsd-spec.h 2007-12-21 20:21:32.000000000 -0500
|
||||
@@ -75,7 +75,9 @@
|
||||
#define FBSD_TARGET_OS_CPP_BUILTINS() \
|
||||
do \
|
||||
{ \
|
||||
- if (FBSD_MAJOR == 7) \
|
||||
+ if (FBSD_MAJOR == 8) \
|
||||
+ builtin_define ("__FreeBSD__=8"); \
|
||||
+ else if (FBSD_MAJOR == 7) \
|
||||
builtin_define ("__FreeBSD__=7"); \
|
||||
else if (FBSD_MAJOR == 6) \
|
||||
builtin_define ("__FreeBSD__=6"); \
|
Loading…
Reference in a new issue