Gentoo Archives: gentoo-commits

From: Lars Wendler <polynomial-c@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-misc/htpdate/
Date: Wed, 31 Mar 2021 14:07:44
Message-Id: 1617199654.008d0f8ba86ba9a26c0d714afe8a59b64c924c4c.polynomial-c@gentoo
1 commit: 008d0f8ba86ba9a26c0d714afe8a59b64c924c4c
2 Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
3 AuthorDate: Wed Mar 31 14:06:06 2021 +0000
4 Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
5 CommitDate: Wed Mar 31 14:07:34 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=008d0f8b
7
8 net-misc/htpdate: Bump to version 1.2.6
9
10 Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>
11
12 net-misc/htpdate/Manifest | 1 +
13 net-misc/htpdate/htpdate-1.2.6.ebuild | 57 +++++++++++++++++++++++++++++++++++
14 2 files changed, 58 insertions(+)
15
16 diff --git a/net-misc/htpdate/Manifest b/net-misc/htpdate/Manifest
17 index 376fc113e47..30cab06962d 100644
18 --- a/net-misc/htpdate/Manifest
19 +++ b/net-misc/htpdate/Manifest
20 @@ -1,2 +1,3 @@
21 DIST htpdate-1.2.0.tar.gz 13618 BLAKE2B a94f08738d08c0caacc876d2e25e1dba43bbe371b0a31f957a1d5ff522b0ae5bd7bf5abcde63802843b1c32799e4cc38bacda657a9efb3a56a1eaccdb4f8c35c SHA512 5447d54a54038cc3c33f7877410ae42022e01eb10a93bd79fe4937452a823c65c6bdb743213bc77a8506128d5b384e26812f1291a0ffa1aeafde0230c1b645d4
22 DIST htpdate-1.2.2.tar.gz 13625 BLAKE2B 11813def81e3cce1194120a21cf99e8ad288b0f604aab201850f03b6ca786d19792b9586c9d805aa1945bbc651e6afc5099b5c7cb6ea354473a4b3bab01397e3 SHA512 00d52b291004ddb3d0282aef78c5fbe5d9397dbf171a6646803ee7ba4bd0514af6089f7e48a92397dd1b0fbae5ba314f5165c9902028438e16d3516b65724de0
23 +DIST htpdate-1.2.6.tar.gz 15083 BLAKE2B 913337f51fd26e811e33f195e463adc57e2512ba502f668f2429676d962623ea943bdb1d42ceddf6d35e7e8ba727b3f1300b34a8370ed661b3fa5b4b53ef1af7 SHA512 fe7442be5581eea0579060c02fb4ffe52151c6408d1b47afc9be049d2a8b1c8d0acd3b3481680a4b6a50f52622d47266afc0fe8dc67c5bb2a3aca2422e34f23f
24
25 diff --git a/net-misc/htpdate/htpdate-1.2.6.ebuild b/net-misc/htpdate/htpdate-1.2.6.ebuild
26 new file mode 100644
27 index 00000000000..03379020927
28 --- /dev/null
29 +++ b/net-misc/htpdate/htpdate-1.2.6.ebuild
30 @@ -0,0 +1,57 @@
31 +# Copyright 1999-2021 Gentoo Authors
32 +# Distributed under the terms of the GNU General Public License v2
33 +
34 +EAPI=7
35 +
36 +inherit flag-o-matic readme.gentoo-r1 toolchain-funcs
37 +
38 +DESCRIPTION="Synchronize local workstation with time offered by remote webservers"
39 +HOMEPAGE="https://github.com/angeloc/htpdate"
40 +if [[ "${PV}" == *9999 ]] ; then
41 + inherit git-r3
42 + EGIT_REPO_URI="https://github.com/angeloc/htpdate.git"
43 +else
44 + SRC_URI="https://github.com/angeloc/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
45 + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~mips ~ppc ~ppc64 ~s390 ~x86 ~amd64-linux ~x86-linux"
46 +fi
47 +IUSE="+ssl"
48 +LICENSE="GPL-2"
49 +SLOT="0"
50 +
51 +DEPEND="ssl? ( dev-libs/openssl:0= )"
52 +RDEPEND="${DEPEND}"
53 +BDEPEND="ssl? ( virtual/pkgconfig )"
54 +
55 +DOC_CONTENTS="If you would like to run htpdate as a daemon, set
56 +appropriate http servers in /etc/conf.d/htpdate!"
57 +
58 +PATCHES=( "${FILESDIR}/${PN}-1.2.6-ldlibs.patch" )
59 +
60 +src_prepare() {
61 + default
62 +
63 + # Use more standard adjtimex() to fix uClibc builds.
64 + sed -i 's:ntp_adjtime:adjtimex:g' htpdate.[8c] || die
65 + # Don't compress man pages by default
66 + sed '/gzip/d' -i Makefile || die
67 +}
68 +
69 +src_compile() {
70 + if use ssl ; then
71 + append-cflags -DENABLE_HTTPS
72 + export PKG_CONFIG="$(tc-getPKG_CONFIG)"
73 + fi
74 +
75 + emake CFLAGS="-Wall ${CFLAGS}" CC="$(tc-getCC)" \
76 + $(usex ssl 'ENABLE_HTTPS=1' '')
77 +}
78 +
79 +src_install() {
80 + emake DESTDIR="${D}" bindir='$(prefix)/sbin' install
81 + dodoc README.md Changelog
82 +
83 + newconfd "${FILESDIR}"/htpdate.conf htpdate
84 + newinitd "${FILESDIR}"/htpdate.init-r1 htpdate
85 +
86 + readme.gentoo_create_doc
87 +}