Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 770591 Details for
Bug 831352
net-misc/ntpsec-1.2.1-r1 fails to compile
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
try to only run tests in src_test removing them from src_install
0001-net-misc-ntpsec-Try-to-only-run-tests-in-src_test-on.patch (text/plain), 13.06 KB, created by
James Browning
on 2022-04-13 09:08:50 UTC
(
hide
)
Description:
try to only run tests in src_test removing them from src_install
Filename:
MIME Type:
Creator:
James Browning
Created:
2022-04-13 09:08:50 UTC
Size:
13.06 KB
patch
obsolete
>From e792458c808ab4ac400d81e57cbf3425a3e2fe72 Mon Sep 17 00:00:00 2001 >From: James Browning <jamesb.fe80@gmail.com> >Date: Tue, 12 Apr 2022 04:52:09 -0700 >Subject: [PATCH] net-misc/ntpsec: Try to only run tests in src_test only > >Since ./waf test runs all the test, this eliminates the need for >the tests useflag which filled that space. Thus it's eliminated. > >Signed-off-by: James T Browning <JamesB.fe80@gmail.com> >tested: a little more >--- > net-misc/ntpsec/Manifest | 8 ++-- > .../files/ntpsec-1.2.1-build-notests.patch | 48 +++++++++++++++++++ > .../files/ntpsec-py3-test-clarify.patch | 34 +++++++++++++ > net-misc/ntpsec/metadata.xml | 1 - > net-misc/ntpsec/ntpsec-1.2.1-r2.ebuild | 18 +++++-- > net-misc/ntpsec/ntpsec-9999.ebuild | 17 +++++-- > 6 files changed, 114 insertions(+), 12 deletions(-) > create mode 100644 net-misc/ntpsec/files/ntpsec-1.2.1-build-notests.patch > create mode 100644 net-misc/ntpsec/files/ntpsec-py3-test-clarify.patch > >diff --git a/net-misc/ntpsec/Manifest b/net-misc/ntpsec/Manifest >index 16b2e1b..94af072 100644 >--- a/net-misc/ntpsec/Manifest >+++ b/net-misc/ntpsec/Manifest >@@ -3,10 +3,12 @@ AUX ntpd-r1.service 613 BLAKE2B 9e0d0fdefa670c2ac25142bfb37880ce4ba0662f70f7cf9a > AUX ntpd.confd 90 BLAKE2B 980ea88c97b1deff65f53c13410fe46bc1e19a80140776002ae2fdc0a3ad18c9855b74a70f1a89eb31854bbdad6729753c3a199cddb25b58178a79a0ea0a7050 SHA512 a2fdf88f6f55bcf0a6545db77817e3a740dba50bf56b4fdd80d335e8c909d0880fbd962041754d7f5fb3946ed131d9a739ec72008bacab9f1f47ff82dc74c542 > AUX ntpd.rc-r2 484 BLAKE2B 826a3ee09486d912525fe6d44b967e25d8b31485d89a80987afcf459ea335058ff8a7835f3931017505aad6c5ba60e546b608ce26a51ad38f5972675d0a47559 SHA512 dc89a58edf6f83878d42522a015f2c3e12db9505ea3d6bc4b04e6e82947a7be6e8d143e8808bb58644641dd754744fd4be20c8b944a4261b460c30b95436fc31 > AUX ntpsec-1.1.9-remove-asciidoctor-from-config.patch 680 BLAKE2B 7204a831b3dc0dba7f268febd10fa7599ef6b9bee30199ce10529d2d326719f5b376d301aabfef3beacecd4af813bcef1d6a65d61ab00996d72f1240f83ef8e3 SHA512 3e012ad70507f440ed3a4aca4886a96e40d49a0dd7c14572f664633a56139cb7767e07ee1bb5e8295fc32052914364660c928d11369b6f80193ae7e190e5a48e >+AUX ntpsec-1.2.1-build-notests.patch 1512 BLAKE2B 16f1b49802c2883866d5ddc862c49ddca994fc530938b53d6059a0f044aa67692180efd528727b91940357562eb4db4a1abaa0a04404b13b912eb11a6a94b9fc SHA512 5b9cf22809a727c687d4a6796a334fd515d1de3883f2e72b5a44e787dd5e1189cc86e5a50c7f693d45e58ac1c5ee0503571fe4aa15cc31f7fc7d3f409128d21e > AUX ntpsec-1.2.1-seccomp-rollup.patch 2987 BLAKE2B 82bd355cdd169133f232f6514f363e87b6876472d49d69d034dd33aefe7179dc3db5e661909774471635dd947761f5e8ab47ecc0dcf8d6c2e62ffdad06044a3f SHA512 34c1941dfd7d7968fa954fb36411aad5e711767f1c0b6aca52cd8f8c839163110af2d4774a7a41b1f3d0daa49af5823b74e9c8a2a9ec12b9a344c72ce505d279 > AUX ntpsec-1.2.1-seccomp-rseq-glibc-2.35.patch 785 BLAKE2B df61801e9748e20ce7fa8577c472ea2ed4e31a8d2cb1aef39a245bfe145e482b61b6b30398fc5c2da69685ed872b70ac8399481ec71ea35fc4469df1b83bd195 SHA512 a35ba539aa6a0b8f28079e1dd7a729e7ea21ab045233d7b5e1938a11c03a72aa87907068505e0330c644ebb9b509663a21a24ad9a4cc954a0f03ec7198309c0e > AUX ntpsec-no-bsd.patch 1538 BLAKE2B 6abb7acf23149a5a47f8e479bff090966e7e6161fc0d5bca1f9e5b9396d90898a783e7d309d6cdbdf689ea12314c804aa7a39f05b3f11d75a95eb337cea95b55 SHA512 7ddb346c7f0c9b30ea08ac28eaa39cf86e3d6cee7eaeba3bc7fe0883acd5087966e4e7beb298cee02607dfa3198a8c1dfcd9ce43ead820de3bb7014cefe75302 >+AUX ntpsec-py3-test-clarify.patch 993 BLAKE2B 85df81d6301e3f057601bbb2e01590a11cefe338b8a309d37818524896cb694d9a479ab80613763bd2c779680ccecc06526dfca87370409372788ba9254b9003 SHA512 3ac296a2329b2a9dede51499a75f82eeae1870ad5dbd769b7ea1f3d4634ff2512fda8383f7d3adc6fa1a4fd03e035cf0b52157639ca21f458af161fffbf6a0e4 > DIST ntpsec-1.2.1.tar.gz 2681237 BLAKE2B bfb2674131718dcf9f393e93d1148cfb6631591dbcce1ade91746586f261123b80b238393ac2a763fab119cd627f8eae4b006b023ad2b319e752db9eb4b04cc0 SHA512 0b8b0bda52d3025f6e9a06c00b1e0c25c595ada72b87ed0e5d3d6f77a034f557745156bc6d9a263c9876c041efffa38d42fa93ba8bfda31f67efbd842a726277 >-EBUILD ntpsec-1.2.1-r2.ebuild 4434 BLAKE2B fc33f87243be18fe8ccf1faccc5aa261a162656e8c675fedaa333631ae85c95ca59bf8a06b24c4a3b3e46ab669bc026ae164afdb2a507f3e19b2cef3c7139602 SHA512 d564a533817ad9a54c81db43b8ab1e09dea2f8aa749c930662e2912bb0e058d9fdc835ab22599d403fe34dc85c6a1a25fe0635667ea8a6cf12cd9d5718baa507 >-EBUILD ntpsec-9999.ebuild 4329 BLAKE2B f6706f89cbd8191608ca4092ee2de304db5ac676cd6fcf3fc0d2c107acb5a66da0d546d8b060ff80db60a00a9029b0746e104b71546b0109ffddef259144d778 SHA512 26a81887ef0537376df3f458772cf000fb7f40171e7d481a1f72393f0226ee7c3c810715bcae144dab63b06e942767d6e073112e7626e2a12db5ecc80c8fc6e5 >-MISC metadata.xml 1902 BLAKE2B d807dc3dae199835bfa1624e76b43e39a1392f07d736ab5936c48bd4cfd69fdc1bae71a02c3cd9f405aa0992e7ebe27f5ffb639eafed027deba96eaa99ace391 SHA512 a29e4dfebcda69c393487ccfccdefd2b9e4e5c63591d2ed7c008b54b7c04afea071938fd2e0ce6c67f26ccecf427053b1a2b8e946dfcc3e092f64d00bc28aadf >+EBUILD ntpsec-1.2.1-r2.ebuild 4676 BLAKE2B 9b639988f63026b8d4913d31793110e624a27c4373d5c735de27557f11353f2cdce11ee6a59283807c98f196cba2917134683edf8b0f69506159b07b9efe1a3b SHA512 da31c3d8fb8e2964acc10555a08e563bd513d2b0e73d022c0e4cb8e854b84b8c6aae4d92849ff38cc82f73ed69895fc06411b064a8bfa9c3f29a526180b24137 >+EBUILD ntpsec-9999.ebuild 4524 BLAKE2B 32ebcada4e3665801633a7a9de226323696c682f9dd2cb45ba856b3ece155a37e27c2830ab34a8e9e3b98d16d1d5cefc3b06283834bc321dbe191c1fa54417e1 SHA512 d14b415cd141a151e15677cbbd4c036f64d6aa1c656fe5ada776d819ddbd2a489ed10007995200cd4ebb76e4136ebfbe148ea46616ea1741186933bbc5cc9f07 >+MISC metadata.xml 1861 BLAKE2B 0fabc902c8e69cc6f2c97bde03b0faa2420e480757a73053667c5a6ee256d09c6b9f60e337dd3fd3d848f9007c09650f20c317d301109663f8cbb0d2d4ffa2c4 SHA512 4fb728215e2d49458ba723031370be0b3cb271b1ee04cba1dcf7eeb39d01a191beceb5196da5ffc4586779443e40a88f77a3bb4a97dede7667b44bf84c370ea8 >diff --git a/net-misc/ntpsec/files/ntpsec-1.2.1-build-notests.patch b/net-misc/ntpsec/files/ntpsec-1.2.1-build-notests.patch >new file mode 100644 >index 0000000..dab51a9 >--- /dev/null >+++ b/net-misc/ntpsec/files/ntpsec-1.2.1-build-notests.patch >@@ -0,0 +1,48 @@ >+From 1a7bb2e3a2749bd709ea4cf10b66b6f6d05aaf9d Mon Sep 17 00:00:00 2001 >+From: James Browning <jamesb.fe80@gmail.com> >+Date: Sun, 10 Apr 2022 07:53:37 -0700 >+Subject: [PATCH] I: NTPsec build does not repect --notests >+ >+STR: (run the following) >+- git clone https://gitlab.com/NTPsec/ntpsec >+- cd ntpsec >+- ./waf configure build --notests -p >+ >+AR: NTPsec runs tests despite having a parameter telling it not to >+ER: NTPsec should not run tests when it has been told not to >+--- >+ wscript | 4 +++- >+ 1 file changed, 3 insertions(+), 1 deletion(-) >+ >+diff --git a/wscript b/wscript >+index c1d765046..d8a20b82e 100644 >+--- a/wscript >++++ b/wscript >+@@ -1131,6 +1131,7 @@ def build(ctx): >+ ctx.manpage(8, "ntpclients/ntpsnmpd-man.adoc") >+ >+ # Skip running unit tests on a cross compile build >++ from waflib import Options >+ if not ctx.env.ENABLE_CROSS: >+ # Force re-running of tests. Same as 'waf --alltests' >+ if ctx.cmd == "check": >+@@ -1139,6 +1140,8 @@ def build(ctx): >+ # Print log if -v is supplied >+ if verbose > 0: >+ ctx.add_post_fun(test_print_log) >++ elif Options.options.no_tests: >++ return >+ >+ # Test binaries >+ ctx.add_post_fun(bin_test) >+@@ -1152,7 +1155,6 @@ def build(ctx): >+ ctx.add_post_fun(bin_test_summary) >+ else: >+ pprint("YELLOW", "Unit test runner skipped on a cross-compiled build.") >+- from waflib import Options >+ Options.options.no_tests = True >+ >+ if ctx.cmd == "build": >+-- >+2.32.0 >+ >diff --git a/net-misc/ntpsec/files/ntpsec-py3-test-clarify.patch b/net-misc/ntpsec/files/ntpsec-py3-test-clarify.patch >new file mode 100644 >index 0000000..027c3df >--- /dev/null >+++ b/net-misc/ntpsec/files/ntpsec-py3-test-clarify.patch >@@ -0,0 +1,34 @@ >+From f360741dec76a9c9d831f0b547596891ea321599 Mon Sep 17 00:00:00 2001 >+From: James Browning <jamesb.fe80@gmail.com> >+Date: Sun, 10 Apr 2022 16:23:34 -0700 >+Subject: [PATCH] clean test output up in Python 3 >+ >+--- >+ wafhelpers/test.py | 9 +++++---- >+ 1 file changed, 5 insertions(+), 4 deletions(-) >+ >+diff --git a/wafhelpers/test.py b/wafhelpers/test.py >+index 9351a5675..6bba34881 100644 >+--- a/wafhelpers/test.py >++++ b/wafhelpers/test.py >+@@ -31,12 +31,13 @@ def test_print_log(ctx): >+ pprint("YELLOW", "RETURN VALUE:", retval) >+ print("") >+ >+- if retval or error: >++ if retval: >+ pprint("RED", "****** ERROR ******\n") >+ >+- print(error or lines) >++ print(polystr(error) or polystr(lines)) >+ >+- if (not retval) and (not error): >+- pprint("GREEN", "****** LOG ******\n", lines) >++ else: >++ pprint("GREEN", "****** LOG ******\n", >++ polystr(lines), polystr(error)) >+ >+ print("") >+-- >+2.32.0 >+ >diff --git a/net-misc/ntpsec/metadata.xml b/net-misc/ntpsec/metadata.xml >index 69f78f9..e19df03 100644 >--- a/net-misc/ntpsec/metadata.xml >+++ b/net-misc/ntpsec/metadata.xml >@@ -31,6 +31,5 @@ NTPsec project - a secure, hardened, and improved implementation of Network Time > <flag name="rclock_modem">NIST/USNO/PTB Modem Time Services</flag> > <flag name="rclock_local">Support for undisciplined local clock (not recommended)</flag> > <flag name="smear">Specify the interval over which a leap second is applied (experimental)</flag> >- <flag name="tests">Enable tests</flag> > </use> > </pkgmetadata> >diff --git a/net-misc/ntpsec/ntpsec-1.2.1-r2.ebuild b/net-misc/ntpsec/ntpsec-1.2.1-r2.ebuild >index 80e17ec..10c6300 100644 >--- a/net-misc/ntpsec/ntpsec-1.2.1-r2.ebuild >+++ b/net-misc/ntpsec/ntpsec-1.2.1-r2.ebuild >@@ -30,7 +30,7 @@ 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 >+IUSE="${IUSE_NTPSEC_REFCLOCK} debug doc early gdb heat libbsd nist ntpviz samba seccomp smear" #ionice > REQUIRED_USE="${PYTHON_REQUIRED_USE} nist? ( rclock_local )" > > # net-misc/pps-tools oncore,pps >@@ -61,6 +61,8 @@ PATCHES=( > "${FILESDIR}/${PN}-1.1.9-remove-asciidoctor-from-config.patch" > "${FILESDIR}/${PN}-1.2.1-seccomp-rollup.patch" > "${FILESDIR}/${PN}-1.2.1-seccomp-rseq-glibc-2.35.patch" >+ "${FILESDIR}/${PN}-1.2.1-build-notests.patch" >+ "${FILESDIR}/${PN}-py3-test-clarify.patch" > ) > > WAF_BINARY="${S}/waf" >@@ -94,6 +96,7 @@ src_configure() { > CLOCKSTRING="`echo ${string_127}|sed 's|,$||'`" > > local myconf=( >+ --notests > --nopyc > --nopyo > --enable-pylib ext >@@ -105,7 +108,6 @@ src_configure() { > $(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") > ) > >@@ -118,14 +120,22 @@ src_configure() { > src_compile() { > unset MAKEOPTS > python_compile() { >- waf-utils_src_compile >+ waf-utils_src_compile --notests >+ } >+ python_foreach_impl run_in_build_dir python_compile >+} >+ >+src_test() { >+ debug-print-function ${FUNCNAME} "$@" >+ python_compile() { >+ waf-utils_src_compile check > } > python_foreach_impl run_in_build_dir python_compile > } > > src_install() { > python_install() { >- waf-utils_src_install >+ waf-utils_src_install --notests > python_fix_shebang "${ED}" > } > python_foreach_impl run_in_build_dir python_install >diff --git a/net-misc/ntpsec/ntpsec-9999.ebuild b/net-misc/ntpsec/ntpsec-9999.ebuild >index 2065ee5..9916c57 100644 >--- a/net-misc/ntpsec/ntpsec-9999.ebuild >+++ b/net-misc/ntpsec/ntpsec-9999.ebuild >@@ -30,7 +30,7 @@ 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 >+IUSE="${IUSE_NTPSEC_REFCLOCK} debug doc early gdb heat libbsd nist ntpviz samba seccomp smear" #ionice > REQUIRED_USE="${PYTHON_REQUIRED_USE} nist? ( rclock_local )" > > # net-misc/pps-tools oncore,pps >@@ -59,6 +59,7 @@ DEPEND="${CDEPEND} > > PATCHES=( > "${FILESDIR}/${PN}-1.1.9-remove-asciidoctor-from-config.patch" >+ "${FILESDIR}/${PN}-py3-test-clarify.patch" > ) > > WAF_BINARY="${S}/waf" >@@ -92,6 +93,7 @@ src_configure() { > CLOCKSTRING="`echo ${string_127}|sed 's|,$||'`" > > local myconf=( >+ --notests > --nopyc > --nopyo > --enable-pylib ext >@@ -103,7 +105,6 @@ src_configure() { > $(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") > ) > >@@ -116,14 +117,22 @@ src_configure() { > src_compile() { > unset MAKEOPTS > python_compile() { >- waf-utils_src_compile >+ waf-utils_src_compile --notests >+ } >+ python_foreach_impl run_in_build_dir python_compile >+} >+ >+src_test() { >+ debug-print-function ${FUNCNAME} "$@" >+ python_compile() { >+ waf-utils_src_compile check > } > python_foreach_impl run_in_build_dir python_compile > } > > src_install() { > python_install() { >- waf-utils_src_install >+ waf-utils_src_install --notests > python_fix_shebang "${ED}" > } > python_foreach_impl run_in_build_dir python_install >-- >2.35.1 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 831352
:
762394
|
762401
|
769850
|
769883
|
770276
|
770363
|
770471
| 770591