From d0c22992eeb876576ee7f5061b0210bb739fbda5 Mon Sep 17 00:00:00 2001 From: Leah Neukirchen Date: Tue, 25 Aug 2020 16:47:53 +0200 Subject: [PATCH 1/2] New package: judy-1.0.5 --- common/shlibs | 1 + srcpkgs/judy-devel | 1 + srcpkgs/judy/patches/e95874a4.patch | 85 +++++++++++++++++++++++++++++ srcpkgs/judy/template | 31 +++++++++++ 4 files changed, 118 insertions(+) create mode 120000 srcpkgs/judy-devel create mode 100644 srcpkgs/judy/patches/e95874a4.patch create mode 100644 srcpkgs/judy/template diff --git a/common/shlibs b/common/shlibs index 676eb94366b11e..b28d158df83872 100644 --- a/common/shlibs +++ b/common/shlibs @@ -3980,3 +3980,4 @@ libfcft.so.3 fcft-2.2.2_1 libaml.so.0 aml-0.1.0_1 libneatvnc.so.0 neatvnc-0.2.0_1 libtdjson.so.1.6.0 libtd-1.6.0_1 +libJudy.so.1 judy-1.0.5_1 diff --git a/srcpkgs/judy-devel b/srcpkgs/judy-devel new file mode 120000 index 00000000000000..06fb2e8a00cd54 --- /dev/null +++ b/srcpkgs/judy-devel @@ -0,0 +1 @@ +judy \ No newline at end of file diff --git a/srcpkgs/judy/patches/e95874a4.patch b/srcpkgs/judy/patches/e95874a4.patch new file mode 100644 index 00000000000000..43cb20e49c1c2f --- /dev/null +++ b/srcpkgs/judy/patches/e95874a4.patch @@ -0,0 +1,85 @@ +From e95874a4e271d0f8535ab78862af3d57d33e9d1e Mon Sep 17 00:00:00 2001 +From: James Mills +Date: Wed, 15 Jul 2020 20:21:23 +1000 +Subject: [PATCH] Applying patch to workaround a GCC bug from + https://sourceforge.net/p/judy/bugs/25/ (#2) + +Co-authored-by: Burak Arslan +--- + src/JudyCommon/JudyPrivateBranch.h | 33 +++++++++++++++++++----------- + 1 file changed, 21 insertions(+), 12 deletions(-) + +diff --git a/src/JudyCommon/JudyPrivateBranch.h b/src/JudyCommon/JudyPrivateBranch.h +index 70a2d54..10295ba 100644 +--- a/src/JudyCommon/JudyPrivateBranch.h ++++ b/src/JudyCommon/JudyPrivateBranch.h +@@ -19,7 +19,7 @@ + // Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + // _________________ + +-// @(#) $Revision: 4.57 $ $Source: /judy/src/JudyCommon/JudyPrivateBranch.h $ ++// @(#) $Revision: 1.2 $ $Source: /home/doug/judy-1.0.5_min/test/../src/JudyCommon/RCS/JudyPrivateBranch.h,v $ + // + // Header file for all Judy sources, for global but private (non-exported) + // declarations specific to branch support. +@@ -55,7 +55,7 @@ typedef struct J_UDY_POINTER_OTHERS // JPO. + { + Word_t j_po_Addr; // first word: Pjp_t, Word_t, etc. + union { +-// Word_t j_po_DcdPop0:cJU_BITSPERWORD-cJU_BITSPERBYTE; ++ Word_t j_po_Addr1; + uint8_t j_po_DcdP0[sizeof(Word_t) - 1]; + uint8_t j_po_Bytes[sizeof(Word_t)]; // last byte = jp_Type. + } jpo_u; +@@ -78,13 +78,18 @@ typedef struct J_UDY_POINTER_OTHERS // JPO. + // TBD: Revise this structure to not overload j_po_DcdPopO this way? The + // current arrangement works, its just confusing. + +-typedef struct _JUDY_POINTER_IMMED // JPI. ++typedef struct _JUDY_POINTER_IMMEDL + { +- uint8_t j_pi_1Index[sizeof(Word_t)]; // see above. +- uint8_t j_pi_LIndex[sizeof(Word_t) - 1]; // see above. +- uint8_t j_pi_Type; // JP type, 1 of cJ*_JPIMMED*. +- } jpi_t; ++ Word_t j_pL_Addr; ++ uint8_t j_pL_LIndex[sizeof(Word_t) - 1]; // see above. ++ uint8_t j_pL_Type; ++ } jpL_t; + ++typedef struct _JUDY_POINTER_IMMED1 ++ { ++ uint8_t j_p1_1Index[(2 * sizeof(Word_t)) - 1]; ++ uint8_t j_p1_Type; ++ } jp1_t; + + // UNION OF JP TYPES: + // +@@ -96,18 +101,22 @@ typedef struct _JUDY_POINTER_IMMED // JPI. + typedef union J_UDY_POINTER // JP. + { + jpo_t j_po; // other than immediate indexes. +- jpi_t j_pi; // immediate indexes. ++ jpL_t j_pL; // immediate indexes. ++ jp1_t j_p1; // immediate indexes. + } jp_t, *Pjp_t; + + // For coding convenience: + // +-// Note, jp_Type has the same bits in jpo_t and jpi_t. ++// Note, jp_Type has the same bits in jpo_t jpL_t and jp1_t. + +-#define jp_1Index j_pi.j_pi_1Index // for storing Indexes in first word. +-#define jp_LIndex j_pi.j_pi_LIndex // for storing Indexes in second word. ++#define jp_1Index j_p1.j_p1_1Index // for storing Indexes in first word. ++#define jp_LIndex j_pL.j_pL_LIndex // for storing Indexes in second word. + #define jp_Addr j_po.j_po_Addr ++#define jp_Addr1 j_po.jpo_u.j_po_Addr1 + //#define jp_DcdPop0 j_po.jpo_u.j_po_DcdPop0 +-#define jp_Type j_po.jpo_u.j_po_Bytes[sizeof(Word_t) - 1] ++#define jp_Addr1 j_po.jpo_u.j_po_Addr1 ++//#define jp_Type j_po.jpo_u.j_po_Bytes[sizeof(Word_t) - 1] ++#define jp_Type j_p1.j_p1_Type + #define jp_DcdP0 j_po.jpo_u.j_po_DcdP0 + + diff --git a/srcpkgs/judy/template b/srcpkgs/judy/template new file mode 100644 index 00000000000000..15bdb3548fa482 --- /dev/null +++ b/srcpkgs/judy/template @@ -0,0 +1,31 @@ +# Template file for 'judy' +pkgname=judy +version=1.0.5 +revision=1 +build_style=gnu-configure +build_helper=qemu +short_desc="C library creating and accessing dynamic arrays" +maintainer="Leah Neukirchen " +license="LGPL-2.1-or-later" +homepage="http://judy.sourceforge.net/" +distfiles="${SOURCEFORGE_SITE}/judy/Judy-${version}.tar.gz" +checksum=d2704089f85fdb6f2cd7e77be21170ced4b4375c03ef1ad4cf1075bd414a63eb +disable_parallel_build=yes +patch_args="-Np1" + +if [ "$CROSS_BUILD" ]; then +post_extract() { + sed -i "s|./Judy.TablesGen|/usr/bin/qemu-${XBPS_TARGET_QEMU_MACHINE}-static &|g" src/*/Makefile.in +} +fi + +judy-devel_package() { + depends="judy>=${version}_${revision}" + short_desc+=" - development files" + pkg_install() { + vmove usr/share/man/man3 + vmove usr/include + vmove "usr/lib/*.a" + vmove "usr/lib/*.so" + } +} From 9204c696a999dfa59aa8b0ca4f6555d12694d5b5 Mon Sep 17 00:00:00 2001 From: Leah Neukirchen Date: Tue, 25 Aug 2020 16:53:34 +0200 Subject: [PATCH 2/2] netdata: update to 1.24.0. --- srcpkgs/netdata/INSTALL | 4 ---- srcpkgs/netdata/template | 27 ++++++++++++++++----------- 2 files changed, 16 insertions(+), 15 deletions(-) diff --git a/srcpkgs/netdata/INSTALL b/srcpkgs/netdata/INSTALL index f61e2afec0924c..1275931376c8d7 100644 --- a/srcpkgs/netdata/INSTALL +++ b/srcpkgs/netdata/INSTALL @@ -1,9 +1,5 @@ case ${ACTION} in post) - chown _netdata:_netdata var/lib/netdata/ - chown _netdata:root var/lib/netdata/registry/ - chown root usr/libexec/netdata/plugins.d/apps.plugin - chmod 0755 usr/libexec/netdata/plugins.d/apps.plugin setcap cap_dac_read_search,cap_sys_ptrace+ep usr/libexec/netdata/plugins.d/apps.plugin ;; esac diff --git a/srcpkgs/netdata/template b/srcpkgs/netdata/template index 29e9ca1ce2c452..205d798561487c 100644 --- a/srcpkgs/netdata/template +++ b/srcpkgs/netdata/template @@ -1,18 +1,27 @@ # Template file for 'netdata' pkgname=netdata -version=1.22.1 +version=1.24.0 revision=1 +wrksrc="${pkgname}-v${version}" build_style=gnu-configure -configure_args="--with-user=_netdata" +configure_args="--with-user=_netdata ac_cv_file_externaldeps_libbpf_libbpf_a=no" hostmakedepends="pkg-config autoconf automake" -makedepends="libuuid-devel zlib-devel libuv-devel" +makedepends="json-c-devel judy-devel libcap-devel liblz4-devel libmnl-devel + libnetfilter_acct-devel libressl-devel libuuid-devel libuv-devel zlib-devel" +depends="libcap-progs" short_desc="Real-time performance monitoring, done right" maintainer="Michael Aldridge " license="GPL-3.0-or-later" homepage="http://my-netdata.io" -distfiles="https://github.com/netdata/netdata/archive/v${version}.tar.gz" -checksum=6efd785eab82f98892b4b4017cadfa4ce1688985915499bc75f2f888765a3446 -python_version=2 +distfiles="https://github.com/netdata/netdata/releases/download/v${version}/netdata-v${version}.tar.gz" +checksum=e7d6691fdce893b5a341fc2ee11b3b4f951e7b426031fae4178e669066c264c0 +python_version=3 +make_dirs=" + /var/lib/netdata 0755 _netdata _netdata + /var/lib/netdata/registry 0755 _netdata root + /var/cache/netdata 0755 _netdata _netdata + /var/log/netdata 0755 _netdata _netdata +" system_accounts="_netdata" conf_files="/etc/${pkgname}/*.conf" @@ -28,10 +37,6 @@ if [ -z "$_without_node" ]; then subpackages+=" netdata-plugins-nodejs" fi -make_dirs=" - /var/cache/netdata 0755 _netdata _netdata - /var/log/netdata 0755 _netdata _netdata" - pre_configure() { autoreconf -ivf } @@ -57,7 +62,7 @@ netdata-plugins-nodejs_package() { netdata-plugins-python_package() { short_desc+=" - Python Plugins" - depends="${sourcepkg}>=${version}_${revision} python" + depends="${sourcepkg}>=${version}_${revision} python3" archs=noarch pkg_install() { vmove usr/libexec/netdata/plugins.d/python.d.plugin