1 |
commit: f108aece8a44161ce4f4a6b957ca737b989d11e1 |
2 |
Author: Anthony G. Basile <blueness <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sat Feb 24 01:20:56 2018 +0000 |
4 |
Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Feb 24 01:21:11 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f108aece |
7 |
|
8 |
net-misc/ntpsec: fix config files and remove strip executables |
9 |
|
10 |
Package-Manager: Portage-2.3.19, Repoman-2.3.6 |
11 |
|
12 |
net-misc/ntpsec/metadata.xml | 1 + |
13 |
...{ntpsec-1.0.0.ebuild => ntpsec-1.0.0-r1.ebuild} | 40 ++++++++++++++-------- |
14 |
2 files changed, 26 insertions(+), 15 deletions(-) |
15 |
|
16 |
diff --git a/net-misc/ntpsec/metadata.xml b/net-misc/ntpsec/metadata.xml |
17 |
index 7bb04cc47d2..018f5f40f71 100644 |
18 |
--- a/net-misc/ntpsec/metadata.xml |
19 |
+++ b/net-misc/ntpsec/metadata.xml |
20 |
@@ -15,6 +15,7 @@ NTPsec project - a secure, hardened, and improved implementation of Network Time |
21 |
<use> |
22 |
<flag name="early">Drop root privileges early</flag> |
23 |
<flag name="gdb">Enable debugging with gdb</flag> |
24 |
+ <flag name="heat">Install contrib heat generating scripts</flag> |
25 |
<flag name="nist">Enable lockclock</flag> |
26 |
<flag name="ntpviz">Make visualizations of offsets, jiffies, etc.</flag> |
27 |
<flag name="rclock_oncore">Oncore driver</flag> |
28 |
|
29 |
diff --git a/net-misc/ntpsec/ntpsec-1.0.0.ebuild b/net-misc/ntpsec/ntpsec-1.0.0-r1.ebuild |
30 |
similarity index 75% |
31 |
rename from net-misc/ntpsec/ntpsec-1.0.0.ebuild |
32 |
rename to net-misc/ntpsec/ntpsec-1.0.0-r1.ebuild |
33 |
index d4cca435dbb..91a7ea1e911 100644 |
34 |
--- a/net-misc/ntpsec/ntpsec-1.0.0.ebuild |
35 |
+++ b/net-misc/ntpsec/ntpsec-1.0.0-r1.ebuild |
36 |
@@ -32,7 +32,7 @@ IUSE_NTPSEC_REFCLOCK=${NTPSEC_REFCLOCK[@]/#/rclock_} |
37 |
|
38 |
LICENSE="HPND MIT BSD-2 BSD CC-BY-SA-4.0" |
39 |
SLOT="0" |
40 |
-IUSE="${IUSE_NTPSEC_REFCLOCK} debug doc early gdb nist ntpviz samba seccomp smear tests" #ionice |
41 |
+IUSE="${IUSE_NTPSEC_REFCLOCK} debug doc early gdb heat libressl nist ntpviz samba seccomp smear tests" #ionice |
42 |
REQUIRED_USE="${PYTHON_REQUIRED_USE}" |
43 |
|
44 |
# net-misc/pps-tools oncore,pps |
45 |
@@ -40,7 +40,8 @@ CDEPEND="${PYTHON_DEPS} |
46 |
${BDEPEND} |
47 |
sys-libs/libcap |
48 |
dev-python/psutil |
49 |
- dev-libs/openssl:* |
50 |
+ libressl? ( dev-libs/libressl:0= ) |
51 |
+ !libressl? ( dev-libs/openssl:0= ) |
52 |
seccomp? ( sys-libs/libseccomp ) |
53 |
" |
54 |
RDEPEND="${CDEPEND} |
55 |
@@ -68,16 +69,21 @@ src_configure() { |
56 |
local string_127="" |
57 |
local rclocks=""; |
58 |
local CLOCKSTRING="" |
59 |
+ |
60 |
for refclock in ${NTPSEC_REFCLOCK[@]} ; do |
61 |
- if use rclock_${refclock} ; then |
62 |
+ if use rclock_${refclock} ; then |
63 |
string_127+="$refclock," |
64 |
fi |
65 |
done |
66 |
CLOCKSTRING="`echo ${string_127}|sed 's|,$||'`" |
67 |
+ |
68 |
+ # Remove autostripping of binaries |
69 |
+ sed -i -e '/Strip binaries/d' wscript |
70 |
+ |
71 |
waf-utils_src_configure --nopyc --nopyo --refclock="${CLOCKSTRING}" \ |
72 |
- $(use doc && echo "--enable-doc") \ |
73 |
+ $(use doc && echo "--enable-doc") \ |
74 |
$(use early && echo "--enable-early-droproot") \ |
75 |
- $(use gdb && echo "--enable-debug-gdb") \ |
76 |
+ $(use gdb && echo "--enable-debug-gdb") \ |
77 |
$(use nist && echo "--enable-lockclock") \ |
78 |
$(use samba && echo "--enable-mssntp") \ |
79 |
$(use seccomp && echo "--enable-seccomp") \ |
80 |
@@ -88,19 +94,23 @@ src_configure() { |
81 |
|
82 |
src_install() { |
83 |
waf-utils_src_install |
84 |
- mv -v "${ED}/usr/"{,share/}man |
85 |
- dosbin "${S}/contrib/ntpheat"{,usb} |
86 |
- dodoc "${S}/contrib/logrotate-ntpd" |
87 |
- systemd_newunit "${FILESDIR}/ntpd.service" ntpd.service |
88 |
+ |
89 |
+ # Install heat generating scripts |
90 |
+ use heat && dosbin "${S}/contrib/ntpheat"{,usb} |
91 |
+ |
92 |
+ # Install the openrc files |
93 |
newinitd "${FILESDIR}/ntpd.rc-r1" "ntp" |
94 |
newconfd "${FILESDIR}/ntpd.confd" "ntp" |
95 |
- mkdir "${ED}/etc/systemd/system/" |
96 |
- cp -v "${FILESDIR}/ntpd.service" "${ED}/etc/systemd/system/" |
97 |
- # ntpd.confd ntpd.rc-r1 ntpd.service |
98 |
|
99 |
- mkdir -pv "${ED}/etc/"{logrotate,ntp-conf}.d |
100 |
+ # Install the systemd unit file |
101 |
+ systemd_newunit "${FILESDIR}/ntpd.service" ntpd.service |
102 |
+ |
103 |
+ # Install a log rotate script |
104 |
+ mkdir -pv "${ED}/etc/"logrotate.d |
105 |
cp -v "${S}/etc/logrotate-config.ntpd" "${ED}/etc/logrotate.d/ntpd" |
106 |
+ |
107 |
+ # Install the configuration files |
108 |
cp -Rv "${S}/etc/ntp.d/" "${ED}/etc/" |
109 |
- mv -v "${ED}/etc/ntp.d/example.conf" "${ED}/etc/ntp.conf" |
110 |
- sed "s|includefile |includefile ntp-conf.d/|" -i "${ED}/etc/ntp.conf" |
111 |
+ mv -v "${ED}/etc/ntp.d/default.conf" "${ED}/etc/ntp.conf" |
112 |
+ sed "s|includefile |includefile ntp.d/|" -i "${ED}/etc/ntp.conf" |
113 |
} |