aboutsummaryrefslogtreecommitdiffstats
path: root/sysutils
diff options
context:
space:
mode:
authormakc <makc@FreeBSD.org>2010-04-25 23:31:17 +0800
committermakc <makc@FreeBSD.org>2010-04-25 23:31:17 +0800
commit63844e673e3c5348fcfab0f4d0817d9fbf4f1985 (patch)
treeaf78ef6d3783cc196b9337f0c468b315dadea61b /sysutils
parentdfc29702e7353f8543eb31ca0eacfc713616bb45 (diff)
downloadfreebsd-ports-gnome-63844e673e3c5348fcfab0f4d0817d9fbf4f1985.tar.gz
freebsd-ports-gnome-63844e673e3c5348fcfab0f4d0817d9fbf4f1985.tar.zst
freebsd-ports-gnome-63844e673e3c5348fcfab0f4d0817d9fbf4f1985.zip
Some utils link with gmp library if exists.
Add optional dependency on math/gmp and disable gmp support properly when it's not needed. PR: ports/146027 Reported by: Craig Leres <leres at ee.lbl.gov>
Diffstat (limited to 'sysutils')
-rw-r--r--sysutils/coreutils/Makefile26
1 files changed, 18 insertions, 8 deletions
diff --git a/sysutils/coreutils/Makefile b/sysutils/coreutils/Makefile
index 1b0086fd3f89..b3d9253c2808 100644
--- a/sysutils/coreutils/Makefile
+++ b/sysutils/coreutils/Makefile
@@ -24,14 +24,6 @@ USE_GMAKE= yes
USE_LDCONFIG= yes
#USE_BISON= yes
-.if defined(WITHOUT_NLS)
-CONFIGURE_ARGS+=--disable-nls
-PLIST_SUB+= NLS="@comment "
-.else
-USE_GETTEXT= yes
-PLIST_SUB+= NLS=""
-.endif
-
INFO= coreutils
MAN1= gbasename.1 gcat.1 gchcon.1 gchgrp.1 gchmod.1 gchown.1 gchroot.1 \
@@ -49,6 +41,24 @@ MAN1= gbasename.1 gcat.1 gchcon.1 gchgrp.1 gchmod.1 gchown.1 gchroot.1 \
gusers.1 gvdir.1 gwc.1 gwho.1 gwhoami.1 gyes.1 gbase64.1 gsha224sum.1 \
gsha256sum.1 gsha384sum.1 gsha512sum.1 gshuf.1
+OPTIONS= GMP "Build with GNU Multiple Precision Arithmetic Library" off
+
+.include <bsd.port.options.mk>
+
+.if defined(WITHOUT_NLS)
+CONFIGURE_ARGS+=--disable-nls
+PLIST_SUB+= NLS="@comment "
+.else
+USE_GETTEXT= yes
+PLIST_SUB+= NLS=""
+.endif
+
+.if defined(WITH_GMP)
+LIB_DEPENDS+= gmp.10:${PORTSDIR}/math/gmp
+.else
+CONFIGURE_ARGS+=--without-gmp
+.endif
+
.include <bsd.port.pre.mk>
.if ${OSVERSION} >= 800039