From 08ce0156e4775da2b530914a16022c1ac9d3047c Mon Sep 17 00:00:00 2001 From: Ben Siraphob Date: Sat, 30 Jan 2021 17:19:29 +0700 Subject: pleroma-otp: stdenv.lib -> lib --- pkgs/servers/pleroma-otp/default.nix | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'pkgs') diff --git a/pkgs/servers/pleroma-otp/default.nix b/pkgs/servers/pleroma-otp/default.nix index e66ae693a0e81..4905acd075773 100644 --- a/pkgs/servers/pleroma-otp/default.nix +++ b/pkgs/servers/pleroma-otp/default.nix @@ -1,4 +1,5 @@ -{ stdenv +{ lib +, stdenv , autoPatchelfHook , fetchurl , file @@ -60,11 +61,11 @@ stdenv.mkDerivation { pleroma = nixosTests.pleroma; }; - meta = { + meta = with lib; { description = "ActivityPub microblogging server"; homepage = https://git.pleroma.social/pleroma/pleroma; - license = stdenv.lib.licenses.agpl3; - maintainers = with stdenv.lib.maintainers; [ ninjatrappeur ]; + license = licenses.agpl3; + maintainers = with maintainers; [ ninjatrappeur ]; platforms = [ "x86_64-linux" "aarch64-linux" ]; }; } -- cgit 1.4.1 From 7ff2c85a8ee2e5122c9b0c51946d9470a527223e Mon Sep 17 00:00:00 2001 From: Ben Siraphob Date: Sat, 30 Jan 2021 17:19:44 +0700 Subject: cargo-valgrind: stdenv.lib -> lib --- pkgs/development/tools/rust/cargo-valgrind/default.nix | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'pkgs') diff --git a/pkgs/development/tools/rust/cargo-valgrind/default.nix b/pkgs/development/tools/rust/cargo-valgrind/default.nix index 138fc060568fd..50cffe74848ed 100644 --- a/pkgs/development/tools/rust/cargo-valgrind/default.nix +++ b/pkgs/development/tools/rust/cargo-valgrind/default.nix @@ -1,4 +1,5 @@ -{ stdenv +{ lib +, stdenv , rustPlatform , fetchFromGitHub , nix-update-script @@ -30,10 +31,10 @@ rustPlatform.buildRustPackage rec { nativeBuildInputs = [ makeWrapper ]; postInstall = '' - wrapProgram $out/bin/cargo-valgrind --prefix PATH : ${stdenv.lib.makeBinPath [ valgrind ]} + wrapProgram $out/bin/cargo-valgrind --prefix PATH : ${lib.makeBinPath [ valgrind ]} ''; - meta = with stdenv.lib; { + meta = with lib; { description = ''Cargo subcommand "valgrind": runs valgrind and collects its output in a helpful manner''; homepage = "https://github.com/jfrimmel/cargo-valgrind"; license = with licenses; [ asl20 /* or */ mit ]; -- cgit 1.4.1 From 9071feb01d79d4e9a42a485f72bc5cb325baf8dc Mon Sep 17 00:00:00 2001 From: Ben Siraphob Date: Sat, 30 Jan 2021 17:19:55 +0700 Subject: hspell: stdenv.lib -> lib --- pkgs/development/libraries/hspell/default.nix | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'pkgs') diff --git a/pkgs/development/libraries/hspell/default.nix b/pkgs/development/libraries/hspell/default.nix index 67e593d27f4fc..2a65afad809a8 100644 --- a/pkgs/development/libraries/hspell/default.nix +++ b/pkgs/development/libraries/hspell/default.nix @@ -16,15 +16,15 @@ stdenv.mkDerivation rec { }; patchPhase = "patchShebangs ."; - preBuild = stdenv.lib.optionalString (stdenv.hostPlatform != stdenv.buildPlatform) '' + preBuild = lib.optionalString (stdenv.hostPlatform != stdenv.buildPlatform) '' make CC=${buildPackages.stdenv.cc}/bin/cc find_sizes mv find_sizes find_sizes_build make clean substituteInPlace Makefile --replace "./find_sizes" "./find_sizes_build" - substituteInPlace Makefile --replace "ar cr" "${stdenv.lib.getBin stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}ar cr" - substituteInPlace Makefile --replace "ranlib" "${stdenv.lib.getBin stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}ranlib" - substituteInPlace Makefile --replace "STRIP=strip" "STRIP=${stdenv.lib.getBin stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}strip" + substituteInPlace Makefile --replace "ar cr" "${lib.getBin stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}ar cr" + substituteInPlace Makefile --replace "ranlib" "${lib.getBin stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}ranlib" + substituteInPlace Makefile --replace "STRIP=strip" "STRIP=${lib.getBin stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}strip" ''; nativeBuildInputs = [ perl zlib ]; # buildInputs = [ zlib ]; -- cgit 1.4.1 From 32e8cec5d9be7963c3cc23541c2679a4a5989348 Mon Sep 17 00:00:00 2001 From: Ben Siraphob Date: Sat, 30 Jan 2021 17:23:49 +0700 Subject: stdenv: warn about use of inherited lib --- pkgs/stdenv/generic/default.nix | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'pkgs') diff --git a/pkgs/stdenv/generic/default.nix b/pkgs/stdenv/generic/default.nix index c7c3bb9f3f3f9..125eff9aec570 100644 --- a/pkgs/stdenv/generic/default.nix +++ b/pkgs/stdenv/generic/default.nix @@ -152,9 +152,12 @@ let inherit lib config stdenv; }) mkDerivation; - # For convenience, bring in the library functions in lib/ so - # packages don't have to do that themselves. - inherit lib; + # Slated for deprecation in 21.11 + lib = builtins.trace ( "Warning: `stdenv.lib` is deprecated " + + "and will be removed in the next release. " + + "Please use `pkgs.lib` instead. " + + "For more information see https://github.com/NixOS/nixpkgs/issues/108938") + lib; inherit fetchurlBoot; -- cgit 1.4.1 From 227693ed69a03605d7b9d5e051f2158aaf8cbe3c Mon Sep 17 00:00:00 2001 From: Ben Siraphob Date: Sun, 31 Jan 2021 03:03:11 +0000 Subject: Update pkgs/stdenv/generic/default.nix Co-authored-by: John Ericson --- pkgs/stdenv/generic/default.nix | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'pkgs') diff --git a/pkgs/stdenv/generic/default.nix b/pkgs/stdenv/generic/default.nix index 125eff9aec570..52d57a6decee3 100644 --- a/pkgs/stdenv/generic/default.nix +++ b/pkgs/stdenv/generic/default.nix @@ -153,11 +153,11 @@ let }) mkDerivation; # Slated for deprecation in 21.11 - lib = builtins.trace ( "Warning: `stdenv.lib` is deprecated " - + "and will be removed in the next release. " - + "Please use `pkgs.lib` instead. " - + "For more information see https://github.com/NixOS/nixpkgs/issues/108938") - lib; + lib = builtins.trace + ( "Warning: `stdenv.lib` is deprecated and will be removed in the next release." + + " Please use `pkgs.lib` instead." + + " For more information see https://github.com/NixOS/nixpkgs/issues/108938") + lib; inherit fetchurlBoot; -- cgit 1.4.1