From 7fbb9e8d04bedeb74c415a74ee6f79c577e67a18 Mon Sep 17 00:00:00 2001 From: happysalada Date: Wed, 23 Dec 2020 13:16:44 +0900 Subject: [PATCH 01/51] beam-modules: add fetch-mix-deps --- pkgs/development/beam-modules/default.nix | 1 + .../beam-modules/fetch-mix-deps.nix | 41 +++++++++++++++++++ 2 files changed, 42 insertions(+) create mode 100644 pkgs/development/beam-modules/fetch-mix-deps.nix diff --git a/pkgs/development/beam-modules/default.nix b/pkgs/development/beam-modules/default.nix index 4f312129b38..2392f778bc0 100644 --- a/pkgs/development/beam-modules/default.nix +++ b/pkgs/development/beam-modules/default.nix @@ -33,6 +33,7 @@ let buildRebar3 = callPackage ./build-rebar3.nix {}; buildHex = callPackage ./build-hex.nix {}; buildErlangMk = callPackage ./build-erlang-mk.nix {}; + fetchMixDeps = callPackage ./fetch-mix-deps.nix { }; buildMix = callPackage ./build-mix.nix {}; # BEAM-based languages. diff --git a/pkgs/development/beam-modules/fetch-mix-deps.nix b/pkgs/development/beam-modules/fetch-mix-deps.nix new file mode 100644 index 00000000000..31f0821e81d --- /dev/null +++ b/pkgs/development/beam-modules/fetch-mix-deps.nix @@ -0,0 +1,41 @@ +{ stdenvNoCC, elixir, hex, rebar, rebar3, cacert }: + +{ name, version, sha256, src, mixEnv ? "prod", debug ? false, meta ? { } }: + +with stdenvNoCC.lib; + +stdenvNoCC.mkDerivation ({ + name = "mix-deps-${name}-${version}"; + + phases = [ "configurePhase" "downloadPhase" ]; + + nativeBuildInputs = [ elixir hex cacert ]; + + inherit src; + + MIX_ENV = mixEnv; + MIX_REBAR = "${rebar}/bin/rebar"; + MIX_REBAR3 = "${rebar3}/bin/rebar3"; + MIX_DEBUG = if debug then 1 else 0; + + configurePhase = '' + mkdir -p $out/deps + mkdir -p $out/.hex + export HEX_HOME="$out/.hex"; + export MIX_HOME="$TEMPDIR/.mix"; + export MIX_DEPS_PATH="$out/deps"; + ''; + + downloadPhase = '' + ln -s ${src}/mix.exs ./mix.exs + ln -s ${src}/mix.lock ./mix.lock + mix deps.get --only ${mixEnv} + ''; + + outputHashAlgo = "sha256"; + outputHashMode = "recursive"; + outputHash = sha256; + + impureEnvVars = stdenvNoCC.lib.fetchers.proxyImpureEnvVars; + inherit meta; +}) From 28b8e38666067bcfb8b4f62ed7c4531fb8c00563 Mon Sep 17 00:00:00 2001 From: happysalada Date: Thu, 31 Dec 2020 12:27:08 +0900 Subject: [PATCH 02/51] add git dependency --- pkgs/development/beam-modules/fetch-mix-deps.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/beam-modules/fetch-mix-deps.nix b/pkgs/development/beam-modules/fetch-mix-deps.nix index 31f0821e81d..efdaba4368c 100644 --- a/pkgs/development/beam-modules/fetch-mix-deps.nix +++ b/pkgs/development/beam-modules/fetch-mix-deps.nix @@ -1,4 +1,4 @@ -{ stdenvNoCC, elixir, hex, rebar, rebar3, cacert }: +{ stdenvNoCC, elixir, hex, rebar, rebar3, cacert, git }: { name, version, sha256, src, mixEnv ? "prod", debug ? false, meta ? { } }: @@ -9,7 +9,7 @@ stdenvNoCC.mkDerivation ({ phases = [ "configurePhase" "downloadPhase" ]; - nativeBuildInputs = [ elixir hex cacert ]; + nativeBuildInputs = [ elixir hex cacert git ]; inherit src; From 10d464e887fbacf87ac7f82250ca35ca04e25368 Mon Sep 17 00:00:00 2001 From: happysalada Date: Sun, 3 Jan 2021 12:09:49 +0900 Subject: [PATCH 03/51] remove exporting of .hex --- pkgs/development/beam-modules/fetch-mix-deps.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/beam-modules/fetch-mix-deps.nix b/pkgs/development/beam-modules/fetch-mix-deps.nix index efdaba4368c..513e5629183 100644 --- a/pkgs/development/beam-modules/fetch-mix-deps.nix +++ b/pkgs/development/beam-modules/fetch-mix-deps.nix @@ -21,7 +21,7 @@ stdenvNoCC.mkDerivation ({ configurePhase = '' mkdir -p $out/deps mkdir -p $out/.hex - export HEX_HOME="$out/.hex"; + export HEX_HOME="$TEMPDIR/.hex"; export MIX_HOME="$TEMPDIR/.mix"; export MIX_DEPS_PATH="$out/deps"; ''; From 39c85b0bcfe1f807389225492d6efa72c58fa192 Mon Sep 17 00:00:00 2001 From: happysalada Date: Sun, 10 Jan 2021 17:46:10 +0900 Subject: [PATCH 04/51] use correct commands to set local rebar and rebar3 --- pkgs/development/beam-modules/fetch-mix-deps.nix | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/pkgs/development/beam-modules/fetch-mix-deps.nix b/pkgs/development/beam-modules/fetch-mix-deps.nix index 513e5629183..5103e63dce5 100644 --- a/pkgs/development/beam-modules/fetch-mix-deps.nix +++ b/pkgs/development/beam-modules/fetch-mix-deps.nix @@ -14,16 +14,19 @@ stdenvNoCC.mkDerivation ({ inherit src; MIX_ENV = mixEnv; - MIX_REBAR = "${rebar}/bin/rebar"; - MIX_REBAR3 = "${rebar3}/bin/rebar3"; MIX_DEBUG = if debug then 1 else 0; + DEBUG = if debug then 1 else 0; # for rebar3 configurePhase = '' - mkdir -p $out/deps - mkdir -p $out/.hex export HEX_HOME="$TEMPDIR/.hex"; export MIX_HOME="$TEMPDIR/.mix"; - export MIX_DEPS_PATH="$out/deps"; + export MIX_DEPS_PATH="$out"; + + # Rebar + mix local.rebar rebar "${rebar}/bin/rebar" + mix local.rebar rebar3 "${rebar3}/bin/rebar3" + export REBAR_GLOBAL_CONFIG_DIR="$TMPDIR/rebar3" + export REBAR_CACHE_DIR="$TMPDIR/rebar3.cache" ''; downloadPhase = '' From f38079ff95813ff20ca8b8077e187baa54e90240 Mon Sep 17 00:00:00 2001 From: happysalada Date: Mon, 1 Feb 2021 09:58:51 +0900 Subject: [PATCH 05/51] use lib only where required use standard phases --- pkgs/development/beam-modules/fetch-mix-deps.nix | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/pkgs/development/beam-modules/fetch-mix-deps.nix b/pkgs/development/beam-modules/fetch-mix-deps.nix index 5103e63dce5..020a82ad70b 100644 --- a/pkgs/development/beam-modules/fetch-mix-deps.nix +++ b/pkgs/development/beam-modules/fetch-mix-deps.nix @@ -1,14 +1,10 @@ -{ stdenvNoCC, elixir, hex, rebar, rebar3, cacert, git }: +{ stdenvNoCC, lib, elixir, hex, rebar, rebar3, cacert, git }: { name, version, sha256, src, mixEnv ? "prod", debug ? false, meta ? { } }: -with stdenvNoCC.lib; - stdenvNoCC.mkDerivation ({ name = "mix-deps-${name}-${version}"; - phases = [ "configurePhase" "downloadPhase" ]; - nativeBuildInputs = [ elixir hex cacert git ]; inherit src; @@ -29,9 +25,9 @@ stdenvNoCC.mkDerivation ({ export REBAR_CACHE_DIR="$TMPDIR/rebar3.cache" ''; - downloadPhase = '' - ln -s ${src}/mix.exs ./mix.exs - ln -s ${src}/mix.lock ./mix.lock + dontBuild = true; + + installPhase = '' mix deps.get --only ${mixEnv} ''; @@ -39,6 +35,6 @@ stdenvNoCC.mkDerivation ({ outputHashMode = "recursive"; outputHash = sha256; - impureEnvVars = stdenvNoCC.lib.fetchers.proxyImpureEnvVars; + impureEnvVars = lib.fetchers.proxyImpureEnvVars; inherit meta; }) From a98090337f7c1121d110ce3daf68e80bb61a53fc Mon Sep 17 00:00:00 2001 From: Pasquale Date: Sat, 30 Jan 2021 00:56:55 +0100 Subject: [PATCH 06/51] zinit: 2.3 -> 3.7 --- pkgs/shells/zsh/{zplugin => zinit}/default.nix | 14 ++++++++------ pkgs/top-level/aliases.nix | 2 ++ pkgs/top-level/all-packages.nix | 2 +- 3 files changed, 11 insertions(+), 7 deletions(-) rename pkgs/shells/zsh/{zplugin => zinit}/default.nix (73%) diff --git a/pkgs/shells/zsh/zplugin/default.nix b/pkgs/shells/zsh/zinit/default.nix similarity index 73% rename from pkgs/shells/zsh/zplugin/default.nix rename to pkgs/shells/zsh/zinit/default.nix index c148f60b2ee..d59f50ce3b9 100644 --- a/pkgs/shells/zsh/zplugin/default.nix +++ b/pkgs/shells/zsh/zinit/default.nix @@ -1,12 +1,13 @@ { stdenvNoCC, lib, fetchFromGitHub, installShellFiles }: + stdenvNoCC.mkDerivation rec { - pname = "zplugin"; - version = "2.3"; + pname = "zinit"; + version = "3.7"; src = fetchFromGitHub { owner = "zdharma"; repo = pname; rev = "v${version}"; - sha256 = "0qqv5p19s8jb06d6h55dm4acji9x2rpxb2ni3h7fb0q43iz6y85w"; + hash = "sha256-B+cTGz+U8MR22l6xXdRAAjDr+ulCk+CJ9GllFMK0axE="; }; # adapted from https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=zsh-zplugin-git dontBuild = true; @@ -18,11 +19,12 @@ stdenvNoCC.mkDerivation rec { # Zplugin's source files install -dm0755 "$outdir" - install -m0644 zplugin{,-side,-install,-autoload}.zsh "$outdir" + # Installing also backward compatibility layer + install -m0644 z{plugin,init}{,-side,-install,-autoload}.zsh "$outdir" install -m0755 git-process-output.zsh "$outdir" # Zplugin autocompletion - installShellCompletion --zsh _zplugin + installShellCompletion --zsh _zinit #TODO:Zplugin-module files # find zmodules/ -type d -exec install -dm 755 "{}" "$outdir/{}" \; @@ -32,7 +34,7 @@ stdenvNoCC.mkDerivation rec { #TODO:doc output meta = with lib; { - homepage = "https://github.com/zdharma/zplugin"; + homepage = "https://github.com/zdharma/zinit"; description = "Flexible zsh plugin manager"; license = licenses.mit; maintainers = with maintainers; [ pasqui23 ]; diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix index 22ceedfe4e1..e471cdb73af 100644 --- a/pkgs/top-level/aliases.nix +++ b/pkgs/top-level/aliases.nix @@ -840,6 +840,8 @@ mapAliases ({ /* Added 2021-01-02 */ ttyrec = ovh-ttyrec; + zplugin = zinit; # Added 2021-01-30 + /* If these are in the scope of all-packages.nix, they cause collisions between mixed versions of qt. See: https://github.com/NixOS/nixpkgs/pull/101369 */ diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index f823ee0f8be..012c0e969a7 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -9184,7 +9184,7 @@ in zplug = callPackage ../shells/zsh/zplug { }; - zplugin = callPackage ../shells/zsh/zplugin {} ; + zinit = callPackage ../shells/zsh/zinit {} ; zsh-autoenv = callPackage ../tools/misc/zsh-autoenv { }; From c37421fee41866785bc54a42935ec8420ac05c8b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 30 Jan 2021 18:27:03 +0100 Subject: [PATCH 07/51] libav: mark as insecure --- pkgs/development/libraries/libav/default.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkgs/development/libraries/libav/default.nix b/pkgs/development/libraries/libav/default.nix index 93d6e0d209c..ad95edb68cb 100644 --- a/pkgs/development/libraries/libav/default.nix +++ b/pkgs/development/libraries/libav/default.nix @@ -127,6 +127,10 @@ let license = with licenses; if enableUnfree then unfree #ToDo: redistributable or not? else if enableGPL then gpl2Plus else lgpl21Plus; platforms = with platforms; linux ++ darwin; + knownVulnerabilities = + lib.optional (lib.versionOlder version "12.1") "CVE-2017-9051" + ++ lib.optionals (lib.versionOlder version "12.3") [ "CVE-2018-5684" "CVE-2018-5766" ] + ++ lib.optionals (lib.versionOlder version "12.4") [ "CVE-2019-9717" "CVE-2019-9720" ]; }; }; # libavFun From e60d822e27098645a83f1c5ff14eee86f473cc56 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 30 Jan 2021 19:28:16 +0100 Subject: [PATCH 08/51] keyfinder-cli: 2015-09-13 -> 1.1.1 Also use ffmpeg instead of libav. --- pkgs/applications/audio/keyfinder-cli/default.nix | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/audio/keyfinder-cli/default.nix b/pkgs/applications/audio/keyfinder-cli/default.nix index d6e96d90834..62db3d79690 100644 --- a/pkgs/applications/audio/keyfinder-cli/default.nix +++ b/pkgs/applications/audio/keyfinder-cli/default.nix @@ -1,17 +1,17 @@ -{ lib, stdenv, fetchFromGitHub, libav, libkeyfinder }: +{ lib, stdenv, fetchFromGitHub, ffmpeg, libkeyfinder }: stdenv.mkDerivation rec { pname = "keyfinder-cli"; - version = "2015-09-13"; + version = "1.1.1"; src = fetchFromGitHub { repo = "keyfinder-cli"; owner = "EvanPurkhiser"; - rev = "8579282f15ab3ebad937fed398ec5c88843be03d"; - sha256 = "0jylykigxmsqvdny265k58vpxa4cqs1hq2f7mph1nl3apfx2shrh"; + rev = "v${version}"; + sha256 = "1mlcygbj3gqii3cz8jd6ks1lz612i4jp0343qjg293xm39fg47ns"; }; - buildInputs = [ libav libkeyfinder ]; + buildInputs = [ ffmpeg libkeyfinder ]; makeFlags = [ "PREFIX=$(out)" ]; From d2144f14060f3cf2aa51636876a48d893f85d341 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 30 Jan 2021 19:35:35 +0100 Subject: [PATCH 09/51] appimageTools: don't depend on libav It's not in https://github.com/AppImage/pkg2appimage/blob/master/excludelist --- pkgs/build-support/appimage/default.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/pkgs/build-support/appimage/default.nix b/pkgs/build-support/appimage/default.nix index 6824b8215e5..2a13d107bd0 100644 --- a/pkgs/build-support/appimage/default.nix +++ b/pkgs/build-support/appimage/default.nix @@ -121,7 +121,6 @@ rec { libusb1 udev dbus-glib - libav atk at-spi2-atk libudev0-shim From 276920469616b2494342f7e0ed7c272a4e5fcda9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 30 Jan 2021 20:00:43 +0100 Subject: [PATCH 10/51] unpaper: use ffmpeg instead of libav --- pkgs/tools/graphics/unpaper/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/tools/graphics/unpaper/default.nix b/pkgs/tools/graphics/unpaper/default.nix index dd6ecb473e9..20dfe15dc6c 100644 --- a/pkgs/tools/graphics/unpaper/default.nix +++ b/pkgs/tools/graphics/unpaper/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchurl, pkg-config, libav, libxslt }: +{ lib, stdenv, fetchurl, pkg-config, ffmpeg, libxslt }: stdenv.mkDerivation rec { pname = "unpaper"; @@ -10,7 +10,7 @@ stdenv.mkDerivation rec { }; nativeBuildInputs = [ pkg-config ]; - buildInputs = [ libav libxslt ]; + buildInputs = [ ffmpeg libxslt ]; meta = with lib; { homepage = "https://www.flameeyes.eu/projects/unpaper"; From 7acbde998b1b38ca79c8f0cf687540b798d42516 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 30 Jan 2021 20:06:13 +0100 Subject: [PATCH 11/51] sdrangel: use ffmpeg instead of libav --- pkgs/applications/radio/sdrangel/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/radio/sdrangel/default.nix b/pkgs/applications/radio/sdrangel/default.nix index b4a6cb775cc..6f723971c8e 100644 --- a/pkgs/applications/radio/sdrangel/default.nix +++ b/pkgs/applications/radio/sdrangel/default.nix @@ -9,7 +9,7 @@ fftwFloat, glew, hackrf, lib, -libav, +ffmpeg, libiio, libopus, libpulseaudio, @@ -44,7 +44,7 @@ mkDerivation rec { nativeBuildInputs = [ cmake pkg-config ]; buildInputs = [ - glew opencv3 libusb1 boost libopus limesuite libav libiio libpulseaudio + glew opencv3 libusb1 boost libopus limesuite ffmpeg libiio libpulseaudio qtbase qtwebsockets qtmultimedia rtl-sdr airspy hackrf fftwFloat codec2 cm256cc serialdv qtserialport libbladeRF uhd soapysdr-with-plugins From fc8a4420da46a996c6ad509751ba79fc173e0a2f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 30 Jan 2021 21:07:29 +0100 Subject: [PATCH 12/51] musly: use ffmpeg instead of libav --- pkgs/applications/audio/musly/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/audio/musly/default.nix b/pkgs/applications/audio/musly/default.nix index 1e8d29d3770..0d10b55d329 100644 --- a/pkgs/applications/audio/musly/default.nix +++ b/pkgs/applications/audio/musly/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchFromGitHub, cmake, eigen, libav }: +{ lib, stdenv, fetchFromGitHub, cmake, eigen, ffmpeg }: stdenv.mkDerivation { pname = "musly"; version = "unstable-2017-04-26"; @@ -9,7 +9,7 @@ stdenv.mkDerivation { sha256 = "1q42wvdwy2pac7bhfraqqj2czw7w2m33ms3ifjl8phm7d87i8825"; }; nativeBuildInputs = [ cmake ]; - buildInputs = [ eigen (libav.override { vaapiSupport = stdenv.isLinux; }) ]; + buildInputs = [ eigen ffmpeg ]; fixupPhase = if stdenv.isDarwin then '' install_name_tool -change libmusly.dylib $out/lib/libmusly.dylib $out/bin/musly install_name_tool -change libmusly_resample.dylib $out/lib/libmusly_resample.dylib $out/bin/musly From 872b7637100f5cb8e0b00215ab51fad5ef217bd5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 30 Jan 2021 21:35:57 +0100 Subject: [PATCH 13/51] performous: use ffmpeg instead of libav --- pkgs/games/performous/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/games/performous/default.nix b/pkgs/games/performous/default.nix index b0fc9483629..dce771faec1 100644 --- a/pkgs/games/performous/default.nix +++ b/pkgs/games/performous/default.nix @@ -1,6 +1,6 @@ { lib, stdenv, fetchFromGitHub, cmake, pkg-config, gettext , glibmm, libxmlxx, pango, librsvg -, SDL2, glew, boost, libav, portaudio, epoxy +, SDL2, glew, boost, ffmpeg, portaudio, epoxy }: stdenv.mkDerivation rec { @@ -27,6 +27,6 @@ stdenv.mkDerivation rec { buildInputs = [ glibmm libxmlxx pango librsvg - SDL2 glew boost libav portaudio epoxy + SDL2 glew boost ffmpeg portaudio epoxy ]; } From cc92cabcb47975236e56ea6e202e11c81ccaad02 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sun, 31 Jan 2021 00:23:20 +0100 Subject: [PATCH 14/51] electricsheep: use ffmpeg instead of libav --- pkgs/misc/screensavers/electricsheep/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/misc/screensavers/electricsheep/default.nix b/pkgs/misc/screensavers/electricsheep/default.nix index ea68e147ba7..74d9e3cffee 100644 --- a/pkgs/misc/screensavers/electricsheep/default.nix +++ b/pkgs/misc/screensavers/electricsheep/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchFromGitHub, autoreconfHook, wxGTK30, libav, lua5_1, curl +{ lib, stdenv, fetchFromGitHub, autoreconfHook, wxGTK30, ffmpeg, lua5_1, curl , libpng, xorg, pkg-config, flam3, libgtop, boost, tinyxml, freeglut, libGLU, libGL , glee }: @@ -16,7 +16,7 @@ stdenv.mkDerivation rec { nativeBuildInputs = [ autoreconfHook pkg-config ]; buildInputs = [ - wxGTK30 libav lua5_1 curl libpng xorg.libXrender + wxGTK30 ffmpeg lua5_1 curl libpng xorg.libXrender flam3 libgtop boost tinyxml freeglut libGLU libGL glee ]; From a4db89997b96b094f6011ab056bdd45491397db7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Mon, 1 Feb 2021 13:52:16 +0100 Subject: [PATCH 15/51] untrunc: make alias of untrunc-anthwlock The latter has more features and doesn't depend on an outdated version of libav. --- pkgs/tools/video/untrunc/default.nix | 39 ---------------------------- pkgs/top-level/aliases.nix | 1 + pkgs/top-level/all-packages.nix | 2 -- 3 files changed, 1 insertion(+), 41 deletions(-) delete mode 100644 pkgs/tools/video/untrunc/default.nix diff --git a/pkgs/tools/video/untrunc/default.nix b/pkgs/tools/video/untrunc/default.nix deleted file mode 100644 index 3ef025f5875..00000000000 --- a/pkgs/tools/video/untrunc/default.nix +++ /dev/null @@ -1,39 +0,0 @@ -{ lib, stdenv, gcc, libav_12, fetchFromGitHub }: - -stdenv.mkDerivation { - pname = "untrunc"; - version = "2020.02.09"; - - src = fetchFromGitHub { - owner = "ponchio"; - repo = "untrunc"; - rev = "4eed44283168c727ace839ff7590092fda2e0848"; - sha256 = "0nfj67drc6bxqlkf8a1iazqhi0w38a7rjrb2bpa74gwq6xzygvbr"; - }; - - buildInputs = [ gcc libav_12 ]; - - # Untrunc uses the internal libav headers 'h264dec.h' and 'config.h'. - # The latter must be created through 'configure'. - libavConfiguredSrc = libav_12.overrideAttrs (oldAttrs: { - name = "libav-configured-src"; - outputs = [ "out" ]; - phases = [ "unpackPhase" "patchPhase" "configurePhase" "installPhase" ]; - installPhase = "cp -r . $out"; - }); - - buildCommand = '' - mkdir -p $out/bin - g++ -o $out/bin/untrunc \ - -Wno-deprecated-declarations \ - $src/file.cpp $src/main.cpp $src/track.cpp $src/atom.cpp $src/mp4.cpp \ - -I$libavConfiguredSrc -lavformat -lavcodec -lavutil - ''; - - meta = with lib; { - description = "Restore a damaged (truncated) mp4, m4v, mov, 3gp video from a similar, undamaged video"; - license = licenses.gpl2; - homepage = "https://github.com/ponchio/untrunc"; - maintainers = [ maintainers.earvstedt ]; - }; -} diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix index bb2fb36bb5b..e4ac34b0782 100644 --- a/pkgs/top-level/aliases.nix +++ b/pkgs/top-level/aliases.nix @@ -709,6 +709,7 @@ mapAliases ({ ultrastardx-beta = ultrastardx; # added 2017-08-12 unicorn-emu = unicorn; # added 2020-10-29 unifiStable = unifi6; # added 2020-12-28 + untrunc = untrunc-anthwlock; # added 2021-02-01 usb_modeswitch = usb-modeswitch; # added 2016-05-10 usbguard-nox = usbguard; # added 2019-09-04 utillinux = util-linux; # added 2020-11-24 diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 5a1fedf9f53..1b8e681f7c5 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -8527,8 +8527,6 @@ in untex = callPackage ../tools/text/untex { }; - untrunc = callPackage ../tools/video/untrunc { }; - untrunc-anthwlock = callPackage ../tools/video/untrunc-anthwlock { }; up = callPackage ../tools/misc/up { }; From 68169c85c49c4f1950c97c7681b2dce9bc1d50b4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Mon, 1 Feb 2021 14:08:30 +0100 Subject: [PATCH 16/51] guitarix: does not depend on libav --- pkgs/applications/audio/guitarix/default.nix | 2 -- 1 file changed, 2 deletions(-) diff --git a/pkgs/applications/audio/guitarix/default.nix b/pkgs/applications/audio/guitarix/default.nix index 69e427dd96c..7f41fa6c5f9 100644 --- a/pkgs/applications/audio/guitarix/default.nix +++ b/pkgs/applications/audio/guitarix/default.nix @@ -17,7 +17,6 @@ , hicolor-icon-theme , intltool , ladspaH -, libav , libjack2 , libsndfile , lilv @@ -74,7 +73,6 @@ stdenv.mkDerivation rec { gtk3 gtkmm3 ladspaH - libav libjack2 libsndfile lilv From 8139e563a312b4ba072ddf8bf58fdaeda616e373 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Mon, 1 Feb 2021 14:16:48 +0100 Subject: [PATCH 17/51] jabref: does not depend on libav --- pkgs/applications/office/jabref/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/office/jabref/default.nix b/pkgs/applications/office/jabref/default.nix index 3974e75a2f7..4eb39f4d1f8 100644 --- a/pkgs/applications/office/jabref/default.nix +++ b/pkgs/applications/office/jabref/default.nix @@ -1,5 +1,5 @@ { lib, stdenv, fetchurl, makeWrapper, makeDesktopItem, wrapGAppsHook, gtk3, gsettings-desktop-schemas -, zlib , libX11, libXext, libXi, libXrender, libXtst, libGL, alsaLib, libav, cairo, freetype, pango, gdk-pixbuf, glib }: +, zlib , libX11, libXext, libXi, libXrender, libXtst, libGL, alsaLib, cairo, freetype, pango, gdk-pixbuf, glib }: stdenv.mkDerivation rec { version = "5.1"; @@ -25,7 +25,7 @@ stdenv.mkDerivation rec { nativeBuildInputs = [ makeWrapper wrapGAppsHook ]; buildInputs = [ gsettings-desktop-schemas ] ++ systemLibs; - systemLibs = [ gtk3 zlib libX11 libXext libXi libXrender libXtst libGL alsaLib libav cairo freetype pango gdk-pixbuf glib ]; + systemLibs = [ gtk3 zlib libX11 libXext libXi libXrender libXtst libGL alsaLib cairo freetype pango gdk-pixbuf glib ]; systemLibPaths = lib.makeLibraryPath systemLibs; installPhase = '' From 0de5ec913e52a62f24b26501c06515c4a03fc913 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Mon, 1 Feb 2021 15:51:34 +0100 Subject: [PATCH 18/51] libgroove: use ffmpeg_3 instead of libav --- pkgs/development/libraries/libgroove/default.nix | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/pkgs/development/libraries/libgroove/default.nix b/pkgs/development/libraries/libgroove/default.nix index 963bf722b2a..f14524df0dc 100644 --- a/pkgs/development/libraries/libgroove/default.nix +++ b/pkgs/development/libraries/libgroove/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchFromGitHub, cmake, libav, SDL2, chromaprint, libebur128 }: +{ lib, stdenv, fetchFromGitHub, fetchpatch, cmake, ffmpeg_3, SDL2, chromaprint, libebur128 }: stdenv.mkDerivation rec { version = "4.3.0"; @@ -11,10 +11,17 @@ stdenv.mkDerivation rec { sha256 = "1la9d9kig50mc74bxvhx6hzqv0nrci9aqdm4k2j4q0s1nlfgxipd"; }; - patches = [ ./no-warnings-as-errors.patch ]; + patches = [ + ./no-warnings-as-errors.patch + (fetchpatch { + name = "update-for-ffmpeg-3.0.patch"; + url = "https://aur.archlinux.org/cgit/aur.git/plain/0001-update-for-ffmpeg-3.0.patch?h=libgroove&id=a9f3bd2a5afd3227733414a5d54c7a2aa0a1249e"; + sha256 = "0800drk9df1kwbv80f2ffv77xk888249fk0d961rp2a305hvyrk0"; + }) + ]; nativeBuildInputs = [ cmake ]; - buildInputs = [ libav SDL2 chromaprint libebur128 ]; + buildInputs = [ ffmpeg_3 SDL2 chromaprint libebur128 ]; meta = with lib; { description = "Streaming audio processing library"; From 55b97f7ce62eb93e353b1d8af332f4c9323b5f8f Mon Sep 17 00:00:00 2001 From: rnhmjoj Date: Tue, 2 Feb 2021 02:47:36 +0100 Subject: [PATCH 19/51] thinkfan: cleanup - Remove the custom installPhase: upstream has added an install target and it does a better job than we do - Improve meta: description -> longDescription and add a short one - Fix license: GPL3 -> GPL3+ --- pkgs/tools/system/thinkfan/default.nix | 43 ++++++++++++-------------- 1 file changed, 20 insertions(+), 23 deletions(-) diff --git a/pkgs/tools/system/thinkfan/default.nix b/pkgs/tools/system/thinkfan/default.nix index c9af119fb73..4f9e1e28998 100644 --- a/pkgs/tools/system/thinkfan/default.nix +++ b/pkgs/tools/system/thinkfan/default.nix @@ -1,5 +1,13 @@ -{ lib, stdenv, fetchFromGitHub, cmake, libyamlcpp, pkg-config -, smartSupport ? false, libatasmart }: +{ lib +, stdenv +, fetchFromGitHub +, cmake +, libyamlcpp +, pkg-config +, procps +, coreutils +, smartSupport ? false, libatasmart +}: stdenv.mkDerivation rec { pname = "thinkfan"; @@ -21,27 +29,16 @@ stdenv.mkDerivation rec { buildInputs = [ libyamlcpp ] ++ lib.optional smartSupport libatasmart; - installPhase = '' - runHook preInstall - - install -Dm755 {.,$out/bin}/thinkfan - - cd "$NIX_BUILD_TOP"; cd "$sourceRoot" # attempt to be a bit robust - install -Dm644 {.,$out/share/doc/thinkfan}/README.md - cp -R examples $out/share/doc/thinkfan - install -Dm644 {src,$out/share/man/man1}/thinkfan.1 - - runHook postInstall - ''; - - meta = with lib; { - description = "A minimalist fan control program"; - longDescription = "A minimalist fan control program. Originally designed -specifically for IBM/Lenovo Thinkpads, it now supports any kind of system via -the sysfs hwmon interface (/sys/class/hwmon)."; - license = licenses.gpl3; + meta = { + description = "A simple, lightweight fan control program"; + longDescription = '' + Thinkfan is a minimalist fan control program. Originally designed + specifically for IBM/Lenovo Thinkpads, it now supports any kind of + system via the sysfs hwmon interface (/sys/class/hwmon). + ''; + license = lib.licenses.gpl3Plus; homepage = "https://github.com/vmatare/thinkfan"; - maintainers = with maintainers; [ domenkozar ]; - platforms = platforms.linux; + maintainers = with lib.maintainers; [ domenkozar ]; + platforms = lib.platforms.linux; }; } From f5461e2654a4817aad199b747f488ab67e5ef04f Mon Sep 17 00:00:00 2001 From: rnhmjoj Date: Wed, 3 Feb 2021 11:37:45 +0100 Subject: [PATCH 20/51] thinkfan: install systemd unit files --- pkgs/tools/system/thinkfan/default.nix | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/pkgs/tools/system/thinkfan/default.nix b/pkgs/tools/system/thinkfan/default.nix index 4f9e1e28998..ea9deb8af66 100644 --- a/pkgs/tools/system/thinkfan/default.nix +++ b/pkgs/tools/system/thinkfan/default.nix @@ -20,9 +20,24 @@ stdenv.mkDerivation rec { sha256 = "18vgm5w5pjnpipa34j4x87q10695w2jnqwvc2f027afy7mnzw7kz"; }; + postPatch = '' + # fix hardcoded install path + substituteInPlace CMakeLists.txt --replace /etc $out/etc + + # fix command paths in unit files + for unit in rcscripts/systemd/*; do + substituteInPlace "$unit" \ + --replace /bin/kill ${procps}/bin/kill \ + --replace /usr/bin/pkill ${procps}/bin/pkill \ + --replace /usr/bin/sleep ${coreutils}/bin/sleep + done + ''; + cmakeFlags = [ "-DCMAKE_INSTALL_DOCDIR=share/doc/${pname}" "-DUSE_NVML=OFF" + # force install unit files + "-DSYSTEMD_FOUND=ON" ] ++ lib.optional smartSupport "-DUSE_ATASMART=ON"; nativeBuildInputs = [ cmake pkg-config ]; From 32e1eb37422b0aa3c19790e1d5be72948c0899c7 Mon Sep 17 00:00:00 2001 From: rnhmjoj Date: Wed, 3 Feb 2021 11:29:34 +0100 Subject: [PATCH 21/51] thinkfan: add rnhmjoj as maintainer --- pkgs/tools/system/thinkfan/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/tools/system/thinkfan/default.nix b/pkgs/tools/system/thinkfan/default.nix index ea9deb8af66..97c61d2da0e 100644 --- a/pkgs/tools/system/thinkfan/default.nix +++ b/pkgs/tools/system/thinkfan/default.nix @@ -53,7 +53,7 @@ stdenv.mkDerivation rec { ''; license = lib.licenses.gpl3Plus; homepage = "https://github.com/vmatare/thinkfan"; - maintainers = with lib.maintainers; [ domenkozar ]; + maintainers = with lib.maintainers; [ domenkozar rnhmjoj ]; platforms = lib.platforms.linux; }; } From 11bae6e9fbe2b029399a5f9bf1d1420942160219 Mon Sep 17 00:00:00 2001 From: 06kellyjac Date: Wed, 3 Feb 2021 18:38:46 +0000 Subject: [PATCH 22/51] agate: init at 2.3.0 --- pkgs/servers/gemini/agate/default.nix | 29 +++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 31 insertions(+) create mode 100644 pkgs/servers/gemini/agate/default.nix diff --git a/pkgs/servers/gemini/agate/default.nix b/pkgs/servers/gemini/agate/default.nix new file mode 100644 index 00000000000..7c15f4769e3 --- /dev/null +++ b/pkgs/servers/gemini/agate/default.nix @@ -0,0 +1,29 @@ +{ lib, fetchFromGitHub, rustPlatform, installShellFiles }: + +rustPlatform.buildRustPackage rec { + pname = "agate"; + version = "2.3.0"; + + src = fetchFromGitHub { + owner = "mbrubeck"; + repo = pname; + rev = "v${version}"; + sha256 = "sha256-rwoEZnxh0x+xaggJuoeSjE1ctF43ChW5awcDJyoWioA="; + }; + + cargoSha256 = "sha256-ey/fUHkPoWjWlLjh1WNpwMKOkdQKgFYcLwQdx2RQ3CI="; + + meta = with lib; { + homepage = "gemini://gem.limpet.net/agate"; + changelog = "gemini://gem.limpet.net/agate"; + description = "Very simple server for the Gemini hypertext protocol"; + longDescription = '' + Agate is a server for the Gemini network protocol, built with the Rust + programming language. Agate has very few features, and can only serve + static files. It uses async I/O, and should be quite efficient even when + running on low-end hardware and serving many concurrent requests. + ''; + license = licenses.asl20; + maintainers = with maintainers; [ jk ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index c54a8e8d672..fcbe39fb6e5 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -701,6 +701,8 @@ in afpfs-ng = callPackage ../tools/filesystems/afpfs-ng { }; + agate = callPackage ../servers/gemini/agate { }; + agda-pkg = callPackage ../development/tools/agda-pkg { }; agrep = callPackage ../tools/text/agrep { }; From cc0e52acebd71e364e722c8c93a77c94c53765e5 Mon Sep 17 00:00:00 2001 From: Jack Kelly Date: Thu, 4 Feb 2021 08:59:20 +0000 Subject: [PATCH 23/51] agate: proxy gemini links in meta Co-authored-by: Sandro --- pkgs/servers/gemini/agate/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/servers/gemini/agate/default.nix b/pkgs/servers/gemini/agate/default.nix index 7c15f4769e3..558efe2fb01 100644 --- a/pkgs/servers/gemini/agate/default.nix +++ b/pkgs/servers/gemini/agate/default.nix @@ -14,8 +14,8 @@ rustPlatform.buildRustPackage rec { cargoSha256 = "sha256-ey/fUHkPoWjWlLjh1WNpwMKOkdQKgFYcLwQdx2RQ3CI="; meta = with lib; { - homepage = "gemini://gem.limpet.net/agate"; - changelog = "gemini://gem.limpet.net/agate"; + homepage = "https://proxy.vulpes.one/gemini/gem.limpet.net/agate"; + changelog = "https://proxy.vulpes.one/gemini/gem.limpet.net/agate"; description = "Very simple server for the Gemini hypertext protocol"; longDescription = '' Agate is a server for the Gemini network protocol, built with the Rust From 83e82c1caffe00b7b19996217db2610c72841de6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Mon, 1 Feb 2021 23:05:10 +0100 Subject: [PATCH 24/51] steam-run-native: use ffmpeg instead of libav --- pkgs/games/steam/fhsenv.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/games/steam/fhsenv.nix b/pkgs/games/steam/fhsenv.nix index 57326667cb0..924714d802a 100644 --- a/pkgs/games/steam/fhsenv.nix +++ b/pkgs/games/steam/fhsenv.nix @@ -171,7 +171,7 @@ in buildFHSUserEnv rec { SDL2 libusb1 dbus-glib - libav + ffmpeg atk # Only libraries are needed from those two libudev0-shim From 3673ad819fe106d53eecbfd3dfabf2ef9ed00a4a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Tue, 2 Feb 2021 09:59:12 +0100 Subject: [PATCH 25/51] graalvm*-ee: remove unused argument libav_0_8 --- pkgs/development/compilers/graalvm/enterprise-edition.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/compilers/graalvm/enterprise-edition.nix b/pkgs/development/compilers/graalvm/enterprise-edition.nix index c9c5206f6da..eb3045d52ad 100644 --- a/pkgs/development/compilers/graalvm/enterprise-edition.nix +++ b/pkgs/development/compilers/graalvm/enterprise-edition.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, requireFile, perl, unzip, glibc, zlib, bzip2, gdk-pixbuf, xorg, glib, fontconfig, freetype, cairo, pango, gtk3, gtk2, ffmpeg, libGL, atk, alsaLib, libav_0_8, setJavaClassPath }: +{ lib, stdenv, requireFile, perl, unzip, glibc, zlib, bzip2, gdk-pixbuf, xorg, glib, fontconfig, freetype, cairo, pango, gtk3, gtk2, ffmpeg, libGL, atk, alsaLib, setJavaClassPath }: let common = javaVersion: From 013953c89b0186caa22d1f2c4ded6dc1526a23b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Tue, 2 Feb 2021 10:24:27 +0100 Subject: [PATCH 26/51] gerbera: don't pass pkgs as argument --- pkgs/servers/gerbera/default.nix | 41 ++++++++++++++++---------------- 1 file changed, 20 insertions(+), 21 deletions(-) diff --git a/pkgs/servers/gerbera/default.nix b/pkgs/servers/gerbera/default.nix index f81cc6600f1..eba17567d91 100644 --- a/pkgs/servers/gerbera/default.nix +++ b/pkgs/servers/gerbera/default.nix @@ -2,18 +2,17 @@ , cmake, pkg-config # required , libupnp, libuuid, pugixml, libiconv, sqlite, zlib, spdlog, fmt -, pkgs # options -, enableDuktape ? true -, enableCurl ? true -, enableTaglib ? true -, enableLibmagic ? true -, enableLibmatroska ? true -, enableAvcodec ? false -, enableLibexif ? true -, enableExiv2 ? false -, enableFFmpegThumbnailer ? false -, enableInotifyTools ? true +, enableDuktape ? true, duktape +, enableCurl ? true, curl +, enableTaglib ? true, taglib +, enableLibmagic ? true, file +, enableLibmatroska ? true, libmatroska, libebml +, enableAvcodec ? false, libav +, enableLibexif ? true, libexif +, enableExiv2 ? false, exiv2 +, enableFFmpegThumbnailer ? false, ffmpegthumbnailer +, enableInotifyTools ? true, inotify-tools }: with lib; @@ -51,16 +50,16 @@ in stdenv.mkDerivation rec { libupnp libuuid pugixml libiconv sqlite zlib fmt.dev spdlog ] - ++ optionals enableDuktape [ pkgs.duktape ] - ++ optionals enableCurl [ pkgs.curl ] - ++ optionals enableTaglib [ pkgs.taglib ] - ++ optionals enableLibmagic [ pkgs.file ] - ++ optionals enableLibmatroska [ pkgs.libmatroska pkgs.libebml ] - ++ optionals enableAvcodec [ pkgs.libav.dev ] - ++ optionals enableLibexif [ pkgs.libexif ] - ++ optionals enableExiv2 [ pkgs.exiv2 ] - ++ optionals enableInotifyTools [ pkgs.inotify-tools ] - ++ optionals enableFFmpegThumbnailer [ pkgs.ffmpegthumbnailer ]; + ++ optionals enableDuktape [ duktape ] + ++ optionals enableCurl [ curl ] + ++ optionals enableTaglib [ taglib ] + ++ optionals enableLibmagic [ file ] + ++ optionals enableLibmatroska [ libmatroska libebml ] + ++ optionals enableAvcodec [ libav.dev ] + ++ optionals enableLibexif [ libexif ] + ++ optionals enableExiv2 [ exiv2 ] + ++ optionals enableInotifyTools [ inotify-tools ] + ++ optionals enableFFmpegThumbnailer [ ffmpegthumbnailer ]; meta = with lib; { From 9cba0bbf6dc3a8925abd934b744e6f34f6fca1f1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Tue, 2 Feb 2021 10:25:06 +0100 Subject: [PATCH 27/51] gerbera: use ffmpeg instead of libav --- pkgs/servers/gerbera/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/servers/gerbera/default.nix b/pkgs/servers/gerbera/default.nix index eba17567d91..7736ed1a014 100644 --- a/pkgs/servers/gerbera/default.nix +++ b/pkgs/servers/gerbera/default.nix @@ -8,7 +8,7 @@ , enableTaglib ? true, taglib , enableLibmagic ? true, file , enableLibmatroska ? true, libmatroska, libebml -, enableAvcodec ? false, libav +, enableAvcodec ? false, ffmpeg , enableLibexif ? true, libexif , enableExiv2 ? false, exiv2 , enableFFmpegThumbnailer ? false, ffmpegthumbnailer @@ -55,7 +55,7 @@ in stdenv.mkDerivation rec { ++ optionals enableTaglib [ taglib ] ++ optionals enableLibmagic [ file ] ++ optionals enableLibmatroska [ libmatroska libebml ] - ++ optionals enableAvcodec [ libav.dev ] + ++ optionals enableAvcodec [ ffmpeg.dev ] ++ optionals enableLibexif [ libexif ] ++ optionals enableExiv2 [ exiv2 ] ++ optionals enableInotifyTools [ inotify-tools ] From 564d498580bb21703c01a64c7f241e53cd65b821 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Wed, 3 Feb 2021 11:28:08 +0100 Subject: [PATCH 28/51] zulu8: does not depend on libav --- pkgs/development/compilers/zulu/8.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/compilers/zulu/8.nix b/pkgs/development/compilers/zulu/8.nix index e81cc412428..2bc90539be1 100644 --- a/pkgs/development/compilers/zulu/8.nix +++ b/pkgs/development/compilers/zulu/8.nix @@ -1,5 +1,5 @@ { stdenv, lib, fetchurl, unzip, makeWrapper, setJavaClassPath -, zulu, glib, libxml2, libav_0_8, ffmpeg_3, libxslt, libGL, alsaLib +, zulu, glib, libxml2, ffmpeg_3, libxslt, libGL, alsaLib , fontconfig, freetype, pango, gtk2, cairo, gdk-pixbuf, atk, xorg , swingSupport ? true }: @@ -15,7 +15,7 @@ let extension = if stdenv.isDarwin then "zip" else "tar.gz"; libraries = [ - stdenv.cc.libc glib libxml2 libav_0_8 ffmpeg_3 libxslt libGL + stdenv.cc.libc glib libxml2 ffmpeg_3 libxslt libGL xorg.libXxf86vm alsaLib fontconfig freetype pango gtk2 cairo gdk-pixbuf atk ] ++ (lib.optionals swingSupport (with xorg; [ From 6c478b944fd3075a2a15f78506aed3d1bc648d63 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Wed, 3 Feb 2021 11:28:36 +0100 Subject: [PATCH 29/51] zulu: does not depend on libav --- pkgs/development/compilers/zulu/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/compilers/zulu/default.nix b/pkgs/development/compilers/zulu/default.nix index 63b95465c27..cbfa9997b8d 100644 --- a/pkgs/development/compilers/zulu/default.nix +++ b/pkgs/development/compilers/zulu/default.nix @@ -1,5 +1,5 @@ { stdenv, lib, fetchurl, unzip, makeWrapper, setJavaClassPath -, zulu, glib, libxml2, libav_0_8, ffmpeg_3, libxslt, libGL, alsaLib +, zulu, glib, libxml2, ffmpeg_3, libxslt, libGL, alsaLib , fontconfig, freetype, pango, gtk2, cairo, gdk-pixbuf, atk, xorg, zlib , swingSupport ? true }: @@ -15,7 +15,7 @@ let extension = if stdenv.isDarwin then "zip" else "tar.gz"; libraries = [ - stdenv.cc.libc glib libxml2 libav_0_8 ffmpeg_3 libxslt libGL + stdenv.cc.libc glib libxml2 ffmpeg_3 libxslt libGL xorg.libXxf86vm alsaLib fontconfig freetype pango gtk2 cairo gdk-pixbuf atk zlib ] ++ (lib.optionals swingSupport (with xorg; [ From 8484b0bdb8dbece62a96d904da0b257bc2373a0f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Thu, 4 Feb 2021 15:21:00 +0100 Subject: [PATCH 30/51] keyfinder: 2.2 -> 2.4 --- pkgs/applications/audio/keyfinder/default.nix | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/audio/keyfinder/default.nix b/pkgs/applications/audio/keyfinder/default.nix index 19433466ec3..80cd8f4d9a0 100644 --- a/pkgs/applications/audio/keyfinder/default.nix +++ b/pkgs/applications/audio/keyfinder/default.nix @@ -1,12 +1,12 @@ -{ lib, stdenv, fetchFromGitHub, libav_0_8, libkeyfinder, qtbase, qtxmlpatterns, qmake, taglib }: +{ lib, mkDerivation, fetchFromGitHub, libav_0_8, libkeyfinder, qtbase, qtxmlpatterns, qmake, taglib }: -stdenv.mkDerivation rec { +mkDerivation rec { pname = "keyfinder"; - version = "2.2"; + version = "2.4"; src = fetchFromGitHub { - sha256 = "0vjszk1h8vj2qycgbffzy6k7amg75jlvlnzwaqhz9nll2pcvw0zl"; - rev = version; + sha256 = "11yhdwan7bz8nn8vxr54drckyrnlxynhx5s981i475bbccg8g7ls"; + rev = "530034d6fe86d185f6a68b817f8db5f552f065d7"; # tag is missing repo = "is_KeyFinder"; owner = "ibsh"; }; From 774fba51d82587853002482dc98ebc612025693f Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Fri, 5 Feb 2021 11:54:31 +0100 Subject: [PATCH 31/51] python3Packages.docutils: add licensing details --- pkgs/development/python-modules/docutils/default.nix | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/docutils/default.nix b/pkgs/development/python-modules/docutils/default.nix index e24a00564be..bae0acc1d45 100644 --- a/pkgs/development/python-modules/docutils/default.nix +++ b/pkgs/development/python-modules/docutils/default.nix @@ -29,9 +29,10 @@ buildPythonPackage rec { done ''; - meta = { + meta = with lib; { description = "Python Documentation Utilities"; homepage = "http://docutils.sourceforge.net/"; - maintainers = with lib.maintainers; [ AndersonTorres ]; + license = with licenses; [ publicDomain bsd2 psfl gpl3Plus ]; + maintainers = with maintainers; [ AndersonTorres ]; }; } From 08871edb4dfb6f560b72d1ca0f3df47d166dff14 Mon Sep 17 00:00:00 2001 From: ajs124 Date: Sat, 6 Feb 2021 18:30:20 +0100 Subject: [PATCH 32/51] php73: 7.3.26 -> 7.3.27 https://www.php.net/ChangeLog-7.php#7.3.27 Fixes CVE-2021-21702 --- pkgs/development/interpreters/php/7.3.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/interpreters/php/7.3.nix b/pkgs/development/interpreters/php/7.3.nix index 13b64e8cb6e..d611cb7693c 100644 --- a/pkgs/development/interpreters/php/7.3.nix +++ b/pkgs/development/interpreters/php/7.3.nix @@ -4,8 +4,8 @@ let generic = (import ./generic.nix) _args; base = callPackage generic (_args // { - version = "7.3.26"; - sha256 = "0klxnf6nhsib9b2mdls1x2wbpi04gmgwxajbn593rzalh5y5l7ip"; + version = "7.3.27"; + sha256 = "00z0vadxazm2flks9g8qmchj2pwkli880kg313jgbb1mx3shc84x"; # https://bugs.php.net/bug.php?id=76826 extraPatches = lib.optional stdenv.isDarwin ./php73-darwin-isfinite.patch; From 0761e651c469ff00394945add40827a9c64bbb79 Mon Sep 17 00:00:00 2001 From: ajs124 Date: Sat, 6 Feb 2021 18:30:45 +0100 Subject: [PATCH 33/51] php74: 7.4.14 -> 7.4.15 https://www.php.net/ChangeLog-7.php#7.4.15 Fixes CVE-2021-21702 and a some regular bugs --- pkgs/development/interpreters/php/7.4.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/interpreters/php/7.4.nix b/pkgs/development/interpreters/php/7.4.nix index 9ee0c9c9e7c..42aa28b65e6 100644 --- a/pkgs/development/interpreters/php/7.4.nix +++ b/pkgs/development/interpreters/php/7.4.nix @@ -4,8 +4,8 @@ let generic = (import ./generic.nix) _args; base = callPackage generic (_args // { - version = "7.4.14"; - sha256 = "1xm1s2w9fsd8q7kjbpqw8s4bs7ggziwws23m0ykkmvmd0l3cm2b8"; + version = "7.4.15"; + sha256 = "0mvp7b16sy9j36v9v1mhixwz16hi8mhax7rwpqy3sv24jc1bxmqv"; }); in base.withExtensions ({ all, ... }: with all; ([ From 8e8b21a0e43967b30d8ccc4f8d28803977ab8f33 Mon Sep 17 00:00:00 2001 From: ajs124 Date: Sat, 6 Feb 2021 18:31:02 +0100 Subject: [PATCH 34/51] php80: 8.0.1 -> 8.0.2 https://www.php.net/ChangeLog-8.php#8.0.2 Fixes CVE-2021-21702 and a whole buch of regular bugs --- pkgs/development/interpreters/php/8.0.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/interpreters/php/8.0.nix b/pkgs/development/interpreters/php/8.0.nix index 5779c836dd4..a4aa4842dfa 100644 --- a/pkgs/development/interpreters/php/8.0.nix +++ b/pkgs/development/interpreters/php/8.0.nix @@ -4,8 +4,8 @@ let generic = (import ./generic.nix) _args; base = callPackage generic (_args // { - version = "8.0.1"; - sha256 = "1vmx9rhks8v2198f9d6cq62bway5mrfsz72garjdwcyi82ppckn4"; + version = "8.0.2"; + sha256 = "1rm3gc2h9l0zd1ccawpg1wxqm8v8rllq417f2w5pqcdf7sgah3q0"; }); in base.withExtensions ({ all, ... }: with all; ([ From a9e03c40a1da210c17e3ea6f44a29e443c9d46ab Mon Sep 17 00:00:00 2001 From: Matej Urbas Date: Sun, 7 Feb 2021 09:49:03 +0000 Subject: [PATCH 35/51] terraform-providers.shell: uses default model --- .../cluster/terraform-providers/default.nix | 1 - .../terraform-providers/providers.json | 9 ++++++ .../terraform-providers/shell/default.nix | 32 ------------------- 3 files changed, 9 insertions(+), 33 deletions(-) delete mode 100644 pkgs/applications/networking/cluster/terraform-providers/shell/default.nix diff --git a/pkgs/applications/networking/cluster/terraform-providers/default.nix b/pkgs/applications/networking/cluster/terraform-providers/default.nix index 3570191fd84..cbabdcac72f 100644 --- a/pkgs/applications/networking/cluster/terraform-providers/default.nix +++ b/pkgs/applications/networking/cluster/terraform-providers/default.nix @@ -63,7 +63,6 @@ let libvirt = callPackage ./libvirt {}; linuxbox = callPackage ./linuxbox {}; lxd = callPackage ./lxd {}; - shell = callPackage ./shell {}; vpsadmin = callPackage ./vpsadmin {}; vercel = callPackage ./vercel {}; }; diff --git a/pkgs/applications/networking/cluster/terraform-providers/providers.json b/pkgs/applications/networking/cluster/terraform-providers/providers.json index c015afb787d..2c7b5447d2c 100644 --- a/pkgs/applications/networking/cluster/terraform-providers/providers.json +++ b/pkgs/applications/networking/cluster/terraform-providers/providers.json @@ -856,6 +856,15 @@ "sha256": "1fs96qd2b4glk8hhn5m9r04ap679g0kf3nnhjx1a2idqwrv71gcl", "version": "3.3.0" }, + "shell": { + "owner": "scottwinkler", + "provider-source-address": "registry.terraform.io/scottwinkler/shell", + "repo": "terraform-provider-shell", + "rev": "v1.6.0", + "sha256": "0jxb30vw93ibnwz8nfqapac7p9r2famzvsf2h4nfbmhkm6mpan4l", + "vendorSha256": "1p2ja6cw3dl7mx41svri6frjpgb9pxsrl7sq0rk1d3sviw0f88sg", + "version": "1.6.0" + }, "signalfx": { "owner": "terraform-providers", "repo": "terraform-provider-signalfx", diff --git a/pkgs/applications/networking/cluster/terraform-providers/shell/default.nix b/pkgs/applications/networking/cluster/terraform-providers/shell/default.nix deleted file mode 100644 index f2e9b86a646..00000000000 --- a/pkgs/applications/networking/cluster/terraform-providers/shell/default.nix +++ /dev/null @@ -1,32 +0,0 @@ -{ lib, fetchFromGitHub, buildGoModule }: -buildGoModule rec { - pname = "terraform-provider-shell"; - version = "1.6.0"; - - src = fetchFromGitHub { - owner = "scottwinkler"; - repo = pname; - rev = "v${version}"; - sha256 = "0jxb30vw93ibnwz8nfqapac7p9r2famzvsf2h4nfbmhkm6mpan4l"; - }; - - vendorSha256 = "1p2ja6cw3dl7mx41svri6frjpgb9pxsrl7sq0rk1d3sviw0f88sg"; - - doCheck = false; - - subPackages = [ "." ]; - - # Terraform allows checking the provider versions, but this breaks - # if the versions are not provided via file paths. - postInstall = "mv $out/bin/${pname}{,_v${version}}"; - - passthru.provider-source-address = "registry.terraform.io/scottwinkler/shell"; - - meta = with lib; { - inherit (src.meta) homepage; - description = "Terraform provider for executing shell commands and saving output to state file"; - changelog = "https://github.com/scottwinkler/terraform-provider-shell/releases/tag/v${version}"; - license = licenses.mpl20; - maintainers = with maintainers; [ mupdt ]; - }; -} From 02b872310d6a6503639f5a71a14f00441f961bc9 Mon Sep 17 00:00:00 2001 From: rnhmjoj Date: Tue, 2 Feb 2021 02:13:15 +0100 Subject: [PATCH 36/51] nixos/thinkfan: rewrite for 1.2 update Thinkfan underwent some major changes and the config file is now based on YAML. This commit contains a number of changes: - rewrite the module to output the new format; - add a `settings` option, following RFC 0042[1]; - add fancy type-checking for the most critical options - use upstream systemd units (which fix the resume issue) [1]: https://github.com/NixOS/rfcs/blob/master/rfcs/0042-config-option.md --- nixos/modules/services/hardware/thinkfan.nix | 254 ++++++++++++------- 1 file changed, 163 insertions(+), 91 deletions(-) diff --git a/nixos/modules/services/hardware/thinkfan.nix b/nixos/modules/services/hardware/thinkfan.nix index 3bda61ed1a9..7a5a7e1c41c 100644 --- a/nixos/modules/services/hardware/thinkfan.nix +++ b/nixos/modules/services/hardware/thinkfan.nix @@ -5,50 +5,96 @@ with lib; let cfg = config.services.thinkfan; - configFile = pkgs.writeText "thinkfan.conf" '' - # ATTENTION: There is only very basic sanity checking on the configuration. - # That means you can set your temperature limits as insane as you like. You - # can do anything stupid, e.g. turn off your fan when your CPU reaches 70°C. - # - # That's why this program is called THINKfan: You gotta think for yourself. - # - ###################################################################### - # - # IBM/Lenovo Thinkpads (thinkpad_acpi, /proc/acpi/ibm) - # ==================================================== - # - # IMPORTANT: - # - # To keep your HD from overheating, you have to specify a correction value for - # the sensor that has the HD's temperature. You need to do this because - # thinkfan uses only the highest temperature it can find in the system, and - # that'll most likely never be your HD, as most HDs are already out of spec - # when they reach 55 °C. - # Correction values are applied from left to right in the same order as the - # temperatures are read from the file. - # - # For example: - # tp_thermal /proc/acpi/ibm/thermal (0, 0, 10) - # will add a fixed value of 10 °C the 3rd value read from that file. Check out - # http://www.thinkwiki.org/wiki/Thermal_Sensors to find out how much you may - # want to add to certain temperatures. + settingsFormat = pkgs.formats.yaml { }; + configFile = settingsFormat.generate "thinkfan.yaml" cfg.settings; + thinkfan = pkgs.thinkfan.override { inherit (cfg) smartSupport; }; - ${cfg.fan} - ${cfg.sensors} + # fan-speed and temperature levels + levelType = with types; + let + tuple = ts: mkOptionType { + name = "tuple"; + merge = mergeOneOption; + check = xs: all id (zipListsWith (t: x: t.check x) ts xs); + description = "tuple of" + concatMapStrings (t: " (${t.description})") ts; + }; + level = ints.unsigned; + special = enum [ "level auto" "level full-speed" "level disengage" ]; + in + tuple [ (either level special) level level ]; - # Syntax: - # (LEVEL, LOW, HIGH) - # LEVEL is the fan level to use (0-7 with thinkpad_acpi) - # LOW is the temperature at which to step down to the previous level - # HIGH is the temperature at which to step up to the next level - # All numbers are integers. - # + # sensor or fan config + sensorType = name: types.submodule { + freeformType = types.attrsOf settingsFormat.type; + options = { + type = mkOption { + type = types.enum [ "hwmon" "atasmart" "tpacpi" "nvml" ]; + description = '' + The ${name} type, can be + hwmon for standard ${name}s, - ${cfg.levels} + atasmart to read the temperature via + S.M.A.R.T (requires smartSupport to be enabled), + + tpacpi for the legacy thinkpac_acpi driver, or + + nvml for the (proprietary) nVidia driver. + ''; + }; + query = mkOption { + type = types.str; + description = '' + The query string used to match one or more ${name}s: can be + a fullpath to the temperature file (single ${name}) or a fullpath + to a driver directory (multiple ${name}s). + + + When multiple ${name}s match, the query can be restricted using the + or options. + + ''; + }; + indices = mkOption { + type = with types; nullOr (listOf ints.unsigned); + default = null; + description = '' + A list of ${name}s to pick in case multiple ${name}s match the query. + + Indices start from 0. + ''; + }; + } // optionalAttrs (name == "sensor") { + correction = mkOption { + type = with types; nullOr (listOf int); + default = null; + description = '' + A list of values to be added to the temperature of each sensor, + can be used to equalize small discrepancies in temperature ratings. + ''; + }; + }; + }; + + # removes NixOS special and unused attributes + sensorToConf = { type, query, ... }@args: + (filterAttrs (k: v: v != null && !(elem k ["type" "query"])) args) + // { "${type}" = query; }; + + syntaxNote = name: '' + + This section slightly departs from the thinkfan.conf syntax. + The type and path must be specified like this: + + type = "tpacpi"; + query = "/proc/acpi/ibm/${name}"; + + instead of a single declaration like: + + - tpacpi: /proc/acpi/ibm/${name} + + ''; - thinkfan = pkgs.thinkfan.override { smartSupport = cfg.smartSupport; }; - in { options = { @@ -59,76 +105,93 @@ in { type = types.bool; default = false; description = '' - Whether to enable thinkfan, fan controller for IBM/Lenovo ThinkPads. + Whether to enable thinkfan, a fan control program. + + + This module targets IBM/Lenovo thinkpads by default, for + other hardware you will have configure it more carefully. + ''; + relatedPackages = [ "thinkfan" ]; }; smartSupport = mkOption { type = types.bool; default = false; description = '' - Whether to build thinkfan with SMART support to read temperatures + Whether to build thinkfan with S.M.A.R.T. support to read temperatures directly from hard disks. ''; }; sensors = mkOption { - type = types.lines; - default = '' - tp_thermal /proc/acpi/ibm/thermal (0,0,10) - ''; - description ='' - thinkfan can read temperatures from three possible sources: - - /proc/acpi/ibm/thermal - Which is provided by the thinkpad_acpi kernel - module (keyword tp_thermal) - - /sys/class/hwmon/*/temp*_input - Which may be provided by any hwmon drivers (keyword - hwmon) - - S.M.A.R.T. (requires smartSupport to be enabled) - Which reads the temperature directly from the hard - disk using libatasmart (keyword atasmart) - - Multiple sensors may be added, in which case they will be - numbered in their order of appearance. - ''; + type = types.listOf (sensorType "sensor"); + default = [ + { type = "tpacpi"; + query = "/proc/acpi/ibm/thermal"; + } + ]; + description = '' + List of temperature sensors thinkfan will monitor. + '' + syntaxNote "thermal"; }; - fan = mkOption { - type = types.str; - default = "tp_fan /proc/acpi/ibm/fan"; - description ='' - Specifies the fan we want to use. - On anything other than a Thinkpad you'll probably - use some PWM control file in /sys/class/hwmon. - A sysfs fan would be specified like this: - pwm_fan /sys/class/hwmon/hwmon2/device/pwm1 - ''; + fans = mkOption { + type = types.listOf (sensorType "fan"); + default = [ + { type = "tpacpi"; + query = "/proc/acpi/ibm/fan"; + } + ]; + description = '' + List of fans thinkfan will control. + '' + syntaxNote "fan"; }; levels = mkOption { - type = types.lines; - default = '' - (0, 0, 55) - (1, 48, 60) - (2, 50, 61) - (3, 52, 63) - (6, 56, 65) - (7, 60, 85) - (127, 80, 32767) - ''; + type = types.listOf levelType; + default = [ + [0 0 55] + [1 48 60] + [2 50 61] + [3 52 63] + [6 56 65] + [7 60 85] + ["level auto" 80 32767] + ]; description = '' - (LEVEL, LOW, HIGH) - LEVEL is the fan level to use (0-7 with thinkpad_acpi). + [LEVEL LOW HIGH] + + LEVEL is the fan level to use: it can be an integer (0-7 with thinkpad_acpi), + "level auto" (to keep the default firmware behavior), "level full-speed" or + "level disengage" (to run the fan as fast as possible). LOW is the temperature at which to step down to the previous level. HIGH is the temperature at which to step up to the next level. All numbers are integers. ''; }; + extraArgs = mkOption { + type = types.listOf types.str; + default = [ ]; + example = [ "-b" "0" ]; + description = '' + A list of extra command line arguments to pass to thinkfan. + Check the thinkfan(1) manpage for available arguments. + ''; + }; + + settings = mkOption { + type = types.attrsOf settingsFormat.type; + default = { }; + description = '' + Thinkfan settings. Use this option to configure thinkfan + settings not exposed in a NixOS option or to bypass one. + Before changing this, read the thinkfan.conf(5) + manpage and take a look at the example config file at + + ''; + }; }; @@ -138,12 +201,21 @@ in { environment.systemPackages = [ thinkfan ]; - systemd.services.thinkfan = { - description = "Thinkfan"; - after = [ "basic.target" ]; - wantedBy = [ "multi-user.target" ]; - path = [ thinkfan ]; - serviceConfig.ExecStart = "${thinkfan}/bin/thinkfan -n -c ${configFile}"; + services.thinkfan.settings = mapAttrs (k: v: mkDefault v) { + sensors = map sensorToConf cfg.sensors; + fans = map sensorToConf cfg.fans; + levels = cfg.levels; + }; + + systemd.packages = [ thinkfan ]; + + systemd.services = { + thinkfan.environment.THINKFAN_ARGS = escapeShellArgs ([ "-c" configFile ] ++ cfg.extraArgs); + + # must be added manually, see issue #81138 + thinkfan.wantedBy = [ "multi-user.target" ]; + thinkfan-wakeup.wantedBy = [ "sleep.target" ]; + thinkfan-sleep.wantedBy = [ "sleep.target" ]; }; boot.extraModprobeConfig = "options thinkpad_acpi experimental=1 fan_control=1"; From c753910d987b393acb14feab88daa0e38af3ba36 Mon Sep 17 00:00:00 2001 From: rnhmjoj Date: Tue, 2 Feb 2021 03:15:51 +0100 Subject: [PATCH 37/51] nixos/release-notes: mention thinkfan 1.2 update --- nixos/doc/manual/release-notes/rl-2103.xml | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/nixos/doc/manual/release-notes/rl-2103.xml b/nixos/doc/manual/release-notes/rl-2103.xml index 24a0281310c..9b2035d0440 100644 --- a/nixos/doc/manual/release-notes/rl-2103.xml +++ b/nixos/doc/manual/release-notes/rl-2103.xml @@ -466,6 +466,19 @@ self: super: ALSA OSS emulation (sound.enableOSSEmulation) is now disabled by default. + + + Thinkfan as been updated to 1.2.x, which comes with a + new YAML based configuration format. For this reason, several NixOS options + of the thinkfan module have been changed to non-backward compatible types. + In addition, a new option has + been added. + + + Please read the + thinkfan documentation before updating. + + From 2222cdb6c8e76a88eb953ccb3c9d12ad673eb30c Mon Sep 17 00:00:00 2001 From: Eric Bailey Date: Mon, 25 Jan 2021 10:11:49 -0600 Subject: [PATCH 38/51] maintainers: add DianaOlympos --- maintainers/maintainer-list.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix index b8f7b7d38f1..719043fc0c0 100644 --- a/maintainers/maintainer-list.nix +++ b/maintainers/maintainer-list.nix @@ -2279,6 +2279,12 @@ githubId = 265220; name = "David Leung"; }; + DianaOlympos = { + email = "DianaOlympos@noreply.github.com"; + github = "DianaOlympos"; + githubId = 15774340; + name = "Thomas Depierre"; + }; dipinhora = { email = "dipinhora+github@gmail.com"; github = "dipinhora"; From 35056b3b61a9919bbf143ce50d6cc5ceda848cde Mon Sep 17 00:00:00 2001 From: Eric Bailey Date: Sat, 23 Jan 2021 14:25:40 -0600 Subject: [PATCH 39/51] maintainers/teams: add beam team --- maintainers/team-list.nix | 12 ++++++++++++ nixos/modules/services/networking/epmd.nix | 2 ++ pkgs/development/compilers/gleam/default.nix | 2 +- .../interpreters/elixir/generic-builder.nix | 2 +- .../interpreters/erlang/generic-builder.nix | 2 +- .../development/interpreters/lfe/generic-builder.nix | 2 +- .../tools/build-managers/rebar/default.nix | 1 + .../tools/build-managers/rebar3/default.nix | 2 +- 8 files changed, 20 insertions(+), 5 deletions(-) diff --git a/maintainers/team-list.nix b/maintainers/team-list.nix index b34c3f71bd8..7d778a8ae30 100644 --- a/maintainers/team-list.nix +++ b/maintainers/team-list.nix @@ -29,6 +29,18 @@ with lib.maintainers; { scope = "Maintain ACME-related packages and modules."; }; + beam = { + members = [ + ankhers + Br1ght0ne + DianaOlympos + gleber + happysalada + yurrriq + ]; + scope = "Maintain BEAM-related packages and modules."; + }; + cinnamon = { members = [ mkg20001 diff --git a/nixos/modules/services/networking/epmd.nix b/nixos/modules/services/networking/epmd.nix index 692b75e4f08..f7cdc0fe79c 100644 --- a/nixos/modules/services/networking/epmd.nix +++ b/nixos/modules/services/networking/epmd.nix @@ -53,4 +53,6 @@ in }; }; }; + + meta.maintainers = teams.beam.members; } diff --git a/pkgs/development/compilers/gleam/default.nix b/pkgs/development/compilers/gleam/default.nix index b9c7e7e1e3d..78a335f1b7b 100644 --- a/pkgs/development/compilers/gleam/default.nix +++ b/pkgs/development/compilers/gleam/default.nix @@ -22,6 +22,6 @@ rustPlatform.buildRustPackage rec { description = "A statically typed language for the Erlang VM"; homepage = "https://gleam.run/"; license = licenses.asl20; - maintainers = with maintainers; [ Br1ght0ne ]; + maintainers = teams.beam.members; }; } diff --git a/pkgs/development/interpreters/elixir/generic-builder.nix b/pkgs/development/interpreters/elixir/generic-builder.nix index 358fff039c6..85e5fdf733c 100644 --- a/pkgs/development/interpreters/elixir/generic-builder.nix +++ b/pkgs/development/interpreters/elixir/generic-builder.nix @@ -69,6 +69,6 @@ in license = licenses.epl10; platforms = platforms.unix; - maintainers = with maintainers; [ havvy couchemar ankhers Br1ght0ne ]; + maintainers = teams.beam.members; }; }) diff --git a/pkgs/development/interpreters/erlang/generic-builder.nix b/pkgs/development/interpreters/erlang/generic-builder.nix index 4429dc1eaf3..0db577ca6eb 100644 --- a/pkgs/development/interpreters/erlang/generic-builder.nix +++ b/pkgs/development/interpreters/erlang/generic-builder.nix @@ -126,7 +126,7 @@ in stdenv.mkDerivation ({ ''; platforms = platforms.unix; - maintainers = with maintainers; [ sjmackenzie couchemar gleber ]; + maintainers = teams.beam.members; license = licenses.asl20; } // meta); } diff --git a/pkgs/development/interpreters/lfe/generic-builder.nix b/pkgs/development/interpreters/lfe/generic-builder.nix index 895054fac46..397be81e7c8 100644 --- a/pkgs/development/interpreters/lfe/generic-builder.nix +++ b/pkgs/development/interpreters/lfe/generic-builder.nix @@ -87,7 +87,7 @@ buildRebar3 { downloadPage = "https://github.com/rvirding/lfe/releases"; license = licenses.asl20; - maintainers = with maintainers; [ yurrriq ankhers ]; + maintainers = teams.beam.members; platforms = platforms.unix; }; } diff --git a/pkgs/development/tools/build-managers/rebar/default.nix b/pkgs/development/tools/build-managers/rebar/default.nix index d3926beb321..30c55dbca37 100644 --- a/pkgs/development/tools/build-managers/rebar/default.nix +++ b/pkgs/development/tools/build-managers/rebar/default.nix @@ -37,5 +37,6 @@ stdenv.mkDerivation { platforms = lib.platforms.unix; license = lib.licenses.asl20; + maintainers = lib.teams.beam.members; }; } diff --git a/pkgs/development/tools/build-managers/rebar3/default.nix b/pkgs/development/tools/build-managers/rebar3/default.nix index aa3af12c934..0c6450766b1 100644 --- a/pkgs/development/tools/build-managers/rebar3/default.nix +++ b/pkgs/development/tools/build-managers/rebar3/default.nix @@ -136,7 +136,7 @@ stdenv.mkDerivation rec { ''; platforms = lib.platforms.unix; - maintainers = with lib.maintainers; [ gleber tazjin ]; + maintainers = lib.teams.beam.members; license = lib.licenses.asl20; }; } From c6ec272c78d49dfe7b232b3c63b25c98d069e462 Mon Sep 17 00:00:00 2001 From: Logan Glasson Date: Mon, 8 Feb 2021 12:03:11 +1300 Subject: [PATCH 40/51] nixos/prometheus-nginx-exporter: only create service if nginx exporter is enabled On a system with nginx enabled but the prometheus exporter not enabled, the prometheus-nginx-exporter service should not be created. --- nixos/modules/services/monitoring/prometheus/exporters.nix | 3 --- .../services/monitoring/prometheus/exporters/nginx.nix | 7 +++++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/nixos/modules/services/monitoring/prometheus/exporters.nix b/nixos/modules/services/monitoring/prometheus/exporters.nix index 1fd85c66f84..64de15f4a2f 100644 --- a/nixos/modules/services/monitoring/prometheus/exporters.nix +++ b/nixos/modules/services/monitoring/prometheus/exporters.nix @@ -238,9 +238,6 @@ in services.prometheus.exporters.minio.minioAccessSecret = mkDefault config.services.minio.secretKey; })] ++ [(mkIf config.services.prometheus.exporters.rtl_433.enable { hardware.rtl-sdr.enable = mkDefault true; - })] ++ [(mkIf config.services.nginx.enable { - systemd.services.prometheus-nginx-exporter.after = [ "nginx.service" ]; - systemd.services.prometheus-nginx-exporter.requires = [ "nginx.service" ]; })] ++ [(mkIf config.services.postfix.enable { services.prometheus.exporters.postfix.group = mkDefault config.services.postfix.setgidGroup; })] ++ (mapAttrsToList (name: conf: diff --git a/nixos/modules/services/monitoring/prometheus/exporters/nginx.nix b/nixos/modules/services/monitoring/prometheus/exporters/nginx.nix index 56cddfc55b7..5ee8c346be1 100644 --- a/nixos/modules/services/monitoring/prometheus/exporters/nginx.nix +++ b/nixos/modules/services/monitoring/prometheus/exporters/nginx.nix @@ -42,7 +42,7 @@ in ''; }; }; - serviceOpts = { + serviceOpts = mkMerge ([{ serviceConfig = { ExecStart = '' ${pkgs.prometheus-nginx-exporter}/bin/nginx-prometheus-exporter \ @@ -54,7 +54,10 @@ in ${concatStringsSep " \\\n " cfg.extraFlags} ''; }; - }; + }] ++ [(mkIf config.services.nginx.enable { + after = [ "nginx.service" ]; + requires = [ "nginx.service" ]; + })]); imports = [ (mkRenamedOptionModule [ "telemetryEndpoint" ] [ "telemetryPath" ]) (mkRemovedOptionModule [ "insecure" ] '' From d78ddc828e0c99563ba6c997bf9fa8feefa2c9b0 Mon Sep 17 00:00:00 2001 From: Winter Date: Tue, 2 Feb 2021 19:03:29 -0500 Subject: [PATCH 41/51] maintainers: add winterqt --- maintainers/maintainer-list.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix index 3adde0d14e4..90f8a5be860 100644 --- a/maintainers/maintainer-list.nix +++ b/maintainers/maintainer-list.nix @@ -9940,6 +9940,12 @@ githubId = 6016963; name = "Patrick Winter"; }; + winterqt = { + email = "nixos@winter.cafe"; + github = "winterqt"; + githubId = 78392041; + name = "Winter"; + }; wishfort36 = { email = "42300264+wishfort36@users.noreply.github.com"; github = "wishfort36"; From 33cb47aed5a2a936aa6d1509fc3ccd3a6df4747a Mon Sep 17 00:00:00 2001 From: Winter Date: Tue, 2 Feb 2021 19:00:44 -0500 Subject: [PATCH 42/51] surface-control: init at 0.3.1-1 --- .../misc/surface-control/default.nix | 37 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 39 insertions(+) create mode 100644 pkgs/applications/misc/surface-control/default.nix diff --git a/pkgs/applications/misc/surface-control/default.nix b/pkgs/applications/misc/surface-control/default.nix new file mode 100644 index 00000000000..2c5db1fe15a --- /dev/null +++ b/pkgs/applications/misc/surface-control/default.nix @@ -0,0 +1,37 @@ +{ lib, rustPlatform, fetchFromGitHub, installShellFiles, coreutils }: + +rustPlatform.buildRustPackage rec { + pname = "surface-control"; + version = "0.3.1-1"; + + src = fetchFromGitHub { + owner = "linux-surface"; + repo = pname; + rev = "v${version}"; + sha256 = "0wclzlix0a2naxbdg3wym7yw19p2wqpcjmkf7gn8cs00shrmzjld"; + }; + + cargoSha256 = "0vi26v9mvx298kx6k5g7h8dnn7r208an9knadc23vxcrrxjr6pn5"; + + nativeBuildInputs = [ installShellFiles ]; + + postInstall = '' + installShellCompletion \ + $releaseDir/build/surface-*/out/surface.{bash,fish} \ + --zsh $releaseDir/build/surface-*/out/_surface + install -Dm 0444 -t $out/etc/udev/rules.d \ + etc/udev/40-surface-control.rules + substituteInPlace $out/etc/udev/rules.d/40-surface-control.rules \ + --replace "/usr/bin/chmod" "${coreutils}/bin/chmod" \ + --replace "/usr/bin/chown" "${coreutils}/bin/chown" + ''; + + meta = with lib; { + description = + "Control various aspects of Microsoft Surface devices on Linux from the Command-Line"; + homepage = "https://github.com/linux-surface/surface-control"; + license = licenses.mit; + maintainers = with maintainers; [ winterqt ]; + platforms = platforms.linux; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index e57409a0b91..f987d339798 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -7973,6 +7973,8 @@ in stubby = callPackage ../tools/networking/stubby { }; + surface-control = callPackage ../applications/misc/surface-control { }; + syntex = callPackage ../tools/graphics/syntex {}; sl = callPackage ../tools/misc/sl { stdenv = gccStdenv; }; From aa43e629340cc533dc9574d3d53639f665c6471b Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Sat, 6 Feb 2021 23:24:48 +0000 Subject: [PATCH 43/51] umurmur: 0.2.17 -> 0.2.19 --- pkgs/applications/networking/umurmur/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/networking/umurmur/default.nix b/pkgs/applications/networking/umurmur/default.nix index 05aa66eb39c..bf45db92098 100644 --- a/pkgs/applications/networking/umurmur/default.nix +++ b/pkgs/applications/networking/umurmur/default.nix @@ -2,13 +2,13 @@ stdenv.mkDerivation rec { pname = "umurmur"; - version = "0.2.17"; + version = "0.2.19"; src = fetchFromGitHub { owner = "umurmur"; repo = "umurmur"; rev = version; - sha256 = "074px4ygmv4ydy2pqwxwnz17f0hfswqkz5kc9qfz0iby3h5i3fyl"; + sha256 = "sha256-86wveYlM493RIuU8aKac6XTOMPv0JxlZL4qH2N2AqRU="; }; nativeBuildInputs = [ autoreconfHook ]; From 3d36400ac392f81b874e05522d9a0eef1a4549be Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Sat, 6 Feb 2021 22:39:26 +0000 Subject: [PATCH 44/51] toxic: 0.10.0 -> 0.10.1 --- .../networking/instant-messengers/toxic/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/networking/instant-messengers/toxic/default.nix b/pkgs/applications/networking/instant-messengers/toxic/default.nix index e59e5864432..fc6c78a4f67 100644 --- a/pkgs/applications/networking/instant-messengers/toxic/default.nix +++ b/pkgs/applications/networking/instant-messengers/toxic/default.nix @@ -4,13 +4,13 @@ stdenv.mkDerivation rec { pname = "toxic"; - version = "0.10.0"; + version = "0.10.1"; src = fetchFromGitHub { owner = "Tox"; repo = "toxic"; rev = "v${version}"; - sha256 = "1v9cdpy6i3xl70g75zg33sqi4aqp20by0pyjhjg5iz24fxvfaw6c"; + sha256 = "sha256-EElDi/VEYgYPpoDNatxcKQC1pnCU8kOcj0bAFojD9fU="; }; makeFlags = [ "PREFIX=$(out)"]; From 4036f1d3e2b580ae39636542f2b202f04027578f Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Sat, 6 Feb 2021 16:47:09 +0000 Subject: [PATCH 45/51] pioneer: 20200203 -> 20210203 --- pkgs/games/pioneer/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/games/pioneer/default.nix b/pkgs/games/pioneer/default.nix index 0d348e3fa9e..51eda72bdef 100644 --- a/pkgs/games/pioneer/default.nix +++ b/pkgs/games/pioneer/default.nix @@ -5,13 +5,13 @@ stdenv.mkDerivation rec { pname = "pioneer"; - version = "20200203"; + version = "20210203"; src = fetchFromGitHub{ owner = "pioneerspacesim"; repo = "pioneer"; rev = version; - sha256 = "1011xsi94jhw98mhm8kryq8ajig0qfbrdx5xdasi92bd4nk7lcp8"; + sha256 = "sha256-51HXbX15uB1Xf9Re7Qi41BnJ9OW+GeXQhylJ+HwP0f8="; }; nativeBuildInputs = [ cmake pkg-config ]; From e7aedc1e2589550f817d01092bd90c120df149d8 Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Fri, 5 Feb 2021 14:06:13 +0000 Subject: [PATCH 46/51] privoxy: 3.0.30 -> 3.0.31 --- pkgs/tools/networking/privoxy/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/tools/networking/privoxy/default.nix b/pkgs/tools/networking/privoxy/default.nix index 0b5a0d96ae5..efb57e7d247 100644 --- a/pkgs/tools/networking/privoxy/default.nix +++ b/pkgs/tools/networking/privoxy/default.nix @@ -3,11 +3,11 @@ stdenv.mkDerivation rec { pname = "privoxy"; - version = "3.0.30"; + version = "3.0.31"; src = fetchurl { url = "mirror://sourceforge/ijbswa/Sources/${version}%20%28stable%29/${pname}-${version}-stable-src.tar.gz"; - sha256 = "sha256-pP4kHF2nAQsoS/ienp4xoyHx8+scx5ZVnT+6ublBXuE="; + sha256 = "sha256-B3cpo6rHkiKk6NiKZQ2QKNFv1LDWA42o9fXkcSDQBOs="; }; hardeningEnable = [ "pie" ]; From 56f764720f9e78ec13fac62a31d6917d50148df2 Mon Sep 17 00:00:00 2001 From: Pavol Rusnak Date: Mon, 8 Feb 2021 09:31:08 +0100 Subject: [PATCH 47/51] tor: 0.4.4.6 -> 0.4.4.7 --- pkgs/tools/security/tor/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/tools/security/tor/default.nix b/pkgs/tools/security/tor/default.nix index ca68f8b71fc..8766e957aaf 100644 --- a/pkgs/tools/security/tor/default.nix +++ b/pkgs/tools/security/tor/default.nix @@ -30,11 +30,11 @@ let in stdenv.mkDerivation rec { pname = "tor"; - version = "0.4.4.6"; + version = "0.4.4.7"; src = fetchurl { url = "https://dist.torproject.org/${pname}-${version}.tar.gz"; - sha256 = "1p0zpqmbskygx0wmiijhprg8r45n2wqbbjl7kv4gbb83b0alq5az"; + sha256 = "1vh5kdx7s74il8a6gr7jydbpv0an01nla4y2r8w7h33z2wk2jv9j"; }; outputs = [ "out" "geoip" ]; From fa59b9235e8147a8dae296d7ec80770112494ca8 Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Thu, 4 Feb 2021 10:44:04 +0000 Subject: [PATCH 48/51] fldigi: 4.1.17 -> 4.1.18 --- pkgs/applications/radio/fldigi/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/radio/fldigi/default.nix b/pkgs/applications/radio/fldigi/default.nix index 51728bfb403..d14e0017f6d 100644 --- a/pkgs/applications/radio/fldigi/default.nix +++ b/pkgs/applications/radio/fldigi/default.nix @@ -2,12 +2,12 @@ libsamplerate, libpulseaudio, libXinerama, gettext, pkg-config, alsaLib }: stdenv.mkDerivation rec { - version = "4.1.17"; + version = "4.1.18"; pname = "fldigi"; src = fetchurl { url = "mirror://sourceforge/${pname}/${pname}-${version}.tar.gz"; - sha256 = "1gzff60sn3h05279f9mdi1rkdws52m28shcil16911lvlq6ki13m"; + sha256 = "sha256-PH/YSrOoS6RSWyUenVYSDa7mJqODFoSpdP2tR2+QJw0="; }; buildInputs = [ libXinerama gettext hamlib fltk14 libjpeg libpng portaudio From 70bcde432957406bba6c5a8fc6d9edfbe3ea550b Mon Sep 17 00:00:00 2001 From: AndersonTorres Date: Sun, 7 Feb 2021 23:02:59 -0300 Subject: [PATCH 49/51] 0verkill: init at 2011-01-13 --- pkgs/games/0verkill/default.nix | 39 +++++++++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 41 insertions(+) create mode 100644 pkgs/games/0verkill/default.nix diff --git a/pkgs/games/0verkill/default.nix b/pkgs/games/0verkill/default.nix new file mode 100644 index 00000000000..69a371f09d9 --- /dev/null +++ b/pkgs/games/0verkill/default.nix @@ -0,0 +1,39 @@ +{ lib +, stdenv +, fetchFromGitHub +, autoreconfHook +, xorgproto +, libX11 +, libXpm +}: + +stdenv.mkDerivation rec { + pname = "0verkill"; + version = "unstable-2011-01-13"; + + src = fetchFromGitHub { + owner = "hackndev"; + repo = pname; + rev = "522f11a3e40670bbf85e0fada285141448167968"; + sha256 = "WO7PN192HhcDl6iHIbVbH7MVMi1Tl2KyQbDa9DWRO6M="; + }; + + nativeBuildInputs = [ autoreconfHook ]; + buildInputs = [ libX11 xorgproto libXpm ]; + + configureFlags = [ "--with-x" ]; + + preAutoreconf = '' + autoupdate + ''; + + hardeningDisable = [ "all" ]; # Someday the upstream will update the code... + + meta = with lib; { + homepage = "https://github.com/hackndev/0verkill"; + description = "ASCII-ART bloody 2D action deathmatch-like game"; + license = with licenses; gpl2Only; + maintainers = with maintainers; [ AndersonTorres ]; + platforms = with platforms; unix; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 0840f57d0de..c6ed3e24ace 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -27339,6 +27339,8 @@ in zeroad = zeroadPackages.zeroad; + _0verkill = callPackage ../games/0verkill { }; + ### DESKTOP ENVIRONMENTS cdesktopenv = callPackage ../desktops/cdesktopenv { }; From 5da323fe47b645260a04b834365cdf131cd2756d Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Tue, 19 Jan 2021 12:13:00 +0000 Subject: [PATCH 50/51] ding: 1.8.1 -> 1.9 --- pkgs/applications/misc/ding/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/misc/ding/default.nix b/pkgs/applications/misc/ding/default.nix index f0a7e2a779f..36e2923522d 100644 --- a/pkgs/applications/misc/ding/default.nix +++ b/pkgs/applications/misc/ding/default.nix @@ -10,11 +10,11 @@ let }; in stdenv.mkDerivation rec { - name = "ding-1.8.1"; + name = "ding-1.9"; src = fetchurl { url = "http://ftp.tu-chemnitz.de/pub/Local/urz/ding/${name}.tar.gz"; - sha256 = "0chjqs3z9zs1w3l7b5lsaj682rgnkf9kibcbzhggqqcn1pbvl5sq"; + sha256 = "sha256-aabIH894WihsBTo1LzIBzIZxxyhRYVxLcHpDQwmwmOU="; }; buildInputs = [ aspellEnv fortune gnugrep makeWrapper tk tre ]; From d2e0fb3122038a404d27815ee30be075cb41e702 Mon Sep 17 00:00:00 2001 From: Ingo Blechschmidt Date: Tue, 12 Jan 2021 02:21:24 +0100 Subject: [PATCH 51/51] abuse: init at 0.8 --- pkgs/games/abuse/abuse.sh | 18 +++++++++++ pkgs/games/abuse/default.nix | 54 +++++++++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 3 files changed, 74 insertions(+) create mode 100644 pkgs/games/abuse/abuse.sh create mode 100644 pkgs/games/abuse/default.nix diff --git a/pkgs/games/abuse/abuse.sh b/pkgs/games/abuse/abuse.sh new file mode 100644 index 00000000000..de837d27181 --- /dev/null +++ b/pkgs/games/abuse/abuse.sh @@ -0,0 +1,18 @@ +#! @shell@ + +if grep datadir ~/.abuse/abuserc &>/dev/null; then + if [ ! -d "$(grep datadir ~/.abuse/abuserc | cut -d= -f2)" ]; then + echo "Warning: ~/.abuse/abuserc references a datadir which is not existent." >&2 + echo "Try removing ~/.abuse/abuserc, else abuse will most likely not run." >&2 + echo >&2 + # This can happen if the build hash of abuse changes and the older version + # is garbage-collected. The correct path of the datadir is compiled into + # the binary, but unfortunately abuse writes out the path into abuserc on + # first start. This entry may later become stale. + fi +fi + +# The timidity bundled into SDL_mixer looks in . and in several global places +# like /etc for its configuration file. +cd @out@/etc +exec @out@/bin/.abuse-bin "$@" diff --git a/pkgs/games/abuse/default.nix b/pkgs/games/abuse/default.nix new file mode 100644 index 00000000000..2e863022a68 --- /dev/null +++ b/pkgs/games/abuse/default.nix @@ -0,0 +1,54 @@ +{ lib, stdenv, fetchurl, makeDesktopItem, copyDesktopItems, SDL, SDL_mixer, freepats }: + +stdenv.mkDerivation rec { + pname = "abuse"; + version = "0.8"; + + src = fetchurl { + url = "http://abuse.zoy.org/raw-attachment/wiki/download/${pname}-${version}.tar.gz"; + sha256 = "0104db5fd2695c9518583783f7aaa7e5c0355e27c5a803840a05aef97f9d3488"; + }; + + configureFlags = [ + "--with-x" + "--with-assetdir=$(out)/orig" + # The "--enable-debug" is to work around a segfault on start, see https://bugs.archlinux.org/task/52915. + "--enable-debug" + ]; + + desktopItems = [ (makeDesktopItem { + name = "abuse"; + exec = "abuse"; + icon = "abuse"; + desktopName = "Abuse"; + comment = "Side-scroller action game that pits you against ruthless alien killers"; + categories = "Game;ActionGame;"; + }) ]; + + postInstall = '' + mkdir $out/etc + echo -e "dir ${freepats}\nsource ${freepats}/freepats.cfg" > $out/etc/timidity.cfg + + mv $out/bin/abuse $out/bin/.abuse-bin + substituteAll "${./abuse.sh}" $out/bin/abuse + chmod +x $out/bin/abuse + + install -Dm644 doc/abuse.png $out/share/pixmaps/abuse.png + ''; + + nativeBuildInputs = [ copyDesktopItems ]; + buildInputs = [ SDL SDL_mixer freepats ]; + + meta = with lib; { + description = "Side-scroller action game that pits you against ruthless alien killers"; + homepage = "http://abuse.zoy.org/"; + license = with licenses; [ unfree ]; + # Most of abuse is free (public domain, GPL2+, WTFPL), however the creator + # of its sfx and music only gave Debian permission to redistribute the + # files. Our friends from Debian thought about it some more: + # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=648272 + maintainers = with maintainers; [ iblech ]; + platforms = platforms.unix; + broken = stdenv.isDarwin; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index c6ed3e24ace..bac6dd13abb 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -26344,6 +26344,8 @@ in abbaye-des-morts = callPackage ../games/abbaye-des-morts { }; + abuse = callPackage ../games/abuse { }; + adom = callPackage ../games/adom { }; airstrike = callPackage ../games/airstrike { };