Makefile 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126
  1. # This file is part of the OpenADK project. OpenADK is copyrighted
  2. # material, please see the LICENCE file in the top-level directory.
  3. include ${TOPDIR}/rules.mk
  4. PKG_NAME:= ulogd
  5. PKG_VERSION:= 2.0.2
  6. PKG_RELEASE:= 2
  7. PKG_MD5SUM:= 660516de4b5b1e110c12dae414619e0f
  8. PKG_DESCR:= Netfilter userspace logging daemon
  9. PKG_SECTION:= firewall
  10. PKG_DEPENDS:= iptables libnetfilter-conntrack libnetfilter-log libnetfilter-acct libmnl
  11. PKG_BUILDDEP:= iptables libnetfilter_conntrack libnetfilter_log libnetfilter_acct libmnl
  12. PKG_URL:= http://www.netfilter.org/projects/ulogd/
  13. PKG_SITES:= http://www.netfilter.org/projects/ulogd/files/
  14. PKG_MULTI:= 1
  15. PKG_NOPARALLEL:= 1
  16. PKG_SUBPKGS:= ULOGD ULOGD_MOD_MYSQL ULOGD_MOD_PCAP ULOGD_MOD_PGSQL ULOGD_MOD_SQLITE
  17. PKGSD_ULOGD_MOD_MYSQL:= MySQL plugin for ulogd
  18. PKGSB_ULOGD_MOD_MYSQL:= mysql
  19. PKGSS_ULOGD_MOD_MYSQL:= zlib libmysqlclient
  20. PKGSD_ULOGD_MOD_PGSQL:= PostgreSQL plugin for ulogd
  21. PKGSB_ULOGD_MOD_PGSQL:= postgresql
  22. PKGSS_ULOGD_MOD_PGSQL:= libpq
  23. PKGSD_ULOGD_MOD_SQLITE:= sqlite plugin for ulogd
  24. PKGSB_ULOGD_MOD_SQLITE:= sqlite
  25. PKGSS_ULOGD_MOD_SQLITE:= libsqlite
  26. PKGSD_ULOGD_MOD_PCAP:= libpcap plugin for ulogd
  27. PKGSB_ULOGD_MOD_PCAP:= libpcap
  28. PKGSS_ULOGD_MOD_PCAP:= libpcap
  29. PKG_HOST_DEPENDS:= !cygwin
  30. DISTFILES:= ${PKG_NAME}-${PKG_VERSION}.tar.bz2
  31. include ${TOPDIR}/mk/package.mk
  32. $(eval $(call PKG_template,ULOGD,ulogd,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  33. $(eval $(call PKG_template,ULOGD_MOD_MYSQL,ulogd-mod-mysql,${PKG_VERSION}-${PKG_RELEASE},${PKGSS_ULOGD_MOD_MYSQL},${PKGSD_ULOGD_MOD_MYSQL},${PKG_SECTION}))
  34. $(eval $(call PKG_template,ULOGD_MOD_PCAP,ulogd-mod-pcap,${PKG_VERSION}-${PKG_RELEASE},${PKGSS_ULOGD_MOD_PCAP},${PKGSD_ULOGD_MOD_PCAP},${PKG_SECTION}))
  35. $(eval $(call PKG_template,ULOGD_MOD_PGSQL,ulogd-mod-pgsql,${PKG_VERSION}-${PKG_RELEASE},${PKGSS_ULOGD_MOD_PGSQL},${PKGSD_ULOGD_MOD_PGSQL},${PKG_SECTION}))
  36. $(eval $(call PKG_template,ULOGD_MOD_SQLITE,ulogd-mod-sqlite,${PKG_VERSION}-${PKG_RELEASE},${PKGSS_ULOGD_MOD_SQLITE},${PKGSD_ULOGD_MOD_SQLITE},${PKG_SECTION}))
  37. TARGET_CPPFLAGS+= -D_GNU_SOURCE
  38. TARGET_CFLAGS+= -fPIC
  39. ifneq (${ADK_PACKAGE_ULOGD_MOD_MYSQL},)
  40. CONFIGURE_ARGS+= --with-mysql=${STAGING_TARGET_DIR}/usr
  41. endif
  42. ifneq (${ADK_PACKAGE_ULOGD_MOD_PGSQL},)
  43. CONFIGURE_ARGS+= --with-pgsql=${STAGING_TARGET_DIR}/usr
  44. endif
  45. ulogd-install:
  46. ${INSTALL_DIR} ${IDIR_ULOGD}/etc
  47. ${INSTALL_DATA} ${WRKBUILD}/ulogd.conf ${IDIR_ULOGD}/etc
  48. ${INSTALL_DIR} ${IDIR_ULOGD}/usr/sbin ${IDIR_ULOGD}/usr/lib/ulogd/
  49. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_raw2packet_BASE.so \
  50. ${IDIR_ULOGD}/usr/lib/ulogd/
  51. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_filter_HWHDR.so \
  52. ${IDIR_ULOGD}/usr/lib/ulogd/
  53. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_filter_IFINDEX.so \
  54. ${IDIR_ULOGD}/usr/lib/ulogd/
  55. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_filter_IP2BIN.so \
  56. ${IDIR_ULOGD}/usr/lib/ulogd/
  57. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_filter_IP2HBIN.so \
  58. ${IDIR_ULOGD}/usr/lib/ulogd/
  59. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_filter_IP2STR.so \
  60. ${IDIR_ULOGD}/usr/lib/ulogd/
  61. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_filter_MARK.so \
  62. ${IDIR_ULOGD}/usr/lib/ulogd/
  63. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_filter_PRINTFLOW.so \
  64. ${IDIR_ULOGD}/usr/lib/ulogd/
  65. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_filter_PRINTPKT.so \
  66. ${IDIR_ULOGD}/usr/lib/ulogd/
  67. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_filter_PWSNIFF.so \
  68. ${IDIR_ULOGD}/usr/lib/ulogd/
  69. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_inpflow_NFACCT.so \
  70. ${IDIR_ULOGD}/usr/lib/ulogd/
  71. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_inpflow_NFCT.so \
  72. ${IDIR_ULOGD}/usr/lib/ulogd/
  73. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_inppkt_NFLOG.so \
  74. ${IDIR_ULOGD}/usr/lib/ulogd/
  75. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_inppkt_ULOG.so \
  76. ${IDIR_ULOGD}/usr/lib/ulogd/
  77. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_inppkt_UNIXSOCK.so \
  78. ${IDIR_ULOGD}/usr/lib/ulogd/
  79. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_output_GPRINT.so \
  80. ${IDIR_ULOGD}/usr/lib/ulogd/
  81. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_output_GRAPHITE.so \
  82. ${IDIR_ULOGD}/usr/lib/ulogd/
  83. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_output_LOGEMU.so \
  84. ${IDIR_ULOGD}/usr/lib/ulogd/
  85. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_output_NACCT.so \
  86. ${IDIR_ULOGD}/usr/lib/ulogd/
  87. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_output_OPRINT.so \
  88. ${IDIR_ULOGD}/usr/lib/ulogd/
  89. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_output_SYSLOG.so \
  90. ${IDIR_ULOGD}/usr/lib/ulogd/
  91. ${INSTALL_BIN} ${WRKINST}/usr/lib/ulogd/ulogd_output_XML.so \
  92. ${IDIR_ULOGD}/usr/lib/ulogd/
  93. ${INSTALL_BIN} ${WRKINST}/usr/sbin/ulogd ${IDIR_ULOGD}/usr/sbin
  94. ulogd-mod-pcap-install:
  95. ${INSTALL_DIR} ${IDIR_ULOGD_MOD_PCAP}/usr/lib/ulogd
  96. ${CP} ${WRKINST}/usr/lib/ulogd/ulogd_output_PCAP.so \
  97. ${IDIR_ULOGD_MOD_PCAP}/usr/lib/ulogd
  98. ulogd-mod-sqlite-install:
  99. ${INSTALL_DIR} ${IDIR_ULOGD_MOD_SQLITE}/usr/lib/ulogd
  100. ${CP} ${WRKINST}/usr/lib/ulogd/ulogd_output_SQLITE3.so \
  101. ${IDIR_ULOGD_MOD_SQLITE}/usr/lib/ulogd
  102. ulogd-mod-pgsql-install:
  103. ${INSTALL_DIR} ${IDIR_ULOGD_MOD_PGSQL}/usr/lib/ulogd
  104. ${CP} ${WRKINST}/usr/lib/ulogd/ulogd_output_PGSQL.so \
  105. ${IDIR_ULOGD_MOD_PGSQL}/usr/lib/ulogd
  106. ulogd-mod-mysql-install:
  107. ${INSTALL_DIR} ${IDIR_ULOGD_MOD_MYSQL}/usr/lib/ulogd
  108. ${CP} ${WRKINST}/usr/lib/ulogd/ulogd_output_MYSQL.so \
  109. ${IDIR_ULOGD_MOD_MYSQL}/usr/lib/ulogd
  110. include ${TOPDIR}/mk/pkg-bottom.mk