2 # Copyright (C) 2006-2009 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR)/rules.mk
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://www.packetfactory.net/projects/libnids/dist/
16 PKG_MD5SUM:=9ee6dcdfac97bae6fe611aa27d2594a5
18 include $(INCLUDE_DIR)/package.mk
20 define Package/libnids
24 TITLE:=A network intrusion detection library
25 URL:=http://www.packetfactory.net/projects/libnids/
28 define Package/libnids/description
29 An implementation of an E-component of Network Intrusion Detection
33 define Build/Configure
34 $(call Build/Configure/Default, \
37 --with-libnet="$(STAGING_DIR)/usr/lib/libnet-1.0.x" \
38 --with-libpcap="$(STAGING_DIR)/usr" \
40 CFLAGS="$$$$CFLAGS $$$$CPPFLAGS" \
44 TARGET_CFLAGS += $(FPIC)
47 $(MAKE) -C $(PKG_BUILD_DIR) \
48 LNETLIB="-L$(STAGING_DIR)/usr/lib/libnet-1.0.x/lib -lnet" \
49 PCAPLIB="$(TARGET_LDFLAGS) -lpcap" \
50 install_prefix="$(PKG_INSTALL_DIR)" \
54 define Build/InstallDev
55 $(INSTALL_DIR) $(1)/usr/include
56 $(CP) $(PKG_INSTALL_DIR)/usr/include/nids.h $(1)/usr/include/
57 $(INSTALL_DIR) $(1)/usr/lib
58 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libnids.{a,so*} $(1)/usr/lib/
61 define Package/libnids/install
62 $(INSTALL_DIR) $(1)/usr/lib
63 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libnids.so.* $(1)/usr/lib/
66 $(eval $(call BuildPackage,libnids))