2 # Copyright (C) 2008-2016 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
12 PKG_RELEASE
:=$(AUTORELEASE
)
14 PKG_MAINTAINER
:=Josef Schlehofer
<pepe.schlehofer@gmail.com
>, Daniel Engberg
<daniel.engberg.lists@pyret.net
>
15 PKG_LICENSE
:=GPL-3.0
-or-later
16 PKG_LICENSE_FILES
:=COPYING
17 PKG_CPE_ID
:=cpe
:/a
:my-netdata
:netdata
19 PKG_SOURCE
:=$(PKG_NAME
)-v
$(PKG_VERSION
).
tar.gz
20 PKG_SOURCE_URL
:=https
://github.com
/netdata
/netdata
/releases
/download
/v
$(PKG_VERSION
)
21 PKG_HASH
:=20ba8695d87187787b27128ac3aab9b09aa29ca6b508c48542e0f7d50ec9322b
22 PKG_BUILD_DIR
=$(BUILD_DIR
)/$(PKG_NAME
)-v
$(PKG_VERSION
)
29 include $(INCLUDE_DIR
)/package.mk
31 define Package
/netdata
33 CATEGORY
:=Administration
34 DEPENDS
:=+zlib
+libuuid
+libuv
+libmnl
+libjson-c
35 TITLE
:=Real-time performance monitoring tool
36 URL
:=https
://www.netdata.cloud
/
39 define Package
/netdata
/description
40 netdata is a highly optimized Linux daemon providing real-time performance
41 monitoring for Linux systems
, applications and SNMP devices over the web.
43 If you want to use Python plugins
install python3
, python3-yaml and
47 TARGET_CFLAGS
:= $(filter-out -O
%,$(TARGET_CFLAGS
))
48 TARGET_CFLAGS
+= -ffunction-sections
-fdata-sections
-O3
49 TARGET_LDFLAGS
+= -Wl
,--gc-sections
60 --disable-compression \
61 --disable-plugin-nfacct \
62 --disable-plugin-freeipmi \
63 --disable-plugin-cups \
64 --disable-plugin-xenstat \
65 --disable-backend-prometheus-remote-write \
66 --disable-unit-tests \
70 define Build
/Configure
71 $(SED
) 's/m4_esyscmd(\[git describe .*\])/$(PKG_VERSION)/' $(PKG_BUILD_DIR
)/configure.ac
72 $(Build
/Configure
/Default
)
75 define Package
/netdata
/conffiles
79 define Package
/netdata
/install
80 $(INSTALL_DIR
) $(1)/etc
/netdata
/custom-plugins.d
81 $(CP
) $(PKG_INSTALL_DIR
)/etc
/netdata
$(1)/etc
82 $(CP
) .
/files
/netdata.conf
$(1)/etc
/netdata
83 touch
$(1)/etc
/netdata
/.opt-out-from-anonymous-statistics
84 $(INSTALL_DIR
) $(1)/usr
/lib
85 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/netdata
$(1)/usr
/lib
86 $(CP
) $(1)/usr
/lib
/netdata
/conf.d
/fping.conf
$(1)/etc
87 $(CP
) $(1)/usr
/lib
/netdata
/conf.d
/health_alarm_notify.conf
$(1)/etc
88 $(CP
) $(1)/usr
/lib
/netdata
/plugins.d
/tc-qos-helper.sh
$(1)/etc
89 $(INSTALL_DIR
) $(1)/usr
/sbin
90 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/netdata
$(1)/usr
/sbin
91 $(INSTALL_DIR
) $(1)/usr
/share
/netdata
92 $(CP
) $(PKG_INSTALL_DIR
)/usr
/share
/netdata
$(1)/usr
/share
93 rm $(1)/usr
/share
/netdata
/web
/demo
*html
94 rm $(1)/usr
/share
/netdata
/web
/fonts
/*.svg
95 rm $(1)/usr
/share
/netdata
/web
/fonts
/*.ttf
96 rm $(1)/usr
/share
/netdata
/web
/fonts
/*.woff
97 rm $(1)/usr
/share
/netdata
/web
/images
/*.png
98 rm $(1)/usr
/share
/netdata
/web
/images
/*.gif
99 rm $(1)/usr
/share
/netdata
/web
/images
/*.ico
100 rm -rf
$(1)/usr
/share
/netdata
/web
/old
101 $(INSTALL_DIR
) $(1)/etc
/init.d
102 $(INSTALL_BIN
) .
/files
/netdata.init
$(1)/etc
/init.d
/netdata
105 $(eval
$(call BuildPackage
,netdata
))