61fe44c07d98feeb3fedd658425770d3642b27ba
[openwrt/svn-archive/archive.git] / net / dansguardian / Makefile
1 #
2 # Copyright (C) 2008 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=dansguardian
11 PKG_VERSION:=2.10.0.2
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://dansguardian.org/downloads/2/Stable
16 PKG_MD5SUM:=0a6c6d35c9e0c82fbc4a2150e8ffe977
17
18 PKG_FIXUP = libtool
19
20 include $(INCLUDE_DIR)/package.mk
21
22 define Package/dansguardian
23 SECTION:=net
24 DEPENDS:=+libpthread +uclibcxx +zlib
25 CATEGORY:=Network
26 TITLE:=DansGuardian
27 URL:=http://dansguardian.org
28 endef
29
30 define Package/dansguardian/conffiles
31 /etc/dansguardian/dansguardian.conf
32 endef
33
34 CONFIGURE_VARS += \
35 INCLUDES="" \
36 CXXFLAGS="$$$$CXXFLAGS -fno-builtin -fno-rtti -nostdinc++" \
37 CPPFLAGS="-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include -I$(STAGING_DIR)/usr/include/uClibc++" \
38 LDFLAGS="$$$$LDFLAGS" \
39 LIBS="-nodefaultlibs -luClibc++ -lpthread $(LIBGCC_S)" \
40
41 define Build/Configure
42 $(call Build/Configure/Default,\
43 --disable-clamav \
44 --with-sysconfsubdir=dansguardian \
45 --with-proxyuser=root \
46 --with-proxygroup=root \
47 --disable-pcre \
48 )
49 endef
50
51 define Build/Compile
52 $(MAKE) -C $(PKG_BUILD_DIR) \
53 DESTDIR="$(PKG_INSTALL_DIR)" \
54 all install
55 endef
56
57 define Package/dansguardian/install
58 $(INSTALL_DIR) $(1)/usr/sbin
59 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/dansguardian $(1)/usr/sbin/
60 $(INSTALL_DIR) $(1)/etc
61 $(CP) $(PKG_INSTALL_DIR)/etc/dansguardian $(1)/etc/
62 $(INSTALL_DIR) $(1)/usr/share/dansguardian
63 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/dansguardian/transparent1x1.gif $(1)/usr/share/dansguardian/
64 $(INSTALL_DIR) $(1)/usr/share/dansguardian/languages/ukenglish
65 $(CP) $(PKG_INSTALL_DIR)/usr/share/dansguardian/languages/ukenglish/* $(1)/usr/share/dansguardian/languages/ukenglish/
66 endef
67
68 $(eval $(call BuildPackage,dansguardian))