From 40aaaa64e86ba6710bbeb31c4615a6ce80e75e11 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Wed, 28 Apr 2021 20:21:43 +0100 Subject: gentoo resync : 28.04.2021 --- net-misc/ntpsec/Manifest | 7 +- .../files/ntpsec-1.2.0-move-newfstatat.patch | 20 +++ net-misc/ntpsec/ntpsec-1.1.9.ebuild | 6 +- net-misc/ntpsec/ntpsec-1.2.0-r1.ebuild | 167 +++++++++++++++++++++ net-misc/ntpsec/ntpsec-1.2.0.ebuild | 163 -------------------- net-misc/ntpsec/ntpsec-9999.ebuild | 6 +- 6 files changed, 197 insertions(+), 172 deletions(-) create mode 100644 net-misc/ntpsec/files/ntpsec-1.2.0-move-newfstatat.patch create mode 100644 net-misc/ntpsec/ntpsec-1.2.0-r1.ebuild delete mode 100644 net-misc/ntpsec/ntpsec-1.2.0.ebuild (limited to 'net-misc/ntpsec') diff --git a/net-misc/ntpsec/Manifest b/net-misc/ntpsec/Manifest index 2e17afa98526..80a6cdd22bef 100644 --- a/net-misc/ntpsec/Manifest +++ b/net-misc/ntpsec/Manifest @@ -4,10 +4,11 @@ AUX ntpd.confd 90 BLAKE2B 980ea88c97b1deff65f53c13410fe46bc1e19a80140776002ae2fd AUX ntpd.rc-r2 484 BLAKE2B 826a3ee09486d912525fe6d44b967e25d8b31485d89a80987afcf459ea335058ff8a7835f3931017505aad6c5ba60e546b608ce26a51ad38f5972675d0a47559 SHA512 dc89a58edf6f83878d42522a015f2c3e12db9505ea3d6bc4b04e6e82947a7be6e8d143e8808bb58644641dd754744fd4be20c8b944a4261b460c30b95436fc31 AUX ntpsec-1.1.8-fix-missing-scmp_sys-on-aarch64.patch 536 BLAKE2B cac17041a05d0ec22b8d95dbb16118d7603c74a7d4c873422de65451f5ddd74b7d9aceb51714d842ef7c4a37ea638212487d6db99ebfa201b01b9654b732538c SHA512 c54b3304ca467e8434e29d312e5839c788becd8ae9068737ec9725a42f22073ea0e86355999dc6d606c12f4c733497cbe48bd49b6e150c39e6540e581df6087e AUX ntpsec-1.1.9-remove-asciidoctor-from-config.patch 680 BLAKE2B 7204a831b3dc0dba7f268febd10fa7599ef6b9bee30199ce10529d2d326719f5b376d301aabfef3beacecd4af813bcef1d6a65d61ab00996d72f1240f83ef8e3 SHA512 3e012ad70507f440ed3a4aca4886a96e40d49a0dd7c14572f664633a56139cb7767e07ee1bb5e8295fc32052914364660c928d11369b6f80193ae7e190e5a48e +AUX ntpsec-1.2.0-move-newfstatat.patch 544 BLAKE2B 877bb058fc2d06c315c086b5501181bac1a63d3e08bfd900bd3cd651b8dafaac0531357c4b9f30c51eccf17f0debd219daba2d3f115843ad77bb4b9bcdfb47fb SHA512 fe2fac5c6b6cd5c905209685c57ef3a2f2fb14f633b5cd0e73aaace0f7774f76b1cb1b07b6c94558a6bff3017c8498574d12b703495ef314eaf5f1298a9c078f AUX ntpsec-no-bsd.patch 1538 BLAKE2B 6abb7acf23149a5a47f8e479bff090966e7e6161fc0d5bca1f9e5b9396d90898a783e7d309d6cdbdf689ea12314c804aa7a39f05b3f11d75a95eb337cea95b55 SHA512 7ddb346c7f0c9b30ea08ac28eaa39cf86e3d6cee7eaeba3bc7fe0883acd5087966e4e7beb298cee02607dfa3198a8c1dfcd9ce43ead820de3bb7014cefe75302 DIST ntpsec-1.1.9.tar.gz 2606066 BLAKE2B bbc482333c7f86936fa20751df1b427bc24be159969050caf5751e26724714bbf6491b120986563497f015c96ac9cdbdf0e999c6446a68798aff23076f631ecc SHA512 e04267aa675a5b528f3478d00329a569ecb9bbe2b6ad18697020854d2ee451bc188c4603cd5f420a08a7e3bf047d2db1301416f57f9156df23aceb1f57303b0b DIST ntpsec-1.2.0.tar.gz 2625968 BLAKE2B 23ceae5a1f241fcf5a17801fec2f15f9b9d9d64a108bebe29bdc75196303091eaf0efee7df67ce10acefb7c8dba90ce1144a0c0c5432797d7659714d162f26bb SHA512 9e18b3ca2f786a1ea323ba2384b51cff3d862115cea1ae576fc98172c476ac5e7d0d0fc873e47be0b19b050204ea9ed49669d94e66eb94525068dd1b08a8ae71 -EBUILD ntpsec-1.1.9.ebuild 4195 BLAKE2B 87535628390d2c8a8831c0231df3a26abe9f3bc31ea95735057847b8990a0929820717fb0dd504a21e0dabca1ba0567eaa363823b2a7bb844016edf045333526 SHA512 f240a105239c6dc38dfe7ea0a482947ad0a4bc55e45bf88b46f14e95b74417582088cee3b38233617c7c5472bb41f923f64e55d740693553c51174c1fe9afdc0 -EBUILD ntpsec-1.2.0.ebuild 4321 BLAKE2B 381e3c2d4d65f28f6e2677ee42e580fdb8fafabb917c61e4406966315578ff63e17aab1fde3ce1f6fa0f0f83bb5b5300cfe85c578888c50197d4c2a5894e64f7 SHA512 2a697d316d7e15134860bb6c94b37792e50be0f87f300b0a735b01c5c6b0c4c992dd46e686eaec32b2eec54064a6aa41d22e10451da5338ccfb17099bda87f27 -EBUILD ntpsec-9999.ebuild 4054 BLAKE2B efa90bfe1f54b23675a0efcb1aae76d612232f4e459c22deeb4a1c425a3ded6d82780099eee309a49145fbfdd73a599a800266501b0526670abc8fc5bd2683ad SHA512 b38be80a59f243a86e25d6472926666a987b2c310d554f8cae9865b802e604fc4cf01a852c13bfcddae6d467e513269e888d532dbd61a25f9b9946e9444b215c +EBUILD ntpsec-1.1.9.ebuild 4202 BLAKE2B 1ebc5057450b6540711e2ea2f5b8fb931003d2a48e414cf7d3bb053ca0edecb0c1ef25a98e43d7548ac343e790c28ff1b06a5df8109aca59dac4fba4939491f0 SHA512 2cdbff26ce55200b1c27d21bca50fab17754390a30b51dd755c13448493858f103600b377cbd858c5e601d390d8aaceea9ac11db99b8ddae55b6cd3c00a42fe7 +EBUILD ntpsec-1.2.0-r1.ebuild 4445 BLAKE2B a680005d9aad4391f8df584d76484f22461168229c2ee0519f26e01a166b959b98f3ac92a9ad52ab1f9939f8eeda99ddb3931dc70c90df0f06f5067b6854f7cc SHA512 39e84d394ea3a7e849073b189c814f042387f97dfbe8387be35bf556b247194cd3962311a15346c782cb004cc95b5a186610cc6097a390473f22d81517266894 +EBUILD ntpsec-9999.ebuild 4061 BLAKE2B 8da977b7169633fe0ff502be5972399ab72207bb5b2a3a1d2a469c6b716b501f899814a1f3993a2ec1ceb796cf611cbc5ffe279d60b275465f930d99e643e040 SHA512 a3a122de2ac5e2d16c714599547d9470598f8736d3ee26b8f1adf45f91259ad31ba59feaea4b3b913217a04aae35ba0e3a4adf2bd50653eebe0b873fbc51ac87 MISC metadata.xml 2078 BLAKE2B c15f3c9143653044f1da8fdf1e36298df819a6266ca369c511a9d4247cf32d93377b26f4898070c60d59b4737581b22b27a1097de38c314ec03cc908a18a31d3 SHA512 691f4b463d437616d897d979538e20726eda0a4835f3209639ef0ae7ecbcea6fd01c7bfd1849b91bfdd37e71b8306daa07cf6223a08848c7e45f8128135fa6fc diff --git a/net-misc/ntpsec/files/ntpsec-1.2.0-move-newfstatat.patch b/net-misc/ntpsec/files/ntpsec-1.2.0-move-newfstatat.patch new file mode 100644 index 000000000000..75453c6cb5f6 --- /dev/null +++ b/net-misc/ntpsec/files/ntpsec-1.2.0-move-newfstatat.patch @@ -0,0 +1,20 @@ +diff --git a/ntpd/ntp_sandbox.c b/ntpd/ntp_sandbox.c +index e66faaa8c..b2af654e5 100644 +--- a/ntpd/ntp_sandbox.c ++++ b/ntpd/ntp_sandbox.c +@@ -349,6 +349,7 @@ int scmp_sc[] = { + SCMP_SYS(lseek), + SCMP_SYS(membarrier), /* Needed on Alpine 3.11.3 */ + SCMP_SYS(munmap), ++ SCMP_SYS(newfstatat), + SCMP_SYS(open), + #ifdef __NR_openat + SCMP_SYS(openat), /* SUSE */ +@@ -451,7 +452,6 @@ int scmp_sc[] = { + #endif + #if defined(__aarch64__) + SCMP_SYS(faccessat), +- SCMP_SYS(newfstatat), + SCMP_SYS(renameat), + SCMP_SYS(linkat), + SCMP_SYS(unlinkat), diff --git a/net-misc/ntpsec/ntpsec-1.1.9.ebuild b/net-misc/ntpsec/ntpsec-1.1.9.ebuild index 0f812f1ed853..0cfaff72ab52 100644 --- a/net-misc/ntpsec/ntpsec-1.1.9.ebuild +++ b/net-misc/ntpsec/ntpsec-1.1.9.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2020 Gentoo Authors +# Copyright 1999-2021 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=6 @@ -66,9 +66,9 @@ WAF_BINARY="${S}/waf" src_prepare() { default # Remove autostripping of binaries - sed -i -e '/Strip binaries/d' wscript + sed -i -e '/Strip binaries/d' wscript || die if ! use libbsd ; then - epatch "${FILESDIR}/${PN}-no-bsd.patch" + eapply "${FILESDIR}/${PN}-no-bsd.patch" fi python_copy_sources } diff --git a/net-misc/ntpsec/ntpsec-1.2.0-r1.ebuild b/net-misc/ntpsec/ntpsec-1.2.0-r1.ebuild new file mode 100644 index 000000000000..efc382f1edd9 --- /dev/null +++ b/net-misc/ntpsec/ntpsec-1.2.0-r1.ebuild @@ -0,0 +1,167 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +PYTHON_COMPAT=( python3_{6..9} ) +PYTHON_REQ_USE='threads(+)' +DISTUTILS_USE_SETUPTOOLS=no + +inherit distutils-r1 flag-o-matic waf-utils systemd + +if [[ ${PV} == *9999* ]]; then + inherit git-r3 + EGIT_REPO_URI="https://gitlab.com/NTPsec/ntpsec.git" +else + SRC_URI="ftp://ftp.ntpsec.org/pub/releases/${PN}-${PV}.tar.gz" + RESTRICT="mirror" + KEYWORDS="~amd64 ~arm ~arm64 ~x86" +fi + +DESCRIPTION="The NTP reference implementation, refactored" +HOMEPAGE="https://www.ntpsec.org/" + +NTPSEC_REFCLOCK=( + oncore trimble truetime gpsd jjy generic spectracom + shm pps hpgps zyfer arbiter nmea neoclock modem + local) + +IUSE_NTPSEC_REFCLOCK=${NTPSEC_REFCLOCK[@]/#/rclock_} + +LICENSE="HPND MIT BSD-2 BSD CC-BY-SA-4.0" +SLOT="0" +IUSE="${IUSE_NTPSEC_REFCLOCK} debug doc early gdb heat libbsd nist ntpviz samba seccomp smear tests" #ionice +REQUIRED_USE="${PYTHON_REQUIRED_USE} nist? ( rclock_local )" + +# net-misc/pps-tools oncore,pps +CDEPEND="${PYTHON_DEPS} + sys-libs/libcap + dev-python/psutil[${PYTHON_USEDEP}] + libbsd? ( dev-libs/libbsd:0= ) + dev-libs/openssl:0= + seccomp? ( sys-libs/libseccomp ) +" +RDEPEND="${CDEPEND} + ntpviz? ( sci-visualization/gnuplot media-fonts/liberation-fonts ) + !net-misc/ntp + !net-misc/openntpd + acct-group/ntp + acct-user/ntp +" +DEPEND="${CDEPEND} + >=app-text/asciidoc-8.6.8 + dev-libs/libxslt + app-text/docbook-xsl-stylesheets + sys-devel/bison + rclock_oncore? ( net-misc/pps-tools ) + rclock_pps? ( net-misc/pps-tools ) +" + +PATCHES=( + "${FILESDIR}/${PN}-1.1.8-fix-missing-scmp_sys-on-aarch64.patch" + "${FILESDIR}/${PN}-1.1.9-remove-asciidoctor-from-config.patch" + "${FILESDIR}/${PN}-1.2.0-move-newfstatat.patch" +) + +WAF_BINARY="${S}/waf" + +src_prepare() { + default + # Remove autostripping of binaries + sed -i -e '/Strip binaries/d' wscript || die + if ! use libbsd ; then + eapply "${FILESDIR}/${PN}-no-bsd.patch" + fi + # remove extra default pool servers + sed -i '/use-pool/s/^/#/' "${S}"/etc/ntp.d/default.conf || die + + python_copy_sources +} + +src_configure() { + is-flagq -flto* && filter-flags -flto* -fuse-linker-plugin + + local string_127="" + local rclocks=""; + local CLOCKSTRING="" + + for refclock in ${NTPSEC_REFCLOCK[@]} ; do + if use rclock_${refclock} ; then + string_127+="$refclock," + fi + done + CLOCKSTRING="`echo ${string_127}|sed 's|,$||'`" + + local myconf=( + --nopyc + --nopyo + --enable-pylib ext + --refclock="${CLOCKSTRING}" + --build-epoch="$(date +%s)" + $(use doc || echo "--disable-doc") + $(use early && echo "--enable-early-droproot") + $(use gdb && echo "--enable-debug-gdb") + $(use samba && echo "--enable-mssntp") + $(use seccomp && echo "--enable-seccomp") + $(use smear && echo "--enable-leap-smear") + $(use tests && echo "--alltests") + $(use debug && echo "--enable-debug") + ) + + python_configure() { + waf-utils_src_configure "${myconf[@]}" + } + python_foreach_impl run_in_build_dir python_configure +} + +src_compile() { + unset MAKEOPTS + python_compile() { + waf-utils_src_compile + } + python_foreach_impl run_in_build_dir python_compile +} + +src_install() { + python_install() { + waf-utils_src_install + python_fix_shebang "${ED}" + } + python_foreach_impl run_in_build_dir python_install + python_foreach_impl python_optimize + + # Install heat generating scripts + use heat && dosbin "${S}"/contrib/ntpheat{,usb} + + # Install the openrc files + newinitd "${FILESDIR}"/ntpd.rc-r2 ntp + newconfd "${FILESDIR}"/ntpd.confd ntp + + # Install the systemd unit file + systemd_newunit "${FILESDIR}"/ntpd-r1.service ntpd.service + + # Prepare a directory for the ntp.drift file + mkdir -pv "${ED}"/var/lib/ntp + chown ntp:ntp "${ED}"/var/lib/ntp + chmod 770 "${ED}"/var/lib/ntp + keepdir /var/lib/ntp + + # Install a log rotate script + mkdir -pv "${ED}"/etc/logrotate.d + cp -v "${S}"/etc/logrotate-config.ntpd "${ED}"/etc/logrotate.d/ntpd + + # Install the configuration file and sample configuration + cp -v "${FILESDIR}"/ntp.conf "${ED}"/etc/ntp.conf + cp -Rv "${S}"/etc/ntp.d/ "${ED}"/etc/ + + # move doc files to /usr/share/doc/"${P}" + use doc && mv -v "${ED}"/usr/share/doc/"${PN}" "${ED}"/usr/share/doc/"${P}"/html +} + +pkg_postinst() { + einfo "If you want to serve time on your local network, then" + einfo "you should disable all the ref_clocks unless you have" + einfo "one and can get stable time from it. Feel free to try" + einfo "it but PPS probably won't work unless you have a UART" + einfo "GPS that actually provides PPS messages." +} diff --git a/net-misc/ntpsec/ntpsec-1.2.0.ebuild b/net-misc/ntpsec/ntpsec-1.2.0.ebuild deleted file mode 100644 index a5193f995902..000000000000 --- a/net-misc/ntpsec/ntpsec-1.2.0.ebuild +++ /dev/null @@ -1,163 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=6 - -PYTHON_COMPAT=( python3_{7..9} ) -PYTHON_REQ_USE='threads(+)' - -inherit flag-o-matic python-r1 waf-utils systemd - -if [[ ${PV} == *9999* ]]; then - inherit git-r3 - EGIT_REPO_URI="https://gitlab.com/NTPsec/ntpsec.git" -else - SRC_URI="ftp://ftp.ntpsec.org/pub/releases/${PN}-${PV}.tar.gz" - RESTRICT="mirror" - KEYWORDS="~amd64 ~arm ~arm64 ~x86" -fi - -DESCRIPTION="The NTP reference implementation, refactored" -HOMEPAGE="https://www.ntpsec.org/" - -NTPSEC_REFCLOCK=( - oncore trimble truetime gpsd jjy generic spectracom - shm pps hpgps zyfer arbiter nmea neoclock modem - local) - -IUSE_NTPSEC_REFCLOCK=${NTPSEC_REFCLOCK[@]/#/rclock_} - -LICENSE="HPND MIT BSD-2 BSD CC-BY-SA-4.0" -SLOT="0" -IUSE="${IUSE_NTPSEC_REFCLOCK} debug doc early gdb heat libbsd nist ntpviz samba seccomp smear tests" #ionice -REQUIRED_USE="${PYTHON_REQUIRED_USE} nist? ( rclock_local )" - -# net-misc/pps-tools oncore,pps -CDEPEND="${PYTHON_DEPS} - sys-libs/libcap - dev-python/psutil[${PYTHON_USEDEP}] - libbsd? ( dev-libs/libbsd:0= ) - dev-libs/openssl:0= - seccomp? ( sys-libs/libseccomp ) -" -RDEPEND="${CDEPEND} - ntpviz? ( sci-visualization/gnuplot media-fonts/liberation-fonts ) - !net-misc/ntp - !net-misc/openntpd - acct-group/ntp - acct-user/ntp -" -DEPEND="${CDEPEND} - >=app-text/asciidoc-8.6.8 - dev-libs/libxslt - app-text/docbook-xsl-stylesheets - sys-devel/bison - rclock_oncore? ( net-misc/pps-tools ) - rclock_pps? ( net-misc/pps-tools ) -" - -PATCHES=( - "${FILESDIR}/${PN}-1.1.8-fix-missing-scmp_sys-on-aarch64.patch" - "${FILESDIR}/${PN}-1.1.9-remove-asciidoctor-from-config.patch" -) - -WAF_BINARY="${S}/waf" - -src_prepare() { - default - # Remove autostripping of binaries - sed -i -e '/Strip binaries/d' wscript - if ! use libbsd ; then - epatch "${FILESDIR}/${PN}-no-bsd.patch" - fi - # remove extra default pool servers - sed -i '/use-pool/s/^/#/' "${S}"/etc/ntp.d/default.conf - python_copy_sources -} - -src_configure() { - is-flagq -flto* && filter-flags -flto* -fuse-linker-plugin - - local string_127="" - local rclocks=""; - local CLOCKSTRING="" - - for refclock in ${NTPSEC_REFCLOCK[@]} ; do - if use rclock_${refclock} ; then - string_127+="$refclock," - fi - done - CLOCKSTRING="`echo ${string_127}|sed 's|,$||'`" - - local myconf=( - --nopyc - --nopyo - --enable-pylib ext - --refclock="${CLOCKSTRING}" - --build-epoch="$(date +%s)" - $(use doc || echo "--disable-doc") - $(use early && echo "--enable-early-droproot") - $(use gdb && echo "--enable-debug-gdb") - $(use samba && echo "--enable-mssntp") - $(use seccomp && echo "--enable-seccomp") - $(use smear && echo "--enable-leap-smear") - $(use tests && echo "--alltests") - $(use debug && echo "--enable-debug") - ) - - python_configure() { - waf-utils_src_configure "${myconf[@]}" - } - python_foreach_impl run_in_build_dir python_configure -} - -src_compile() { - unset MAKEOPTS - python_compile() { - waf-utils_src_compile - } - python_foreach_impl run_in_build_dir python_compile -} - -src_install() { - python_install() { - waf-utils_src_install - } - python_foreach_impl run_in_build_dir python_install - python_foreach_impl python_optimize - - # Install heat generating scripts - use heat && dosbin "${S}"/contrib/ntpheat{,usb} - - # Install the openrc files - newinitd "${FILESDIR}"/ntpd.rc-r2 ntp - newconfd "${FILESDIR}"/ntpd.confd ntp - - # Install the systemd unit file - systemd_newunit "${FILESDIR}"/ntpd-r1.service ntpd.service - - # Prepare a directory for the ntp.drift file - mkdir -pv "${ED}"/var/lib/ntp - chown ntp:ntp "${ED}"/var/lib/ntp - chmod 770 "${ED}"/var/lib/ntp - keepdir /var/lib/ntp - - # Install a log rotate script - mkdir -pv "${ED}"/etc/logrotate.d - cp -v "${S}"/etc/logrotate-config.ntpd "${ED}"/etc/logrotate.d/ntpd - - # Install the configuration file and sample configuration - cp -v "${FILESDIR}"/ntp.conf "${ED}"/etc/ntp.conf - cp -Rv "${S}"/etc/ntp.d/ "${ED}"/etc/ - - # move doc files to /usr/share/doc/"${P}" - use doc && mv -v "${ED}"/usr/share/doc/"${PN}" "${ED}"/usr/share/doc/"${P}"/html -} - -pkg_postinst() { - einfo "If you want to serve time on your local network, then" - einfo "you should disable all the ref_clocks unless you have" - einfo "one and can get stable time from it. Feel free to try" - einfo "it but PPS probably won't work unless you have a UART" - einfo "GPS that actually provides PPS messages." -} diff --git a/net-misc/ntpsec/ntpsec-9999.ebuild b/net-misc/ntpsec/ntpsec-9999.ebuild index 05e06f346200..361635d422b3 100644 --- a/net-misc/ntpsec/ntpsec-9999.ebuild +++ b/net-misc/ntpsec/ntpsec-9999.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2020 Gentoo Authors +# Copyright 1999-2021 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=6 @@ -61,9 +61,9 @@ WAF_BINARY="${S}/waf" src_prepare() { default # Remove autostripping of binaries - sed -i -e '/Strip binaries/d' wscript + sed -i -e '/Strip binaries/d' wscript || die if ! use libbsd ; then - epatch "${FILESDIR}/${PN}-no-bsd.patch" + eapply "${FILESDIR}/${PN}-no-bsd.patch" fi python_copy_sources } -- cgit v1.2.3