summaryrefslogtreecommitdiff
path: root/devel/gmp/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'devel/gmp/Makefile')
-rw-r--r--devel/gmp/Makefile24
1 files changed, 21 insertions, 3 deletions
diff --git a/devel/gmp/Makefile b/devel/gmp/Makefile
index 1d027d0c97a..78811061582 100644
--- a/devel/gmp/Makefile
+++ b/devel/gmp/Makefile
@@ -1,6 +1,6 @@
-# $NetBSD: Makefile,v 1.45 2007/10/16 23:49:02 tnn Exp $
+# $NetBSD: Makefile,v 1.46 2007/10/30 01:36:59 bjs Exp $
-DISTNAME= gmp-4.2.1
+DISTNAME= gmp-4.2.2
CATEGORIES= devel math
MASTER_SITES= ${MASTER_SITE_GNU:=gmp/}
EXTRACT_SUFX= .tar.bz2
@@ -8,7 +8,9 @@ EXTRACT_SUFX= .tar.bz2
MAINTAINER= pkgsrc-users@NetBSD.org
HOMEPAGE= http://swox.com/gmp/
COMMENT= Library for arbitrary precision arithmetic
+LICENSE= gnu-lgpl-v3
+PKG_DESTDIR_SUPPORT= user-destdir
PKG_INSTALLATION_TYPES= overwrite pkgviews
USE_LANGUAGES= c c++ c99
@@ -30,9 +32,25 @@ ABI= o32
GCC_REQD+= 3.0
.endif
-.if ${OPSYS} == "Darwin" && ${MACHINE_ARCH} == "i386"
+.if ${MACHINE_ARCH} == "i386"
+. if ${OPSYS} == "Darwin"
# don't use x86 assembly (it doesn't build)
CONFIGURE_ENV+= MPN_PATH="generic"
+. else
+PKG_OPTIONS_VAR= PKG_OPTIONS.gmp
+PKG_SUPPORTED_OPTIONS= gmp-fat
+#PKG_SUGGESTED_OPTIONS= gmp-fat # XXX could be good for bulk builds (?)
+. include "../../mk/bsd.options.mk"
+###
+### Support for a "fat" binary on i386. There's CPU autodetection,
+### so we'll be safe and filter out -march/-mcpu, et. al.
+###
+. if !empty(PKG_OPTIONS:Mgmp-fat)
+CONFIGURE_ARGS+= --enable-fat
+BUILDLINK_TRANSFORM+= rm-optarg:-march rm-optarg:-mcpu
+BUILDLINK_TRANSFORM+= rm:-mmmx rm:-msse rm:-msse2 rm:-msse3 rm:-m3dnow
+. endif
+. endif
.endif
.include "../../mk/bsd.pkg.mk"