summaryrefslogtreecommitdiff
blob: 83152d7202321facce719f8b34a52179dde04cd6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-misc/clockspeed/clockspeed-0.62-r2.ebuild,v 1.4 2003/04/01 21:46:56 drobbins Exp $

inherit eutils

IUSE="static"

DESCRIPTION="A simple Network Time Protocol (NTP) client"
SRC_URI="http://cr.yp.to/clockspeed/${P}.tar.gz"
HOMEPAGE="http://cr.yp.to/"

SLOT="0"
LICENSE="as-is"
KEYWORDS="x86 ~ppc ~sparc"

DEPEND="sys-apps/groff"

src_compile() {
	epatch ${FILESDIR}/${PF}-gentoo.diff

	cp conf-cc{,.old}
	sed -e "s/@CFLAGS@/${CFLAGS}/" conf-cc.old > conf-cc

	use static && LDFLAGS="${LDFLAGS} -static"

	cp conf-ld{,.old}
	sed -e "s:@LDFLAGS@:${LDFLAGS}:" conf-ld.old > conf-ld

	emake || die
}

src_install() {
	dobin clockspeed clockadd clockview sntpclock taiclock taiclockd
	dosbin ${FILESDIR}/ntpclockset

	doman clockspeed.1 clockadd.1 clockview.1 sntpclock.1 taiclock.1 taiclockd.1
	dodoc BLURB CHANGES README THANKS TODO INSTALL

	insinto /etc
	doins leapsecs.dat
}

pkg_postinst() {
	echo
	einfo "Use ntpclockset to set your clock!"
	echo
}