| @@ -1,81 +1,81 @@ | | | @@ -1,81 +1,81 @@ |
1 | # $NetBSD: Makefile,v 1.71 2013/10/02 15:10:55 adam Exp $ | | 1 | # $NetBSD: Makefile,v 1.72 2013/10/02 15:13:46 adam Exp $ |
2 | | | 2 | |
3 | DISTNAME= gmp-5.1.3 | | 3 | DISTNAME= gmp-5.1.3 |
4 | CATEGORIES= devel math | | 4 | CATEGORIES= devel math |
5 | MASTER_SITES= ftp://ftp.gmplib.org/pub/${DISTNAME}/ | | 5 | MASTER_SITES= ftp://ftp.gmplib.org/pub/${DISTNAME}/ |
6 | # Use .tar.bz2 distfile so that no extra dependency on archivers/xz | | 6 | # Use .tar.bz2 distfile so that no extra dependency on archivers/xz |
7 | # is needed when building lang/gcc* with option gcc-inplace-math. | | 7 | # is needed when building lang/gcc* with option gcc-inplace-math. |
8 | EXTRACT_SUFX= .tar.xz | | 8 | EXTRACT_SUFX= .tar.bz2 |
9 | | | 9 | |
10 | MAINTAINER= pkgsrc-users@NetBSD.org | | 10 | MAINTAINER= pkgsrc-users@NetBSD.org |
11 | HOMEPAGE= http://gmplib.org/ | | 11 | HOMEPAGE= http://gmplib.org/ |
12 | COMMENT= Library for arbitrary precision arithmetic | | 12 | COMMENT= Library for arbitrary precision arithmetic |
13 | LICENSE= gnu-lgpl-v3 AND gnu-gpl-v3 | | 13 | LICENSE= gnu-lgpl-v3 AND gnu-gpl-v3 |
14 | | | 14 | |
15 | PKG_INSTALLATION_TYPES= overwrite pkgviews | | 15 | PKG_INSTALLATION_TYPES= overwrite pkgviews |
16 | | | 16 | |
17 | INFO_FILES= yes | | 17 | INFO_FILES= yes |
18 | USE_LANGUAGES= c c++ c99 | | 18 | USE_LANGUAGES= c c++ c99 |
19 | USE_LIBTOOL= yes | | 19 | USE_LIBTOOL= yes |
20 | USE_TOOLS+= gm4 autoconf makeinfo | | 20 | USE_TOOLS+= gm4 autoconf makeinfo |
21 | GNU_CONFIGURE= yes | | 21 | GNU_CONFIGURE= yes |
22 | CONFIGURE_ARGS+= --without-readline | | 22 | CONFIGURE_ARGS+= --without-readline |
23 | | | 23 | |
24 | TEST_TARGET= check | | 24 | TEST_TARGET= check |
25 | | | 25 | |
26 | PLIST_VARS+= cxx | | 26 | PLIST_VARS+= cxx |
27 | | | 27 | |
28 | .include "../../mk/bsd.prefs.mk" | | 28 | .include "../../mk/bsd.prefs.mk" |
29 | | | 29 | |
30 | .if !empty(USE_CROSS_COMPILE:M[yY][eE][sS]) | | 30 | .if !empty(USE_CROSS_COMPILE:M[yY][eE][sS]) |
31 | CONFIGURE_ENV+= CC_FOR_BUILD=${NATIVE_CC:Q} | | 31 | CONFIGURE_ENV+= CC_FOR_BUILD=${NATIVE_CC:Q} |
32 | .endif | | 32 | .endif |
33 | | | 33 | |
34 | .if empty(PKGSRC_COMPILER:Msunpro) | | 34 | .if empty(PKGSRC_COMPILER:Msunpro) |
35 | CONFIGURE_ARGS+= --enable-cxx | | 35 | CONFIGURE_ARGS+= --enable-cxx |
36 | PLIST.cxx= yes | | 36 | PLIST.cxx= yes |
37 | .endif | | 37 | .endif |
38 | | | 38 | |
39 | .if !empty(MACHINE_PLATFORM:MIRIX-5*) && !empty(ABI) | | 39 | .if !empty(MACHINE_PLATFORM:MIRIX-5*) && !empty(ABI) |
40 | ABI= o32 | | 40 | ABI= o32 |
41 | .endif | | 41 | .endif |
42 | | | 42 | |
43 | .if ${MACHINE_ARCH} == "arm" || ${MACHINE_ARCH} == "arm32" | | 43 | .if ${MACHINE_ARCH} == "arm" || ${MACHINE_ARCH} == "arm32" |
44 | # The configure script thinks gcc 2.95 for ARM is too buggy to use. | | 44 | # The configure script thinks gcc 2.95 for ARM is too buggy to use. |
45 | GCC_REQD+= 3.0 | | 45 | GCC_REQD+= 3.0 |
46 | .endif | | 46 | .endif |
47 | | | 47 | |
48 | .if ${MACHINE_ARCH} == "i386" | | 48 | .if ${MACHINE_ARCH} == "i386" |
49 | # XXX SunOS should work, but currently bombs in mpn/fat.c | | 49 | # XXX SunOS should work, but currently bombs in mpn/fat.c |
50 | . if ${OPSYS} == "Darwin" || ${OPSYS} == "SunOS" || !empty(PKGSRC_COMPILER:Msunpro) | | 50 | . if ${OPSYS} == "Darwin" || ${OPSYS} == "SunOS" || !empty(PKGSRC_COMPILER:Msunpro) |
51 | # don't use x86 assembly (it doesn't build) | | 51 | # don't use x86 assembly (it doesn't build) |
52 | CONFIGURE_ENV+= MPN_PATH="generic" | | 52 | CONFIGURE_ENV+= MPN_PATH="generic" |
53 | . else | | 53 | . else |
54 | PKG_OPTIONS_VAR= PKG_OPTIONS.gmp | | 54 | PKG_OPTIONS_VAR= PKG_OPTIONS.gmp |
55 | PKG_SUPPORTED_OPTIONS= gmp-fat mmx simd | | 55 | PKG_SUPPORTED_OPTIONS= gmp-fat mmx simd |
56 | PKG_SUGGESTED_OPTIONS= gmp-fat | | 56 | PKG_SUGGESTED_OPTIONS= gmp-fat |
57 | . include "../../mk/bsd.options.mk" | | 57 | . include "../../mk/bsd.options.mk" |
58 | ### | | 58 | ### |
59 | ### Support for a "fat" binary on i386. There's CPU autodetection, | | 59 | ### Support for a "fat" binary on i386. There's CPU autodetection, |
60 | ### so we'll be safe and filter out -march/-mcpu, et. al. | | 60 | ### so we'll be safe and filter out -march/-mcpu, et. al. |
61 | ### | | 61 | ### |
62 | ### XXX Currently, the 'mmx' and 'simd' options imply the same thing, | | 62 | ### XXX Currently, the 'mmx' and 'simd' options imply the same thing, |
63 | ### as cpu detection is done at runtime. Is there a more elegant | | 63 | ### as cpu detection is done at runtime. Is there a more elegant |
64 | ### way to handle this? | | 64 | ### way to handle this? |
65 | ### | | 65 | ### |
66 | . if empty(PKG_OPTIONS:Mgmp-fat) && \ | | 66 | . if empty(PKG_OPTIONS:Mgmp-fat) && \ |
67 | (!empty(PKG_OPTIONS:Mmmx) || !empty(PKG_OPTIONS:Msimd)) | | 67 | (!empty(PKG_OPTIONS:Mmmx) || !empty(PKG_OPTIONS:Msimd)) |
68 | PKG_OPTIONS+= gmp-fat | | 68 | PKG_OPTIONS+= gmp-fat |
69 | . endif | | 69 | . endif |
70 | . if !empty(PKG_OPTIONS:Mgmp-fat) | | 70 | . if !empty(PKG_OPTIONS:Mgmp-fat) |
71 | CONFIGURE_ARGS+= --enable-fat | | 71 | CONFIGURE_ARGS+= --enable-fat |
72 | BUILDLINK_TRANSFORM+= rm-optarg:-march rm-optarg:-mcpu | | 72 | BUILDLINK_TRANSFORM+= rm-optarg:-march rm-optarg:-mcpu |
73 | BUILDLINK_TRANSFORM+= rm:-mmmx rm:-msse rm:-msse2 rm:-msse3 rm:-m3dnow | | 73 | BUILDLINK_TRANSFORM+= rm:-mmmx rm:-msse rm:-msse2 rm:-msse3 rm:-m3dnow |
74 | . endif | | 74 | . endif |
75 | . endif | | 75 | . endif |
76 | .endif | | 76 | .endif |
77 | | | 77 | |
78 | pre-configure: | | 78 | pre-configure: |
79 | cd ${WRKSRC} && type autoconf && autoconf | | 79 | cd ${WRKSRC} && type autoconf && autoconf |
80 | | | 80 | |
81 | .include "../../mk/bsd.pkg.mk" | | 81 | .include "../../mk/bsd.pkg.mk" |