2019-01-16 11:31:19 +00:00
|
|
|
include $(TOPDIR)/rules.mk
|
2017-01-06 12:51:50 +00:00
|
|
|
|
|
|
|
PKG_NAME:=syslog-ng
|
2023-10-04 10:26:54 +00:00
|
|
|
PKG_VERSION:=4.4.0
|
treewide: remove AUTORELEASE
Automatically compute and substitute current values for all
$(AUTORELEASE) instances as this feature is deprecated and shouldn't be
used.
The following temporary change was made to the core:
diff --git a/rules.mk b/rules.mk
index 57d7995d4fa8..f16367de87a8 100644
--- a/rules.mk
+++ b/rules.mk
@@ -429,7 +429,7 @@ endef
abi_version_str = $(subst -,,$(subst _,,$(subst .,,$(1))))
COMMITCOUNT = $(if $(DUMP),0,$(call commitcount))
-AUTORELEASE = $(if $(DUMP),0,$(call commitcount,1))
+AUTORELEASE = $(if $(DUMP),0,$(shell sed -i "s/\$$(AUTORELEASE)/$(call commitcount,1)/" $(CURDIR)/Makefile))
all:
FORCE: ;
And this command used to fix affected packages:
for i in $(cd feeds/packages; git grep -l PKG_RELEASE:=.*AUTORELEASE | \
sed 's^.*/\([^/]*\)/Makefile^\1^';);
do
make package/$i/download
done
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2023-04-21 16:32:27 +00:00
|
|
|
PKG_RELEASE:=1
|
2017-01-06 12:51:50 +00:00
|
|
|
|
2023-09-04 09:00:32 +00:00
|
|
|
PKG_MAINTAINER:=Josef Schlehofer <pepe.schlehofer@gmail.com>
|
2019-09-01 14:21:57 +00:00
|
|
|
PKG_LICENSE:=LGPL-2.1-or-later GPL-2.0-or-later
|
|
|
|
PKG_LICENSE_FILES:=COPYING LGPL.txt GPL.txt
|
2019-01-16 11:31:19 +00:00
|
|
|
PKG_CPE_ID:=cpe:/a:balabit:syslog-ng
|
2017-01-06 12:51:50 +00:00
|
|
|
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
2020-03-07 08:54:13 +00:00
|
|
|
PKG_SOURCE_URL:=https://github.com/syslog-ng/syslog-ng/releases/download/$(PKG_NAME)-$(PKG_VERSION)/
|
2023-10-04 10:26:54 +00:00
|
|
|
PKG_HASH:=583b147f3ec17fbc2dbbf31aafb1e3966237d7541313de5b41ea885dc16d932e
|
2017-01-06 12:51:50 +00:00
|
|
|
|
2019-01-16 11:31:19 +00:00
|
|
|
PKG_BUILD_PARALLEL:=1
|
2017-01-06 12:51:50 +00:00
|
|
|
PKG_INSTALL:=1
|
|
|
|
|
2022-01-25 00:02:32 +00:00
|
|
|
PKG_BUILD_DEPENDS:= \
|
|
|
|
HOST_OS_MACOS:fakeuname/host \
|
|
|
|
|
2019-01-16 11:31:19 +00:00
|
|
|
PKG_CONFIG_DEPENDS:= \
|
|
|
|
CONFIG_IPV6 \
|
|
|
|
|
2017-01-06 12:51:50 +00:00
|
|
|
include $(INCLUDE_DIR)/package.mk
|
|
|
|
include $(INCLUDE_DIR)/nls.mk
|
2022-01-25 00:02:32 +00:00
|
|
|
ifeq ($(CONFIG_HOST_OS_MACOS),y)
|
|
|
|
include ../../utils/fakeuname/fakeuname.mk
|
|
|
|
endif
|
2017-01-06 12:51:50 +00:00
|
|
|
|
|
|
|
define Package/syslog-ng
|
|
|
|
SECTION:=admin
|
|
|
|
CATEGORY:=Administration
|
|
|
|
TITLE:=A powerful syslog daemon
|
2019-01-16 11:31:19 +00:00
|
|
|
URL:=https://www.syslog-ng.com/products/open-source-log-management/
|
2023-09-03 08:26:21 +00:00
|
|
|
DEPENDS:=+libpcre2 +glib2 +libopenssl +libpthread +librt +zlib +libdbi +libjson-c +libcurl +libuuid +SYSLOGNG_LOGROTATE:logrotate
|
2017-01-06 12:51:50 +00:00
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/syslog-ng/description
|
|
|
|
syslog-ng reads and logs messages to the system console, log
|
|
|
|
files, other machines and/or users as specified by its
|
|
|
|
configuration file.
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/syslog-ng/conffiles
|
2017-07-25 20:10:15 +00:00
|
|
|
/etc/syslog-ng.conf
|
|
|
|
/etc/syslog-ng.d/
|
2019-01-16 11:31:19 +00:00
|
|
|
/etc/scl.conf
|
2017-01-06 12:51:50 +00:00
|
|
|
endef
|
|
|
|
|
2022-08-09 08:28:43 +00:00
|
|
|
define Package/syslog-ng/config
|
|
|
|
config SYSLOGNG_LOGROTATE
|
|
|
|
bool "Logrotate support"
|
|
|
|
depends on PACKAGE_syslog-ng
|
|
|
|
default n
|
|
|
|
help
|
|
|
|
It adds support for logrotate functionality.
|
|
|
|
|
|
|
|
config SYSLOGNG_LOGROTATE_MAXSIZE
|
|
|
|
string "Maximum size of /var/log/messages log file"
|
|
|
|
depends on SYSLOGNG_LOGROTATE
|
|
|
|
default "1M"
|
|
|
|
help
|
|
|
|
Log files are rotated when they grow bigger than defined size bytes.
|
|
|
|
|
|
|
|
config SYSLOGNG_LOGROTATE_ROTATE_COUNT
|
|
|
|
int "Maximum rotation count for /var/log/messages log file"
|
|
|
|
depends on SYSLOGNG_LOGROTATE
|
|
|
|
default 1
|
|
|
|
help
|
|
|
|
Log files are rotated count times before being removed or mailed to
|
|
|
|
the address specified in a mail directive. If count is 0, old
|
|
|
|
versions are removed rather than rotated.
|
|
|
|
endef
|
|
|
|
|
2017-01-06 12:51:50 +00:00
|
|
|
define Build/Configure
|
|
|
|
$(SED) 's,-I/usr/include,,' $(PKG_BUILD_DIR)/configure
|
|
|
|
$(Build/Configure/Default)
|
|
|
|
endef
|
|
|
|
|
2022-08-09 08:28:43 +00:00
|
|
|
LOGROTATE_MAXSIZE:=$(call qstrip,$(CONFIG_SYSLOGNG_LOGROTATE_MAXSIZE))
|
|
|
|
LOGROTATE_ROTATE:=$(call qstrip,$(CONFIG_SYSLOGNG_LOGROTATE_ROTATE_COUNT))
|
|
|
|
|
2019-01-16 11:31:19 +00:00
|
|
|
CONFIGURE_ARGS += \
|
2020-05-06 21:50:34 +00:00
|
|
|
--disable-afsnmp \
|
2019-01-16 11:31:19 +00:00
|
|
|
$(call autoconf_bool,CONFIG_IPV6,ipv6) \
|
|
|
|
--disable-tcp-wrapper \
|
|
|
|
--disable-spoof-source \
|
|
|
|
--disable-sql \
|
|
|
|
--disable-linux-caps \
|
|
|
|
--with-jsonc=system \
|
2023-09-03 08:26:21 +00:00
|
|
|
--enable-cpp=no \
|
2019-01-16 11:31:19 +00:00
|
|
|
--enable-json=yes \
|
|
|
|
--enable-http=yes \
|
|
|
|
--disable-smtp \
|
2021-07-12 14:14:31 +00:00
|
|
|
--disable-mqtt \
|
2019-01-16 11:31:19 +00:00
|
|
|
--disable-redis \
|
|
|
|
--disable-dependency-tracking \
|
|
|
|
--disable-python \
|
2019-03-11 06:06:13 +00:00
|
|
|
--disable-geoip2 \
|
2019-01-16 11:31:19 +00:00
|
|
|
--disable-java \
|
|
|
|
--disable-java-modules \
|
|
|
|
--with-librabbitmq-client=no \
|
|
|
|
--with-mongoc=no
|
2017-01-06 12:51:50 +00:00
|
|
|
|
|
|
|
CONFIGURE_VARS += \
|
2022-01-25 00:02:32 +00:00
|
|
|
$(if $(CONFIG_HOST_OS_MACOS),PATH=$(FAKEUNAME_PATH):$(PATH)) \
|
2019-01-16 11:31:19 +00:00
|
|
|
LIBDBI_CFLAGS="-I$(STAGING_DIR)/usr/include"
|
2017-01-06 12:51:50 +00:00
|
|
|
|
|
|
|
define Package/syslog-ng/install
|
2019-01-16 11:31:19 +00:00
|
|
|
cd $(PKG_BUILD_DIR); make DESTDIR=$(1) install
|
|
|
|
|
|
|
|
$(call libtool_remove_files,$(1)) # This removes .la files in folder (including subfolders) /usr/lib
|
|
|
|
rm -rf $(1)/usr/lib/pkgconfig \
|
|
|
|
$(1)/usr/lib/*.a \
|
|
|
|
$(1)/usr/include \
|
|
|
|
$(1)/var
|
|
|
|
|
2017-01-06 12:51:50 +00:00
|
|
|
$(INSTALL_DIR) $(1)/etc/init.d
|
|
|
|
$(INSTALL_BIN) ./files/syslog-ng.init $(1)/etc/init.d/syslog-ng
|
2019-01-16 11:31:19 +00:00
|
|
|
$(INSTALL_DIR) $(1)/etc/syslog-ng.d
|
2017-01-06 12:51:50 +00:00
|
|
|
$(INSTALL_DATA) ./files/syslog-ng.conf $(1)/etc
|
2016-12-15 10:12:45 +00:00
|
|
|
touch $(1)/etc/syslog-ng.d/.keep
|
2019-01-27 22:38:16 +00:00
|
|
|
|
2020-03-07 08:54:13 +00:00
|
|
|
$(INSTALL_DIR) $(1)/sbin
|
|
|
|
$(INSTALL_BIN) ./files/logread $(1)/sbin
|
2020-06-26 09:37:32 +00:00
|
|
|
|
|
|
|
$(INSTALL_DIR) $(1)/usr/share/syslog-ng/include/
|
|
|
|
$(CP) -r ./files/scl $(1)/usr/share/syslog-ng/include/
|
2022-08-09 08:28:43 +00:00
|
|
|
|
|
|
|
ifneq ($(strip $(CONFIG_SYSLOGNG_LOGROTATE)),)
|
|
|
|
$(INSTALL_DIR) $(1)/etc/logrotate.d
|
|
|
|
sed \
|
|
|
|
-e 's#@MAXSIZE@#$(LOGROTATE_MAXSIZE)#g' \
|
|
|
|
-e 's#@ROTATE@#$(LOGROTATE_ROTATE)#g' \
|
|
|
|
./files/syslog-ng.logrotate > $(1)/etc/logrotate.d/syslog-ng.conf
|
|
|
|
endif
|
2017-01-06 12:51:50 +00:00
|
|
|
endef
|
|
|
|
|
2019-01-16 11:31:19 +00:00
|
|
|
define Package/syslog-ng/postinst
|
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
[ -n "$$IPKG_INSTROOT" ] || {
|
|
|
|
/etc/init.d/syslog-ng enable
|
|
|
|
/etc/init.d/syslog-ng restart
|
|
|
|
}
|
|
|
|
endef
|
|
|
|
|
2018-08-22 23:13:20 +00:00
|
|
|
define Package/syslog-ng/prerm
|
2019-01-16 11:31:19 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
[ -n "$$IPKG_INSTROOT" ] || {
|
|
|
|
/etc/init.d/syslog-ng disable
|
|
|
|
/etc/init.d/syslog-ng stop
|
|
|
|
}
|
2018-08-22 23:13:20 +00:00
|
|
|
endef
|
|
|
|
|
2017-01-06 12:51:50 +00:00
|
|
|
$(eval $(call BuildPackage,syslog-ng))
|