From 0364ee565058c1aa82fdb6fc3b5a2a17aae8bfa5 Mon Sep 17 00:00:00 2001 From: adrianp Date: Tue, 5 Apr 2005 22:13:29 +0000 Subject: - Add support for building with libnet 1.1.x branch using options.mk - Issue highlighted by diro@nixsys.bz in PR# 29814 --- net/libnids/Makefile | 7 ++++--- net/libnids/options.mk | 32 ++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+), 3 deletions(-) create mode 100644 net/libnids/options.mk (limited to 'net/libnids') diff --git a/net/libnids/Makefile b/net/libnids/Makefile index a003c8591b7..02b3a4ba2af 100644 --- a/net/libnids/Makefile +++ b/net/libnids/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.18 2005/03/23 17:06:33 wiz Exp $ +# $NetBSD: Makefile,v 1.19 2005/04/05 22:13:29 adrianp Exp $ # DISTNAME= libnids-1.20 @@ -14,8 +14,9 @@ GNU_CONFIGURE= yes BUILDLINK_DEPMETHOD.libnet= build BUILDLINK_DEPMETHOD.libpcap= build -BUILDLINK_DEPENDS.libnet+= libnet-1.0.* -.include "../../devel/libnet/buildlink3.mk" +.include "../../mk/bsd.prefs.mk" +.include "options.mk" + .include "../../net/libpcap/buildlink3.mk" .include "../../mk/bsd.pkg.mk" diff --git a/net/libnids/options.mk b/net/libnids/options.mk new file mode 100644 index 00000000000..b599f17fcb2 --- /dev/null +++ b/net/libnids/options.mk @@ -0,0 +1,32 @@ +# $NetBSD: options.mk,v 1.1 2005/04/05 22:13:29 adrianp Exp $ + +PKG_OPTIONS_VAR= PKG_OPTIONS.libnids +PKG_SUPPORTED_OPTIONS= libnet10 libnet11 + +.if !defined(PKG_OPTIONS.libnids) +PKG_DEFAULT_OPTIONS+= libnet10 +.endif + +.include "../../mk/bsd.options.mk" + +### +### Can't support both versions of libnet +### +.if !empty(PKG_OPTIONS:Mlibnet10) && !empty(PKG_OPTIONS:Mlibnet11) +PKG_FAIL_REASON+= "libnet-1.0.x and libnet-1.1.x cannot both be selected." \ + "This is due to the packages conflicting." +.endif + +### +### libnet 1.0.x branch support +### +.if !empty(PKG_OPTIONS:Mlibnet10) +. include "../../devel/libnet/buildlink3.mk" +.endif + +### +### libnet 1.1.x branch support +### +.if !empty(PKG_OPTIONS:Mlibnet11) +. include "../../devel/libnet11/buildlink3.mk" +.endif -- cgit v1.2.3