From b739da06931e6df03ac18f6d85be40d301042969 Mon Sep 17 00:00:00 2001 From: Yves-Stan Le Cornec Date: Mon, 3 Oct 2022 12:43:33 +0200 Subject: [PATCH 01/37] buildBazelPackage: optionally run bazel tests in checkPhase Tests from the bazelTestTargets argument will be run before the build. The new bazelTestFlags argument can be used to pass additional flags to this phase. --- .../build-bazel-package/default.nix | 120 +++++++++++------- 1 file changed, 71 insertions(+), 49 deletions(-) diff --git a/pkgs/build-support/build-bazel-package/default.nix b/pkgs/build-support/build-bazel-package/default.nix index d69fddaf03fa..14f7ac38d3ff 100644 --- a/pkgs/build-support/build-bazel-package/default.nix +++ b/pkgs/build-support/build-bazel-package/default.nix @@ -13,35 +13,37 @@ args@{ , bazel ? bazelPkg , bazelFlags ? [] , bazelBuildFlags ? [] +, bazelTestFlags ? [] , bazelFetchFlags ? [] , bazelTarget +, bazelTestTargets ? [] , buildAttrs , fetchAttrs -# Newer versions of Bazel are moving away from built-in rules_cc and instead -# allow fetching it as an external dependency in a WORKSPACE file[1]. If -# removed in the fixed-output fetch phase, building will fail to download it. -# This can be seen e.g. in #73097 -# -# This option allows configuring the removal of rules_cc in cases where a -# project depends on it via an external dependency. -# -# [1]: https://github.com/bazelbuild/rules_cc + # Newer versions of Bazel are moving away from built-in rules_cc and instead + # allow fetching it as an external dependency in a WORKSPACE file[1]. If + # removed in the fixed-output fetch phase, building will fail to download it. + # This can be seen e.g. in #73097 + # + # This option allows configuring the removal of rules_cc in cases where a + # project depends on it via an external dependency. + # + # [1]: https://github.com/bazelbuild/rules_cc , removeRulesCC ? true , removeLocalConfigCc ? true , removeLocal ? true -# Use build --nobuild instead of fetch. This allows fetching the dependencies -# required for the build as configured, rather than fetching all the dependencies -# which may not work in some situations (e.g. Java code which ends up relying on -# Debian-specific /usr/share/java paths, but doesn't in the configured build). + # Use build --nobuild instead of fetch. This allows fetching the dependencies + # required for the build as configured, rather than fetching all the dependencies + # which may not work in some situations (e.g. Java code which ends up relying on + # Debian-specific /usr/share/java paths, but doesn't in the configured build). , fetchConfigured ? true -# Don’t add Bazel --copt and --linkopt from NIX_CFLAGS_COMPILE / -# NIX_LDFLAGS. This is necessary when using a custom toolchain which -# Bazel wants all headers / libraries to come from, like when using -# CROSSTOOL. Weirdly, we can still get the flags through the wrapped -# compiler. + # Don’t add Bazel --copt and --linkopt from NIX_CFLAGS_COMPILE / + # NIX_LDFLAGS. This is necessary when using a custom toolchain which + # Bazel wants all headers / libraries to come from, like when using + # CROSSTOOL. Weirdly, we can still get the flags through the wrapped + # compiler. , dontAddBazelOpts ? false , ... }: @@ -50,13 +52,33 @@ let fArgs = removeAttrs args [ "buildAttrs" "fetchAttrs" "removeRulesCC" ]; fBuildAttrs = fArgs // buildAttrs; fFetchAttrs = fArgs // removeAttrs fetchAttrs [ "sha256" ]; - -in stdenv.mkDerivation (fBuildAttrs // { - inherit name bazelFlags bazelBuildFlags bazelFetchFlags bazelTarget; + bazelCmd = { cmd, additionalFlags, targets }: + lib.optionalString (targets != [ ]) '' + # See footnote called [USER and BAZEL_USE_CPP_ONLY_TOOLCHAIN variables] + BAZEL_USE_CPP_ONLY_TOOLCHAIN=1 \ + USER=homeless-shelter \ + bazel \ + --batch \ + --output_base="$bazelOut" \ + --output_user_root="$bazelUserRoot" \ + ${cmd} \ + --curses=no \ + -j $NIX_BUILD_CORES \ + "''${copts[@]}" \ + "''${host_copts[@]}" \ + "''${linkopts[@]}" \ + "''${host_linkopts[@]}" \ + $bazelFlags \ + ${lib.strings.concatStringsSep " " additionalFlags} \ + ${lib.strings.concatStringsSep " " targets} + ''; +in +stdenv.mkDerivation (fBuildAttrs // { + inherit name bazelFlags bazelBuildFlags bazelTestFlags bazelFetchFlags bazelTarget bazelTestTargets; deps = stdenv.mkDerivation (fFetchAttrs // { name = "${name}-deps.tar.gz"; - inherit bazelFlags bazelBuildFlags bazelFetchFlags bazelTarget; + inherit bazelFlags bazelBuildFlags bazelTestFlags bazelFetchFlags bazelTarget bazelTestTargets; impureEnvVars = lib.fetchers.proxyImpureEnvVars ++ fFetchAttrs.impureEnvVars or []; @@ -77,14 +99,7 @@ in stdenv.mkDerivation (fBuildAttrs // { buildPhase = fFetchAttrs.buildPhase or '' runHook preBuild - # Bazel computes the default value of output_user_root before parsing the - # flag. The computation of the default value involves getting the $USER - # from the environment. I don't have that variable when building with - # sandbox enabled. Code here - # https://github.com/bazelbuild/bazel/blob/9323c57607d37f9c949b60e293b573584906da46/src/main/cpp/startup_options.cc#L123-L124 - # - # On macOS Bazel will use the system installed Xcode or CLT toolchain instead of the one in the PATH unless we pass BAZEL_USE_CPP_ONLY_TOOLCHAIN - + # See footnote called [USER and BAZEL_USE_CPP_ONLY_TOOLCHAIN variables]. # We disable multithreading for the fetching phase since it can lead to timeouts with many dependencies/threads: # https://github.com/bazelbuild/bazel/issues/6502 BAZEL_USE_CPP_ONLY_TOOLCHAIN=1 \ @@ -97,7 +112,8 @@ in stdenv.mkDerivation (fBuildAttrs // { --loading_phase_threads=1 \ $bazelFlags \ $bazelFetchFlags \ - $bazelTarget + ${bazelTarget} \ + ${lib.strings.concatStringsSep " " bazelTestTargets} runHook postBuild ''; @@ -189,7 +205,7 @@ in stdenv.mkDerivation (fBuildAttrs // { # the wrappers are expecting will not be set. So instead of relying on the # wrappers picking them up, pass them in explicitly via `--copt`, `--linkopt` # and related flags. - # + copts=() host_copts=() linkopts=() @@ -209,23 +225,29 @@ in stdenv.mkDerivation (fBuildAttrs // { done fi - BAZEL_USE_CPP_ONLY_TOOLCHAIN=1 \ - USER=homeless-shelter \ - bazel \ - --batch \ - --output_base="$bazelOut" \ - --output_user_root="$bazelUserRoot" \ - build \ - --curses=no \ - -j $NIX_BUILD_CORES \ - "''${copts[@]}" \ - "''${host_copts[@]}" \ - "''${linkopts[@]}" \ - "''${host_linkopts[@]}" \ - $bazelFlags \ - $bazelBuildFlags \ - $bazelTarget - + ${ + bazelCmd { + cmd = "test"; + additionalFlags = + ["--test_output=errors"] ++ bazelTestFlags; + targets = bazelTestTargets; + } + } + ${ + bazelCmd { + cmd = "build"; + additionalFlags = bazelBuildFlags; + targets = [bazelTarget]; + } + } runHook postBuild ''; }) + +# [USER and BAZEL_USE_CPP_ONLY_TOOLCHAIN variables]: +# Bazel computes the default value of output_user_root before parsing the +# flag. The computation of the default value involves getting the $USER +# from the environment. Code here : +# https://github.com/bazelbuild/bazel/blob/9323c57607d37f9c949b60e293b573584906da46/src/main/cpp/startup_options.cc#L123-L124 +# +# On macOS Bazel will use the system installed Xcode or CLT toolchain instead of the one in the PATH unless we pass BAZEL_USE_CPP_ONLY_TOOLCHAIN. From 6b1a33bede0e96f19b73e64de6dc4b5cbf400771 Mon Sep 17 00:00:00 2001 From: Yves-Stan Le Cornec Date: Mon, 3 Oct 2022 12:44:12 +0200 Subject: [PATCH 02/37] vertible: run tests before building in buildBazelPackage --- pkgs/development/tools/verible/default.nix | 23 +++++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) diff --git a/pkgs/development/tools/verible/default.nix b/pkgs/development/tools/verible/default.nix index 6763638cab74..dc2d015a46f4 100644 --- a/pkgs/development/tools/verible/default.nix +++ b/pkgs/development/tools/verible/default.nix @@ -31,11 +31,15 @@ buildBazelPackage rec { ./remove-unused-deps.patch ]; - bazelFlags = [ "--//bazel:use_local_flex_bison" ]; + bazelFlags = [ + "--//bazel:use_local_flex_bison" + "--javabase=@bazel_tools//tools/jdk:remote_jdk11" + "--host_javabase=@bazel_tools//tools/jdk:remote_jdk11" + ]; fetchAttrs = { # Fixed output derivation hash after bazel fetch - sha256 = "sha256-XoLdlEeoDJlyWlnXZADHOKu06zKHgHJfgey8UhOt+LM="; + sha256 = "sha256-45PINJ7VtL5Jl/nAQNkiSCt8wUwtytNfgeNMZaz3Y9U="; }; nativeBuildInputs = [ @@ -45,14 +49,23 @@ buildBazelPackage rec { ]; postPatch = '' - patchShebangs bazel/build-version.py \ - common/util/create_version_header.sh \ + patchShebangs\ + bazel/build-version.py \ + bazel/sh_test_with_runfiles_lib.sh \ + common/lsp/dummy-ls_test.sh \ common/parser/move_yacc_stack_symbols.sh \ - common/parser/record_syntax_error.sh + common/parser/record_syntax_error.sh \ + common/tools/patch_tool_test.sh \ + common/tools/verible-transform-interactive.sh \ + common/tools/verible-transform-interactive-test.sh \ + common/util/create_version_header.sh \ + kythe-browse.sh \ + verilog/tools ''; removeRulesCC = false; bazelTarget = ":install-binaries"; + bazelTestTargets = [ "//..." ]; bazelBuildFlags = [ "-c opt" ]; From d35d7ca6f9d4b766570f4fe308395ca2a1f9915b Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Sun, 9 Oct 2022 17:31:47 +0100 Subject: [PATCH 03/37] xorg.libXaw3d: remove in favour of Xaw3d Noticed this redundant attribute that no package uses. All packages use `Xaw3d`. Let's use that instead. --- pkgs/servers/x11/xorg/default.nix | 16 ---------------- pkgs/servers/x11/xorg/tarballs.list | 1 - 2 files changed, 17 deletions(-) diff --git a/pkgs/servers/x11/xorg/default.nix b/pkgs/servers/x11/xorg/default.nix index 77d68e1d9aab..6d57f881bea4 100644 --- a/pkgs/servers/x11/xorg/default.nix +++ b/pkgs/servers/x11/xorg/default.nix @@ -935,22 +935,6 @@ lib.makeScope newScope (self: with self; { meta.platforms = lib.platforms.unix; }) {}; - # THIS IS A GENERATED FILE. DO NOT EDIT! - libXaw3d = callPackage ({ stdenv, pkg-config, fetchurl, libX11, libXext, libXmu, libXpm, xorgproto, libXt }: stdenv.mkDerivation { - pname = "libXaw3d"; - version = "1.6.3"; - builder = ./builder.sh; - src = fetchurl { - url = "mirror://xorg/individual/lib/libXaw3d-1.6.3.tar.bz2"; - sha256 = "0i653s8g25cc0mimkwid9366bqkbyhdyjhckx7bw77j20hzrkfid"; - }; - hardeningDisable = [ "bindnow" "relro" ]; - strictDeps = true; - nativeBuildInputs = [ pkg-config ]; - buildInputs = [ libX11 libXext libXmu libXpm xorgproto libXt ]; - meta.platforms = lib.platforms.unix; - }) {}; - # THIS IS A GENERATED FILE. DO NOT EDIT! libXcomposite = callPackage ({ stdenv, pkg-config, fetchurl, xorgproto, libX11, libXfixes }: stdenv.mkDerivation { pname = "libXcomposite"; diff --git a/pkgs/servers/x11/xorg/tarballs.list b/pkgs/servers/x11/xorg/tarballs.list index 302d56a06636..d0f8661e93e1 100644 --- a/pkgs/servers/x11/xorg/tarballs.list +++ b/pkgs/servers/x11/xorg/tarballs.list @@ -177,7 +177,6 @@ mirror://xorg/individual/lib/libWindowsWM-1.0.1.tar.bz2 mirror://xorg/individual/lib/libX11-1.8.1.tar.xz mirror://xorg/individual/lib/libXau-1.0.9.tar.bz2 mirror://xorg/individual/lib/libXaw-1.0.14.tar.bz2 -mirror://xorg/individual/lib/libXaw3d-1.6.3.tar.bz2 mirror://xorg/individual/lib/libxcb-1.14.tar.xz mirror://xorg/individual/lib/libXcomposite-0.4.5.tar.bz2 mirror://xorg/individual/lib/libXcursor-1.2.0.tar.bz2 From 1e4c40896e25826838109ea7ffac54ea45ae15e9 Mon Sep 17 00:00:00 2001 From: OPNA2608 Date: Wed, 12 Oct 2022 22:16:28 +0200 Subject: [PATCH 04/37] licenses: Add apsl10 --- lib/licenses.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/licenses.nix b/lib/licenses.nix index 1408eda523d4..6e5d9e764f72 100644 --- a/lib/licenses.nix +++ b/lib/licenses.nix @@ -78,6 +78,12 @@ in mkLicense lset) ({ url = "https://aomedia.org/license/patent-license/"; }; + apsl10 = { + spdxId = "APSL-1.0"; + fullName = "Apple Public Source License 1.0"; + url = "https://web.archive.org/web/20040701000000*/http://www.opensource.apple.com/apsl/1.0.txt"; + }; + apsl20 = { spdxId = "APSL-2.0"; fullName = "Apple Public Source License 2.0"; From 9443d83e6fee728c1926a783647b45011bd3b514 Mon Sep 17 00:00:00 2001 From: colin Date: Thu, 13 Oct 2022 21:46:04 -0700 Subject: [PATCH 05/37] freshrss: patchShebangs instead of specifying interpreter at use site this makes it easier for one to manually administer freshrss. for example, i can import OPML from the CLI like: ``` $ nix build .#freshrss $ freshrss FRESHRSS_DATA_PATH=/var/lib/freshrss ./result/cli/import-for-user.php --user admin --file my-opml.opml ``` whereas previously i would have needed to include `environment.systemPackages = [ php ];` in my system for that to work. --- nixos/modules/services/web-apps/freshrss.nix | 12 ++++++------ pkgs/servers/web-apps/freshrss/default.nix | 14 +++++++++++++- 2 files changed, 19 insertions(+), 7 deletions(-) diff --git a/nixos/modules/services/web-apps/freshrss.nix b/nixos/modules/services/web-apps/freshrss.nix index 68780a3fe9dd..7898347e0b4f 100644 --- a/nixos/modules/services/web-apps/freshrss.nix +++ b/nixos/modules/services/web-apps/freshrss.nix @@ -238,17 +238,17 @@ in # do installation or reconfigure if test -f ${cfg.dataDir}/config.php; then # reconfigure with settings - ${pkgs.php}/bin/php ./cli/reconfigure.php ${settingsFlags} - ${pkgs.php}/bin/php ./cli/update-user.php --user ${cfg.defaultUser} --password "$(cat ${cfg.passwordFile})" + ./cli/reconfigure.php ${settingsFlags} + ./cli/update-user.php --user ${cfg.defaultUser} --password "$(cat ${cfg.passwordFile})" else # Copy the user data template directory cp -r ./data ${cfg.dataDir} # check correct folders in data folder - ${pkgs.php}/bin/php ./cli/prepare.php + ./cli/prepare.php # install with settings - ${pkgs.php}/bin/php ./cli/do-install.php ${settingsFlags} - ${pkgs.php}/bin/php ./cli/create-user.php --user ${cfg.defaultUser} --password "$(cat ${cfg.passwordFile})" + ./cli/do-install.php ${settingsFlags} + ./cli/create-user.php --user ${cfg.defaultUser} --password "$(cat ${cfg.passwordFile})" fi ''; }; @@ -267,7 +267,7 @@ in Group = "freshrss"; StateDirectory = "freshrss"; WorkingDirectory = cfg.package; - ExecStart = "${pkgs.php}/bin/php ./app/actualize_script.php"; + ExecStart = "./app/actualize_script.php"; } // systemd-hardening; }; }; diff --git a/pkgs/servers/web-apps/freshrss/default.nix b/pkgs/servers/web-apps/freshrss/default.nix index c627ae4d1692..dd2de486b886 100644 --- a/pkgs/servers/web-apps/freshrss/default.nix +++ b/pkgs/servers/web-apps/freshrss/default.nix @@ -1,4 +1,10 @@ -{ stdenvNoCC, lib, fetchFromGitHub, nixosTests, pkgs }: +{ stdenvNoCC +, lib +, fetchFromGitHub +, nixosTests +, php +, pkgs +}: stdenvNoCC.mkDerivation rec { pname = "FreshRSS"; @@ -13,6 +19,8 @@ stdenvNoCC.mkDerivation rec { passthru.tests = nixosTests.freshrss; + buildInputs = [ php ]; + # There's nothing to build. dontBuild = true; @@ -22,6 +30,10 @@ stdenvNoCC.mkDerivation rec { define('DATA_PATH', getenv('FRESHRSS_DATA_PATH')); ''; + postPatch = '' + patchShebangs cli/*.php app/actualize_script.php + ''; + installPhase = '' mkdir -p $out cp -vr * $out/ From c7ee149d58b1def0829a37f15f28fe2131aa1137 Mon Sep 17 00:00:00 2001 From: quasigod-io Date: Mon, 17 Oct 2022 14:31:24 -0400 Subject: [PATCH 06/37] grapejuice: 5.5.4 -> 6.2.2 --- pkgs/games/grapejuice/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/games/grapejuice/default.nix b/pkgs/games/grapejuice/default.nix index 8f621ff7fe48..f58596fccc12 100644 --- a/pkgs/games/grapejuice/default.nix +++ b/pkgs/games/grapejuice/default.nix @@ -18,13 +18,13 @@ python3Packages.buildPythonApplication rec { pname = "grapejuice"; - version = "5.5.4"; + version = "6.2.2"; src = fetchFromGitLab { owner = "BrinkerVII"; repo = "grapejuice"; rev = "v${version}"; - sha256 = "sha256-y4J0589FgNahRmoPkVtHYtc6/OIfUi9bhz6BZrSeWVI="; + sha256 = "sha256-wwM3q8Z4bYZod7/KcGc/PXlyLQxLRPkF1TdtFcg8mNE="; }; nativeBuildInputs = [ From 17bbf15d66e4b778d255a8a442c760393deb880c Mon Sep 17 00:00:00 2001 From: "R. Ryantm" Date: Tue, 18 Oct 2022 18:21:25 +0000 Subject: [PATCH 07/37] octoprint: 1.8.4 -> 1.8.6 --- pkgs/applications/misc/octoprint/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/misc/octoprint/default.nix b/pkgs/applications/misc/octoprint/default.nix index 474bdd0b6427..27c6da799064 100644 --- a/pkgs/applications/misc/octoprint/default.nix +++ b/pkgs/applications/misc/octoprint/default.nix @@ -74,13 +74,13 @@ let self: super: { octoprint = self.buildPythonPackage rec { pname = "OctoPrint"; - version = "1.8.4"; + version = "1.8.6"; src = fetchFromGitHub { owner = "OctoPrint"; repo = "OctoPrint"; rev = version; - hash = "sha256-oYP+K7WBkYP7gajXZdbZso17u+GeyrIgEbhNjwRXbAo="; + hash = "sha256-DCUesPy4/g7DYN/9CDRvwAWHcv4dFsF+gsysg5UWThQ="; }; propagatedBuildInputs = with super; [ From 24e81b7bf307c329ed594554c3d4c3eae5a5ebb4 Mon Sep 17 00:00:00 2001 From: figsoda Date: Tue, 18 Oct 2022 16:05:28 -0400 Subject: [PATCH 08/37] epick: 0.8.2 -> 0.9.0 --- pkgs/applications/graphics/epick/default.nix | 27 +++++++++++--------- pkgs/top-level/all-packages.nix | 2 +- 2 files changed, 16 insertions(+), 13 deletions(-) diff --git a/pkgs/applications/graphics/epick/default.nix b/pkgs/applications/graphics/epick/default.nix index c82f4f4d5f80..fd767e356f12 100644 --- a/pkgs/applications/graphics/epick/default.nix +++ b/pkgs/applications/graphics/epick/default.nix @@ -2,44 +2,47 @@ , rustPlatform , fetchFromGitHub , stdenv -, python3 +, pkg-config +, expat +, fontconfig +, freetype , libGL , xorg -, libxkbcommon +, darwin , AppKit -, IOKit }: rustPlatform.buildRustPackage rec { pname = "epick"; - version = "0.8.2"; + version = "0.9.0"; src = fetchFromGitHub { owner = "vv9k"; repo = pname; rev = version; - sha256 = "sha256-b4if2ggJY+8CsCX8jbnnWXy16k7sfB88CLlYYCrtltk="; + sha256 = "sha256-k0WQu1n1sAHVor58jr060vD5/2rDrt1k5zzJlrK9WrU="; }; - cargoSha256 = "sha256-HyGSmeLJ+2Twkg94p1QqXZDix0mU2jGFfEot6hgUg34="; + cargoSha256 = "sha256-OQZPOiMTpoWabxHa3TJG8L3zq8WxMeFttw8xggSXsMA="; - nativeBuildInputs = lib.optional stdenv.isLinux python3; + nativeBuildInputs = lib.optionals stdenv.isLinux [ + pkg-config + ]; buildInputs = lib.optionals stdenv.isLinux [ - libGL + expat + fontconfig + freetype xorg.libX11 xorg.libXcursor xorg.libXi xorg.libXrandr - xorg.libxcb - libxkbcommon ] ++ lib.optionals stdenv.isDarwin [ AppKit - IOKit ]; postFixup = lib.optionalString stdenv.isLinux '' - patchelf --set-rpath ${lib.makeLibraryPath buildInputs} $out/bin/epick + patchelf $out/bin/epick --add-rpath ${lib.makeLibraryPath [ libGL ]} ''; meta = with lib; { diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 5590178de132..b1643e828bd7 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -27869,7 +27869,7 @@ with pkgs; epic5 = callPackage ../applications/networking/irc/epic5 { }; epick = callPackage ../applications/graphics/epick { - inherit (darwin.apple_sdk.frameworks) AppKit IOKit; + inherit (darwin.apple_sdk.frameworks) AppKit; }; epr = callPackage ../applications/misc/epr { }; From 544a7f3577f1b5124e0ef678cbc433f453b6dfb0 Mon Sep 17 00:00:00 2001 From: "R. Ryantm" Date: Wed, 19 Oct 2022 00:18:37 +0000 Subject: [PATCH 09/37] vtm: 0.9.3 -> 0.9.6a --- pkgs/tools/misc/vtm/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/tools/misc/vtm/default.nix b/pkgs/tools/misc/vtm/default.nix index 756c474716d5..e7bb344b71f0 100644 --- a/pkgs/tools/misc/vtm/default.nix +++ b/pkgs/tools/misc/vtm/default.nix @@ -6,13 +6,13 @@ stdenv.mkDerivation rec { pname = "vtm"; - version = "0.9.3"; + version = "0.9.6a"; src = fetchFromGitHub { owner = "netxs-group"; repo = "vtm"; rev = "v${version}"; - sha256 = "sha256-m22Bj/Zj72OMZgmmX4cIuhb0JO/K9FopvXi9V9cMqDg="; + sha256 = "sha256-rl/QktX8pUbfTpqNCqNrAYM/N+CaAAo8+5RRCmOr7H8="; }; nativeBuildInputs = [ cmake ]; From 46539f80fd65bd1007ed090129533959f312eb6f Mon Sep 17 00:00:00 2001 From: wentam Date: Sun, 25 Sep 2022 05:33:19 -0400 Subject: [PATCH 10/37] proycon-wayout: init at 0.1.3 --- pkgs/tools/wayland/proycon-wayout/default.nix | 46 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 48 insertions(+) create mode 100644 pkgs/tools/wayland/proycon-wayout/default.nix diff --git a/pkgs/tools/wayland/proycon-wayout/default.nix b/pkgs/tools/wayland/proycon-wayout/default.nix new file mode 100644 index 000000000000..2b4dc0f54e4f --- /dev/null +++ b/pkgs/tools/wayland/proycon-wayout/default.nix @@ -0,0 +1,46 @@ +{ stdenv +, lib +, fetchFromSourcehut +, meson +, wayland-protocols +, wayland +, cairo +, pango +, scdoc +, ninja +, cmake +, pkg-config +, wayland-scanner +}: + +stdenv.mkDerivation rec { + pname = "proycon-wayout"; + version = "0.1.3"; + + src = fetchFromSourcehut { + owner = "~proycon"; + repo = "wayout"; + rev = version; + sha256 = "sha256-pxHz8y63xX9I425OG0jPvQVx4mAbTYHxVMMkfjZpURo="; + }; + + postPatch = '' + substituteInPlace meson.build --replace "'werror=true'," "" # Build fails with -Werror, remove + ''; + + postFixup = '' + mv $out/bin/wayout $out/bin/proycon-wayout # Avoid conflict with shinyzenith/wayout + ''; + + depsBuildBuild = [ pkg-config ]; + nativeBuildInputs = [ scdoc ninja meson cmake pkg-config wayland-scanner ]; + buildInputs = [ wayland-protocols wayland cairo pango ]; + + meta = with lib; { + description = "Takes text from standard input and outputs it to a desktop-widget on Wayland desktops."; + homepage = "https://git.sr.ht/~proycon/wayout"; + license = licenses.gpl3; + platforms = platforms.linux; + maintainers = with maintainers; [ wentam ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index eecc50b96c10..43b4e9981056 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -1351,6 +1351,8 @@ with pkgs; pferd = callPackage ../tools/misc/pferd {}; + proycon-wayout = callPackage ../tools/wayland/proycon-wayout {}; + q = callPackage ../tools/networking/q {}; qFlipper = libsForQt515.callPackage ../tools/misc/qflipper { }; From b6910964819e1c068a956aa2b71b0cad886efd83 Mon Sep 17 00:00:00 2001 From: wentam Date: Sun, 25 Sep 2022 06:17:19 -0400 Subject: [PATCH 11/37] maintainers: add wentam --- maintainers/maintainer-list.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix index 5e51f2641677..7065e4eeb94b 100644 --- a/maintainers/maintainer-list.nix +++ b/maintainers/maintainer-list.nix @@ -14312,6 +14312,12 @@ fingerprint = "2145 955E 3F5E 0C95 3458 41B5 11F7 BAEA 8567 43FF"; }]; }; + wentam = { + name = "Matt Egeler"; + email = "wentam42@gmail.com"; + github = "wentam"; + githubId = 901583; + }; wentasah = { name = "Michal Sojka"; email = "wsh@2x.cz"; From 2b44223dff38ff42bce44945e5df0138f60d5519 Mon Sep 17 00:00:00 2001 From: Matej Urbas Date: Sun, 16 Oct 2022 16:57:59 +0100 Subject: [PATCH 12/37] dupe-krill: init at 1.4.8 --- pkgs/tools/filesystems/dupe-krill/Cargo.lock | 339 ++++++++++++++++++ pkgs/tools/filesystems/dupe-krill/default.nix | 25 ++ pkgs/top-level/all-packages.nix | 2 + 3 files changed, 366 insertions(+) create mode 100644 pkgs/tools/filesystems/dupe-krill/Cargo.lock create mode 100644 pkgs/tools/filesystems/dupe-krill/default.nix diff --git a/pkgs/tools/filesystems/dupe-krill/Cargo.lock b/pkgs/tools/filesystems/dupe-krill/Cargo.lock new file mode 100644 index 000000000000..98c3d7157a1a --- /dev/null +++ b/pkgs/tools/filesystems/dupe-krill/Cargo.lock @@ -0,0 +1,339 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "arrayref" +version = "0.3.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4c527152e37cf757a3f78aae5a06fbeefdb07ccc535c980a3208ee3060dd544" + +[[package]] +name = "arrayvec" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8da52d66c7071e2e3fa2a1e5c6d088fec47b593032b254f5e980de8ea54454d6" + +[[package]] +name = "autocfg" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" + +[[package]] +name = "bitflags" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" + +[[package]] +name = "blake3" +version = "1.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a08e53fc5a564bb15bfe6fae56bd71522205f1f91893f9c0116edad6496c183f" +dependencies = [ + "arrayref", + "arrayvec", + "cc", + "cfg-if", + "constant_time_eq", + "digest", +] + +[[package]] +name = "block-buffer" +version = "0.10.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "69cce20737498f97b993470a6e536b8523f0af7892a4f928cceb1ac5e52ebe7e" +dependencies = [ + "generic-array", +] + +[[package]] +name = "cc" +version = "1.0.73" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2fff2a6927b3bb87f9595d67196a70493f627687a71d87a0d692242c33f58c11" + +[[package]] +name = "cfg-if" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" + +[[package]] +name = "constant_time_eq" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "245097e9a4535ee1e3e3931fcfcd55a796a44c643e8596ff6566d68f09b87bbc" + +[[package]] +name = "crypto-common" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" +dependencies = [ + "generic-array", + "typenum", +] + +[[package]] +name = "ctrlc" +version = "3.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1d91974fbbe88ec1df0c24a4f00f99583667a7e2e6272b2b92d294d81e462173" +dependencies = [ + "nix", + "winapi", +] + +[[package]] +name = "digest" +version = "0.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "adfbc57365a37acbd2ebf2b64d7e69bb766e2fea813521ed536f5d0520dcf86c" +dependencies = [ + "block-buffer", + "crypto-common", + "subtle", +] + +[[package]] +name = "dupe-krill" +version = "1.4.8" +dependencies = [ + "blake3", + "ctrlc", + "getopts", + "serde", + "serde_derive", + "serde_json", + "smallvec", + "tempdir", +] + +[[package]] +name = "fuchsia-cprng" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a06f77d526c1a601b7c4cdd98f54b5eaabffc14d5f2f0296febdc7f357c6d3ba" + +[[package]] +name = "generic-array" +version = "0.14.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bff49e947297f3312447abdca79f45f4738097cc82b06e72054d2223f601f1b9" +dependencies = [ + "typenum", + "version_check", +] + +[[package]] +name = "getopts" +version = "0.2.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "14dbbfd5c71d70241ecf9e6f13737f7b5ce823821063188d7e46c41d371eebd5" +dependencies = [ + "unicode-width", +] + +[[package]] +name = "itoa" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4217ad341ebadf8d8e724e264f13e593e0648f5b3e94b3896a5df283be015ecc" + +[[package]] +name = "libc" +version = "0.2.135" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "68783febc7782c6c5cb401fbda4de5a9898be1762314da0bb2c10ced61f18b0c" + +[[package]] +name = "nix" +version = "0.25.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e322c04a9e3440c327fca7b6c8a63e6890a32fa2ad689db972425f07e0d22abb" +dependencies = [ + "autocfg", + "bitflags", + "cfg-if", + "libc", +] + +[[package]] +name = "proc-macro2" +version = "1.0.47" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ea3d908b0e36316caf9e9e2c4625cdde190a7e6f440d794667ed17a1855e725" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "quote" +version = "1.0.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbe448f377a7d6961e30f5955f9b8d106c3f5e449d493ee1b125c1d43c2b5179" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "rand" +version = "0.4.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "552840b97013b1a26992c11eac34bdd778e464601a4c2054b5f0bff7c6761293" +dependencies = [ + "fuchsia-cprng", + "libc", + "rand_core 0.3.1", + "rdrand", + "winapi", +] + +[[package]] +name = "rand_core" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a6fdeb83b075e8266dcc8762c22776f6877a63111121f5f8c7411e5be7eed4b" +dependencies = [ + "rand_core 0.4.2", +] + +[[package]] +name = "rand_core" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c33a3c44ca05fa6f1807d8e6743f3824e8509beca625669633be0acbdf509dc" + +[[package]] +name = "rdrand" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "678054eb77286b51581ba43620cc911abf02758c91f93f479767aed0f90458b2" +dependencies = [ + "rand_core 0.3.1", +] + +[[package]] +name = "remove_dir_all" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3acd125665422973a33ac9d3dd2df85edad0f4ae9b00dafb1a05e43a9f5ef8e7" +dependencies = [ + "winapi", +] + +[[package]] +name = "ryu" +version = "1.0.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4501abdff3ae82a1c1b477a17252eb69cee9e66eb915c1abaa4f44d873df9f09" + +[[package]] +name = "serde" +version = "1.0.145" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "728eb6351430bccb993660dfffc5a72f91ccc1295abaa8ce19b27ebe4f75568b" + +[[package]] +name = "serde_derive" +version = "1.0.145" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "81fa1584d3d1bcacd84c277a0dfe21f5b0f6accf4a23d04d4c6d61f1af522b4c" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "serde_json" +version = "1.0.86" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41feea4228a6f1cd09ec7a3593a682276702cd67b5273544757dae23c096f074" +dependencies = [ + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "smallvec" +version = "1.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a507befe795404456341dfab10cef66ead4c041f62b8b11bbb92bffe5d0953e0" + +[[package]] +name = "subtle" +version = "2.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6bdef32e8150c2a081110b42772ffe7d7c9032b606bc226c8260fd97e0976601" + +[[package]] +name = "syn" +version = "1.0.102" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3fcd952facd492f9be3ef0d0b7032a6e442ee9b361d4acc2b1d0c4aaa5f613a1" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "tempdir" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "15f2b5fb00ccdf689e0149d1b1b3c03fead81c2b37735d812fa8bddbbf41b6d8" +dependencies = [ + "rand", + "remove_dir_all", +] + +[[package]] +name = "typenum" +version = "1.15.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dcf81ac59edc17cc8697ff311e8f5ef2d99fcbd9817b34cec66f90b6c3dfd987" + +[[package]] +name = "unicode-ident" +version = "1.0.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6ceab39d59e4c9499d4e5a8ee0e2735b891bb7308ac83dfb4e80cad195c9f6f3" + +[[package]] +name = "unicode-width" +version = "0.1.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c0edd1e5b14653f783770bce4a4dabb4a5108a5370a5f5d8cfe8710c361f6c8b" + +[[package]] +name = "version_check" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" + +[[package]] +name = "winapi" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419" +dependencies = [ + "winapi-i686-pc-windows-gnu", + "winapi-x86_64-pc-windows-gnu", +] + +[[package]] +name = "winapi-i686-pc-windows-gnu" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" + +[[package]] +name = "winapi-x86_64-pc-windows-gnu" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" diff --git a/pkgs/tools/filesystems/dupe-krill/default.nix b/pkgs/tools/filesystems/dupe-krill/default.nix new file mode 100644 index 000000000000..b28aaadca906 --- /dev/null +++ b/pkgs/tools/filesystems/dupe-krill/default.nix @@ -0,0 +1,25 @@ +{ lib, fetchFromGitHub, rustPlatform, runCommand }: + +rustPlatform.buildRustPackage rec { + pname = "dupe-krill"; + version = "1.4.8"; + + src = fetchFromGitHub { + owner = "kornelski"; + repo = pname; + rev = "v${version}"; + sha256 = "sha256-2fT9bw5LgJUQ0tm1T/vV5SaDjNH0OGKt7QUQLd7nmOs="; + postFetch = '' + cp ${./Cargo.lock} $out/Cargo.lock + ''; + }; + + cargoSha256 = "sha256-JUcIDUVzSLzblb2EbmSfuCAB+S0fyW6wpGF0b/xR+b0="; + + meta = with lib; { + description = " A fast file deduplicator."; + homepage = "https://github.com/kornelski/dupe-krill"; + license = with licenses; [ mit ]; + maintainers = with maintainers; [ urbas ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 9d2a4fd18dab..7b296dcea512 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -5951,6 +5951,8 @@ with pkgs; duo-unix = callPackage ../tools/security/duo-unix { }; + dupe-krill = callPackage ../tools/filesystems/dupe-krill { }; + duplicacy = callPackage ../tools/backup/duplicacy { }; duplicati = callPackage ../tools/backup/duplicati { }; From 53580d9f09d24c749c4fce323888bd7df8b4b6b3 Mon Sep 17 00:00:00 2001 From: ners Date: Mon, 17 Oct 2022 11:04:41 +0200 Subject: [PATCH 13/37] 389-ds-base: 2.0.7 -> 2.3.0 --- pkgs/servers/ldap/389/default.nix | 184 ++++++++---------- .../apache-directory-server/default.nix | 0 pkgs/top-level/all-packages.nix | 4 +- 3 files changed, 83 insertions(+), 105 deletions(-) rename pkgs/servers/{ => ldap}/apache-directory-server/default.nix (100%) diff --git a/pkgs/servers/ldap/389/default.nix b/pkgs/servers/ldap/389/default.nix index 438d7d0e630f..8a3e91bf0305 100644 --- a/pkgs/servers/ldap/389/default.nix +++ b/pkgs/servers/ldap/389/default.nix @@ -1,144 +1,121 @@ -{ stdenv -, autoreconfHook +{ lib +, stdenv , fetchFromGitHub -, lib - -, bzip2 -, cmocka +, autoconf +, automake +, libtool +, pkg-config , cracklib -, cyrus_sasl -, db -, doxygen -, icu +, lmdb +, json_c +, linux-pam , libevent -, libkrb5 -, lm_sensors -, net-snmp , nspr , nss , openldap -, openssl -, pcre -, perl -, perlPackages -, pkg-config +, withOpenldap ? true +, db +, withBdb ? true +, cyrus_sasl +, icu +, net-snmp +, withNetSnmp ? true +, krb5 +, pcre2 , python3 -, svrcore +, rustPlatform +, openssl +, systemd +, withSystemd ? stdenv.isLinux , zlib - -, enablePamPassthru ? true -, pam - -, enableCockpit ? true , rsync - -, enableDna ? true -, enableLdapi ? true -, enableAutobind ? false -, enableAutoDnSuffix ? false -, enableBitwise ? true -, enableAcctPolicy ? true -, enablePosixWinsync ? true +, withCockpit ? true +, withAsan ? false }: stdenv.mkDerivation rec { pname = "389-ds-base"; - version = "2.0.7"; + version = "2.3.0"; src = fetchFromGitHub { owner = "389ds"; repo = pname; rev = "${pname}-${version}"; - sha256 = "sha256-aM1qo+yHrCFespPWHv2f25ooqQVCIZGaZS43dY6kiC4="; + sha256 = "sha256-GnntF0UaufDrgcM6FFFdwxwVoU9Hu2NXTW1A2lTb6T4="; }; - nativeBuildInputs = [ autoreconfHook pkg-config doxygen ]; + cargoDeps = rustPlatform.fetchCargoTarball { + inherit src; + sourceRoot = "source/src"; + name = "${pname}-${version}"; + hash = "sha256-OJXvNL7STNwvt6EiV2r8zv2ZoUGgNUj7UssAQNLN4KI="; + }; + + nativeBuildInputs = [ + autoconf + automake + libtool + pkg-config + python3 + rustPlatform.rust.cargo + rustPlatform.rust.rustc + ] + ++ lib.optional withCockpit rsync; buildInputs = [ - bzip2 cracklib - cyrus_sasl - db - icu + lmdb + json_c + linux-pam libevent - libkrb5 - lm_sensors - net-snmp nspr nss - openldap + cyrus_sasl + icu + krb5 + pcre2 openssl - pcre - perl - python3 - svrcore zlib - - # tests - cmocka - libevent - - # lib389 - (python3.withPackages (ps: with ps; [ - setuptools - python-ldap - six - pyasn1 - pyasn1-modules - python-dateutil - argcomplete - libselinux - ])) - - # logconv.pl - perlPackages.DBFile - perlPackages.ArchiveTar ] - ++ lib.optional enableCockpit rsync - ++ lib.optional enablePamPassthru pam; + ++ lib.optional withSystemd systemd + ++ lib.optional withOpenldap openldap + ++ lib.optional withBdb db + ++ lib.optional withNetSnmp net-snmp; postPatch = '' - substituteInPlace Makefile.am \ - --replace 's,@perlpath\@,$(perldir),g' 's,@perlpath\@,$(perldir) $(PERLPATH),g' - patchShebangs ./buildnum.py ./ldap/servers/slapd/mkDBErrStrs.py ''; preConfigure = '' - # Create perl paths for library imports in perl scripts - PERLPATH="" - for P in $(echo $PERL5LIB | sed 's/:/ /g'); do - PERLPATH="$PERLPATH $(echo $P/*/*)" - done - export PERLPATH + ./autogen.sh --prefix="$out" ''; - configureFlags = - let - mkEnable = cond: name: if cond then "--enable-${name}" else "--disable-${name}"; - in - [ - "--enable-cmocka" - "--localstatedir=/var" - "--sysconfdir=/etc" - "--with-db-inc=${db.dev}/include" - "--with-db-lib=${db.out}/lib" - "--with-db=yes" - "--with-netsnmp-inc=${lib.getDev net-snmp}/include" - "--with-netsnmp-lib=${lib.getLib net-snmp}/lib" - "--with-netsnmp=yes" - "--with-openldap" + preBuild = '' + mkdir -p ./vendor + tar -xzf ${cargoDeps} -C ./vendor --strip-components=1 + ''; - "${mkEnable enableCockpit "cockpit"}" - "${mkEnable enablePamPassthru "pam-passthru"}" - "${mkEnable enableDna "dna"}" - "${mkEnable enableLdapi "ldapi"}" - "${mkEnable enableAutobind "autobind"}" - "${mkEnable enableAutoDnSuffix "auto-dn-suffix"}" - "${mkEnable enableBitwise "bitwise"}" - "${mkEnable enableAcctPolicy "acctpolicy"}" - "${mkEnable enablePosixWinsync "posix-winsync"}" - ]; + configureFlags = [ + "--enable-rust-offline" + "--enable-autobind" + ] + ++ lib.optionals withSystemd [ + "--with-systemd" + "--with-systemdsystemunitdir=${placeholder "out"}/etc/systemd/system" + ] ++ lib.optionals withOpenldap [ + "--with-openldap" + ] ++ lib.optionals withBdb [ + "--with-db-inc=${lib.getDev db}/include" + "--with-db-lib=${lib.getLib db}/lib" + ] ++ lib.optionals withNetSnmp [ + "--with-netsnmp-inc=${lib.getDev net-snmp}/include" + "--with-netsnmp-lib=${lib.getLib net-snmp}/lib" + ] ++ lib.optionals (!withCockpit) [ + "--disable-cockpit" + ] ++ lib.optionals withAsan [ + "--enable-asan" + "--enable-debug" + ]; enableParallelBuilding = true; @@ -156,5 +133,6 @@ stdenv.mkDerivation rec { description = "Enterprise-class Open Source LDAP server for Linux"; license = licenses.gpl3Plus; platforms = platforms.linux; + maintainers = [ maintainers.ners ]; }; } diff --git a/pkgs/servers/apache-directory-server/default.nix b/pkgs/servers/ldap/apache-directory-server/default.nix similarity index 100% rename from pkgs/servers/apache-directory-server/default.nix rename to pkgs/servers/ldap/apache-directory-server/default.nix diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 6ab36fc6f57d..215c17d0ec3e 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -23049,6 +23049,8 @@ with pkgs; alps = callPackage ../servers/alps { }; + apache-directory-server = callPackage ../servers/ldap/apache-directory-server {}; + apacheHttpd_2_4 = callPackage ../servers/http/apache-httpd/2.4.nix { }; apacheHttpd = apacheHttpd_2_4; @@ -26954,8 +26956,6 @@ with pkgs; ao = libfive; - apache-directory-server = callPackage ../servers/apache-directory-server {}; - apache-directory-studio = callPackage ../applications/networking/apache-directory-studio {}; apkeep = callPackage ../tools/misc/apkeep { From 991732fe47efc034869c484fc2dcb1d1aa7683ee Mon Sep 17 00:00:00 2001 From: "R. Ryantm" Date: Wed, 19 Oct 2022 11:36:25 +0000 Subject: [PATCH 14/37] flyctl: 0.0.414 -> 0.0.415 --- pkgs/development/web/flyctl/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/web/flyctl/default.nix b/pkgs/development/web/flyctl/default.nix index 9bedd1648a18..99dcd9909649 100644 --- a/pkgs/development/web/flyctl/default.nix +++ b/pkgs/development/web/flyctl/default.nix @@ -2,16 +2,16 @@ buildGoModule rec { pname = "flyctl"; - version = "0.0.414"; + version = "0.0.415"; src = fetchFromGitHub { owner = "superfly"; repo = "flyctl"; rev = "v${version}"; - sha256 = "sha256-jGza1ltDGRD3mfFYy8GN3T3t5blIVqRVN25m0CN0c78="; + sha256 = "sha256-pw8LDp4uuU0J1HFEBdntROcyJUR8mBId5Xwm/5w9F04="; }; - vendorSha256 = "sha256-ZnT9IaL6j2EzKk2RRftB4qELIi4nXKC/2zBOhInFYHA="; + vendorSha256 = "sha256-AlPdKUNscp71GttiLfPJf8rs/72Ff0CELDSSHcfY/4g="; subPackages = [ "." ]; From 3819d5f7c09b8474985c1bc8eeb18faa09b13375 Mon Sep 17 00:00:00 2001 From: Vincent Haupert Date: Fri, 14 Oct 2022 09:12:27 +0200 Subject: [PATCH 15/37] python310Packages.nc-dnsapi: init at 0.1.5 --- .../python-modules/nc-dnsapi/default.nix | 30 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 32 insertions(+) create mode 100644 pkgs/development/python-modules/nc-dnsapi/default.nix diff --git a/pkgs/development/python-modules/nc-dnsapi/default.nix b/pkgs/development/python-modules/nc-dnsapi/default.nix new file mode 100644 index 000000000000..79838120f614 --- /dev/null +++ b/pkgs/development/python-modules/nc-dnsapi/default.nix @@ -0,0 +1,30 @@ +{ lib +, buildPythonPackage +, fetchPypi +, requests +}: + +buildPythonPackage rec { + pname = "nc-dnsapi"; + version = "0.1.5"; + + src = fetchPypi { + inherit version; + pname = "nc_dnsapi"; + hash = "sha256-1fvzr3e0ZAbSDOovhLz5GHJCS6l+K89fbYHoaWxO9cA="; + }; + + propagatedBuildInputs = [ requests ]; + + pythonImportsCheck = [ "nc_dnsapi" ]; + + # no tests + doCheck = false; + + meta = with lib; { + description = "API wrapper for the netcup DNS api"; + homepage = "https://github.com/nbuchwitz/nc_dnsapi"; + license = licenses.gpl3; + maintainers = with maintainers; [ veehaitch trundle ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index b49f7e43e1b0..b2d077e414c8 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -6150,6 +6150,8 @@ in { nbxmpp = callPackage ../development/python-modules/nbxmpp { }; + nc-dnsapi = callPackage ../development/python-modules/nc-dnsapi { }; + ncclient = callPackage ../development/python-modules/ncclient { }; nclib = callPackage ../development/python-modules/nclib { }; From b362f100ac6b0f4d0d20722478b48d91a84357a6 Mon Sep 17 00:00:00 2001 From: "R. Ryantm" Date: Wed, 19 Oct 2022 15:31:14 +0000 Subject: [PATCH 16/37] python310Packages.clize: 4.2.1 -> 5.0.0 --- pkgs/development/python-modules/clize/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/clize/default.nix b/pkgs/development/python-modules/clize/default.nix index f1e5b16320b6..003b78bbe229 100644 --- a/pkgs/development/python-modules/clize/default.nix +++ b/pkgs/development/python-modules/clize/default.nix @@ -23,12 +23,12 @@ buildPythonPackage rec { pname = "clize"; - version = "4.2.1"; + version = "5.0.0"; format = "pyproject"; src = fetchPypi { inherit pname version; - sha256 = "3177a028e4169d8865c79af82bdd441b24311d4bd9c0ae8803641882d340a51d"; + sha256 = "sha256-/cFpEvAN/Movd38xaE53Y+D9EYg/SFyHeqtlVUo1D0I="; }; postPatch = '' From e0f2f2b676c3d9ffadcb0a05b84328a4c0da0f99 Mon Sep 17 00:00:00 2001 From: Rebecca Turner Date: Wed, 19 Oct 2022 12:19:16 -0400 Subject: [PATCH 17/37] ormolu/fourmolu: Fix build on aarch64-darwin --- .../development/haskell-modules/configuration-darwin.nix | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/pkgs/development/haskell-modules/configuration-darwin.nix b/pkgs/development/haskell-modules/configuration-darwin.nix index 2ebfdb4a8841..468e2ca08c6a 100644 --- a/pkgs/development/haskell-modules/configuration-darwin.nix +++ b/pkgs/development/haskell-modules/configuration-darwin.nix @@ -299,6 +299,15 @@ self: super: ({ # https://github.com/haskell-crypto/cryptonite/issues/360 cryptonite = appendPatch ./patches/cryptonite-remove-argon2.patch super.cryptonite; + # Build segfaults unless `fixity-th` is disabled. + # https://github.com/tweag/ormolu/issues/927 + ormolu_0_5_0_1 = overrideCabal (drv: { + libraryHaskellDepends = drv.libraryHaskellDepends ++ [ self.file-embed ]; + }) (disableCabalFlag "fixity-th" super.ormolu_0_5_0_1); + fourmolu_0_8_2_0 = overrideCabal (drv: { + libraryHaskellDepends = drv.libraryHaskellDepends ++ [ self.file-embed ]; + }) (disableCabalFlag "fixity-th" super.fourmolu_0_8_2_0); + } // lib.optionalAttrs pkgs.stdenv.isx86_64 { # x86_64-darwin # tests appear to be failing to link or something: From 0492580befa44c58e63c36d48ea99049c996d6f7 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Wed, 19 Oct 2022 19:00:39 +0200 Subject: [PATCH 18/37] python310Packages.clize: remove postPatch - disable on older Python releases --- .../python-modules/clize/default.nix | 38 +++++++------------ 1 file changed, 13 insertions(+), 25 deletions(-) diff --git a/pkgs/development/python-modules/clize/default.nix b/pkgs/development/python-modules/clize/default.nix index 003b78bbe229..c4e87fffe4da 100644 --- a/pkgs/development/python-modules/clize/default.nix +++ b/pkgs/development/python-modules/clize/default.nix @@ -1,24 +1,15 @@ { lib -, buildPythonPackage -, fetchPypi - -# build -, setuptools - -# propagtes -, sigtools -, six , attrs -, od +, buildPythonPackage , docutils - -# extras: datetime -, python-dateutil - -# tests +, fetchPypi +, od , pygments -, unittest2 , pytestCheckHook +, python-dateutil +, setuptools +, sigtools +, unittest2 }: buildPythonPackage rec { @@ -26,17 +17,13 @@ buildPythonPackage rec { version = "5.0.0"; format = "pyproject"; + disabled = pythonOlder "3.7"; + src = fetchPypi { inherit pname version; - sha256 = "sha256-/cFpEvAN/Movd38xaE53Y+D9EYg/SFyHeqtlVUo1D0I="; + hash = "sha256-/cFpEvAN/Movd38xaE53Y+D9EYg/SFyHeqtlVUo1D0I="; }; - postPatch = '' - substituteInPlace setup.py \ - --replace "docutils ~= 0.17.0" "docutils" \ - --replace "attrs>=19.1.0,<22" "attrs>=19.1.0" - ''; - nativeBuildInputs = [ setuptools ]; @@ -46,7 +33,6 @@ buildPythonPackage rec { docutils od sigtools - six ]; passthru.optional-dependencies = { @@ -65,7 +51,9 @@ buildPythonPackage rec { unittest2 ]; - pythonImportsCheck = [ "clize" ]; + pythonImportsCheck = [ + "clize" + ]; meta = with lib; { description = "Command-line argument parsing for Python"; From c44448888c840de947d19f33839c13f8ffc508d6 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Wed, 19 Oct 2022 19:03:38 +0200 Subject: [PATCH 19/37] python310Packages.clize: add missing input --- pkgs/development/python-modules/clize/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/development/python-modules/clize/default.nix b/pkgs/development/python-modules/clize/default.nix index c4e87fffe4da..a78b55704aec 100644 --- a/pkgs/development/python-modules/clize/default.nix +++ b/pkgs/development/python-modules/clize/default.nix @@ -6,6 +6,7 @@ , od , pygments , pytestCheckHook +, pythonOlder , python-dateutil , setuptools , sigtools From a3995cc70206cc6fce6687e4b34fd298141f420c Mon Sep 17 00:00:00 2001 From: "R. Ryantm" Date: Wed, 19 Oct 2022 17:09:43 +0000 Subject: [PATCH 20/37] python310Packages.fastbencode: 0.0.13 -> 0.0.15 --- pkgs/development/python-modules/fastbencode/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/fastbencode/default.nix b/pkgs/development/python-modules/fastbencode/default.nix index 0e91f5aaf248..039418dc3bc2 100644 --- a/pkgs/development/python-modules/fastbencode/default.nix +++ b/pkgs/development/python-modules/fastbencode/default.nix @@ -8,14 +8,14 @@ buildPythonPackage rec { pname = "fastbencode"; - version = "0.0.13"; + version = "0.0.15"; format = "setuptools"; disabled = pythonOlder "3.7"; src = fetchPypi { inherit pname version; - hash = "sha256-jwAXWJwrybcV6CrDBlsKY/KL3xdTw016pJUZnAXmxsk="; + hash = "sha256-A1XfgjNV9k4iA3HYf0HlA1CvpwzFh52OaN7f6YLgU+I="; }; nativeBuildInputs = [ From 290d7b281960b1ff4ba5b63302978b5b75b097e6 Mon Sep 17 00:00:00 2001 From: Skyler Grey Date: Tue, 18 Oct 2022 17:55:33 +0100 Subject: [PATCH 21/37] prismlauncher: init at 5.0 --- pkgs/games/prismlauncher/default.nix | 94 ++++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 96 insertions(+) create mode 100644 pkgs/games/prismlauncher/default.nix diff --git a/pkgs/games/prismlauncher/default.nix b/pkgs/games/prismlauncher/default.nix new file mode 100644 index 000000000000..a7797861f30a --- /dev/null +++ b/pkgs/games/prismlauncher/default.nix @@ -0,0 +1,94 @@ +{ lib +, stdenv +, fetchFromGitHub +, cmake +, jdk8 +, jdk +, zlib +, file +, wrapQtAppsHook +, xorg +, libpulseaudio +, qtbase +, libGL +, quazip +, glfw +, openal +, extra-cmake-modules +, tomlplusplus +, ghc_filesystem +, msaClientID ? "" +, jdks ? [ jdk jdk8 ] +, +}: +let + libnbtplusplus = fetchFromGitHub { + owner = "PrismLauncher"; + repo = "libnbtplusplus"; + rev = "2203af7eeb48c45398139b583615134efd8d407f"; + sha256 = "sha256-TvVOjkUobYJD9itQYueELJX3wmecvEdCbJ0FinW2mL4="; + }; +in +stdenv.mkDerivation rec { + pname = "prismlauncher"; + version = "5.0"; + + src = fetchFromGitHub { + owner = "PrismLauncher"; + repo = "PrismLauncher"; + rev = version; + sha256 = "sha256-oN+DpJ08N/ar5wLAahgpBV9DeHtMTwSrE7uOwT3A+Yo="; + }; + + nativeBuildInputs = [ extra-cmake-modules ghc_filesystem cmake file jdk wrapQtAppsHook ]; + buildInputs = [ qtbase zlib quazip tomlplusplus ]; + + cmakeFlags = lib.optionals (msaClientID != "") [ "-DLauncher_MSA_CLIENT_ID=${msaClientID}" ]; + dontWrapQtApps = true; + + postUnpack = '' + rm -rf source/libraries/libnbtplusplus + mkdir source/libraries/libnbtplusplus + ln -s ${libnbtplusplus}/* source/libraries/libnbtplusplus + chmod -R +r+w source/libraries/libnbtplusplus + chown -R $USER: source/libraries/libnbtplusplus + ''; + + postInstall = + let + libpath = with xorg; + lib.makeLibraryPath [ + libX11 + libXext + libXcursor + libXrandr + libXxf86vm + libpulseaudio + libGL + glfw + openal + stdenv.cc.cc.lib + ]; + in + '' + # xorg.xrandr needed for LWJGL [2.9.2, 3) https://github.com/LWJGL/lwjgl/issues/128 + wrapQtApp $out/bin/prismlauncher \ + --set LD_LIBRARY_PATH /run/opengl-driver/lib:${libpath} \ + --prefix PRISMLAUNCHER_JAVA_PATHS : ${lib.makeSearchPath "bin/java" jdks} \ + --prefix PATH : ${lib.makeBinPath [xorg.xrandr]} + ''; + + meta = with lib; { + homepage = "https://prismlauncher.org/"; + description = "A free, open source launcher for Minecraft"; + longDescription = '' + Allows you to have multiple, separate instances of Minecraft (each with + their own mods, texture packs, saves, etc) and helps you manage them and + their associated options with a simple interface. + ''; + platforms = platforms.linux; + changelog = "https://github.com/PrismLauncher/PrismLauncher/releases/tag/${version}"; + license = licenses.gpl3Only; + maintainers = with maintainers; [ minion3665 Scrumplex ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 5697ccd85cd7..f6aa49b0c48e 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -34190,6 +34190,8 @@ with pkgs; polymc = libsForQt5.callPackage ../games/polymc { }; + prismlauncher = libsForQt5.callPackage ../games/prismlauncher { }; + pong3d = callPackage ../games/pong3d { }; pokerth = libsForQt5.callPackage ../games/pokerth { From 879c2dffe14d82e5bd6b9e0fdcd7cba0d1ddffa0 Mon Sep 17 00:00:00 2001 From: Skyler Grey Date: Tue, 18 Oct 2022 18:01:51 +0100 Subject: [PATCH 22/37] polymc: remove - As polymc has been hostily taken over, prismlauncher (the fork) should be used instead - The previous commit packages prismlauncher, this commit makes it so that installing polymc will give an error message --- pkgs/games/polymc/default.nix | 76 --------------------------------- pkgs/top-level/aliases.nix | 3 +- pkgs/top-level/all-packages.nix | 2 - 3 files changed, 2 insertions(+), 79 deletions(-) delete mode 100644 pkgs/games/polymc/default.nix diff --git a/pkgs/games/polymc/default.nix b/pkgs/games/polymc/default.nix deleted file mode 100644 index 53c1647aa990..000000000000 --- a/pkgs/games/polymc/default.nix +++ /dev/null @@ -1,76 +0,0 @@ -{ lib -, stdenv -, fetchFromGitHub -, cmake -, jdk8 -, jdk -, zlib -, file -, wrapQtAppsHook -, xorg -, libpulseaudio -, qtbase -, libGL -, quazip -, glfw -, openal -, msaClientID ? "" -, jdks ? [ jdk jdk8 ] -, extra-cmake-modules -}: - -stdenv.mkDerivation rec { - pname = "polymc"; - version = "1.4.2"; - - src = fetchFromGitHub { - owner = "PolyMC"; - repo = "PolyMC"; - rev = version; - sha256 = "sha256-mqLk7ZcSrtvlUziNUCtnH7xQplXBruuiuN2b1+VX1ng="; - fetchSubmodules = true; - }; - - nativeBuildInputs = [ extra-cmake-modules cmake file jdk wrapQtAppsHook ]; - buildInputs = [ qtbase zlib quazip ]; - - cmakeFlags = lib.optionals (msaClientID != "") [ "-DLauncher_MSA_CLIENT_ID=${msaClientID}" ]; - - dontWrapQtApps = true; - - postInstall = let - libpath = with xorg; lib.makeLibraryPath [ - libX11 - libXext - libXcursor - libXrandr - libXxf86vm - libpulseaudio - libGL - glfw - openal - stdenv.cc.cc.lib - ]; - in '' - # xorg.xrandr needed for LWJGL [2.9.2, 3) https://github.com/LWJGL/lwjgl/issues/128 - wrapQtApp $out/bin/polymc \ - --set LD_LIBRARY_PATH /run/opengl-driver/lib:${libpath} \ - --prefix POLYMC_JAVA_PATHS : ${lib.makeSearchPath "bin/java" jdks} \ - --prefix PATH : ${lib.makeBinPath [ xorg.xrandr ]} - ''; - - meta = with lib; { - homepage = "https://polymc.org/"; - description = "A free, open source launcher for Minecraft"; - longDescription = '' - Allows you to have multiple, separate instances of Minecraft (each with - their own mods, texture packs, saves, etc) and helps you manage them and - their associated options with a simple interface. - ''; - platforms = platforms.linux; - changelog = "https://github.com/PolyMC/PolyMC/releases/tag/${version}"; - license = licenses.gpl3Only; - maintainers = with maintainers; [ cleverca22 starcraft66 ]; - knownVulnerabilities = [ "OVE-20221017-0001" ]; - }; -} diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix index 3be29c104b19..7788125d5b06 100644 --- a/pkgs/top-level/aliases.nix +++ b/pkgs/top-level/aliases.nix @@ -930,7 +930,7 @@ mapAliases ({ mpich2 = throw "'mpich2' has been renamed to/replaced by 'mpich'"; # Converted to throw 2022-02-22 mqtt-bench = throw "mqtt-bench has been dropped due to the lack of maintenance from upstream since 2017"; # Added 2022-06-02 msf = throw "'msf' has been renamed to/replaced by 'metasploit'"; # Converted to throw 2022-02-22 - multimc = throw "multimc was removed from nixpkgs; use polymc instead (see https://github.com/NixOS/nixpkgs/pull/154051 for more information)"; # Added 2022-01-08 + multimc = throw "multimc was removed from nixpkgs; use prismlauncher instead (see https://github.com/NixOS/nixpkgs/pull/154051 for more information)"; # Added 2022-01-08 mumble_git = pkgs.mumble; # Added 2019-08-01 murmur_git = pkgs.murmur; # Added 2019-08-01 mutt-with-sidebar = mutt; # Added 2022-09-17 @@ -1147,6 +1147,7 @@ mapAliases ({ pmtools = throw "'pmtools' has been renamed to/replaced by 'acpica-tools'"; # Converted to throw 2022-02-22 pocketsphinx = throw "pocketsphinx has been removed: unmaintained"; # Added 2022-04-24 polarssl = throw "'polarssl' has been renamed to/replaced by 'mbedtls'"; # Converted to throw 2022-02-22 + polymc = throw "PolyMC has been removed from nixpkgs due to a hostile takeover by a rogue maintainer. The rest of the maintainers have made a fork which is packaged as 'prismlauncher'"; # Added 2022-10-18 polysh = throw "polysh has been removed from nixpkgs as the upstream has abandoned the project"; # Added 2022-01-01 pond = throw "pond has been dropped due to the lack of maintanence from upstream since 2016"; # Added 2022-06-02 poppler_qt5 = throw "'poppler_qt5' has been renamed to/replaced by 'libsForQt5.poppler'"; # Converted to throw 2022-02-22 diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index f6aa49b0c48e..600a81e9f6d6 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -34188,8 +34188,6 @@ with pkgs; planetary_annihilation = callPackage ../games/planetaryannihilation { }; - polymc = libsForQt5.callPackage ../games/polymc { }; - prismlauncher = libsForQt5.callPackage ../games/prismlauncher { }; pong3d = callPackage ../games/pong3d { }; From fcbbc69f132e4de3577c8f5114d0d841c55bcfcd Mon Sep 17 00:00:00 2001 From: Skyler Grey Date: Tue, 18 Oct 2022 18:27:51 +0100 Subject: [PATCH 23/37] release-notes-2205: suggest using prismlauncher - Previously PolyMC was the suggested replacement for MultiMC - As PolyMC is marked as insecure and prismlauncher is a replacement, this commit suggests using it instead --- .../from_md/release-notes/rl-2205.section.xml | 20 +++++++++---------- .../manual/release-notes/rl-2205.section.md | 10 +++++++++- 2 files changed, 19 insertions(+), 11 deletions(-) diff --git a/nixos/doc/manual/from_md/release-notes/rl-2205.section.xml b/nixos/doc/manual/from_md/release-notes/rl-2205.section.xml index 02201861234b..6f06838833eb 100644 --- a/nixos/doc/manual/from_md/release-notes/rl-2205.section.xml +++ b/nixos/doc/manual/from_md/release-notes/rl-2205.section.xml @@ -1501,18 +1501,18 @@ - MultiMC has been replaced with the fork PolyMC due to upstream - developers being hostile to 3rd party package maintainers. - PolyMC removes all MultiMC branding and is aimed at providing - proper 3rd party packages like the one contained in Nixpkgs. - This change affects the data folder where game instances and - other save and configuration files are stored. Users with - existing installations should rename + MultiMC has been replaced with the fork PrismLauncher due to + upstream developers being hostile to 3rd party package + maintainers. PrismLauncher removes all MultiMC branding and is + aimed at providing proper 3rd party packages like the one + contained in Nixpkgs. This change affects the data folder + where game instances and other save and configuration files + are stored. Users with existing installations should rename ~/.local/share/multimc to - ~/.local/share/polymc. The main config - file’s path has also moved from + ~/.local/share/PrismLauncher. The main + config file’s path has also moved from ~/.local/share/multimc/multimc.cfg to - ~/.local/share/polymc/polymc.cfg. + ~/.local/share/PrismLauncher/prismlauncher.cfg. diff --git a/nixos/doc/manual/release-notes/rl-2205.section.md b/nixos/doc/manual/release-notes/rl-2205.section.md index 2d2140d92d59..6fe5eba212f3 100644 --- a/nixos/doc/manual/release-notes/rl-2205.section.md +++ b/nixos/doc/manual/release-notes/rl-2205.section.md @@ -581,7 +581,15 @@ In addition to numerous new and upgraded packages, this release has the followin - The `miller` package has been upgraded from 5.10.3 to [6.2.0](https://github.com/johnkerl/miller/releases/tag/v6.2.0). See [What's new in Miller 6](https://miller.readthedocs.io/en/latest/new-in-miller-6). -- MultiMC has been replaced with the fork PolyMC due to upstream developers being hostile to 3rd party package maintainers. PolyMC removes all MultiMC branding and is aimed at providing proper 3rd party packages like the one contained in Nixpkgs. This change affects the data folder where game instances and other save and configuration files are stored. Users with existing installations should rename `~/.local/share/multimc` to `~/.local/share/polymc`. The main config file's path has also moved from `~/.local/share/multimc/multimc.cfg` to `~/.local/share/polymc/polymc.cfg`. +- MultiMC has been replaced with the fork PrismLauncher due to upstream + developers being hostile to 3rd party package maintainers. PrismLauncher + removes all MultiMC branding and is aimed at providing proper 3rd party + packages like the one contained in Nixpkgs. This change affects the data + folder where game instances and other save and configuration files are stored. + Users with existing installations should rename `~/.local/share/multimc` to + `~/.local/share/PrismLauncher`. The main config file's path has also moved + from `~/.local/share/multimc/multimc.cfg` to + `~/.local/share/PrismLauncher/prismlauncher.cfg`. - `systemd-nspawn@.service` settings have been reverted to the default systemd behaviour. User namespaces are now activated by default. If you want to keep running nspawn containers without user namespaces you need to set `systemd.nspawn..execConfig.PrivateUsers = false` From 49c81f001cf25561e512f0f0ba7c2bd81dd3a018 Mon Sep 17 00:00:00 2001 From: Skyler Grey Date: Wed, 19 Oct 2022 19:00:52 +0100 Subject: [PATCH 24/37] release-notes: state that PolyMC has been replaced --- .../from_md/release-notes/rl-2211.section.xml | 18 ++++++++++++++++++ .../manual/release-notes/rl-2211.section.md | 10 ++++++++++ 2 files changed, 28 insertions(+) diff --git a/nixos/doc/manual/from_md/release-notes/rl-2211.section.xml b/nixos/doc/manual/from_md/release-notes/rl-2211.section.xml index da8bf17c0ccf..f2ba93797222 100644 --- a/nixos/doc/manual/from_md/release-notes/rl-2211.section.xml +++ b/nixos/doc/manual/from_md/release-notes/rl-2211.section.xml @@ -38,6 +38,24 @@ stdenv.buildPlatform.canExecute stdenv.hostPlatform. + + + The polymc package has been removed due to + a rogue maintainer. It has been replaced by + prismlauncher, a fork by the rest of the + maintainers. For more details, see + the + pull request that made this change and + this + issue detailing the vulnerability. Users with existing + installations should rename + ~/.local/share/polymc to + ~/.local/share/PrismLauncher. The main + config file’s path has also moved from + ~/.local/share/polymc/polymc.cfg to + ~/.local/share/PrismLauncher/prismlauncher.cfg. + + The nixpkgs.hostPlatform and diff --git a/nixos/doc/manual/release-notes/rl-2211.section.md b/nixos/doc/manual/release-notes/rl-2211.section.md index 68b46a7e45ab..797d4492ae5a 100644 --- a/nixos/doc/manual/release-notes/rl-2211.section.md +++ b/nixos/doc/manual/release-notes/rl-2211.section.md @@ -20,6 +20,16 @@ In addition to numerous new and upgraded packages, this release has the followin built for `stdenv.hostPlatform` (i.e. produced by `stdenv.cc`) by evaluating `stdenv.buildPlatform.canExecute stdenv.hostPlatform`. +- The `polymc` package has been removed due to a rogue maintainer. It has been + replaced by `prismlauncher`, a fork by the rest of the maintainers. For more + details, see [the pull request that made this + change](https://github.com/NixOS/nixpkgs/pull/196624) and [this issue + detailing the vulnerability](https://github.com/NixOS/nixpkgs/issues/196460). + Users with existing installations should rename `~/.local/share/polymc` to + `~/.local/share/PrismLauncher`. The main config file's path has also moved + from `~/.local/share/polymc/polymc.cfg` to + `~/.local/share/PrismLauncher/prismlauncher.cfg`. + - The `nixpkgs.hostPlatform` and `nixpkgs.buildPlatform` options have been added. These cover and override the `nixpkgs.{system,localSystem,crossSystem}` options. From 5e838fa9ac7e635410de2cfbeb03d336db7e6347 Mon Sep 17 00:00:00 2001 From: Nick Cao Date: Sat, 13 Aug 2022 20:48:51 +0800 Subject: [PATCH 25/37] netplan: fix cross compilation by replacing hardcoded pkg-config with $(PKG_CONFIG) --- pkgs/tools/admin/netplan/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/tools/admin/netplan/default.nix b/pkgs/tools/admin/netplan/default.nix index 39cffeaf2020..1c075fc75b3b 100644 --- a/pkgs/tools/admin/netplan/default.nix +++ b/pkgs/tools/admin/netplan/default.nix @@ -45,7 +45,8 @@ stdenv.mkDerivation rec { substituteInPlace Makefile \ --replace 'SYSTEMD_GENERATOR_DIR=' 'SYSTEMD_GENERATOR_DIR ?= ' \ --replace 'SYSTEMD_UNIT_DIR=' 'SYSTEMD_UNIT_DIR ?= ' \ - --replace 'BASH_COMPLETIONS_DIR=' 'BASH_COMPLETIONS_DIR ?= ' + --replace 'BASH_COMPLETIONS_DIR=' 'BASH_COMPLETIONS_DIR ?= ' \ + --replace 'pkg-config' '$(PKG_CONFIG)' # from upstream https://github.com/canonical/netplan/blob/ee0d5df7b1dfbc3197865f02c724204b955e0e58/rpm/netplan.spec#L81 sed -e "s/-Werror//g" -i Makefile From ac92b409b36f75fc2772c3333346174cb42d5352 Mon Sep 17 00:00:00 2001 From: Adam Joseph Date: Mon, 11 Jul 2022 13:37:49 -0700 Subject: [PATCH 26/37] boost: if isMips use the "cross compile" codepath unconditionally boost-context changed its name for mips from "mips1" to "mips" in this commit: https://github.com/boostorg/context/commit/6edc8184a7136de4603a6f903d9b9b864ca9cf57 however the native-build code to detect the local architecture still reports "mips1": https://github.com/boostorg/boost/blob/67c074b249538cf441724f9bbb3929d0f6b4f333/boostcpp.jam#L637 Therefore native builds of boost-context on mips must specify architecture= explicitly; without this you will get link failures "undefined reference to `jump_fcontext`" in code that uses boost-context. Currently the "cross compile" codepath, which provides explicit architecture/abi/address-model/binary-format/os parameters, is prefixed by this comment: ``` # TODO: make this unconditional ``` This commit does so, at least if `isMips`. This commit is needed in order for native builds of nix to succeed on mips. --- pkgs/development/libraries/boost/generic.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkgs/development/libraries/boost/generic.nix b/pkgs/development/libraries/boost/generic.nix index 1644adb175db..4115d11eeb83 100644 --- a/pkgs/development/libraries/boost/generic.nix +++ b/pkgs/development/libraries/boost/generic.nix @@ -81,7 +81,9 @@ let "-sEXPAT_LIBPATH=${expat.out}/lib" # TODO: make this unconditional - ] ++ optionals (stdenv.hostPlatform != stdenv.buildPlatform) [ + ] ++ optionals (stdenv.hostPlatform != stdenv.buildPlatform || + # required; see this line's `git blame` for an explanation + (stdenv.hostPlatform.isMips && versionAtLeast version "1.79")) [ "address-model=${toString stdenv.hostPlatform.parsed.cpu.bits}" "architecture=${if stdenv.hostPlatform.isMips64 then if versionOlder version "1.78" then "mips1" else "mips" From 2df2b52806129828a1dafaa093027f10817e5b3b Mon Sep 17 00:00:00 2001 From: Adam Joseph Date: Sun, 21 Aug 2022 15:23:54 -0700 Subject: [PATCH 27/37] boost/generic.nix: reference commit-hash in comment The explanation for the conditional introduced by 61d9f201baeef4c4bb91ad8a8f5f89b747e0dfe4 is longer than a reasonable inline comment should be. It directed the reader to use `git blame`, but that tends to bitrot. Let's point the user to a specific nixpkgs git hash. This commit cannot be squashed into the previous commit, because a commit cannot mention its own commit-hash (without performaing an expensive double-sha1 preimage attack, of course). --- pkgs/development/libraries/boost/generic.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/libraries/boost/generic.nix b/pkgs/development/libraries/boost/generic.nix index 4115d11eeb83..d4e74b5788a7 100644 --- a/pkgs/development/libraries/boost/generic.nix +++ b/pkgs/development/libraries/boost/generic.nix @@ -82,7 +82,7 @@ let # TODO: make this unconditional ] ++ optionals (stdenv.hostPlatform != stdenv.buildPlatform || - # required; see this line's `git blame` for an explanation + # required on mips; see 61d9f201baeef4c4bb91ad8a8f5f89b747e0dfe4 (stdenv.hostPlatform.isMips && versionAtLeast version "1.79")) [ "address-model=${toString stdenv.hostPlatform.parsed.cpu.bits}" "architecture=${if stdenv.hostPlatform.isMips64 From bf3412c2c91a19d4d49e8887260c8cfb2bee9cb0 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Wed, 19 Oct 2022 21:08:02 +0200 Subject: [PATCH 28/37] python310Packages.nbclassic: fix input name --- pkgs/development/python-modules/nbclassic/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/nbclassic/default.nix b/pkgs/development/python-modules/nbclassic/default.nix index 504173ba66ab..4c2007d8e376 100644 --- a/pkgs/development/python-modules/nbclassic/default.nix +++ b/pkgs/development/python-modules/nbclassic/default.nix @@ -5,7 +5,7 @@ , ipykernel , ipython_genutils , jinja2 -, jupyter_client +, jupyter-client , jupyter_core , jupyter_server , nbconvert @@ -41,7 +41,7 @@ buildPythonPackage rec { ipykernel ipython_genutils jinja2 - jupyter_client + jupyter-client jupyter_core jupyter_server nbconvert From 6b5ef0729f743910b9cce1d3a28ceb03bdbd7886 Mon Sep 17 00:00:00 2001 From: "R. Ryantm" Date: Wed, 19 Oct 2022 19:14:23 +0000 Subject: [PATCH 29/37] oh-my-posh: 12.3.3 -> 12.6.1 --- pkgs/development/tools/oh-my-posh/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/tools/oh-my-posh/default.nix b/pkgs/development/tools/oh-my-posh/default.nix index 43faf4cec9a8..e2561214bd4c 100644 --- a/pkgs/development/tools/oh-my-posh/default.nix +++ b/pkgs/development/tools/oh-my-posh/default.nix @@ -2,13 +2,13 @@ buildGoModule rec { pname = "oh-my-posh"; - version = "12.3.3"; + version = "12.6.1"; src = fetchFromGitHub { owner = "jandedobbeleer"; repo = pname; rev = "v${version}"; - sha256 = "sha256-XhlBBHGndvZQEixYWqS/eBB/l7+l0+V63TeIKkVWreI="; + sha256 = "sha256-09MLV6t062fT3P7G1pgJedzLLLuXoP+I/95WadMYLSw="; }; vendorSha256 = "sha256-OrtKFkWXqVoXKmN6BT8YbCNjR1gRTT4gPNwmirn7fjU="; From 2122fc67adcf7977aca7c60fbb2cd3313ceed1be Mon Sep 17 00:00:00 2001 From: Mohammad Kefah Date: Wed, 19 Oct 2022 23:26:29 +0300 Subject: [PATCH 30/37] circumflex: init at 2.6 --- .../networking/circumflex/default.nix | 29 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 31 insertions(+) create mode 100644 pkgs/applications/networking/circumflex/default.nix diff --git a/pkgs/applications/networking/circumflex/default.nix b/pkgs/applications/networking/circumflex/default.nix new file mode 100644 index 000000000000..da6f224b8d9e --- /dev/null +++ b/pkgs/applications/networking/circumflex/default.nix @@ -0,0 +1,29 @@ +{ lib, less, ncurses, buildGoModule, fetchFromGitHub, makeWrapper }: + +buildGoModule rec { + pname = "circumflex"; + version = "2.6"; + + src = fetchFromGitHub { + owner = "bensadeh"; + repo = "circumflex"; + rev = version; + hash = "sha256-pcY2PXiOazKAi8mAAbmftXDae01fcUw/u9JPOHQVclI="; + }; + + vendorHash = "sha256-rF1Hu4Pf9AF2MTx4GAPmzSn0M38uTxPS1bsAkO23SdI="; + + nativeBuildInputs = [ makeWrapper ]; + + postInstall = '' + wrapProgram $out/bin/clx \ + --prefix PATH : ${lib.makeBinPath [ less ncurses ]} + ''; + + meta = with lib; { + description = "A command line tool for browsing Hacker News in your terminal"; + homepage = "https://github.com/bensadeh/circumflex"; + license = licenses.agpl3; + mainProgram = "clx"; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index c7b61d7112f4..a5a2aa579f9a 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -322,6 +322,8 @@ with pkgs; cfn-nag = callPackage ../development/tools/cfn-nag { }; + circumflex = callPackage ../applications/networking/circumflex { }; + cxx-rs = callPackage ../development/libraries/cxx-rs { }; elfcat = callPackage ../tools/misc/elfcat { }; From fba19d0290ca8a17fc595fbc4eb15d947a171931 Mon Sep 17 00:00:00 2001 From: Mohammad Kefah Date: Wed, 19 Oct 2022 23:27:04 +0300 Subject: [PATCH 31/37] maintainers: add mktip --- maintainers/maintainer-list.nix | 9 +++++++++ pkgs/applications/networking/circumflex/default.nix | 1 + 2 files changed, 10 insertions(+) diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix index ff6715ec849f..186d4906e3ec 100644 --- a/maintainers/maintainer-list.nix +++ b/maintainers/maintainer-list.nix @@ -9066,6 +9066,15 @@ fingerprint = "E90C BA34 55B3 6236 740C 038F 0D94 8CE1 9CF4 9C5F"; }]; }; + mktip = { + email = "mo.issa.ok+nix@gmail.com"; + github = "mktip"; + githubId = 45905717; + name = "Mohammad Issa"; + keys = [{ + fingerprint = "64BE BF11 96C3 DD7A 443E 8314 1DC0 82FA DE5B A863"; + }]; + }; mlieberman85 = { email = "mlieberman85@gmail.com"; github = "mlieberman85"; diff --git a/pkgs/applications/networking/circumflex/default.nix b/pkgs/applications/networking/circumflex/default.nix index da6f224b8d9e..71fe5b97b8bf 100644 --- a/pkgs/applications/networking/circumflex/default.nix +++ b/pkgs/applications/networking/circumflex/default.nix @@ -24,6 +24,7 @@ buildGoModule rec { description = "A command line tool for browsing Hacker News in your terminal"; homepage = "https://github.com/bensadeh/circumflex"; license = licenses.agpl3; + maintainers = with maintainers; [ mktip ]; mainProgram = "clx"; }; } From ecc04fdd85e632809ccdd89825677afecc388b5d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Wed, 19 Oct 2022 22:28:49 +0200 Subject: [PATCH 32/37] yq-go: 4.28.1 -> 4.28.2 --- pkgs/development/tools/yq-go/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/tools/yq-go/default.nix b/pkgs/development/tools/yq-go/default.nix index b3e4d97de7a4..795147640ab1 100644 --- a/pkgs/development/tools/yq-go/default.nix +++ b/pkgs/development/tools/yq-go/default.nix @@ -2,16 +2,16 @@ buildGoModule rec { pname = "yq-go"; - version = "4.28.1"; + version = "4.28.2"; src = fetchFromGitHub { owner = "mikefarah"; repo = "yq"; rev = "v${version}"; - sha256 = "sha256-GWEsS5RTwz0VVLRAvHPJk0BPo50RB0CeyIS6fne9GoU="; + sha256 = "sha256-wLb7M/M/t6CCpjTyhMMDODaQUp1t6gbQaCY+JPBi/4Q="; }; - vendorSha256 = "sha256-4J/Qz5JN8UUdwa3/Io2/o4Y01eFK9zOcNAZkndzI178="; + vendorSha256 = "sha256-5GHkl9bwzf0ZUQXjhDPke4Fm7ffH+GqbTXC1Qd71B7M="; nativeBuildInputs = [ installShellFiles ]; From 55708226401904b76c6b5d0c9b819d4b1d0a3e37 Mon Sep 17 00:00:00 2001 From: "R. Ryantm" Date: Wed, 19 Oct 2022 20:43:03 +0000 Subject: [PATCH 33/37] python310Packages.gdown: 4.5.2 -> 4.5.3 --- pkgs/development/python-modules/gdown/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/gdown/default.nix b/pkgs/development/python-modules/gdown/default.nix index f50fbc7ed473..91154649c1a7 100644 --- a/pkgs/development/python-modules/gdown/default.nix +++ b/pkgs/development/python-modules/gdown/default.nix @@ -12,14 +12,14 @@ buildPythonApplication rec { pname = "gdown"; - version = "4.5.2"; + version = "4.5.3"; format = "setuptools"; disabled = pythonOlder "3.7"; src = fetchPypi { inherit pname version; - hash = "sha256-YhYzlsBJegYXOnuV/IH0feIXl//EY79GFskHmSZsYcM="; + hash = "sha256-bL991BCFiMc0qliBMdjh1S5k8Ic4cPcfdMusGV8MYO8="; }; propagatedBuildInputs = [ From 24c428a583ed596aafbd69c3a48ce5009246433b Mon Sep 17 00:00:00 2001 From: OPNA2608 Date: Wed, 28 Sep 2022 19:23:12 +0200 Subject: [PATCH 34/37] mac-fdisk: init at 0.1.16 --- pkgs/tools/system/mac-fdisk/default.nix | 112 ++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 114 insertions(+) create mode 100644 pkgs/tools/system/mac-fdisk/default.nix diff --git a/pkgs/tools/system/mac-fdisk/default.nix b/pkgs/tools/system/mac-fdisk/default.nix new file mode 100644 index 000000000000..292b77d2d2cf --- /dev/null +++ b/pkgs/tools/system/mac-fdisk/default.nix @@ -0,0 +1,112 @@ +{ stdenv +, lib +, fetchzip +, fetchpatch +, installShellFiles +}: + +stdenv.mkDerivation rec { + pname = "mac-fdisk"; + version = "0.1.16"; + + src = fetchzip { + url = "https://deb.debian.org/debian/pool/main/m/mac-fdisk/mac-fdisk_0.1.orig.tar.gz"; + sha256 = "sha256-pYNyhPvRKdIje0Rpay0OzmrkGcl+/JOhMv7r+2LZk/Q="; + }; + + patches = [ + # Debian's changeset, extracted into a patch + (fetchpatch { + url = "https://git.adelielinux.org/adelie/packages/-/raw/1b708c8a90e3548c4954c6367a9376f76f3746bd/user/mac-fdisk/mac-fdisk-0.1-debian.patch"; + sha256 = "sha256-a9pGF+UsFeZiXgracmT4anqgpmcGcS/W3jGtFzHZtt4="; + }) + # Include a lot more headers and remove a bunch of braindead __linux__ checks + (fetchpatch { + url = "https://git.adelielinux.org/adelie/packages/-/raw/1fa4c88ee21866eeb0feae8f6b0bf609a04711cc/user/mac-fdisk/mac-fdisk-0.1-headers.patch"; + sha256 = "sha256-FIk9K+lP+3e1pgmNfymTdpdSoTpBDv29kmwYgqYwWQw="; + }) + # Add support for more architectures + (fetchpatch { + url = "https://git.adelielinux.org/adelie/packages/-/raw/1b708c8a90e3548c4954c6367a9376f76f3746bd/user/mac-fdisk/mac-fdisk-0.1-more-arches.patch"; + sha256 = "sha256-HNRmzETUmKfZQFrjg6Y/HPwUnLk0vO5DokfU4umdOm0="; + }) + # From p16 (source?), adjusts some types & fixes PPC64 support + (fetchpatch { + url = "https://git.adelielinux.org/adelie/packages/-/raw/1fa4c88ee21866eeb0feae8f6b0bf609a04711cc/user/mac-fdisk/mac-fdisk-0.1_p16-ppc64.patch"; + sha256 = "sha256-GK0nfga59nOXotkbKI+2ejA9TtyZUwDIxuXWFGGbeFg="; + }) + # From p16 (source?), makes some inlines static + (fetchpatch { + url = "https://git.adelielinux.org/adelie/packages/-/raw/1fa4c88ee21866eeb0feae8f6b0bf609a04711cc/user/mac-fdisk/mac-fdisk-0.1_p16-proper-inline.patch"; + sha256 = "sha256-wr2teKpm0FyqNudKYlTD49pTFDis33Fo+0LULNYIJko="; + }) + # Adds x86_64 support + (fetchpatch { + url = "https://git.adelielinux.org/adelie/packages/-/raw/1b708c8a90e3548c4954c6367a9376f76f3746bd/user/mac-fdisk/mac-fdisk-amd64.patch"; + sha256 = "sha256-iO4/sY5sGKQyymMmAOb/TlCc9id2qgEDw7E8pFZpsHI="; + }) + # Fix missing header in fdisk.c on musl + (fetchpatch { + url = "https://git.adelielinux.org/adelie/packages/-/raw/1fa4c88ee21866eeb0feae8f6b0bf609a04711cc/user/mac-fdisk/mac-fdisk-fdisk-header-musl.patch"; + sha256 = "sha256-mKBVjvLKtxKPADeoPqp17YdJ1QWj2enAYhKKSqTnQ44="; + }) + # Support disks >550GB + (fetchpatch { + url = "https://git.adelielinux.org/adelie/packages/-/raw/1fa4c88ee21866eeb0feae8f6b0bf609a04711cc/user/mac-fdisk/mac-fdisk-large-disk-support.patch"; + sha256 = "sha256-IXZZdozqZKyZEz87ZzB8Jof22GgvHf4GaXBqSKn8su8="; + }) + # Enable Large File Support (>2GiB) + (fetchpatch { + url = "https://git.adelielinux.org/adelie/packages/-/raw/1fa4c88ee21866eeb0feae8f6b0bf609a04711cc/user/mac-fdisk/mac-fdisk-largerthan2gb.patch"; + sha256 = "sha256-ATK7QYXV7BOk8iIFeXY8g+ZHLuuhww9pcrqOMDn/oLM="; + }) + # Fix compilation on non-glibc + (fetchpatch { + url = "https://git.adelielinux.org/adelie/packages/-/raw/1fa4c88ee21866eeb0feae8f6b0bf609a04711cc/user/mac-fdisk/mac-fdisk-non-glibc-support.patch"; + sha256 = "sha256-CBZUKf7dPvvpuG5L+SI1FQ4W7/fDgeKXHUMFkJNu/MY="; + }) + # Flush stdout after printing prompt for better UX + (fetchpatch { + url = "https://git.adelielinux.org/adelie/packages/-/raw/656ae6bf9f8a64aee95c4797b20bfe713627f1f4/user/mac-fdisk/flush-stdout.patch"; + sha256 = "sha256-k7+UPiUf/oCQdDhxDcC+FRwkxS89WSsYzFw6fUB/10I="; + }) + ]; + + nativeBuildInputs = [ + installShellFiles + ]; + + enableParallelBuilding = true; + + NIX_CFLAGS_COMPILE = "-D_GNU_SOURCE"; + + hardeningDisable = [ "format" ]; + + installPhase = '' + runHook preInstall + + install -Dm755 pdisk $out/sbin/mac-fdisk + install -Dm755 fdisk $out/sbin/pmac-fdisk + + for manpage in {,p}mac-fdisk.8; do + mv "$manpage".in $manpage + installManPage $manpage + done + + runHook postInstall + ''; + + meta = with lib; { + description = "68K and PowerPC Mac disk partitioning utility, Adélie Linux version"; + # http://ftp.mklinux.apple.com:/pub/Other_Tools/ but that one's looong dead, link goes to the patch compilation we're using + homepage = "https://git.adelielinux.org/adelie/packages/-/tree/master/user/mac-fdisk"; + license = with licenses; [ + hpnd # original license statements seems to match this (in files that are shared with pdisk) + gpl1Plus # fdisk.c + ]; + maintainers = with maintainers; [ OPNA2608 ]; + # the toolchain that's being expected for Mac support (SCSI.h from Universal Headers 2.0, SIOUX.h from Metrowerks CoreWarrior) is ancient, unsure about BSDs + platforms = platforms.linux; + badPlatforms = platforms.aarch64; # missing some platform definitions + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index eecc50b96c10..c4a0339bdc01 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -7413,6 +7413,8 @@ with pkgs; lucky-cli = callPackage ../development/web/lucky-cli { }; + mac-fdisk = callPackage ../tools/system/mac-fdisk { }; + partclone = callPackage ../tools/backup/partclone { }; partimage = callPackage ../tools/backup/partimage { }; From 28726fadc08fe5b5174a7b8429f94706333bbaa1 Mon Sep 17 00:00:00 2001 From: OPNA2608 Date: Fri, 14 Oct 2022 17:42:25 +0200 Subject: [PATCH 35/37] pdisk: init at 0.9 --- pkgs/tools/system/pdisk/default.nix | 88 +++++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 4 ++ 2 files changed, 92 insertions(+) create mode 100644 pkgs/tools/system/pdisk/default.nix diff --git a/pkgs/tools/system/pdisk/default.nix b/pkgs/tools/system/pdisk/default.nix new file mode 100644 index 000000000000..87fc683063c7 --- /dev/null +++ b/pkgs/tools/system/pdisk/default.nix @@ -0,0 +1,88 @@ +{ stdenv +, lib +, fetchzip +, fetchpatch +, installShellFiles +, libbsd +, CoreFoundation +, IOKit +}: + +stdenv.mkDerivation rec { + pname = "pdisk"; + version = "0.9"; + + src = fetchzip { + url = "https://opensource.apple.com/tarballs/pdisk/pdisk-${lib.versions.minor version}.tar.gz"; + sha256 = "sha256-+gBgnk/1juEHE0nXaz7laUaH7sxrX5SzsLGr0PHsdHs="; + }; + + patches = [ + # Fix makefile for Unix + (fetchpatch { + url = "https://aur.archlinux.org/cgit/aur.git/plain/makefile.patch?h=pdisk&id=39dc371712d2f7dbd38f6e8ddc6ba661faa1a7a9"; + sha256 = "sha256-mLFclu8IlDN/gxNTI7Kei6ARketlAhJRu8ForFUzFU0="; + }) + # Fix lseek usage in file_media.c + (fetchpatch { + url = "https://aur.archlinux.org/cgit/aur.git/plain/file_media.c.patch?h=pdisk&id=39dc371712d2f7dbd38f6e8ddc6ba661faa1a7a9"; + sha256 = "sha256-CCq5fApwx6w1GKDrgP+0nUdQy/5z5ON7/fdp4M63nko="; + }) + # Fix open_partition_map call in cvt_pt.c + (fetchpatch { + url = "https://aur.archlinux.org/cgit/aur.git/plain/cvt_pt.c.patch?h=pdisk&id=39dc371712d2f7dbd38f6e8ddc6ba661faa1a7a9"; + sha256 = "sha256-jScPfzt9/fQHkf2MfHLvYsh/Rw2NZZXkzZiiVo8F5Mc="; + }) + # Replace removed sys_nerr and sys_errlist with strerror + (fetchpatch { + url = "https://aur.archlinux.org/cgit/aur.git/plain/linux_strerror.patch?h=pdisk&id=&id=d0c930ea8bcac008bbd0ade1811133a625caea54"; + sha256 = "sha256-HGJIS+vTn6456KtaETutIgTPPBm2C9OHf1anG8yaJPo="; + }) + ]; + + postPatch = '' + substituteInPlace makefile \ + --replace 'cc' '${stdenv.cc.targetPrefix}cc' + '' + lib.optionalString stdenv.hostPlatform.isDarwin '' + substituteInPlace makefile \ + --replace '-lbsd' '-framework CoreFoundation -framework IOKit' + ''; + + nativeBuildInputs = [ + installShellFiles + ]; + + buildInputs = lib.optionals (!stdenv.hostPlatform.isDarwin) [ + libbsd + ] ++ lib.optionals (stdenv.hostPlatform.isDarwin) [ + CoreFoundation + IOKit + ]; + + NIX_CFLAGS_COMPILE = "-D_GNU_SOURCE"; + + enableParallelBuilding = true; + + installPhase = '' + runHook preInstall + + install -Dm755 cvt_pt $out/bin/cvt_pt + install -Dm755 pdisk $out/bin/pdisk + + installManPage pdisk.8 + install -Dm644 pdisk.html $out/share/doc/pdisk/pdisk.html + + runHook postInstall + ''; + + meta = with lib; { + description = "A low-level Apple partition table editor for Linux, OSS Apple version"; + homepage = "https://github.com/apple-oss-distributions/pdisk"; + license = with licenses; [ + hpnd # original license statements seems to match this (in files that are shared with mac-fdisk) + apsl10 # new files + ]; + maintainers = with maintainers; [ OPNA2608 ]; + platforms = platforms.unix; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index c4a0339bdc01..d2c81817f3d4 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -7419,6 +7419,10 @@ with pkgs; partimage = callPackage ../tools/backup/partimage { }; + pdisk = callPackage ../tools/system/pdisk { + inherit (darwin.apple_sdk.frameworks) CoreFoundation IOKit; + }; + pgf_graphics = callPackage ../tools/graphics/pgf { }; pgformatter = callPackage ../development/tools/pgformatter { }; From d19c0a65e46ac85e7a02cfb8cb37e1e8e98ef207 Mon Sep 17 00:00:00 2001 From: Solene Rapenne Date: Mon, 26 Sep 2022 16:38:41 +0200 Subject: [PATCH 36/37] top-level/aliases: make mpv-with-scripts migration easier to understand --- pkgs/top-level/aliases.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix index a31d1d95ad19..067482791dfd 100644 --- a/pkgs/top-level/aliases.nix +++ b/pkgs/top-level/aliases.nix @@ -946,7 +946,7 @@ mapAliases ({ mesa_drivers = mesa.drivers; mesa_noglu = throw "'mesa_noglu' has been renamed to/replaced by 'mesa'"; # Converted to throw 2022-02-22 - mpv-with-scripts = self.wrapMpv self.mpv-unwrapped { }; # Added 2020-05-22 + mpv-with-scripts = throw "'mpv-with-scripts' has been renamed to/replaced by 'mpv' or with 'mpv.override { scripts = [ mpvScripts.plugin-name ]; }' if you where using plugins."; # Converted to throw 2022-09-24 mssys = throw "'mssys' has been renamed to/replaced by 'ms-sys'"; # Converted to throw 2022-02-22 multipath_tools = throw "'multipath_tools' has been renamed to/replaced by 'multipath-tools'"; # Converted to throw 2022-02-22 mumsi = throw "mumsi has been removed from nixpkgs, as it's unmaintained and does not build anymore"; # Added 2021-11-18 From da85286b28f0be9029a514fcba29ee13d9762317 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phan=20Kochen?= Date: Wed, 19 Oct 2022 22:51:27 +0200 Subject: [PATCH 37/37] rustc: don't strip bootstrap on darwin --- pkgs/development/compilers/rust/binary.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pkgs/development/compilers/rust/binary.nix b/pkgs/development/compilers/rust/binary.nix index 6c3751cbb575..1de90cdddacf 100644 --- a/pkgs/development/compilers/rust/binary.nix +++ b/pkgs/development/compilers/rust/binary.nix @@ -52,6 +52,12 @@ rec { # https://github.com/rust-lang/rust/issues/34722#issuecomment-232164943 ''; + # The strip tool in cctools 973.0.1 and up appears to break rlibs in the + # binaries. The lib.rmeta object inside the ar archive should contain an + # .rmeta section, but it is removed. Luckily, this doesn't appear to be an + # issue for Rust builds produced by Nix. + dontStrip = stdenv.isDarwin; + setupHooks = ./setup-hook.sh; };