aboutsummaryrefslogtreecommitdiffstats
path: root/lang/gcc/Makefile
blob: 7dfd6210c0dc2a0c67ec8e76200dcea98be515e5 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
# ex:ts=8 
# Ports collection makefile for:    egcs 
# Date created:             9 Jan 1998
# Whom:                 John Polstra <jdp@polstra.com>
#
# $FreeBSD$
#

SNAPDATE=   2002-02-25
SNAPVER=    ${SNAPDATE:S/-//g}

PORTNAME=   gcc-devel
PORTVERSION=    ${SNAPVER}
CATEGORIES= lang java
MASTER_SITES=   ${MASTER_SITE_SOURCEWARE}  \
        ftp://ftp.netwinder.org/pub/build/gcc/i386/${SNAPVER}/ \
        ftp://egcs.cygnus.com/pub/egcs/snapshots/${SNAPDATE}/
MASTER_SITE_SUBDIR= gcc/snapshots/${SNAPDATE}
DISTFILES=  \
        gcc-core-${SNAPVER}${EXTRACT_SUFX} \
        gcc-g++-${SNAPVER}${EXTRACT_SUFX} \
        gcc-g77-${SNAPVER}${EXTRACT_SUFX} \
        gcc-java-${SNAPVER}${EXTRACT_SUFX} \
        gcc-objc-${SNAPVER}${EXTRACT_SUFX}
#       gcc-ss-3.1-0_${SNAPVER}.src.rpm

MAINTAINER= obrien@FreeBSD.org

LATEST_LINK=    gcc31
NO_CDROM=   'dated material'

.if defined(NETWINDER_SS)
BUILD_DEPENDS=  rpm:${PORTSDIR}/archivers/rpm

EXTRACT_CMD=        rpm2cpio
EXTRACT_BEFORE_ARGS=
EXTRACT_AFTER_ARGS= |cpio -idum
EXTRACT_ONLY=
.endif
PATCH_ARGS= -d ${SRCDIR} -E ${PATCH_STRIP}
.if !defined(PATCH_DEBUG)
PATCH_ARGS+=    --forward --quiet
.endif
PATCH_WRKDIR=   ${SRCDIR}
#CONFIGURE_SCRIPT=  ../gcc-${SNAPVER}/configure
CONFIGURE_SCRIPT=   ../${SRCDIR:C/${WRKDIR}//}/configure

.include <bsd.port.pre.mk>

.if ${PORTOBJFORMAT} == "elf"
CONFIGURE_TARGET=   ${ARCH}-portbld-freebsd${OSREL}
.else
CONFIGURE_TARGET=   ${ARCH}-portbld-freebsdaout${OSREL}
.endif

#GCC_REV=   ${PORTVERSION:C/\.0$//}
GCC_REV=    3.1
#SRCDIR=        ${WRKDIR}/gcc-${GCC_REV}
SRCDIR=     ${WRKDIR}/gcc-${SNAPVER}
WRKSRC=     ${WRKDIR}/build
TARGLIB=    ${PREFIX}/lib/gcc-lib/${CONFIGURE_TARGET}/${GCC_REV}
PLIST_SUB=  GCC_REV=${GCC_REV} GNU_HOST=${CONFIGURE_TARGET}  \
        SNAPVER=${SNAPVER}
GNU_CONFIGURE=  yes
USE_GMAKE=  yes
USE_BISON=  yes
CONFIGURE_ARGS= --disable-nls --with-gnu-as --with-gnu-ld \
        --with-gxx-include-dir=${TARGLIB}/include/g++
#CONFIGURE_ARGS+=   --program-prefix=e
.if defined(WANT_SHAREDLIBS)
CONFIGURE_ARGS+= --enable-shared
.else
CONFIGURE_ARGS+= --disable-shared
.endif
.if defined(WANT_THREADS_SUPPORT)
CONFIGURE_ARGS+= --enable-threads
#   ?is this an ObjC only thing?
CONFIGURE_ARGS+= --enable-threads=posix
.endif
ALL_TARGET= bootstrap
#MAN1=      gcpp.1 gg++.1 gg77.1 ggcc.1 ggcov.1
MAN1=       gg++.1

pre-fetch:
    @${ECHO} "Making GCC ${DISTNAME:S/^gcc-//} for ${OPSYS} ${OSREL} ${PORTOBJFORMAT}   target ${ARCH}-portbld-freebsd${OSREL}"

.if defined(NETWINDER_SS)
post-extract:
.for F in ${DISTFILES}
    cd ${WRKDIR} ; rpm2cpio ${DISTDIR}/$F |cpio -idum
.endfor
    cd ${WRKDIR} ; ${TAR} -xzf gcc-${SNAPVER}.tar.gz
    cd ${WRKDIR} ; ${LN} -sf gcc gcc-${SNAPVER}
.endif

pre-configure:
    @# Keep from running `autoconf' and `autoheader' since we modified
    @# configure.in by patching it.
    @touch ${SRCDIR}/gcc/configure
    @touch ${SRCDIR}/gcc/cstamp-h.in
    @${MKDIR} ${CONFIGURE_WRKSRC}

pre-build:
    cd ${SRCDIR} ; contrib/gcc_update --touch

pre-install:
    ${MKDIR} ${PREFIX}/info

post-install:
    @${RM} -f ${PREFIX}/bin/c++ ${PREFIX}/bin/${CONFIGURE_TARGET}-c++
    @${MV} -f ${PREFIX}/bin/c++filt ${PREFIX}/bin/g++filt
    @(for prog in ${PREFIX}/bin/gcc ${PREFIX}/bin/g++ \
        ${PREFIX}/bin/g++filt ${PREFIX}/bin/g77 ${PREFIX}/bin/gcov \
        ${PREFIX}/bin/${CONFIGURE_TARGET}-gcc \
        ${PREFIX}/lib/gcc-lib/${CONFIGURE_TARGET}/${GCC_REV}/cc1 \
        ${PREFIX}/lib/gcc-lib/${CONFIGURE_TARGET}/${GCC_REV}/cc1obj \
        ${PREFIX}/lib/gcc-lib/${CONFIGURE_TARGET}/${GCC_REV}/cc1plus \
        ${PREFIX}/lib/gcc-lib/${CONFIGURE_TARGET}/${GCC_REV}/cpp0 \
        ${PREFIX}/lib/gcc-lib/${CONFIGURE_TARGET}/${GCC_REV}/collect2 \
        ${PREFIX}/lib/gcc-lib/${CONFIGURE_TARGET}/${GCC_REV}/f771 ; \
    do \
        strip $$prog ; \
    done )
.for file in gcc g++ cpp g++filt gcov
    ${MV} -f ${PREFIX}/bin/${file} ${PREFIX}/bin/g${file}
    -( test -e ${PREFIX}/man/man1/${file}.1 \
        && ${MV} -f ${PREFIX}/man/man1/${file}.1 \
        ${PREFIX}/man/man1/g${file}.1 )
.endfor
.for file in g77
    ${MV} -f ${PREFIX}/bin/${file} ${PREFIX}/bin/g${file}
    #${MV} -f ${PREFIX}/man/man1/${file}.1 ${PREFIX}/man/man1/g${file}.1
.endfor
    ${MV} -f ${PREFIX}/bin/gccbug ${PREFIX}/bin/gccbug-${SNAPVER}
    # These 3 libraries are moved from PREFIX/lib to avoid conflicts
    #   with the stock compiler.
    ${MV} -f ${PREFIX}/lib/libiberty.a ${TARGLIB}
    ${MV} -f ${PREFIX}/lib/libstdc++.* ${PREFIX}/lib/libsupc++.* ${TARGLIB}
    -${MV} -f ${PREFIX}/lib/ieee ${TARGLIB}
#.if defined(WANT_SHAREDLIBS)
#   ${MV} -f ${PREFIX}/lib/libstdc++.so* ${TARGLIB}
#.endif
.for info in cpp g77 gcc
    install-info ${PREFIX}/info/${info}.info ${PREFIX}/info/dir
.endfor
    cd ${PREFIX} ;\
        ${FIND} ${TARGLIB:S/^${PREFIX}\///} -type f -o -type l  \
            >${WRKDIR}/PLIST.gcc-lib
    cd ${PREFIX} ;\
        ${FIND} ${TARGLIB:S/^${PREFIX}\///} -type d \
            | sort -r | ${SED} -e 's/^/@dirrm /g' >>${WRKDIR}/PLIST.gcc-lib
    ${ECHO_CMD} "r ${TMPPLIST}"     > ${WRKDIR}/ex.script
    ${ECHO_CMD} "/Insert PLIST.gcc-lib" >> ${WRKDIR}/ex.script
    ${ECHO_CMD} "d"             >> ${WRKDIR}/ex.script
    ${ECHO_CMD} "r ${WRKDIR}/PLIST.gcc-lib" >> ${WRKDIR}/ex.script
    ${ECHO_CMD} "x!"            >> ${WRKDIR}/ex.script
    ${CP} -p ${TMPPLIST} ${TMPPLIST}.pre-gcc-lib
    cd ${WRKDIR} ; ex < ex.script

.include <bsd.port.post.mk>
s'>-0/+1 * Add pecl-fribidi 1.0, a PECL extension for the unicode Bidi algorithm.ale2004-07-194-0/+36 * Updated to 1.4skv2004-07-193-3/+38 * Back out prev. commit. Too many ports depends on it and IGNOREache2004-07-161-7/+1 * Don't install this port, if ${PERL_LEVEL} >= 500804ache2004-07-161-1/+7 * Only perl 5.8.4 have Base64 3.01, use 500804 as PERL_LEVELache2004-07-151-1/+1 * Add including pre/post.mk, missing in prev. commitache2004-07-151-1/+3 * Do not install p5-MIME-Base64 for newer perlsache2004-07-151-0/+3 * Update to 1.03. Assign maintainership to perl@.tobez2004-07-143-19/+4 * Update to 1.9.2bland2004-07-106-28/+25 * Apply a big libtool patch to allow porters to use the libtool installed bymarcus2004-07-105-5/+5 * Updated to 1.3skv2004-07-033-7/+3 * Remove xunicode, which is obsolete and no longer used by any otherknu2004-06-225-44/+0 * Set an expiry date of 2004-08-20 for these BROKEN/IGNORE/FORBIDDENkris2004-06-221-0/+2 * - Chase enca shlib bumppav2004-06-081-1/+2 * - Update to 1.5pav2004-06-084-18/+21 * Take over maintanership.bland2004-06-081-1/+1 * Take over maintanership.bland2004-06-081-1/+1 * - Fix fetchingmarkus2004-06-072-4/+2 * - Fix fetchingpav2004-06-071-2/+2 * - Remove dead master sitepav2004-06-071-2/+1 * - Chase 302 redirect in master sitepav2004-06-071-1/+1 * - Chase 302 redirect in master sitespav2004-06-071-1/+1 * Don't use Makefile.kde anymoremarkus2004-06-061-4/+3 * BROKEN on amd64: neds to link against shared librarykris2004-05-301-1/+7 * - Remove dead WWWpav2004-05-301-2/+0 * - Update WWWpav2004-05-301-1/+1 * Add p5-Convert-Binary-C 0.53, binary Data Conversion using C Types.skv2004-05-265-0/+47 * Canonicalize inclusion of master-port's Makefile.linimon2004-05-191-1/+1 * - Remove bogus directorieskrion2004-05-181-2/+0 * - Add missing patch, forgotten by my previous commitkrion2004-05-181-0/+12 * - Update to version 1.8-9krion2004-05-183-845/+850 * This port is actually libutf-8 version 1.0, not libutf version 8.1.0.eik2004-05-151-3/+3 * Reset maintainership. Adam has experienced a machine failure and islinimon2004-05-152-2/+2 * Reset maintainership. Although Adam is the author of the port, illnesslinimon2004-05-151-1/+1 * Respect CC flag.osa2004-05-053-9/+7 * Whitespace cleanup.nork2004-05-041-1/+0 * Move converters/cvs2svn to devel/cvs2svn to correct category.perky2004-05-016-69/+0 * Add new port for cvs2svn 0.0.938 (snapshot),perky2004-05-016-0/+69 * These broken ports are scheduled for deletion on June 18 if they arekris2004-04-191-0/+2 * Correct plist and manpages (add a missing entry and don't remove fileskris2004-04-172-4/+3 * Add missing @dirrmkris2004-04-131-0/+1 * Trim leading or trailing blank lines.trevor2004-04-111-1/+0 * Chase the glib20 update, and bump all affected ports' PORTREVISIONs.marcus2004-04-051-1/+1 * Remove category pkg/COMMENT files in favour of a COMMENT variable in thekris2004-04-022-1/+2 * SIZEify (maintainer timeout)trevor2004-03-3129-0/+29 * - Use USE_ICONV knobkrion2004-03-314-8/+4 * Update to 3.01erwin2004-03-312-3/+3 * - SIZEifymarkus2004-03-291-0/+1 * If inews exists in ${PREFIX}/bin/, then use that instead of usinghoek2004-03-251-3/+13 * Update to 0.5.20 to fix two buffer overflowshoek2004-03-254-8/+6 * Upgrade to 0.5.20 to fix two buffer overflowshoek2004-03-252-6/+4 * Update my email address and make a slight formatting improvement.hoek2004-03-253-9/+9 * Add p5-Convert-BinHex 1.119, perl module to extract data from Macintoshvanilla2004-03-255-0/+37 * - only shared libraries should be build with -fPIC on amd64 and ia64leeym2004-03-242-23/+41 * Add SIZE data.knu2004-03-223-0/+3 * Mastersite seems not to respond (since January).linimon2004-03-221-1/+1 * USE_ICONV.knu2004-03-211-1/+1 * Add size data, approved by maintainers.trevor2004-03-212-0/+2 * Add size data.nork2004-03-201-0/+1 * mark FORBIDDEN: http://people.freebsd.org/~eik/portaudit/6c7661ff-7912-11d8-9...eik2004-03-192-0/+4 * Add size data, approved by maintainers.trevor2004-03-191-0/+1 * Add size data, approved by maintainers.trevor2004-03-198-0/+8 * Fix installation with perl 5.8mat2004-03-181-0/+1 * - Add SIZE to GNOME portspav2004-03-183-0/+3 * - Add SIZEpav2004-03-181-0/+1 * Build and install the bundled iconv module when built with Ruby 1.8.knu2004-03-182-11/+32 * Add SIZE data.perky2004-03-183-0/+3 * SIZEifyijliao2004-03-181-0/+1 * Add size data.trevor2004-03-181-0/+1 * SIZEify my ports.leeym2004-03-181-0/+1 * SIZEifyeik2004-03-181-0/+2 * o Bump $LIB_DEPENDS line to chase expat's shlib version.kuriyama2004-03-141-1/+2 * Whoa there, boy, that's a mighty big commit y'all have there...ade2004-03-145-5/+5 * Since asami's directory on MASTER_SITE_LOCAL is gone, stow histrevor2004-03-131-1/+1 * Date: Wed, 10 Mar 2004 23:30:56 -0800 (PST)edwin2004-03-121-1/+1 * - SIZEifykrion2004-03-081-0/+1 * BROKEN on ia64: Segfault during buildkris2004-03-071-1/+7 * Fix build: replace BUILD_DEPENDS with EXTRACT_DEPENDS where appropriatesanpei2004-02-251-2/+2 * Change my email address.markus2004-02-241-1/+1 * Take maintainership.bland2004-02-231-1/+1 * BROKEN: Checksum mismatchkris2004-02-221-0/+2 * BROKEN: unfetchablekris2004-02-191-0/+2 * Use PLIST_FILES. Drop maintainership.trevor2004-02-181-5/+2 * Remove ktnef, it is now included in kdepimarved2004-02-105-70/+0 * - Fix build on AMD64krion2004-02-101-0/+2 * Add a check for USE_ICONV, and if found, error out. This will avoid forkmarcus2004-02-091-0/+5 * - Fix build on AMD64krion2004-02-091-0/+1 * Back out my previous commit, which was in error.trevor2004-02-091-5/+0 * Add "anti-foot-shooting device".trevor2004-02-091-0/+5 * Use PLIST_FILES (bento-tested, marcus-reviewed).trevor2004-02-0616-8/+9 * Use PLIST_FILES.trevor2004-02-062-1/+1 * Minor clean (use USE_ICONV, etc.)skv2004-02-063-3/+3 * Bump PORTREVISION on all ports that depend on gettext to aid with upgrading.marcus2004-02-046-1/+6 * Add USE_GETTEXT and bump PORTREVISION.marcus2004-02-041-3/+2 * SIZEify.trevor2004-01-299-0/+9 * Add size data.trevor2004-01-281-0/+1 * Now gettext 0.12.1 is gettext-old.trevor2004-01-241-1/+1 * - Update to 0.5.19clement2004-01-182-3/+2 * - Respect CFLAGS and PTHREAD_LIBSclement2004-01-181-1/+7 * - Chase uulib versionclement2004-01-181-2/+2 * - Update to 0.5.19clement2004-01-183-31/+3 * - Update to 0.5.19clement2004-01-186-33/+13 * Update to 3.00erwin2004-01-153-14/+2 * - Fix usage of isXDIGIT() by calling the isxdigit() macroerwin2004-01-132-7/+13 * Somehow, 'make test' doesn't catch all problems. Mark brokenerwin2004-01-121-1/+7 * Move PERL_CONFIGURE before bsd.port.pre.mk.kuriyama2004-01-121-2/+2 * Update to 2.23, which somehow ended uncommitted in my tree.erwin2004-01-122-2/+2 * [PATCH] converters/p5-Convert-ASN1: update to 0.18edwin2004-01-102-2/+2 * Update to 2.22erwin2004-01-092-2/+2 * New port: converters/fix-mime-charset - Fix incorrect Content-Typeedwin2004-01-085-0/+51 * cosmetic fixes which make portlint happy.leeym2004-01-082-6/+6 * - Assign maintainership to Markus Bruefferkrion2004-01-081-1/+1 * - Drop maintainership to ports@krion2004-01-081-1/+1 * Add converters/asr10; provides access to Ensoniq EPS/EPS+/ASR deviceslinimon2004-01-065-0/+37 * Update to 1.0.3perky2004-01-043-2/+6 * update MASTER_SITESmharo2003-12-171-1/+1 * Update to 1.2.osa2003-12-174-18/+21 * - Update to 1.2.1 (now hosted at SourceForge)sergei2003-12-085-103/+29 * Add shftool 1.1.0, converter for the Standard Hex Format (SHF).sergei2003-12-085-0/+40 * Update to 1.0.tobez2003-12-053-2/+17 * Update to 1.1.2perky2003-12-042-2/+2 * Update to 1.0.2perky2003-12-043-2/+10 * USE_REINPLACE need be defined only when REINPLACE_CMD is used.trevor2003-11-171-1/+0 * Update maintainer field with my FreeBSD.org address.pav2003-11-141-1/+1 * switch my ports to my FreeBSD addresseik2003-11-141-1/+1 * ports with possibly unreachable MAINTAINERsedwin2003-11-022-2/+2 * Remove the recursive assignment of SITE_PERL to ${SITE_PERL} introducederwin2003-10-242-2/+0 * utilize SITE_PERLijliao2003-10-2418-207/+204 * new port of showkeytrevor2003-10-245-0/+52 * Cosmetic fix: use %%DOCSDIR%% macro.osa2003-10-227-39/+39 * Changed at maintainer's request.linimon2003-10-214-10/+9 * Changed per maintainer request. Shortened pkg-descr to pacify portlint.linimon2003-10-212-6/+5 * This ports require Python version 2.1 at least.perky2003-10-192-2/+2 * Split up multi-file patch into separate fileskris2003-10-199-128/+245 * Respect CC and CFLAGSkris2003-10-191-4/+8 * Respect CC and CFLAGSkris2003-10-191-6/+17 * Add depricated charset names to mapping. They still required by olderbland2003-10-142-3/+12 * - Starting from FreeBSD 4.6 we have nl_langinfo(CODESET) supported. Thereforebland2003-10-143-6/+42 * Add p5-Cstools 3.42, tools for dealing with Czech encodings in Perl.mat2003-10-135-0/+59 * Add CONFLICTS.lofi2003-10-111-0/+2 * Update to 2.21erwin2003-10-102-2/+2 * use SITE_PERLerwin2003-10-101-8/+8 * Update to 0.31mat2003-10-024-13/+11 * Update to 0.31.01mat2003-10-024-9/+11 * WWW site and MASTER_SITE is moved to BerliOS.perky2003-09-262-3/+2 * Update to 1.0.1perky2003-09-263-5/+4 * Use ${STRIP_CMD} instead of /usr/bin/strip.osa2003-09-241-2/+2 * Make portlint(1) happy by changing strip to ${STRIP_CMD}osa2003-09-241-1/+1 * Update to 2.07mat2003-09-025-24/+35 * Update to 0.12mat2003-09-02