tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
lol
0
fork
atom
overview
issues
pulls
pipelines
chrony: update build configuration
Izorkin
3 years ago
53cbb123
409c646e
+46
-10
2 changed files
expand all
collapse all
unified
split
pkgs
tools
networking
chrony
default.nix
makefile.patch
+23
-10
pkgs/tools/networking/chrony/default.nix
···
1
-
{ lib, stdenv, fetchurl, pkg-config, libcap, readline, texinfo, nss, nspr
2
-
, libseccomp, pps-tools, gnutls }:
0
0
3
4
stdenv.mkDerivation rec {
5
pname = "chrony";
···
7
8
src = fetchurl {
9
url = "https://download.tuxfamily.org/chrony/${pname}-${version}.tar.gz";
10
-
sha256 = "sha256-nQ2oiahl8ImlohYQ/7ZxPjyUOM4wOmO0nC+26v9biAQ=";
11
};
12
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
13
postPatch = ''
14
patchShebangs test
15
'';
16
17
-
buildInputs = [ readline texinfo nss nspr gnutls ]
18
-
++ lib.optionals stdenv.isLinux [ libcap libseccomp pps-tools ];
19
-
nativeBuildInputs = [ pkg-config ];
20
-
21
hardeningEnable = [ "pie" ];
22
-
23
-
configureFlags = [ "--chronyvardir=$(out)/var/lib/chrony" "--enable-ntp-signd" ]
24
-
++ lib.optional stdenv.isLinux "--enable-scfilter";
25
26
meta = with lib; {
27
description = "Sets your computer's clock from time servers on the Net";
···
1
+
{ lib, stdenv, fetchurl, pkg-config
2
+
, gnutls, libedit, nspr, nss, readline, texinfo
3
+
, libcap, libseccomp, pps-tools
4
+
}:
5
6
stdenv.mkDerivation rec {
7
pname = "chrony";
···
9
10
src = fetchurl {
11
url = "https://download.tuxfamily.org/chrony/${pname}-${version}.tar.gz";
12
+
hash = "sha256-nQ2oiahl8ImlohYQ/7ZxPjyUOM4wOmO0nC+26v9biAQ=";
13
};
14
15
+
outputs = [ "out" "man" ];
16
+
17
+
nativeBuildInputs = [ pkg-config ];
18
+
19
+
buildInputs = [ gnutls libedit nspr nss readline texinfo ]
20
+
++ lib.optionals stdenv.isLinux [ libcap libseccomp pps-tools ];
21
+
22
+
configureFlags = [
23
+
"--enable-ntp-signd"
24
+
"--sbindir=$(out)/bin"
25
+
"--chronyrundir=/run/chrony"
26
+
] ++ lib.optional stdenv.isLinux "--enable-scfilter";
27
+
28
+
patches = [
29
+
# Cleanup the installation script
30
+
./makefile.patch
31
+
];
32
+
33
postPatch = ''
34
patchShebangs test
35
'';
36
0
0
0
0
37
hardeningEnable = [ "pie" ];
0
0
0
38
39
meta = with lib; {
40
description = "Sets your computer's clock from time servers on the Net";
+23
pkgs/tools/networking/chrony/makefile.patch
···
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
···
1
+
diff --git a/Makefile.in b/Makefile.in
2
+
index ef100a4..47f54f4 100644
3
+
--- a/Makefile.in
4
+
+++ b/Makefile.in
5
+
@@ -23,7 +23,7 @@
6
+
7
+
SYSCONFDIR = @SYSCONFDIR@
8
+
BINDIR = @BINDIR@
9
+
-SBINDIR = @SBINDIR@
10
+
+SBINDIR = @BINDIR@
11
+
LOCALSTATEDIR = @LOCALSTATEDIR@
12
+
CHRONYVARDIR = @CHRONYVARDIR@
13
+
DESTDIR =
14
+
@@ -86,9 +86,7 @@ getdate :
15
+
16
+
install: chronyd chronyc
17
+
[ -d $(DESTDIR)$(SYSCONFDIR) ] || mkdir -p $(DESTDIR)$(SYSCONFDIR)
18
+
- [ -d $(DESTDIR)$(SBINDIR) ] || mkdir -p $(DESTDIR)$(SBINDIR)
19
+
[ -d $(DESTDIR)$(BINDIR) ] || mkdir -p $(DESTDIR)$(BINDIR)
20
+
- [ -d $(DESTDIR)$(CHRONYVARDIR) ] || mkdir -p $(DESTDIR)$(CHRONYVARDIR)
21
+
if [ -f $(DESTDIR)$(SBINDIR)/chronyd ]; then rm -f $(DESTDIR)$(SBINDIR)/chronyd ; fi
22
+
if [ -f $(DESTDIR)$(BINDIR)/chronyc ]; then rm -f $(DESTDIR)$(BINDIR)/chronyc ; fi
23
+
cp chronyd $(DESTDIR)$(SBINDIR)/chronyd