Files
iopsys/periodicstats/Makefile
Andreas Gnau 454dda3433 treewide: change to zstd tarballs
Change to zstd compressed instead of gz-compressed tarballs. zstd
compresses 7-8 times faster and decompresses 2-3 times faster.

This change also make sharing tarballs between different branches
possible, because OpenWrt 25.12 uses zstd as default.

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2025-12-15 17:04:02 +01:00

57 lines
1.4 KiB
Makefile

#
# Copyright (C) 2021-2023 IOPSYS Software Solutions AB
#
include $(TOPDIR)/rules.mk
PKG_NAME:=periodicstats
PKG_VERSION:=1.6.3
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/bbf/periodicstats.git
PKG_SOURCE_VERSION:=351db77e982b1f4887e5878345fe98be72d262fb
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.zst
PKG_MIRROR_HASH:=skip
endif
PKG_LICENSE:=BSD-3-Clause
PKG_LICENSE_FILES:=LICENSE
include $(INCLUDE_DIR)/package.mk
include $(TOPDIR)/feeds/iopsys/bbfdm/bbfdm.mk
define Package/periodicstats
SECTION:=utils
CATEGORY:=Utilities
TITLE:=Periodic Statistics Daemon
DEPENDS:=+ubus +libuci +libubox +libubus +libblobmsg-json
DEPENDS+=+libbbfdm-api +libbbfdm-ubus +dm-service
endef
define Package/periodicstats/description
Manage periodic statistics
endef
define Package/periodicstats/config
source "$(SOURCE)/Config.in"
endef
TARGET_CFLAGS += -DINTERNAL_SAMPLING_RATE=$(CONFIG_PERIODICSTAT_INTERNAL_SAMPLING_RATE)
ifeq ($(LOCAL_DEV),1)
define Build/Prepare
$(CP) -rf ~/git/periodicstats/* $(PKG_BUILD_DIR)/
endef
endif
define Package/periodicstats/install
$(CP) ./files/* $(1)/
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/periodicstatsd $(1)/usr/sbin
$(BBFDM_REGISTER_SERVICES) ./bbfdm_service.json $(1) $(PKG_NAME)
endef
$(eval $(call BuildPackage,periodicstats))