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
23 include $(INCLUDE_DIR
)/package.mk
25 define Package
/libnids
28 TITLE
:=A network intrusion detection library
29 DESCRIPTION
:=A network intrusion detection library.
\\\
30 An implementation of an E-component of Network Intrusion Detection
\\\
32 URL
:=http
://www.packetfactory.net
/projects
/libnids
/
35 define Build
/Configure
36 (cd
$(PKG_BUILD_DIR
); rm -f config.cache
; \
37 $(TARGET_CONFIGURE_OPTS
) \
38 CFLAGS
="$(TARGET_CFLAGS)" \
39 CPPFLAGS
="-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include" \
40 LDFLAGS
="-L$(STAGING_DIR)/usr/lib -L$(STAGING_DIR)/lib" \
42 --target
=$(GNU_TARGET_NAME
) \
43 --host
=$(GNU_TARGET_NAME
) \
44 --build
=$(GNU_HOST_NAME
) \
50 --datadir=/usr
/share \
51 --includedir=/usr
/include \
52 --infodir=/usr
/share
/info \
54 --libexecdir
=/usr
/lib \
55 --localstatedir
=/var \
56 --mandir=/usr
/share
/man \
60 $(DISABLE_LARGEFILE
) \
63 --with-libnet
="$(STAGING_DIR)/usr" \
64 --with-libpcap
="$(STAGING_DIR)/usr" \
69 rm -rf
$(PKG_INSTALL_DIR
)
70 mkdir
-p
$(PKG_INSTALL_DIR
)
71 $(MAKE
) -C
$(PKG_BUILD_DIR
) \
72 $(TARGET_CONFIGURE_OPTS
) \
73 install_prefix
="$(PKG_INSTALL_DIR)" \
77 define Package
/libnids
/install
78 install -m0755
-d
$(1)/usr
/lib
79 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/libnids.so.
* $(1)/usr
/lib
/
82 define Build
/InstallDev
83 mkdir
-p
$(STAGING_DIR
)/usr
/include
84 $(CP
) $(PKG_INSTALL_DIR
)/usr
/include/nids.h
$(STAGING_DIR
)/usr
/include/
85 mkdir
-p
$(STAGING_DIR
)/usr
/lib
86 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/libnids.
{a
,so
*} $(STAGING_DIR
)/usr
/lib
/
89 define Build
/UninstallDev
91 $(STAGING_DIR
)/usr
/include/nids.h \
92 $(STAGING_DIR
)/usr
/lib
/libnids.
{a
,so
*}
95 $(eval
$(call BuildPackage
,libnids
))