You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

85 lines
2.4 KiB

  1. #
  2. # Copyright (C) 2015 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=e2guardian
  9. PKG_VERSION:=3.2.0
  10. PKG_RELEASE:=2
  11. PKG_LICENSE:=GPL-2.0
  12. PKG_MAINTAINER:=Luka Perkov <luka@openwrt.org>
  13. PKG_SOURCE_PROTO:=git
  14. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
  15. PKG_SOURCE_URL:=https://github.com/$(PKG_NAME)/$(PKG_NAME)
  16. PKG_SOURCE_VERSION:=35be4a5b40aedc6a800c06389c220a8dbf35f1cc
  17. PKG_MIRROR_HASH:=2dab9ba63ee8a2c09ac84f5b69dc5a1e9beb3cf3deede55d405b8bc5dc711e97
  18. PKG_FIXUP:=autoreconf
  19. PKG_BUILD_PARALLEL:=1
  20. PKG_INSTALL:=1
  21. include $(INCLUDE_DIR)/uclibc++.mk
  22. include $(INCLUDE_DIR)/package.mk
  23. define Package/e2guardian
  24. SECTION:=net
  25. DEPENDS:=+libpthread $(CXX_DEPENDS) +zlib +libpcre
  26. CATEGORY:=Network
  27. SUBMENU:=Web Servers/Proxies
  28. TITLE:=E2Guardian
  29. URL:=http://e2guardian.org/cms/
  30. endef
  31. define Package/e2guardian/conffiles
  32. /etc/e2guardian/e2guardianf1.conf
  33. /etc/config/e2guardian
  34. endef
  35. CONFIGURE_VARS += \
  36. INCLUDES="" \
  37. CXXFLAGS="$$$$CXXFLAGS -fno-rtti" \
  38. LIBS="-lpthread"
  39. CONFIGURE_ARGS += \
  40. --with-sysconfsubdir=e2guardian \
  41. --with-proxyuser=nobody \
  42. --with-proxygroup=nogroup \
  43. --enable-pcre=yes \
  44. --with-piddir=/tmp/e2guardian/ \
  45. --enable-sslextralists=no \
  46. --enable-sslmitm=no
  47. define Build/Configure
  48. ( cd $(PKG_BUILD_DIR); ./autogen.sh )
  49. $(call Build/Configure/Default,$CONFIGURE_ARGS)
  50. endef
  51. define Package/e2guardian/install
  52. $(INSTALL_DIR) $(1)/usr/sbin
  53. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/e2guardian $(1)/usr/sbin/
  54. $(INSTALL_DIR) $(1)/etc
  55. $(CP) $(PKG_INSTALL_DIR)/etc/e2guardian $(1)/etc/
  56. $(INSTALL_CONF) ./files/e2guardianf1.conf $(1)/etc/e2guardian/e2guardianf1.conf
  57. $(INSTALL_DIR) $(1)/etc/config
  58. $(INSTALL_CONF) ./files/e2guardian.config $(1)/etc/config/e2guardian
  59. $(INSTALL_DIR) $(1)/usr/share/e2guardian
  60. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/e2guardian/transparent1x1.gif $(1)/usr/share/e2guardian/
  61. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/e2guardian/blockedflash.swf $(1)/usr/share/e2guardian/
  62. $(INSTALL_DIR) $(1)/usr/share/e2guardian/languages/ukenglish
  63. $(CP) $(PKG_INSTALL_DIR)/usr/share/e2guardian/languages/ukenglish/* $(1)/usr/share/e2guardian/languages/ukenglish/
  64. $(INSTALL_DIR) $(1)/etc/init.d/
  65. $(INSTALL_BIN) ./files/e2guardian.init $(1)/etc/init.d/e2guardian
  66. endef
  67. $(eval $(call BuildPackage,e2guardian))