From a2169c31feb3a4133937638a591741b617c4ddc0 Mon Sep 17 00:00:00 2001 From: Alexei Robyn Date: Tue, 19 Nov 2019 20:16:25 +1100 Subject: dante: fix package under Linux --- pkgs/servers/dante/default.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkgs/servers/dante/default.nix b/pkgs/servers/dante/default.nix index ae083f17ada9..c36ca2f8f509 100644 --- a/pkgs/servers/dante/default.nix +++ b/pkgs/servers/dante/default.nix @@ -11,7 +11,9 @@ stdenv.mkDerivation rec { buildInputs = [ pam libkrb5 cyrus_sasl miniupnpc ]; - configureFlags = ["--with-libc=libc${stdenv.targetPlatform.extensions.sharedLibrary}"]; + configureFlags = if !stdenv.isDarwin + then [ "--with-libc=libc.so.6" ] + else [ "--with-libc=libc${stdenv.targetPlatform.extensions.sharedLibrary}" ]; dontAddDisableDepTrack = stdenv.isDarwin; -- cgit v1.2.3 From e40adc8788c506ff24a4dec5cf83b8c26dadecfc Mon Sep 17 00:00:00 2001 From: Dmitry Olyenyov Date: Thu, 21 Nov 2019 11:44:09 +0300 Subject: neovim-qt: 0.2.12 -> 0.2.15 --- pkgs/applications/editors/neovim/qt.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/editors/neovim/qt.nix b/pkgs/applications/editors/neovim/qt.nix index 3a46f68e7755..8fe93d37c7e8 100644 --- a/pkgs/applications/editors/neovim/qt.nix +++ b/pkgs/applications/editors/neovim/qt.nix @@ -4,13 +4,13 @@ let unwrapped = mkDerivation rec { pname = "neovim-qt-unwrapped"; - version = "0.2.12"; + version = "0.2.15"; src = fetchFromGitHub { owner = "equalsraf"; repo = "neovim-qt"; rev = "v${version}"; - sha256 = "09s3044j0y8nmyi8ykslfii6fx7k9mckmdvb0jn2xmdabpb60i20"; + sha256 = "097nykglqp4jyvla4yp32sc1f1hph4cqqhp6rm9ww7br8c0j54xl"; }; cmakeFlags = [ -- cgit v1.2.3 From 984ed379d704d066efda34c15646ba639350cd0d Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Sun, 22 Dec 2019 23:29:35 -0800 Subject: cln: 1.3.5 -> 1.3.6 --- pkgs/development/libraries/cln/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/cln/default.nix b/pkgs/development/libraries/cln/default.nix index dc36414fc28d..6627f46c18e7 100644 --- a/pkgs/development/libraries/cln/default.nix +++ b/pkgs/development/libraries/cln/default.nix @@ -2,11 +2,11 @@ stdenv.mkDerivation rec { pname = "cln"; - version = "1.3.5"; + version = "1.3.6"; src = fetchurl { url = "${meta.homepage}${pname}-${version}.tar.bz2"; - sha256 = "0bc43v4fyxwik9gjkvm8jan74bkx9bjssv61lfh9jhhblmj010bq"; + sha256 = "0jlq9l4hphk7qqlgqj9ihjp4m3rwjbhk6q4v00lsbgbri07574pl"; }; buildInputs = [ gmp ]; -- cgit v1.2.3 From 68317c736e29b72387ed05be99492340df4eaf22 Mon Sep 17 00:00:00 2001 From: Andrew Childs Date: Sat, 4 Jan 2020 09:43:00 +0900 Subject: perl: fix configure phase for Aarch32 In "perl: fuse configureFlags" [1] the effects of the preConfigure phase were merged into configureFlags. After this change values with spaces do not reach the configure script intact. The only flag this affects is `ldflags` for Aarch32 and Mips, and perl builds without it on armv7l-linux so it's probably no longer required on any platform. Fixes: configuring configure flags: -de -Dcc=cc <...> -Dldflags=\"-lm -lrt\" ./Configure: eval: line 1677: unexpected EOF while looking for matching `"' ./Configure: eval: line 1678: syntax error: unexpected end of file Configure: unknown option -lrt" [1] 3b50d0462a4174bb155b258a32ab1ab4176ba2fc --- pkgs/development/interpreters/perl/default.nix | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pkgs/development/interpreters/perl/default.nix b/pkgs/development/interpreters/perl/default.nix index 3231c17e8d9b..751b9667a1f1 100644 --- a/pkgs/development/interpreters/perl/default.nix +++ b/pkgs/development/interpreters/perl/default.nix @@ -96,8 +96,7 @@ let "-Dprefix=${placeholder "out"}" "-Dman1dir=${placeholder "out"}/share/man/man1" "-Dman3dir=${placeholder "out"}/share/man/man3" - ] - ++ optional (stdenv.isAarch32 || stdenv.isMips) "-Dldflags=\"-lm -lrt\""; + ]; configureScript = optionalString (!crossCompiling) "${stdenv.shell} ./Configure"; -- cgit v1.2.3 From 70ebe5b46a79d0f5f215d8d7df919389539e5d38 Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Mon, 6 Jan 2020 05:46:18 -0800 Subject: glfw: 3.3 -> 3.3.1 --- pkgs/development/libraries/glfw/3.x.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/glfw/3.x.nix b/pkgs/development/libraries/glfw/3.x.nix index cf988d323994..16368ae21276 100644 --- a/pkgs/development/libraries/glfw/3.x.nix +++ b/pkgs/development/libraries/glfw/3.x.nix @@ -4,14 +4,14 @@ }: stdenv.mkDerivation rec { - version = "3.3"; + version = "3.3.1"; pname = "glfw"; src = fetchFromGitHub { owner = "glfw"; repo = "GLFW"; rev = version; - sha256 = "1f1hqpqffzg46z33ybs2c3akmkly7b3qmgp5byk50nvad6g2pm4p"; + sha256 = "0c7nlrhq84gdq10diyv6nshjbv8410bmn0vging815pfvis208xc"; }; enableParallelBuilding = true; -- cgit v1.2.3 From 940d12bf5daba9b0af846646b58b84a81107089c Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Mon, 6 Jan 2020 09:16:51 -0800 Subject: htslib: 1.9 -> 1.10.2 --- pkgs/development/libraries/science/biology/htslib/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/science/biology/htslib/default.nix b/pkgs/development/libraries/science/biology/htslib/default.nix index 7d771414fb01..cdd56731fa0e 100644 --- a/pkgs/development/libraries/science/biology/htslib/default.nix +++ b/pkgs/development/libraries/science/biology/htslib/default.nix @@ -2,11 +2,11 @@ stdenv.mkDerivation rec { pname = "htslib"; - version = "1.9"; + version = "1.10.2"; src = fetchurl { url = "https://github.com/samtools/htslib/releases/download/${version}/${pname}-${version}.tar.bz2"; - sha256 = "16ljv43sc3fxmv63w7b2ff8m1s7h89xhazwmbm1bicz8axq8fjz0"; + sha256 = "0f8rglbvf4aaw41i2sxlpq7pvhly93sjqiz0l4q3hwki5zg47dg3"; }; # perl is only used during the check phase. -- cgit v1.2.3 From 634d64071bb0165f5c201d41a9c49e8f2e96c476 Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Mon, 6 Jan 2020 12:10:04 -0800 Subject: libdeflate: 1.3 -> 1.5 --- pkgs/development/libraries/libdeflate/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/libdeflate/default.nix b/pkgs/development/libraries/libdeflate/default.nix index b06a0a9450ab..115ad3831f2f 100644 --- a/pkgs/development/libraries/libdeflate/default.nix +++ b/pkgs/development/libraries/libdeflate/default.nix @@ -2,13 +2,13 @@ stdenv.mkDerivation rec { pname = "libdeflate"; - version = "1.3"; + version = "1.5"; src = fetchFromGitHub { owner = "ebiggers"; repo = "libdeflate"; rev = "v${version}"; - sha256 = "019xsz5dnbpxiz29j3zqsxyi4ksjkkygi6a2zyc8fxbm8lvaa9ar"; + sha256 = "1v0y7998p8a8wpblnpdyk5zzvpj8pbrpzxwxmv0b0axrhaarxrf3"; }; postPatch = '' -- cgit v1.2.3 From aa69b8e65e090b98842c364bbcb3796f96f143bb Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Mon, 6 Jan 2020 13:14:43 -0800 Subject: leptonica: 1.78.0 -> 1.79.0 --- pkgs/development/libraries/leptonica/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/leptonica/default.nix b/pkgs/development/libraries/leptonica/default.nix index e26f4f6022aa..6d73b00a6d17 100644 --- a/pkgs/development/libraries/leptonica/default.nix +++ b/pkgs/development/libraries/leptonica/default.nix @@ -4,11 +4,11 @@ stdenv.mkDerivation rec { pname = "leptonica"; - version = "1.78.0"; + version = "1.79.0"; src = fetchurl { url = "http://www.leptonica.org/source/${pname}-${version}.tar.gz"; - sha256 = "122s9b8hi93va4lgwnwrbma50x5fp740npy0s92xybd2wy0jxvg2"; + sha256 = "1n004gv1dj3pq1fcnfdclvvx5nang80336aa67nvs3nnqp4ncn84"; }; nativeBuildInputs = [ autoreconfHook pkgconfig ]; -- cgit v1.2.3 From 79de730e77c94dcff3f030ce181a4182222e2717 Mon Sep 17 00:00:00 2001 From: worldofpeace Date: Wed, 8 Jan 2020 10:05:39 -0500 Subject: nixos/buildbot: fix eval Fixes https://github.com/NixOS/nixpkgs/issues/77309 --- nixos/modules/services/continuous-integration/buildbot/master.nix | 2 +- nixos/modules/services/continuous-integration/buildbot/worker.nix | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/nixos/modules/services/continuous-integration/buildbot/master.nix b/nixos/modules/services/continuous-integration/buildbot/master.nix index 326d2cbd82cc..e3da3092d459 100644 --- a/nixos/modules/services/continuous-integration/buildbot/master.nix +++ b/nixos/modules/services/continuous-integration/buildbot/master.nix @@ -222,7 +222,7 @@ in { }; config = mkIf cfg.enable { - users.groups = optional (cfg.group == "buildbot") { + users.groups = optionalAttrs (cfg.group == "buildbot") { buildbot = { }; }; diff --git a/nixos/modules/services/continuous-integration/buildbot/worker.nix b/nixos/modules/services/continuous-integration/buildbot/worker.nix index 7613692f0a34..52f24b8cee3c 100644 --- a/nixos/modules/services/continuous-integration/buildbot/worker.nix +++ b/nixos/modules/services/continuous-integration/buildbot/worker.nix @@ -136,7 +136,7 @@ in { config = mkIf cfg.enable { services.buildbot-worker.workerPassFile = mkDefault (pkgs.writeText "buildbot-worker-password" cfg.workerPass); - users.groups = optional (cfg.group == "bbworker") { + users.groups = optionalAttrs (cfg.group == "bbworker") { bbworker = { }; }; -- cgit v1.2.3 From 228a7b173e659a10c0f288f44e18e7ae050c78cb Mon Sep 17 00:00:00 2001 From: Silvan Mosberger Date: Wed, 8 Jan 2020 23:52:42 +0100 Subject: nixos/certmgr: Flip either submodule path type For upcoming allowance of paths as submodules --- nixos/modules/services/security/certmgr.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nixos/modules/services/security/certmgr.nix b/nixos/modules/services/security/certmgr.nix index e89078883ebe..94c0ba141179 100644 --- a/nixos/modules/services/security/certmgr.nix +++ b/nixos/modules/services/security/certmgr.nix @@ -113,7 +113,7 @@ in otherCert = "/var/certmgr/specs/other-cert.json"; } ''; - type = with types; attrsOf (either (submodule { + type = with types; attrsOf (either path (submodule { options = { service = mkOption { type = nullOr str; @@ -148,7 +148,7 @@ in description = "certmgr spec request object."; }; }; - }) path); + })); description = '' Certificate specs as described by: -- cgit v1.2.3 From 6525da6321a7272faa0c2b1c15ffd3501888e9b9 Mon Sep 17 00:00:00 2001 From: Silvan Mosberger Date: Fri, 3 Jan 2020 05:22:11 +0100 Subject: lib/types: Allow paths as submodule values --- lib/tests/modules.sh | 3 +-- lib/types.nix | 8 +++++--- nixos/doc/manual/development/option-types.xml | 6 +++--- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/lib/tests/modules.sh b/lib/tests/modules.sh index f69befd15c64..65b482ec194d 100755 --- a/lib/tests/modules.sh +++ b/lib/tests/modules.sh @@ -174,8 +174,7 @@ checkConfigOutput "true" config.submodule.inner ./declare-submoduleWith-modules. checkConfigOutput "true" config.submodule.outer ./declare-submoduleWith-modules.nix ## Paths should be allowed as values and work as expected -# Temporarily disabled until https://github.com/NixOS/nixpkgs/pull/76861 -#checkConfigOutput "true" config.submodule.enable ./declare-submoduleWith-path.nix +checkConfigOutput "true" config.submodule.enable ./declare-submoduleWith-path.nix cat < A set of sub options o. - o can be an attribute set or a function - returning an attribute set. Submodules are used in composed types to - create modular options. This is equivalent to + o can be an attribute set, a function + returning an attribute set, or a path to a file containing such a value. Submodules are used in + composed types to create modular options. This is equivalent to types.submoduleWith { modules = toList o; shorthandOnlyDefinesConfig = true; }. Submodules are detailed in Date: Thu, 9 Jan 2020 14:28:24 +0100 Subject: cni-plugins: v0.8.3 -> v0.8.4 Signed-off-by: Sascha Grunert --- pkgs/applications/networking/cluster/cni/plugins.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/networking/cluster/cni/plugins.nix b/pkgs/applications/networking/cluster/cni/plugins.nix index d0186fb9b4c0..39c3b9f65072 100644 --- a/pkgs/applications/networking/cluster/cni/plugins.nix +++ b/pkgs/applications/networking/cluster/cni/plugins.nix @@ -1,13 +1,13 @@ { stdenv, lib, fetchFromGitHub, go, removeReferencesTo, buildGoPackage }: buildGoPackage rec { pname = "cni-plugins"; - version = "0.8.3"; + version = "0.8.4"; src = fetchFromGitHub { owner = "containernetworking"; repo = "plugins"; rev = "v${version}"; - sha256 = "0dc4fs08x4x518yhgvq3drjvansnc0cb8rm4h5wiw7k3whjii3cd"; + sha256 = "02kz6y3klhbriybsskn4hmldwli28cycnp2klsm2x0y9c73iczdp"; }; goDeps = ./plugins-deps.nix; -- cgit v1.2.3 From 9d4b59b54949f0849ab9db9d30bc4cce7a205787 Mon Sep 17 00:00:00 2001 From: Silvan Mosberger Date: Wed, 8 Jan 2020 23:59:37 +0100 Subject: nixos/doc: Add incompatibility note for `either submodule path` Co-Authored-By: Robert Hensing --- nixos/doc/manual/release-notes/rl-2003.xml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/nixos/doc/manual/release-notes/rl-2003.xml b/nixos/doc/manual/release-notes/rl-2003.xml index ca319dfea411..51f91268eff0 100644 --- a/nixos/doc/manual/release-notes/rl-2003.xml +++ b/nixos/doc/manual/release-notes/rl-2003.xml @@ -391,6 +391,16 @@ users.users.me = PR #63103. + + + For NixOS modules, the types types.submodule and types.submoduleWith now support + paths as allowed values, similar to how imports supports paths. + Because of this, if you have a module that defines an option of type + either (submodule ...) path, it will break since a path + is now treated as the first type instead of the second. To fix this, change + the type to either path (submodule ...). + + -- cgit v1.2.3 From c9214c394b248e1f26e45dbe1be2bd82363af3a6 Mon Sep 17 00:00:00 2001 From: elseym Date: Fri, 10 Jan 2020 21:24:31 +0100 Subject: lib.commitIdFromGitRepo: support git-worktree lib.commitIdFromGitRepo now resolves the refs from the parent repository in case the supplied path is a file containing the path to said repository. this adds support for git-worktree and things alike. see gitrepository-layout(5). this also: - adds a new boolean function lib.pathIsRegularFile to check whether a path is a regular file - patches lib.revisionWithDefault and the revision and versionSuffix attributes in config.system.nixos in order to support git-worktrees --- lib/default.nix | 2 +- lib/sources.nix | 34 ++++++++++++++++++++++++++++------ lib/trivial.nix | 2 +- nixos/modules/misc/version.nix | 4 ++-- 4 files changed, 32 insertions(+), 10 deletions(-) diff --git a/lib/default.nix b/lib/default.nix index 9f7a088d792d..77dda17f3b4f 100644 --- a/lib/default.nix +++ b/lib/default.nix @@ -100,7 +100,7 @@ let inherit (sources) pathType pathIsDirectory cleanSourceFilter cleanSource sourceByRegex sourceFilesBySuffices commitIdFromGitRepo cleanSourceWith pathHasContext - canCleanSource; + canCleanSource pathIsRegularFile; inherit (modules) evalModules unifyModuleSyntax applyIfFunction mergeModules mergeModules' mergeOptionDecls evalOptionValue mergeDefinitions diff --git a/lib/sources.nix b/lib/sources.nix index 51bcf5559e32..0fd172c42b77 100644 --- a/lib/sources.nix +++ b/lib/sources.nix @@ -9,6 +9,9 @@ rec { # Returns true if the path exists and is a directory, false otherwise pathIsDirectory = p: if builtins.pathExists p then (pathType p) == "directory" else false; + # Returns true if the path exists and is a regular file, false otherwise + pathIsRegularFile = p: if builtins.pathExists p then (pathType p) == "regular" else false; + # Bring in a path as a source, filtering out all Subversion and CVS # directories, as well as backup files (*~). cleanSourceFilter = name: type: let baseName = baseNameOf (toString name); in ! ( @@ -110,24 +113,43 @@ rec { with builtins; let fileName = toString path + "/" + file; packedRefsName = toString path + "/packed-refs"; - in if lib.pathExists fileName + in if pathIsRegularFile path + # Resolve git worktrees. See gitrepository-layout(5) + then + let m = match "^gitdir: (.*)$" (lib.fileContents path); + in if m == null + then throw ("File contains no gitdir reference: " + path) + else + let gitDir = lib.head m; + commonDir' = if pathIsRegularFile "${gitDir}/commondir" + then lib.fileContents "${gitDir}/commondir" + else gitDir; + commonDir = if lib.hasPrefix "/" commonDir' + then commonDir' + else toString (/. + "${gitDir}/${commonDir'}"); + refFile = lib.removePrefix "${commonDir}/" "${gitDir}/${file}"; + in readCommitFromFile refFile commonDir + + else if pathIsRegularFile fileName + # Sometimes git stores the commitId directly in the file but + # sometimes it stores something like: «ref: refs/heads/branch-name» then let fileContent = lib.fileContents fileName; - # Sometimes git stores the commitId directly in the file but - # sometimes it stores something like: «ref: refs/heads/branch-name» matchRef = match "^ref: (.*)$" fileContent; - in if matchRef == null + in if matchRef == null then fileContent else readCommitFromFile (lib.head matchRef) path + + else if pathIsRegularFile packedRefsName # Sometimes, the file isn't there at all and has been packed away in the # packed-refs file, so we have to grep through it: - else if lib.pathExists packedRefsName then let fileContent = readFile packedRefsName; matchRef = match (".*\n([^\n ]*) " + file + "\n.*") fileContent; - in if matchRef == null + in if matchRef == null then throw ("Could not find " + file + " in " + packedRefsName) else lib.head matchRef + else throw ("Not a .git directory: " + path); in readCommitFromFile "HEAD"; diff --git a/lib/trivial.nix b/lib/trivial.nix index 3a25e31fb052..940ec1a3d59e 100644 --- a/lib/trivial.nix +++ b/lib/trivial.nix @@ -191,7 +191,7 @@ rec { let revisionFile = "${toString ./..}/.git-revision"; gitRepo = "${toString ./..}/.git"; - in if lib.pathIsDirectory gitRepo + in if builtins.pathExists gitRepo then lib.commitIdFromGitRepo gitRepo else if lib.pathExists revisionFile then lib.fileContents revisionFile else default; diff --git a/nixos/modules/misc/version.nix b/nixos/modules/misc/version.nix index b85614771ee4..ddbd3963cc57 100644 --- a/nixos/modules/misc/version.nix +++ b/nixos/modules/misc/version.nix @@ -91,8 +91,8 @@ in # These defaults are set here rather than up there so that # changing them would not rebuild the manual version = mkDefault (cfg.release + cfg.versionSuffix); - revision = mkIf (pathIsDirectory gitRepo) (mkDefault gitCommitId); - versionSuffix = mkIf (pathIsDirectory gitRepo) (mkDefault (".git." + gitCommitId)); + revision = mkIf (pathExists gitRepo) (mkDefault gitCommitId); + versionSuffix = mkIf (pathExists gitRepo) (mkDefault (".git." + gitCommitId)); }; # Generate /etc/os-release. See -- cgit v1.2.3 From e85b34c484d2c38cad3eaffbb97e211fecf852bf Mon Sep 17 00:00:00 2001 From: Jan Tojnar Date: Sat, 11 Jan 2020 08:09:56 +0100 Subject: tree-wide: fix more warning related to loaOf deprecation --- nixos/modules/services/mail/postfix.nix | 5 +---- nixos/modules/services/mail/spamassassin.nix | 2 +- pkgs/os-specific/linux/rfkill/udev.nix | 22 +++++++++++----------- 3 files changed, 13 insertions(+), 16 deletions(-) diff --git a/nixos/modules/services/mail/postfix.nix b/nixos/modules/services/mail/postfix.nix index d7378821440d..19e11b31d9ca 100644 --- a/nixos/modules/services/mail/postfix.nix +++ b/nixos/modules/services/mail/postfix.nix @@ -612,10 +612,7 @@ in { environment = { - etc = singleton - { source = "/var/lib/postfix/conf"; - target = "postfix"; - }; + etc.postfix.source = "/var/lib/postfix/conf"; # This makes it comfortable to run 'postqueue/postdrop' for example. systemPackages = [ pkgs.postfix ]; diff --git a/nixos/modules/services/mail/spamassassin.nix b/nixos/modules/services/mail/spamassassin.nix index 07b3bf0420aa..75442c7cdb5e 100644 --- a/nixos/modules/services/mail/spamassassin.nix +++ b/nixos/modules/services/mail/spamassassin.nix @@ -124,7 +124,7 @@ in # Allow users to run 'spamc'. environment = { - etc = singleton { source = spamdEnv; target = "spamassassin"; }; + etc.spamassassin.source = spamdEnv; systemPackages = [ pkgs.spamassassin ]; }; diff --git a/pkgs/os-specific/linux/rfkill/udev.nix b/pkgs/os-specific/linux/rfkill/udev.nix index 41dd3da9d31f..0575c46e28e3 100644 --- a/pkgs/os-specific/linux/rfkill/udev.nix +++ b/pkgs/os-specific/linux/rfkill/udev.nix @@ -8,18 +8,18 @@ # udev.packages = [ pkgs.rfkill_udev ]; # # Add a hook script in the managed etc directory, e.g.: -# etc = [ -# { source = pkgs.writeScript "rtfkill.hook" '' -# #!${pkgs.runtimeShell} +# etc."rfkill.hook" = { +# mode = "0755"; +# text = '' +# #!${pkgs.runtimeShell} # -# if [ "$RFKILL_STATE" -eq "1" ]; then -# exec ${config.system.build.upstart}/sbin/initctl emit -n antenna-on -# else -# exec ${config.system.build.upstart}/sbin/initctl emit -n antenna-off -# fi -# ''; -# target = "rfkill.hook"; -# } +# if [ "$RFKILL_STATE" -eq "1" ]; then +# exec ${config.system.build.upstart}/sbin/initctl emit -n antenna-on +# else +# exec ${config.system.build.upstart}/sbin/initctl emit -n antenna-off +# fi +# ''; +# } # Note: this package does not need the binaries # in the rfkill package. -- cgit v1.2.3 From b0c2c96cbe12c5a3a280ffd2634ebe0c8507e8b0 Mon Sep 17 00:00:00 2001 From: Jan Tojnar Date: Sat, 11 Jan 2020 08:54:42 +0100 Subject: lib/types: improve loaOf warning Not all modules use name attribute as the name of the submodule, for example, environment.etc uses target. We will need to maintain a list of exceptions. --- lib/types.nix | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/lib/types.nix b/lib/types.nix index e86f6d364761..cbbea00058d0 100644 --- a/lib/types.nix +++ b/lib/types.nix @@ -340,18 +340,22 @@ rec { let padWidth = stringLength (toString (length def.value)); unnamed = i: unnamedPrefix + fixedWidthNumber padWidth i; + nameAttrs = { + "environment.etc" = "target"; + }; + nameAttr = nameAttrs.${option} or "name"; res = { inherit (def) file; value = listToAttrs ( imap1 (elemIdx: elem: - { name = elem.name or (unnamed elemIdx); + { name = elem.${nameAttr} or (unnamed elemIdx); value = elem; }) def.value); }; option = concatStringsSep "." loc; sample = take 3 def.value; - list = concatMapStrings (x: ''{ name = "${x.name or "unnamed"}"; ...} '') sample; - set = concatMapStrings (x: ''${x.name or "unnamed"} = {...}; '') sample; + list = concatMapStrings (x: ''{ ${nameAttr} = "${x.${nameAttr} or "unnamed"}"; ...} '') sample; + set = concatMapStrings (x: ''${x.${nameAttr} or "unnamed"} = {...}; '') sample; msg = '' In file ${def.file} a list is being assigned to the option config.${option}. -- cgit v1.2.3 From 2170b1eac54259b4e641ca49b6448cb3edf8892f Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Sat, 11 Jan 2020 04:20:00 -0500 Subject: libdeflate: enable on darwin --- pkgs/development/libraries/libdeflate/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/libraries/libdeflate/default.nix b/pkgs/development/libraries/libdeflate/default.nix index 115ad3831f2f..cc06815bbffc 100644 --- a/pkgs/development/libraries/libdeflate/default.nix +++ b/pkgs/development/libraries/libdeflate/default.nix @@ -25,7 +25,7 @@ stdenv.mkDerivation rec { description = "Fast DEFLATE/zlib/gzip compressor and decompressor"; license = licenses.mit; homepage = https://github.com/ebiggers/libdeflate; - platforms = platforms.linux; + platforms = platforms.unix; maintainers = with maintainers; [ orivej ]; }; } -- cgit v1.2.3 From 6fc46fbb177e22d467c9d92d0fac8581afa81246 Mon Sep 17 00:00:00 2001 From: Jan Tojnar Date: Sat, 11 Jan 2020 13:32:30 +0100 Subject: lib/types: only show ... in loaOf warning when necessary --- lib/types.nix | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/types.nix b/lib/types.nix index cbbea00058d0..6eebc20829c6 100644 --- a/lib/types.nix +++ b/lib/types.nix @@ -354,6 +354,7 @@ rec { }; option = concatStringsSep "." loc; sample = take 3 def.value; + more = lib.optionalString (length def.value > 3) "... "; list = concatMapStrings (x: ''{ ${nameAttr} = "${x.${nameAttr} or "unnamed"}"; ...} '') sample; set = concatMapStrings (x: ''${x.${nameAttr} or "unnamed"} = {...}; '') sample; msg = '' @@ -363,10 +364,10 @@ rec { See https://git.io/fj2zm for more information. Do ${option} = - { ${set}...} + { ${set}${more}} instead of ${option} = - [ ${list}...] + [ ${list}${more}] ''; in lib.warn msg res -- cgit v1.2.3 From 13633bd21ac92dce92f920fd68578f5e430c6c0d Mon Sep 17 00:00:00 2001 From: Jan Tojnar Date: Sat, 11 Jan 2020 15:02:57 +0100 Subject: lib/types: improve loaOf message even more Now we suggest correct names for all options in Nixpkgs and also home-manager at the time of writing. --- lib/types.nix | 71 +++++++++++++++++++++++++++++++++++++++++++++++++++++------ 1 file changed, 64 insertions(+), 7 deletions(-) diff --git a/lib/types.nix b/lib/types.nix index 6eebc20829c6..a090af78acda 100644 --- a/lib/types.nix +++ b/lib/types.nix @@ -340,23 +340,80 @@ rec { let padWidth = stringLength (toString (length def.value)); unnamed = i: unnamedPrefix + fixedWidthNumber padWidth i; - nameAttrs = { - "environment.etc" = "target"; - }; - nameAttr = nameAttrs.${option} or "name"; + anyString = placeholder "name"; + nameAttrs = [ + { path = [ "environment" "etc" ]; + name = "target"; + } + { path = [ "containers" anyString "bindMounts" ]; + name = "mountPoint"; + } + { path = [ "programs" "ssh" "knownHosts" ]; + # hostNames is actually a list so we would need to handle it only when singleton + name = "hostNames"; + } + { path = [ "fileSystems" ]; + name = "mountPoint"; + } + { path = [ "boot" "specialFileSystems" ]; + name = "mountPoint"; + } + { path = [ "services" "znapzend" "zetup" ]; + name = "dataset"; + } + { path = [ "services" "znapzend" "zetup" anyString "destinations" ]; + name = "label"; + } + { path = [ "services" "geoclue2" "appConfig" ]; + name = "desktopID"; + } + { path = [ "home-manager" "users" anyString "programs" "ssh" "matchBlocks" ]; + name = "host"; # https://github.com/rycee/home-manager/blob/e8dbc3561373b68d12decb3c0d7c1ba245f138f7/modules/programs/ssh.nix#L265 + } + { path = [ "home-manager" "users" anyString "home" "file" ]; + name = "target"; # https://github.com/rycee/home-manager/blob/0e9b7aab3c6c27bf020402e0e2ef20b65c040552/modules/files.nix#L33 + } + { path = [ "home-manager" "users" anyString "xdg" "configFile" ]; + name = "target"; # https://github.com/rycee/home-manager/blob/54de0e1d79a1370e57a8f23bef89f99f9b92ab67/modules/misc/xdg.nix#L41 + } + { path = [ "home-manager" "users" anyString "xdg" "dataFile" ]; + name = "target"; # https://github.com/rycee/home-manager/blob/54de0e1d79a1370e57a8f23bef89f99f9b92ab67/modules/misc/xdg.nix#L58 + } + ]; + matched = let + equals = a: b: b == anyString || a == b; + fallback = { name = "name"; }; + in findFirst ({ path, ... }: all (v: v == true) (zipListsWith equals loc path)) fallback nameAttrs; + nameAttr = matched.name; + nameValueOld = value: + if isList value then + if length value > 0 then + "[ " + concatMapStringsSep " " escapeNixString value + " ]" + else + "[ ]" + else + escapeNixString value; + nameValueNew = value: unnamed: + if isList value then + if length value > 0 then + head value + else + unnamed + else + value; res = { inherit (def) file; value = listToAttrs ( imap1 (elemIdx: elem: - { name = elem.${nameAttr} or (unnamed elemIdx); + { name = nameValueNew (elem.${nameAttr} or (unnamed elemIdx)) (unnamed elemIdx); value = elem; }) def.value); }; option = concatStringsSep "." loc; sample = take 3 def.value; more = lib.optionalString (length def.value > 3) "... "; - list = concatMapStrings (x: ''{ ${nameAttr} = "${x.${nameAttr} or "unnamed"}"; ...} '') sample; - set = concatMapStrings (x: ''${x.${nameAttr} or "unnamed"} = {...}; '') sample; + list = concatMapStrings (x: ''{ ${nameAttr} = ${nameValueOld (x.${nameAttr} or "unnamed")}; ...} '') sample; + set = concatMapStrings (x: ''${nameValueNew (x.${nameAttr} or "unnamed") "unnamed"} = {...}; '') sample; msg = '' In file ${def.file} a list is being assigned to the option config.${option}. -- cgit v1.2.3 From 865fc6c97b243c26fdcf9ab5d0dd140adc4054c2 Mon Sep 17 00:00:00 2001 From: Pavol Rusnak Date: Sun, 1 Dec 2019 12:57:05 +0100 Subject: fido2luks: init at 0.2.2 --- pkgs/tools/security/fido2luks/default.nix | 32 +++++++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 34 insertions(+) create mode 100644 pkgs/tools/security/fido2luks/default.nix diff --git a/pkgs/tools/security/fido2luks/default.nix b/pkgs/tools/security/fido2luks/default.nix new file mode 100644 index 000000000000..0bb5a91a81a7 --- /dev/null +++ b/pkgs/tools/security/fido2luks/default.nix @@ -0,0 +1,32 @@ +{ stdenv +, rustPlatform +, fetchFromGitHub +, cryptsetup +, pkg-config +}: + +rustPlatform.buildRustPackage rec { + pname = "fido2luks"; + version = "0.2.2"; + + src = fetchFromGitHub { + owner = "shimunn"; + repo = pname; + rev = version; + sha256 = "018qzbgmgm0f0d0c7i54nqqjbr4k5mzy1xfavi6hpifjll971wci"; + }; + + buildInputs = [ cryptsetup ]; + nativeBuildInputs = [ pkg-config ]; + + cargoSha256 = "1kf757wxxk5h8dfbz588qw1pnyjbg5qzr7rz14i7x8rhmn5xwb74"; + verifyCargoDeps = true; + + meta = with stdenv.lib; { + description = "Decrypt your LUKS partition using a FIDO2 compatible authenticator"; + homepage = "https://github.com/shimunn/fido2luks"; + license = licenses.gpl3; + maintainers = with maintainers; [ prusnak mmahut ]; + platforms = platforms.linux; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index c15a4198f625..90f301d7ac3a 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -3238,6 +3238,8 @@ in flux = callPackage ../development/compilers/flux { }; + fido2luks = callPackage ../tools/security/fido2luks {}; + fierce = callPackage ../tools/security/fierce { }; figlet = callPackage ../tools/misc/figlet { }; -- cgit v1.2.3 From 0778f0aee6d703b68a2b1ea0ffe1c4c81b6f4a1c Mon Sep 17 00:00:00 2001 From: snicket2100 <57048005+snicket2100@users.noreply.github.com> Date: Sat, 11 Jan 2020 20:49:48 +0100 Subject: firejail: local profile handling fixed The sed expression wasn't really catching anything (as local profiles are included in the provided set of profiles by `include aaa.local` and not by `include xx/firejail/aaa.local` as the sed expression used to expect). As a result, it was not possible to create local profiles in any accessible location. This fix makes it possible to create them in `/etc/firejail/` which seems pretty standard. --- pkgs/os-specific/linux/firejail/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/os-specific/linux/firejail/default.nix b/pkgs/os-specific/linux/firejail/default.nix index 28528f48efb3..8200acf62b7d 100644 --- a/pkgs/os-specific/linux/firejail/default.nix +++ b/pkgs/os-specific/linux/firejail/default.nix @@ -36,10 +36,10 @@ stdenv.mkDerivation { sed -e "s@/etc/@$out/etc/@g" -e "/chmod u+s/d" -i Makefile ''; - # We need to set the directory for the .local override files back to + # We need to set the directory for the .local override files to # /etc/firejail so we can actually override them postInstall = '' - sed -E -e 's@^include (.*)(/firejail/.*.local)$@include /etc\2@g' -i $out/etc/firejail/*.profile + sed -E -e 's@^include (.*.local)$@include /etc/firejail/\1@g' -i $out/etc/firejail/*.profile ''; # At high parallelism, the build sometimes fails with: -- cgit v1.2.3 From 9cb67b4028a2db925cadd75fdc2f58f7ed9362b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nguy=E1=BB=85n=20Gia=20Phong?= Date: Sun, 12 Jan 2020 10:49:18 +0700 Subject: Add McSinyx to the list of maintainers --- maintainers/maintainer-list.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix index 6751d00f451a..796fa932867e 100644 --- a/maintainers/maintainer-list.nix +++ b/maintainers/maintainer-list.nix @@ -4307,6 +4307,12 @@ githubId = 158568; name = "Matthias C. M. Troffaes"; }; + McSinyx = { + email = "vn.mcsinyx@gmail.com"; + github = "McSinyx"; + githubId = 13689192; + name = "Nguyễn Gia Phong"; + }; mdaiter = { email = "mdaiter8121@gmail.com"; github = "mdaiter"; -- cgit v1.2.3 From 86c0e79add90cf54280a9f7f08e8c857f8d4882d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nguy=E1=BB=85n=20Gia=20Phong?= Date: Sun, 29 Dec 2019 17:39:52 +0700 Subject: alure2: init at unstable-2020-01-09 --- pkgs/development/libraries/alure2/default.nix | 24 ++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 26 insertions(+) create mode 100644 pkgs/development/libraries/alure2/default.nix diff --git a/pkgs/development/libraries/alure2/default.nix b/pkgs/development/libraries/alure2/default.nix new file mode 100644 index 000000000000..91919873fa63 --- /dev/null +++ b/pkgs/development/libraries/alure2/default.nix @@ -0,0 +1,24 @@ +{ stdenv, fetchFromGitHub, cmake, openal, libvorbis, opusfile, libsndfile }: + +stdenv.mkDerivation rec { + pname = "alure2"; + version = "unstable-2020-01-09"; + + src = fetchFromGitHub { + owner = "kcat"; + repo = "alure"; + rev = "4b7b58d3f0de444d6f26aa705704deb59145f586"; + sha256 = "0ds18hhy2wpvx498z5hcpzfqz9i60ixsi0cjihyvk20rf4qy12vg"; + }; + + nativeBuildInputs = [ cmake ]; + buildInputs = [ openal libvorbis opusfile libsndfile ]; + + meta = with stdenv.lib; { + description = "A utility library for OpenAL, providing a C++ API and managing common tasks that include file loading, caching, and streaming"; + homepage = "https://github.com/kcat/alure"; + license = licenses.zlib; + platforms = platforms.linux; + maintainers = with maintainers; [ McSinyx ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 87169b5296ce..b8611006fca8 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -10616,6 +10616,8 @@ in alure = callPackage ../development/libraries/alure { }; + alure2 = callPackage ../development/libraries/alure2 { }; + agg = callPackage ../development/libraries/agg { }; allegro = allegro4; -- cgit v1.2.3 From 09f0bc828eb4acc10374496ed9a0a34eb88da61d Mon Sep 17 00:00:00 2001 From: jD91mZM2 Date: Sun, 12 Jan 2020 10:41:20 +0000 Subject: rnix-lsp: init at 0.1.0 (#77549) --- pkgs/development/tools/rnix-lsp/default.nix | 22 ++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 24 insertions(+) create mode 100644 pkgs/development/tools/rnix-lsp/default.nix diff --git a/pkgs/development/tools/rnix-lsp/default.nix b/pkgs/development/tools/rnix-lsp/default.nix new file mode 100644 index 000000000000..37a1955ce8b2 --- /dev/null +++ b/pkgs/development/tools/rnix-lsp/default.nix @@ -0,0 +1,22 @@ +{ callPackage, lib, fetchFromGitHub, rustPlatform }: + +rustPlatform.buildRustPackage rec { + pname = "rnix-lsp"; + version = "0.1.0"; + + src = fetchFromGitHub { + owner = "nix-community"; + repo = "rnix-lsp"; + rev = "v${version}"; + + sha256 = "0fy620c34kxl27sd62x9mj0555bcdmnmbsxavmyiwb497z1m9wnn"; + }; + + cargoSha256 = "1wm5m7b6zr6wg1k59rmqis1zp9i2990p7y0ml852hxv34an7pp5d"; + + meta = with lib; { + description = "A work-in-progress language server for Nix, with syntax checking and basic completion"; + license = licenses.mit; + maintainers = with maintainers; [ jD91mZM2 ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index ef9ebc140504..cb964570e350 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -10485,6 +10485,8 @@ in rman = callPackage ../development/tools/misc/rman { }; + rnix-lsp = callPackage ../development/tools/rnix-lsp { }; + rolespec = callPackage ../development/tools/misc/rolespec { }; rr = callPackage ../development/tools/analysis/rr { }; -- cgit v1.2.3 From a9d3d63eaae778aa8b32c609b09e3f7bf9a9a7df Mon Sep 17 00:00:00 2001 From: zowoq <59103226+zowoq@users.noreply.github.com> Date: Sun, 12 Jan 2020 21:35:36 +1000 Subject: gnome3.seahorse: 3.34 -> 3.34.1 (#77543) https://gitlab.gnome.org/GNOME/seahorse/blob/3.34.1/NEWS --- pkgs/desktops/gnome-3/apps/seahorse/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/desktops/gnome-3/apps/seahorse/default.nix b/pkgs/desktops/gnome-3/apps/seahorse/default.nix index c6d5b22f9348..315968fde651 100644 --- a/pkgs/desktops/gnome-3/apps/seahorse/default.nix +++ b/pkgs/desktops/gnome-3/apps/seahorse/default.nix @@ -26,11 +26,11 @@ stdenv.mkDerivation rec { pname = "seahorse"; - version = "3.34"; + version = "3.34.1"; src = fetchurl { url = "mirror://gnome/sources/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.xz"; - sha256 = "16sfnqrdlr5xx6kixx2ln1mva7nngjlw1k3f5n454vyaigffjh2v"; + sha256 = "19c2zylwgycb5q9hal8rmflc2sywc5c2grpsfsq3rf37i9lfwynw"; }; doCheck = true; -- cgit v1.2.3 From a171244455da222c1188011897c46175ac14628c Mon Sep 17 00:00:00 2001 From: Jos van Bakel Date: Sun, 12 Jan 2020 12:51:01 +0100 Subject: nixos/gitea: fix typo --- nixos/modules/services/misc/gitea.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nixos/modules/services/misc/gitea.nix b/nixos/modules/services/misc/gitea.nix index 258476dd9feb..38910a5a005d 100644 --- a/nixos/modules/services/misc/gitea.nix +++ b/nixos/modules/services/misc/gitea.nix @@ -364,7 +364,7 @@ in ''} sed -e "s,#secretkey#,$KEY,g" \ -e "s,#dbpass#,$DBPASS,g" \ - -e "s,#jwtsecet#,$JWTSECET,g" \ + -e "s,#jwtsecret#,$JWTSECRET,g" \ -e "s,#mailerpass#,$MAILERPASSWORD,g" \ -i ${runConfig} chmod 640 ${runConfig} ${secretKey} ${jwtSecret} -- cgit v1.2.3 From 502c16e591fbd70a1398704f422e68a51d6dc0ab Mon Sep 17 00:00:00 2001 From: Matthieu Coudron Date: Thu, 9 Jan 2020 14:09:12 +0100 Subject: ultrastardx: 2017.8.0 -> 2019-01-07 follow up of the fix provided in https://github.com/UltraStar-Deluxe/USDX/issues/462 to use pkg-config to find lua. --- pkgs/games/ultrastardx/default.nix | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/pkgs/games/ultrastardx/default.nix b/pkgs/games/ultrastardx/default.nix index 1c40d8f5800f..feaf6cabf32a 100644 --- a/pkgs/games/ultrastardx/default.nix +++ b/pkgs/games/ultrastardx/default.nix @@ -12,21 +12,19 @@ let in stdenv.mkDerivation rec { pname = "ultrastardx"; - version = "2017.8.0"; + version = "unstable-2019-01-07"; src = fetchFromGitHub { owner = "UltraStar-Deluxe"; repo = "USDX"; - rev = "v${version}"; - sha256 = "1zp0xfwzci3cjmwx3cprcxvm60cik5cvhvrz9n4d6yb8dv38nqzm"; + rev = "3df142590f29db1505cc58746af9f8cf7cb4a6a5"; + sha256 = "EpwGKK9B8seF7gRwo3kCeSzFQQW1p8rP4HXeu8/LoyA="; }; nativeBuildInputs = [ pkgconfig autoreconfHook ]; buildInputs = [ fpc libpng ] ++ sharedLibs; - # https://github.com/UltraStar-Deluxe/USDX/issues/462 postPatch = '' substituteInPlace src/config.inc.in \ - --subst-var-by lua_LIB_NAME liblua.so \ --subst-var-by libpcre_LIBNAME libpcre.so.1 ''; -- cgit v1.2.3 From bbd6d219e4be16f9746ba587c4c0a37ee354c57b Mon Sep 17 00:00:00 2001 From: Linus Heckemann Date: Sun, 12 Jan 2020 13:28:50 +0100 Subject: nixos/wpa_supplicant: fix #61391 --- nixos/modules/services/networking/wpa_supplicant.nix | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/nixos/modules/services/networking/wpa_supplicant.nix b/nixos/modules/services/networking/wpa_supplicant.nix index 8f05c3949fba..de0f11595a94 100644 --- a/nixos/modules/services/networking/wpa_supplicant.nix +++ b/nixos/modules/services/networking/wpa_supplicant.nix @@ -233,6 +233,7 @@ in { path = [ pkgs.wpa_supplicant ]; script = '' + iface_args="-s -u -D${cfg.driver} -c ${configFile}" ${if ifaces == [] then '' for i in $(cd /sys/class/net && echo *); do DEVTYPE= @@ -240,14 +241,14 @@ in { if [ -e "$UEVENT_PATH" ]; then source "$UEVENT_PATH" if [ "$DEVTYPE" = "wlan" -o -e /sys/class/net/$i/wireless ]; then - ifaces="$ifaces''${ifaces:+ -N} -i$i" + args+="''${args:+ -N} -i$i $iface_args" fi fi done '' else '' - ifaces="${concatStringsSep " -N " (map (i: "-i${i}") ifaces)}" + args="${concatMapStringsSep " -N " (i: "-i${i} $iface_args") ifaces}" ''} - exec wpa_supplicant -s -u -D${cfg.driver} -c ${configFile} $ifaces + exec wpa_supplicant $args ''; }; -- cgit v1.2.3 From b108fd5843a2590ae0dc3c9d9945ac43594934d5 Mon Sep 17 00:00:00 2001 From: Robert Helgesson Date: Sun, 12 Jan 2020 15:11:17 +0100 Subject: jwt-cli: fix build on Darwin --- pkgs/tools/security/jwt-cli/default.nix | 4 +++- pkgs/top-level/all-packages.nix | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/pkgs/tools/security/jwt-cli/default.nix b/pkgs/tools/security/jwt-cli/default.nix index 7146cc52e9e1..83b630a4f4f6 100644 --- a/pkgs/tools/security/jwt-cli/default.nix +++ b/pkgs/tools/security/jwt-cli/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, rustPlatform }: +{ stdenv, fetchFromGitHub, rustPlatform, Security }: rustPlatform.buildRustPackage rec { pname = "jwt-cli"; @@ -13,6 +13,8 @@ rustPlatform.buildRustPackage rec { cargoSha256 = "005y92acsn5j490jkp23ny7bsjd9ql1glybmbh4cyc8b15hmy618"; + buildInputs = stdenv.lib.optional stdenv.isDarwin Security; + meta = with stdenv.lib; { description = "Super fast CLI tool to decode and encode JWTs"; homepage = "https://github.com/mike-engel/jwt-cli"; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index cb964570e350..2609e3232529 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -1862,7 +1862,9 @@ in jotta-cli = callPackage ../applications/misc/jotta-cli { }; - jwt-cli = callPackage ../tools/security/jwt-cli { }; + jwt-cli = callPackage ../tools/security/jwt-cli { + inherit (darwin.apple_sdk.frameworks) Security; + }; kapacitor = callPackage ../servers/monitoring/kapacitor { }; -- cgit v1.2.3 From 382b0aa52dfd843779bdae73a86438807ea1a2dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Sun, 12 Jan 2020 13:40:08 +0000 Subject: nixos/openldap: check configuration with slaptest slapd does only print the error and not the line number. Sometimes it is not even clear that it fails to start due to an incorrect configuration file. Example output of slaptest: 5e1b2179 /nix/store/gbn2v319d4qgw851sg41mcmjm5dpn39i-slapd.conf: line 134 objectClass: Missing closing parenthesis before end of input ObjectClassDescription = "(" whsp numericoid whsp ; ObjectClass identifier [ "NAME" qdescrs ] [ "DESC" qdstring ] [ "OBSOLETE" whsp ] [ "SUP" oids ] ; Superior ObjectClasses [ ( "ABSTRACT" / "STRUCTURAL" / "AUXILIARY" ) whsp ] ; default structural [ "MUST" oids ] ; AttributeTypes [ "MAY" oids ] ; AttributeTypes whsp ")" slaptest: bad configuration file! --- nixos/modules/services/databases/openldap.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/nixos/modules/services/databases/openldap.nix b/nixos/modules/services/databases/openldap.nix index 5bf57a1bf9cb..809f61cfa818 100644 --- a/nixos/modules/services/databases/openldap.nix +++ b/nixos/modules/services/databases/openldap.nix @@ -259,6 +259,8 @@ in ${openldap.out}/bin/slapadd ${configOpts} -l ${dataFile} ''} chown -R "${cfg.user}:${cfg.group}" "${cfg.dataDir}" + + ${openldap}/bin/slaptest ${configOpts} ''; serviceConfig.ExecStart = "${openldap.out}/libexec/slapd -d '${cfg.logLevel}' " + -- cgit v1.2.3 From eea18b8b796b62c2f3279106faa5a12fffaea08e Mon Sep 17 00:00:00 2001 From: Patrick Hilhorst Date: Sun, 12 Jan 2020 15:51:02 +0100 Subject: mako: 1.4 -> 1.4.1 --- pkgs/applications/misc/mako/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/misc/mako/default.nix b/pkgs/applications/misc/mako/default.nix index ffb938f30a57..eb7487c6eb36 100644 --- a/pkgs/applications/misc/mako/default.nix +++ b/pkgs/applications/misc/mako/default.nix @@ -4,13 +4,13 @@ stdenv.mkDerivation rec { pname = "mako"; - version = "1.4"; + version = "1.4.1"; src = fetchFromGitHub { owner = "emersion"; repo = pname; rev = "v${version}"; - sha256 = "11ymiq6cr2ma0iva1mqybn3j6k73bsc6lv6pcbdq7hkhd4f9b7j9"; + sha256 = "0hwvibpnrximb628w9dsfjpi30b5jy7nfkm4d94z5vhp78p43vxh"; }; nativeBuildInputs = [ meson ninja pkgconfig scdoc wayland-protocols ]; -- cgit v1.2.3 From 5ad5cd92c51c5188a189e9b7a44fa7df11ecdcce Mon Sep 17 00:00:00 2001 From: Patrick Hilhorst Date: Sun, 12 Jan 2020 15:51:24 +0100 Subject: mako: add Synthetica as maintainer --- pkgs/applications/misc/mako/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/applications/misc/mako/default.nix b/pkgs/applications/misc/mako/default.nix index eb7487c6eb36..f86effe989fa 100644 --- a/pkgs/applications/misc/mako/default.nix +++ b/pkgs/applications/misc/mako/default.nix @@ -22,7 +22,7 @@ stdenv.mkDerivation rec { description = "A lightweight Wayland notification daemon"; homepage = https://wayland.emersion.fr/mako/; license = licenses.mit; - maintainers = with maintainers; [ dywedir ]; + maintainers = with maintainers; [ dywedir synthetica ]; platforms = platforms.linux; }; } -- cgit v1.2.3 From d6ad9ce105f453ead89d65370a1bb4a3ff3180dd Mon Sep 17 00:00:00 2001 From: Silvan Mosberger Date: Sun, 12 Jan 2020 16:53:27 +0100 Subject: nixos/usbmuxd: Fix users.groups assignment A mistake was introduced in https://github.com/NixOS/nixpkgs/pull/63103 --- nixos/modules/services/hardware/usbmuxd.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nixos/modules/services/hardware/usbmuxd.nix b/nixos/modules/services/hardware/usbmuxd.nix index 50b931dcb487..11a4b0a858f9 100644 --- a/nixos/modules/services/hardware/usbmuxd.nix +++ b/nixos/modules/services/hardware/usbmuxd.nix @@ -51,7 +51,7 @@ in }; }; - users.groups = optional (cfg.group == defaultUserGroup) { + users.groups = optionalAttrs (cfg.group == defaultUserGroup) { ${cfg.group} = { }; }; -- cgit v1.2.3 From 3a22c758094fe415c3b8a3e79a88f16dc67799d5 Mon Sep 17 00:00:00 2001 From: Benjamin Hipple Date: Sun, 12 Jan 2020 11:44:22 -0500 Subject: cpp-netlib: remove insecure openssl dependency and unnecessary asio Upstream openssl has dropped support for 1.0.2; see #77503 for details. This also cleans up the old `asio` dependency, which now comes from `boost`, and documents why the test driver fails. --- pkgs/development/libraries/cpp-netlib/default.nix | 16 ++++++++++------ pkgs/top-level/all-packages.nix | 5 ++--- 2 files changed, 12 insertions(+), 9 deletions(-) diff --git a/pkgs/development/libraries/cpp-netlib/default.nix b/pkgs/development/libraries/cpp-netlib/default.nix index a4729cdeaed8..31c4c70dd9d0 100644 --- a/pkgs/development/libraries/cpp-netlib/default.nix +++ b/pkgs/development/libraries/cpp-netlib/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, cmake, boost, openssl, asio }: +{ stdenv, fetchFromGitHub, cmake, boost, openssl }: stdenv.mkDerivation rec { pname = "cpp-netlib"; @@ -14,18 +14,22 @@ stdenv.mkDerivation rec { buildInputs = [ cmake boost openssl ]; - # This can be removed when updating to 0.13, see https://github.com/cpp-netlib/cpp-netlib/issues/629 - propagatedBuildInputs = [ asio ]; - cmakeFlags = [ "-DCPP-NETLIB_BUILD_SHARED_LIBS=ON" ]; enableParallelBuilding = true; + # The test driver binary lacks an RPath to the library's libs + preCheck = '' + export LD_LIBRARY_PATH=$PWD/libs/network/src + ''; + + # Most tests make network GET requests to various websites + doCheck = false; + meta = with stdenv.lib; { - description = - "Collection of open-source libraries for high level network programming"; + description = "Collection of open-source libraries for high level network programming"; homepage = https://cpp-netlib.org; license = licenses.boost; platforms = platforms.all; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 982721ae44d9..b4e9cf144776 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -11065,9 +11065,8 @@ in cpp-ipfs-api = callPackage ../development/libraries/cpp-ipfs-api { }; - cpp-netlib = callPackage ../development/libraries/cpp-netlib { - openssl = openssl_1_0_2; - }; + cpp-netlib = callPackage ../development/libraries/cpp-netlib {}; + uri = callPackage ../development/libraries/uri { }; cppcms = callPackage ../development/libraries/cppcms { }; -- cgit v1.2.3 From 6e8c3775628a4abcce07b5d195cf3f443ce9bbe8 Mon Sep 17 00:00:00 2001 From: Benjamin Hipple Date: Sun, 12 Jan 2020 12:19:17 -0500 Subject: rustPlatform.buildRustPackage: cleaner output on verifyCargoDeps (#77567) When this fails, the user may want to copy-paste the path to the "bad" Cargo.lock file to inspect. The trailing `.` on `$cargoDeps.` gets caught in most terminal copy-pastes. Since half the lines already don't have it, this removes it from all of them for consistent output. --- pkgs/build-support/rust/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/build-support/rust/default.nix b/pkgs/build-support/rust/default.nix index f9cf8f1f0c1f..4089436c0e0b 100644 --- a/pkgs/build-support/rust/default.nix +++ b/pkgs/build-support/rust/default.nix @@ -100,9 +100,9 @@ stdenv.mkDerivation (args // { '' + stdenv.lib.optionalString verifyCargoDeps '' if ! diff source/Cargo.lock $cargoDeps/Cargo.lock ; then echo - echo "ERROR: cargoSha256 is out of date." + echo "ERROR: cargoSha256 is out of date" echo - echo "Cargo.lock is not the same in $cargoDeps." + echo "Cargo.lock is not the same in $cargoDeps" echo echo "To fix the issue:" echo '1. Use "1111111111111111111111111111111111111111111111111111" as the cargoSha256 value' -- cgit v1.2.3 From c2e5ff3fe8e1e57cfbde9a098f55c8b8c2531b83 Mon Sep 17 00:00:00 2001 From: Benjamin Hipple Date: Sun, 12 Jan 2020 12:19:57 -0500 Subject: doc: update rust example on buildRustPackage (#77534) The example in the manual was out of date and didn't use the newer `pname` convention, which simplifies the fetch call. --- doc/languages-frameworks/rust.section.md | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/doc/languages-frameworks/rust.section.md b/doc/languages-frameworks/rust.section.md index 709a0d504cf7..0edf03ad26a9 100644 --- a/doc/languages-frameworks/rust.section.md +++ b/doc/languages-frameworks/rust.section.md @@ -32,17 +32,17 @@ Rust applications are packaged by using the `buildRustPackage` helper from `rust ``` rustPlatform.buildRustPackage rec { - name = "ripgrep-${version}"; - version = "0.4.0"; + pname = "ripgrep"; + version = "11.0.2"; src = fetchFromGitHub { owner = "BurntSushi"; - repo = "ripgrep"; - rev = "${version}"; - sha256 = "0y5d1n6hkw85jb3rblcxqas2fp82h3nghssa4xqrhqnz25l799pj"; + repo = pname; + rev = version; + sha256 = "1iga3320mgi7m853la55xip514a3chqsdi1a1rwv25lr9b1p7vd3"; }; - cargoSha256 = "0q68qyl2h6i0qsz82z840myxlnjay8p1w5z7hfyr8fqp7wgwa9cx"; + cargoSha256 = "17ldqr3asrdcsh4l29m3b5r37r5d0b3npq1lrgjmxb6vlx6a36qh"; verifyCargoDeps = true; meta = with stdenv.lib; { @@ -66,7 +66,11 @@ added in `cargoPatches` will also be prepended to the patches in `patches` at build-time. When `verifyCargoDeps` is set to `true`, the build will also verify that the -`cargoSha256` is not out of date by comparing the `Cargo.lock` file in both the `cargoDeps` and `src`. Note that this option changes the value of `cargoSha256` since it also copies the `Cargo.lock` in it. To avoid breaking backward-compatibility this option is not enabled by default but hopefully will be in the future. +`cargoSha256` is not out of date by comparing the `Cargo.lock` file in both the +`cargoDeps` and `src`. Note that this option changes the value of `cargoSha256` +since it also copies the `Cargo.lock` in it. To avoid breaking +backward-compatibility this option is not enabled by default but hopefully will +be in the future. ### Building a crate for a different target -- cgit v1.2.3 From cf80bce0cc73e5a0900839cd567026b2669d4d59 Mon Sep 17 00:00:00 2001 From: Antonio Nuno Monteiro Date: Sun, 12 Jan 2020 09:52:41 -0800 Subject: bs-platform: add myself to maintainers --- maintainers/maintainer-list.nix | 6 ++++++ pkgs/development/compilers/bs-platform/default.nix | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix index de4c95f7f2c6..180eca8fe322 100644 --- a/maintainers/maintainer-list.nix +++ b/maintainers/maintainer-list.nix @@ -505,6 +505,12 @@ githubId = 750786; name = "Justin Wood"; }; + anmonteiro = { + email = "anmonteiro@gmail.com"; + github = "anmonteiro"; + githubId = 661909; + name = "Antonio Nuno Monteiro"; + }; anpryl = { email = "anpryl@gmail.com"; github = "anpryl"; diff --git a/pkgs/development/compilers/bs-platform/default.nix b/pkgs/development/compilers/bs-platform/default.nix index 5eb11671ca90..59a47bdab70c 100644 --- a/pkgs/development/compilers/bs-platform/default.nix +++ b/pkgs/development/compilers/bs-platform/default.nix @@ -4,7 +4,7 @@ let description = "A JavaScript backend for OCaml focused on smooth integration and clean generated code."; homepage = https://bucklescript.github.io; license = licenses.lgpl3; - maintainers = with maintainers; [ turbomack gamb ]; + maintainers = with maintainers; [ turbomack gamb anmonteiro ]; platforms = platforms.all; }; in -- cgit v1.2.3 From 2f0027f7dc9c8f55317be345dae33c5b81fa1e6e Mon Sep 17 00:00:00 2001 From: Jaka Hudoklin Date: Thu, 3 Oct 2019 13:29:58 +0200 Subject: rippled: 1.2.1 -> 1.4.0 --- pkgs/servers/rippled/default.nix | 74 ++++++++++++++++++++++------------------ pkgs/top-level/all-packages.nix | 4 ++- 2 files changed, 44 insertions(+), 34 deletions(-) diff --git a/pkgs/servers/rippled/default.nix b/pkgs/servers/rippled/default.nix index 840f63f3e058..905e776ea362 100644 --- a/pkgs/servers/rippled/default.nix +++ b/pkgs/servers/rippled/default.nix @@ -1,34 +1,28 @@ -{ stdenv, fetchFromGitHub, fetchgit, fetchurl, git, cmake, pkgconfig +{ stdenv, fetchFromGitHub, fetchgit, fetchurl, runCommand, git, cmake, pkgconfig , openssl, boost, zlib }: let - sqlite3 = fetchurl { + sqlite3 = fetchurl rec { url = "https://www.sqlite.org/2018/sqlite-amalgamation-3260000.zip"; sha256 = "0vh9aa5dyvdwsyd8yp88ss300mv2c2m40z79z569lcxa6fqwlpfy"; - }; - - beast = fetchgit { - url = "https://github.com/boostorg/beast.git"; - rev = "2f9a8440c2432d8a196571d6300404cb76314125"; - sha256 = "1n9ms5cn67b0p0mhldz5psgylds22sm5x22q7knrsf20856vlk5a"; - fetchSubmodules = false; - leaveDotGit = true; + passthru.url = url; }; docca = fetchgit { url = "https://github.com/vinniefalco/docca.git"; rev = "335dbf9c3613e997ed56d540cc8c5ff2e28cab2d"; - sha256 = "09cb90k0ygmnlpidybv6nzf6is51i80lnwlvad6ijc3gf1z6i1yh"; - fetchSubmodules = false; + sha256 = "1yisdg7q2p9q9gz0c446796p3ggx9s4d6g8w4j1pjff55655805h"; leaveDotGit = true; + fetchSubmodules = false; }; - rocksdb = fetchgit { + rocksdb = fetchgit rec { url = "https://github.com/facebook/rocksdb.git"; - rev = "a297643f2e327a8bc7061bfc838fdf11935a2cf2"; - sha256 = "00z8i4fwr27j9d4ymnls7rcgfvm6xh36a4hy2m2njx4x513pgyzw"; - fetchSubmodules = false; + rev = "v5.17.2"; + sha256 = "0d9ssggjls1hc4zhng65yg8slqlcw0lr23qr6f39shg42lzr227p"; leaveDotGit = true; + fetchSubmodules = false; + postFetch = "cd $out && git tag ${rev}"; }; lz4 = fetchgit rec { @@ -51,8 +45,8 @@ let soci = fetchgit { url = "https://github.com/SOCI/soci.git"; - rev = "3a1f602b3021b925d38828e3ff95f9e7f8887ff7"; - sha256 = "0lnps42cidlrn43h13b9yc8cs3fwgz7wb6a1kfc9rnw7swkh757f"; + rev = "04e1870294918d20761736743bb6136314c42dd5"; + sha256 = "0w3b7qi3bwn8bxh4qbqy6c1fw2bbwh7pxvk8b3qb6h4qgsh6kx89"; leaveDotGit = true; fetchSubmodules = false; }; @@ -67,11 +61,11 @@ let }; nudb = fetchgit rec { - url = "https://github.com/vinniefalco/NuDB.git"; - rev = "1.0.0"; - sha256 = "142bxicv25xaw4fmpw8bbblb1grdw30wyj181xl4a5734zw3qgmz"; + url = "https://github.com/CPPAlliance/NuDB.git"; + rev = "2.0.1"; + sha256 = "0h7hmwavrxzj1v547h3z0031ckwphjayfpv1mgcr6q86wm9p5468"; leaveDotGit = true; - fetchSubmodules = false; + fetchSubmodules = true; # submodules are needed, rocksdb is dependency postFetch = "cd $out && git tag ${rev}"; }; @@ -88,40 +82,54 @@ let url = "https://github.com/google/googletest.git"; rev = "c3bb0ee2a63279a803aaad956b9b26d74bf9e6e2"; sha256 = "0pj5b6jnrj5lrccz2disr8hklbnzd8hwmrwbfqmvhiwb9q9p0k2k"; - leaveDotGit = true; fetchSubmodules = false; + leaveDotGit = true; }; google-benchmark = fetchgit { url = "https://github.com/google/benchmark.git"; rev = "5b7683f49e1e9223cf9927b24f6fd3d6bd82e3f8"; sha256 = "0qg70j47zqnr