public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Michał Górny" <mgorny@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: net-misc/openntpd/
Date: Tue,  5 Jan 2021 21:20:21 +0000 (UTC)	[thread overview]
Message-ID: <1609881572.2d23cdc46ebda3861e5a9478f9e4d7c028b54a01.mgorny@gentoo> (raw)

commit:     2d23cdc46ebda3861e5a9478f9e4d7c028b54a01
Author:     Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Fri Jan  1 11:40:24 2021 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Tue Jan  5 21:19:32 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2d23cdc4

net-misc/openntpd: Support dev-libs/libretls

Closes: https://bugs.gentoo.org/762421
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
Closes: https://github.com/gentoo/gentoo/pull/18895
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>

 net-misc/openntpd/metadata.xml              |  1 +
 net-misc/openntpd/openntpd-6.8_p1-r1.ebuild | 67 +++++++++++++++++++++++++++++
 2 files changed, 68 insertions(+)

diff --git a/net-misc/openntpd/metadata.xml b/net-misc/openntpd/metadata.xml
index f5534c78e2f..20734983a2d 100644
--- a/net-misc/openntpd/metadata.xml
+++ b/net-misc/openntpd/metadata.xml
@@ -16,6 +16,7 @@
 		local clock.
 	</longdescription>
 	<use>
+		<flag name="constraints">Enable HTTPS TLS time constraint support</flag>
 		<flag name="libressl">Enable HTTPS TLS time constraint support using <pkg>dev-libs/libressl</pkg></flag>
 	</use>
 </pkgmetadata>

diff --git a/net-misc/openntpd/openntpd-6.8_p1-r1.ebuild b/net-misc/openntpd/openntpd-6.8_p1-r1.ebuild
new file mode 100644
index 00000000000..e1887e86760
--- /dev/null
+++ b/net-misc/openntpd/openntpd-6.8_p1-r1.ebuild
@@ -0,0 +1,67 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit systemd
+
+MY_P="${P/_p/p}"
+
+DESCRIPTION="Lightweight NTP server ported from OpenBSD"
+HOMEPAGE="http://www.openntpd.org/"
+SRC_URI="mirror://openbsd/OpenNTPD/${MY_P}.tar.gz"
+
+LICENSE="BSD GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="constraints libressl selinux"
+
+DEPEND="
+	!net-misc/ntp[-openntpd]
+	constraints? (
+		libressl? ( dev-libs/libressl:= )
+		!libressl? ( dev-libs/libretls:= )
+	)"
+
+RDEPEND="
+	${DEPEND}
+	acct-group/openntpd
+	acct-user/openntpd
+	selinux? ( sec-policy/selinux-ntp )"
+
+S="${WORKDIR}/${MY_P}"
+
+src_prepare() {
+	default
+
+	# fix /run path
+	sed -i 's:/var/run/ntpd:/run/ntpd:g' src/ntpctl.8 src/ntpd.8 || die
+	sed -i 's:LOCALSTATEDIR "/run/ntpd:"/run/ntpd:' src/ntpd.h || die
+
+	# fix ntpd.drift path
+	sed -i 's:/var/db/ntpd.drift:/var/lib/openntpd/ntpd.drift:g' src/ntpd.8 || die
+	sed -i 's:"/db/ntpd.drift":"/openntpd/ntpd.drift":' src/ntpd.h || die
+
+	# fix default config to use gentoo pool
+	sed -i 's:^server:#server:g' ntpd.conf || die
+	printf "\n# Choose servers announced from Gentoo NTP Pool\nservers 0.gentoo.pool.ntp.org\nservers 1.gentoo.pool.ntp.org\nservers 2.gentoo.pool.ntp.org\nservers 3.gentoo.pool.ntp.org\n" >> ntpd.conf || die
+
+	use constraints || sed -ie 's/^constraints/#constraints/g' ntpd.conf || die
+}
+
+src_configure() {
+	econf \
+		--with-privsep-user=openntpd \
+		$(use_enable constraints https-constraint)
+}
+
+src_install() {
+	default
+
+	rm -r "${ED}"/var || die
+
+	newinitd "${FILESDIR}/${PN}.init.d-20080406-r6" ntpd
+	newconfd "${FILESDIR}/${PN}.conf.d-20080406-r6" ntpd
+
+	systemd_newunit "${FILESDIR}/${PN}.service-20080406-r4" ntpd.service
+}


             reply	other threads:[~2021-01-05 21:20 UTC|newest]

