| @@ -1,80 +1,79 @@ | | | @@ -1,80 +1,79 @@ |
1 | # $NetBSD: Makefile,v 1.10 2018/01/03 00:42:46 rillig Exp $ | | 1 | # $NetBSD: Makefile,v 1.11 2018/01/03 22:43:23 rillig Exp $ |
2 | | | 2 | |
3 | DISTNAME= gcc-7.2.0 | | 3 | DISTNAME= gcc-7.2.0 |
4 | PKGNAME= cross-arm-none-eabi-${DISTNAME} | | 4 | PKGNAME= cross-arm-none-eabi-${DISTNAME} |
5 | CATEGORIES= cross | | 5 | CATEGORIES= cross |
6 | NEWLIBVER= 2.5.0 | | 6 | NEWLIBVER= 2.5.0 |
7 | MASTER_SITES= ${MASTER_SITE_GNU:=gcc/gcc-${PKGVERSION_NOREV}/} | | 7 | MASTER_SITES= ${MASTER_SITE_GNU:=gcc/gcc-${PKGVERSION_NOREV}/} |
8 | DISTFILES= ${DEFAULT_DISTFILES} \ | | 8 | DISTFILES= ${DEFAULT_DISTFILES} \ |
9 | newlib-${NEWLIBVER}.tar.gz | | 9 | newlib-${NEWLIBVER}.tar.gz |
10 | SITES.newlib-${NEWLIBVER}.tar.gz= ftp://sources.redhat.com/pub/newlib/ | | 10 | SITES.newlib-${NEWLIBVER}.tar.gz= ftp://sources.redhat.com/pub/newlib/ |
11 | | | 11 | |
12 | | | 12 | |
13 | MAINTAINER= ryoon@NetBSD.org | | 13 | MAINTAINER= ryoon@NetBSD.org |
14 | HOMEPAGE= # none | | 14 | HOMEPAGE= # none |
15 | COMMENT= GCC for bare metal ARM EABI | | 15 | COMMENT= GCC for bare metal ARM EABI |
16 | LICENSE= gnu-gpl-v2 | | | |
17 | | | 16 | |
18 | EXTRACT_USING= bsdtar | | 17 | EXTRACT_USING= bsdtar |
19 | | | 18 | |
20 | | | 19 | |
21 | # for http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33549 | | 20 | # for http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33549 |
22 | # use makeinfo from pkgsrc/devel/gtexinfo. | | 21 | # use makeinfo from pkgsrc/devel/gtexinfo. |
23 | TOOL_DEPENDS+= gtexinfo>=5.1:../../devel/gtexinfo | | 22 | TOOL_DEPENDS+= gtexinfo>=5.1:../../devel/gtexinfo |
24 | _TOOLS_USE_PKGSRC.makeinfo= yes | | 23 | _TOOLS_USE_PKGSRC.makeinfo= yes |
25 | | | 24 | |
26 | DEPENDS+= cross-arm-none-eabi-binutils-[0-9]*:../../cross/arm-none-eabi-binutils | | 25 | DEPENDS+= cross-arm-none-eabi-binutils-[0-9]*:../../cross/arm-none-eabi-binutils |
27 | | | 26 | |
28 | USE_LANGUAGES+= c c++ | | 27 | USE_LANGUAGES+= c c++ |
29 | | | 28 | |
30 | ARMELF_PREFIX= ${PREFIX}/cross-arm-none-eabi | | 29 | ARMELF_PREFIX= ${PREFIX}/cross-arm-none-eabi |
31 | OBJDIR= ../build | | 30 | OBJDIR= ../build |
32 | CONFIGURE_DIRS= ${OBJDIR} | | 31 | CONFIGURE_DIRS= ${OBJDIR} |
33 | CONFIGURE_SCRIPT= ../${DISTNAME}/configure | | 32 | CONFIGURE_SCRIPT= ../${DISTNAME}/configure |
34 | | | 33 | |
35 | CONFIG_SHELL= ${TOOLS_PATH.bash} | | 34 | CONFIG_SHELL= ${TOOLS_PATH.bash} |
36 | WRAPPER_SHELL= ${TOOLS_PATH.bash} | | 35 | WRAPPER_SHELL= ${TOOLS_PATH.bash} |
37 | USE_TOOLS+= bash perl | | 36 | USE_TOOLS+= bash perl |
38 | | | 37 | |
39 | USE_TOOLS+= gmake makeinfo | | 38 | USE_TOOLS+= gmake makeinfo |
40 | GNU_CONFIGURE= yes | | 39 | GNU_CONFIGURE= yes |
41 | | | 40 | |
42 | GNU_CONFIGURE_PREFIX= ${ARMELF_PREFIX} | | 41 | GNU_CONFIGURE_PREFIX= ${ARMELF_PREFIX} |
43 | | | 42 | |
44 | HOSTDIR= build-${MACHINE_ARCH}--${LOWER_OPSYS} | | 43 | HOSTDIR= build-${MACHINE_ARCH}--${LOWER_OPSYS} |
45 | | | 44 | |
46 | CONFIGURE_ARGS+= --target=arm-none-eabi | | 45 | CONFIGURE_ARGS+= --target=arm-none-eabi |
47 | CONFIGURE_ARGS+= --enable-languages=c,c++ | | 46 | CONFIGURE_ARGS+= --enable-languages=c,c++ |
48 | CONFIGURE_ARGS+= --with-newlib | | 47 | CONFIGURE_ARGS+= --with-newlib |
49 | CONFIGURE_ARGS+= --disable-nls | | 48 | CONFIGURE_ARGS+= --disable-nls |
50 | CONFIGURE_ARGS+= --disable-libstdcxx-pch | | 49 | CONFIGURE_ARGS+= --disable-libstdcxx-pch |
51 | | | 50 | |
52 | INFO_FILES= yes | | 51 | INFO_FILES= yes |
53 | | | 52 | |
54 | CONFIGURE_ARGS+= --enable-${PLUGIN_NAME}-plugin | | 53 | CONFIGURE_ARGS+= --enable-${PLUGIN_NAME}-plugin |
55 | | | 54 | |
56 | PLIST_VARS+= libcpp | | 55 | PLIST_VARS+= libcpp |
57 | | | 56 | |
58 | .include "../../mk/compiler.mk" | | 57 | .include "../../mk/compiler.mk" |
59 | .if !empty(PKGSRC_COMPILER:Mclang) | | 58 | .if !empty(PKGSRC_COMPILER:Mclang) |
60 | # geattrtab on neon.md results in a very deeply nested expression | | 59 | # geattrtab on neon.md results in a very deeply nested expression |
61 | # with > 255 brackets. This was reported against GCC 4.9.1 at least | | 60 | # with > 255 brackets. This was reported against GCC 4.9.1 at least |
62 | # already, but it seems noone cares enough in GCC to fix the generator. | | 61 | # already, but it seems noone cares enough in GCC to fix the generator. |
63 | CFLAGS+= -fbracket-depth=1024 | | 62 | CFLAGS+= -fbracket-depth=1024 |
64 | .endif | | 63 | .endif |
65 | | | 64 | |
66 | .if ${OPSYS} == "FreeBSD" || ${OPSYS} == "Linux" || ${OPSYS} == "NetBSD" || ${OPSYS} == "SunOS" | | 65 | .if ${OPSYS} == "FreeBSD" || ${OPSYS} == "Linux" || ${OPSYS} == "NetBSD" || ${OPSYS} == "SunOS" |
67 | PLIST.libcpp= yes | | 66 | PLIST.libcpp= yes |
68 | .endif | | 67 | .endif |
69 | | | 68 | |
70 | post-extract: | | 69 | post-extract: |
71 | ${LN} -s ${WRKDIR}/newlib-${NEWLIBVER}/newlib ${WRKSRC}/newlib | | 70 | ${LN} -s ${WRKDIR}/newlib-${NEWLIBVER}/newlib ${WRKSRC}/newlib |
72 | ${LN} -s ${WRKDIR}/newlib-${NEWLIBVER}/libgloss ${WRKSRC}/libgloss | | 71 | ${LN} -s ${WRKDIR}/newlib-${NEWLIBVER}/libgloss ${WRKSRC}/libgloss |
73 | | | 72 | |
74 | pre-configure: | | 73 | pre-configure: |
75 | ${RUN} cd ${WRKSRC} && ${MKDIR} ${OBJDIR} | | 74 | ${RUN} cd ${WRKSRC} && ${MKDIR} ${OBJDIR} |
76 | | | 75 | |
77 | .include "../../devel/gmp/buildlink3.mk" | | 76 | .include "../../devel/gmp/buildlink3.mk" |
78 | .include "../../math/mpfr/buildlink3.mk" | | 77 | .include "../../math/mpfr/buildlink3.mk" |
79 | .include "../../math/mpcomplex/buildlink3.mk" | | 78 | .include "../../math/mpcomplex/buildlink3.mk" |
80 | .include "../../mk/bsd.pkg.mk" | | 79 | .include "../../mk/bsd.pkg.mk" |