2 # Copyright (C) 2006 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 include $(TOPDIR
)/rules.mk
15 PKG_BUILD_DIR
:=$(BUILD_DIR
)/$(PKG_NAME
)-$(PKG_VERSION
)
16 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
17 PKG_SOURCE_URL
:=http
://www.packetfactory.net
/projects
/libnids
/dist/
18 PKG_MD5SUM
:=9ee6dcdfac97bae6fe611aa27d2594a5
21 PKG_INSTALL_DIR
:=$(PKG_BUILD_DIR
)/ipkg-install
25 include $(INCLUDE_DIR
)/package.mk
27 define Package
/libnids
30 TITLE
:=A network intrusion detection library
31 DESCRIPTION
:=A network intrusion detection library.
\\\
32 An implementation of an E-component of Network Intrusion Detection
\\\
34 URL
:=http
://www.packetfactory.net
/projects
/libnids
/
37 define Build
/Configure
38 (cd
$(PKG_BUILD_DIR
); rm -f config.cache
; \
39 $(TARGET_CONFIGURE_OPTS
) \
40 CFLAGS
="$(TARGET_CFLAGS)" \
41 CPPFLAGS
="-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include" \
42 LDFLAGS
="-L$(STAGING_DIR)/usr/lib -L$(STAGING_DIR)/lib" \
44 --target
=$(GNU_TARGET_NAME
) \
45 --host
=$(GNU_TARGET_NAME
) \
46 --build
=$(GNU_HOST_NAME
) \
52 --datadir=/usr
/share \
53 --includedir=/usr
/include \
54 --infodir=/usr
/share
/info \
56 --libexecdir
=/usr
/lib \
57 --localstatedir
=/var \
58 --mandir=/usr
/share
/man \
62 $(DISABLE_LARGEFILE
) \
65 --with-libnet
="$(STAGING_DIR)/usr" \
66 --with-libpcap
="$(STAGING_DIR)/usr" \
71 rm -rf
$(PKG_INSTALL_DIR
)
72 mkdir
-p
$(PKG_INSTALL_DIR
)
73 $(MAKE
) -C
$(PKG_BUILD_DIR
) \
74 $(TARGET_CONFIGURE_OPTS
) \
75 install_prefix
="$(PKG_INSTALL_DIR)" \
79 define Package
/libnids
/install
80 install -m0755
-d
$(1)/usr
/lib
81 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/libnids.so.
* $(1)/usr
/lib
/
84 define Build
/InstallDev
85 mkdir
-p
$(STAGING_DIR
)/usr
/include
86 $(CP
) $(PKG_INSTALL_DIR
)/usr
/include/nids.h
$(STAGING_DIR
)/usr
/include/
87 mkdir
-p
$(STAGING_DIR
)/usr
/lib
88 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/libnids.
{a
,so
*} $(STAGING_DIR
)/usr
/lib
/
91 define Build
/UninstallDev
93 $(STAGING_DIR
)/usr
/include/nids.h \
94 $(STAGING_DIR
)/usr
/lib
/libnids.
{a
,so
*}
97 $(eval
$(call BuildPackage
,libnids
))