Thread overview: 78+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-05 21:20 Michał Górny [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-05-22  1:06 [gentoo-commits] repo/gentoo:master commit in: net-misc/openntpd/ Sam James
2024-05-22  1:06 Sam James
2024-05-22  1:06 Sam James
2022-11-29 15:58 WANG Xuerui
2022-09-25  1:27 Sam James
2022-07-28 13:31 Sam James
2021-07-28 13:14 Marek Szuba
2021-04-30 13:35 Mikle Kolyada
2021-03-03 18:38 Sam James
2021-02-25  9:53 Sam James
2021-02-25  7:31 Sam James
2021-02-25  2:50 Sam James
2021-02-24 20:25 Sam James
2021-02-24 20:24 Sam James
2021-02-24  1:30 Joshua Kinard
2021-02-23 18:13 Sergei Trofimovich
2021-02-18  7:27 Sam James
2021-01-19 14:25 Sam James
2021-01-19  2:24 Sam James
2021-01-10 15:50 Sergei Trofimovich
2021-01-09 19:09 Sam James
2021-01-09 19:09 Sam James
2021-01-08  7:24 Sergei Trofimovich
2021-01-06 17:35 Sergei Trofimovich
2021-01-06 10:07 Michał Górny
2021-01-06  5:03 Joshua Kinard
2021-01-05 21:59 Andreas K. Hüttel
2020-12-17 14:12 Joonas Niilola
2020-11-27 16:28 Aaron Bauman
2020-11-17 19:05 Agostino Sarubbo
2020-11-04  0:55 Sam James
2020-11-03 22:47 Sergei Trofimovich
2020-11-01 11:19 Sam James
2020-11-01 11:12 Sam James
2020-10-31 20:54 Sergei Trofimovich
2020-10-31 20:20 Sergei Trofimovich
2020-10-31 20:16 Sergei Trofimovich
2020-10-31 16:27 Thomas Deutschmann
2020-06-28 16:52 Christoph Junghans
2020-05-09 19:43 Sergei Trofimovich
2020-05-08 17:13 Agostino Sarubbo
2020-05-08 17:13 Agostino Sarubbo
2020-05-08 17:11 Agostino Sarubbo
2020-05-08 17:10 Agostino Sarubbo
2020-05-06 18:50 Mart Raudsepp
2020-05-06 17:34 Sergei Trofimovich
2020-05-06 14:30 Agostino Sarubbo
2020-05-06 14:23 Agostino Sarubbo
2019-12-08 10:08 Joonas Niilola
2019-03-09  8:18 Mikle Kolyada
2018-03-21 11:08 Mart Raudsepp
2018-02-22  4:45 Christoph Junghans
2017-11-26 23:23 David Seifert
2017-07-21  9:34 Patrice Clement
2017-05-21 19:06 Christoph Junghans
2016-07-08 12:02 Agostino Sarubbo
2016-07-08 10:02 Agostino Sarubbo
2016-07-08  7:53 Agostino Sarubbo
2016-06-21 11:39 Jeroen Roovers
2016-06-04  5:09 Markus Meier
2016-06-03  3:32 Jeroen Roovers
2016-06-01 15:18 Tobias Klausmann
2016-06-01 14:45 Agostino Sarubbo
2016-06-01 14:45 Agostino Sarubbo
2016-05-31 16:35 Christoph Junghans
2016-05-23 20:56 Christoph Junghans
2016-04-16 16:49 Christoph Junghans
2016-02-01 13:52 Tobias Klausmann
2015-12-27  9:52 Mikle Kolyada
2015-11-18  9:32 Agostino Sarubbo
2015-11-12 10:51 Agostino Sarubbo
2015-11-11  9:54 Agostino Sarubbo
2015-11-10 11:45 Agostino Sarubbo
2015-11-07 12:12 Markus Meier
2015-10-26  6:20 Jeroen Roovers
2015-10-26  6:14 Jeroen Roovers
2015-08-27  3:51 Christoph Junghans

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1609881572.2d23cdc46ebda3861e5a9478f9e4d7c028b54a01.mgorny@gentoo \
    --to=mgorny@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox