aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorflz <flz@FreeBSD.org>2006-06-02 02:20:15 +0800
committerflz <flz@FreeBSD.org>2006-06-02 02:20:15 +0800
commitcdd21c9b9c1b8137e89cb00435d6f49a10570589 (patch)
treee573c4b3ba0a48d8c0cc36d68853d36bcdcee57e /net
parent159e2801f4557ef3ef94338995e79dcd4f138d1a (diff)
downloadfreebsd-ports-gnome-cdd21c9b9c1b8137e89cb00435d6f49a10570589.tar.gz
freebsd-ports-gnome-cdd21c9b9c1b8137e89cb00435d6f49a10570589.tar.zst
freebsd-ports-gnome-cdd21c9b9c1b8137e89cb00435d6f49a10570589.zip
- Try to guess sensible default values for OPTIONS.
Diffstat (limited to 'net')
-rw-r--r--net/ipw-firmware/Makefile22
1 files changed, 17 insertions, 5 deletions
diff --git a/net/ipw-firmware/Makefile b/net/ipw-firmware/Makefile
index d36e6a92ae07..af40d0c99487 100644
--- a/net/ipw-firmware/Makefile
+++ b/net/ipw-firmware/Makefile
@@ -25,8 +25,23 @@ FIRMWARES?= ${RELNAME}-${PORTVERSION}-i.fw:${DRIVERNAME}-i.fw \
${RELNAME}-${PORTVERSION}-p.fw:${DRIVERNAME}-p.fw \
${RELNAME}-${PORTVERSION}.fw:${DRIVERNAME}.fw
-OPTIONS= MODULE "Install ${DRIVERNAME}(4) kernel module (very old snapshot)" off \
- CONTROL "Install ${DRIVERNAME}control(8) utility" on
+OSVERSION!= /sbin/sysctl -n kern.osreldate
+
+# Dummy OSVERSION for ipw.
+MIN7OSVERSION?= 999999
+
+# Try to guess sensible defaults.
+.if ${OSVERSION} > ${MIN7OSVERSION}
+OPTIONS+= CONTROL "Install ${DRIVERNAME}control(8) utility" off
+.else
+OPTIONS+= CONTROL "Install ${DRIVERNAME}control(8) utility" on
+.endif
+
+.if ${OSVERSION} > 600023
+OPTIONS+= MODULE "Install ${DRIVERNAME}(4) kernel module (very old snapshot)" off
+.else
+OPTIONS+= MODULE "Install ${DRIVERNAME}(4) kernel module (very old snapshot)" on
+.endif
# Override PREFIX to install ${DRIVERNAME}control(8) somewhere we hope it'll
# be available soon enough.
@@ -48,9 +63,6 @@ MAKE_ENV= BINDIR="${PREFIX}/sbin" \
MANCOMPRESSED= yes
-# Dummy OSVERSION for ipw.
-MIN7OSVERSION?= 999999
-
.if !defined(PACKAGE_BUILDING)
IS_INTERACTIVE= yes
.endif