diff options
author | flz <flz@FreeBSD.org> | 2005-05-17 17:33:50 +0800 |
---|---|---|
committer | flz <flz@FreeBSD.org> | 2005-05-17 17:33:50 +0800 |
commit | b6819df8bbfb5269bdb12cc2bf69bfae96b9f048 (patch) | |
tree | 46f2b68151a1f6391a187d31afff5dedb2c9bebf /net/ipw-firmware/Makefile | |
parent | 1e5778164289b4434e1ada1338bfe1d3fc0e2d56 (diff) | |
download | freebsd-ports-gnome-b6819df8bbfb5269bdb12cc2bf69bfae96b9f048.tar.gz freebsd-ports-gnome-b6819df8bbfb5269bdb12cc2bf69bfae96b9f048.tar.zst freebsd-ports-gnome-b6819df8bbfb5269bdb12cc2bf69bfae96b9f048.zip |
- Add WITH_MODULE knob to build/install if_ipw.ko.
- Mark IGNORE for OSVERSION < 503000 or OSVERSION > 6000233.
- Use OPTIONS.
Diffstat (limited to 'net/ipw-firmware/Makefile')
-rw-r--r-- | net/ipw-firmware/Makefile | 41 |
1 files changed, 40 insertions, 1 deletions
diff --git a/net/ipw-firmware/Makefile b/net/ipw-firmware/Makefile index f0c9dac8ef11..36700b675852 100644 --- a/net/ipw-firmware/Makefile +++ b/net/ipw-firmware/Makefile @@ -18,10 +18,14 @@ COMMENT= Intel PRO/Wireless 2100 Driver Firmware IPW_VERSION= 1.6.4 DISTFILES+= ipw-freebsd-${IPW_VERSION}.tgz +OPTIONS= MODULE "Install ipw(4) kernel module" off + WRKSRC= ${WRKDIR} SUB_FILES= pkg-message SUB_LIST= PORTVERSION="${PORTVERSION}" -MAKE_ENV= BINDIR="${PREFIX}/sbin" MANDIR="${PREFIX}/man/man" +MAKE_ENV= BINDIR="${PREFIX}/sbin" \ + MANDIR="${PREFIX}/man/man" \ + KMODDIR="/boot/modules" USE_RC_SUBR= ipw.sh MAN8= ipwcontrol.8 @@ -29,8 +33,39 @@ MANCOMPRESSED= yes .include <bsd.port.pre.mk> +# That's a bit arbitrary since I have no idea if ipw(4) can be compiled on FreeBSD +# previous to 5.3-RELEASE. This is just too old, people should move on. +# I may change this if I get successful reports though. +# Comment this if you want to test it anyway. +.if ${OSVERSION} < 503000 +IGNORE= Need a fresh version of RELENG_5 +.endif + +.if defined(WITH_MODULE) +. if ${OSVERSION} > 600023 +IGNORE= ipw(4) support is already included in your tree +. else +PLIST_SUB+= IF_IPW_KO="" +MAN4+= ipw.4 +. endif +.else +PLIST_SUB+= IF_IPW_KO="@comment " +.endif + +# "Might" because people still can include ipw(4) support in kernel by extracting +# its source in src/ and tweaking src/sys/conf/files. +.if ${OSVERSION} <= 600023 && !exists(/boot/modules/if_ipw.ko) && !defined(WITH_MODULE) +SUB_LIST+= MIGHT_NEED_MODULE="" +.else +SUB_LIST+= MIGHT_NEED_MODULE="@comment " +.endif + do-build: +.if defined(WITH_MODULE) + cd ${WRKSRC}/ipw-freebsd-${IPW_VERSION}/src/; make all +.else cd ${WRKSRC}/ipw-freebsd-${IPW_VERSION}/src/usr.sbin/ipwcontrol/; make all +.endif do-install: .if !defined(PACKAGE_BUILDING) @@ -39,7 +74,11 @@ do-install: ${SH} ${PKGREQ} ${PORTNAME} INSTALL .endif ${MKDIR} ${DATADIR} +.if defined(WITH_MODULE) + cd ${WRKSRC}/ipw-freebsd-${IPW_VERSION}/src/; make install ${MAKE_ENV} +.else cd ${WRKSRC}/ipw-freebsd-${IPW_VERSION}/src/usr.sbin/ipwcontrol/; make install ${MAKE_ENV} +.endif .for i in LICENSE ipw2100-1.3-i.fw ipw2100-1.3-p.fw ipw2100-1.3.fw ${INSTALL_DATA} ${WRKSRC}/$i ${DATADIR}/ .endfor |