++ lib.optional (!cgiSupport) "--disable-cgi" ++ lib.optional (!cliSupport) "--disable-cli" ++ lib.optional fpmSupport    "--enable-fpm" <del> ++ lib.optional pearSupport [ "--with-pear=$(out)/lib/php/pear" "--enable-xml" "--with-libxml" ] </del> <ins> ++ lib.optional pearSupport [ "--with-pear" "--enable-xml" "--with-libxml" ] </ins> ++ lib.optionals (pearSupport && (lib.versionOlder version "7.4")) [ "--enable-libxml" "--with-libxml-dir=${libxml2.dev}"


{stdenv, fetchurl}: stdenv.mkDerivation rec { <del> name = "ncompress-4.2.4.3"; </del> <ins> name = "ncompress-4.2.4.4"; </ins> builder = ./builder.sh;


src = fetchurl { url = "mirror://sourceforge/project/ncompress/${name}.tar.gz"; <del> sha256 = "1y44ixc1w2vfvj1lm4dkcljlwv882ynrvm5i6l0lg1gf883j246l"; </del> <ins> sha256 = "0yjiwv1hwb253x3m6r1dq2k7m5c9nz0ib2j7fnm3hark7y6s42xh"; </ins> }; meta = {


intltool gtk-doc perl <ins> python3.pkgs.wrapPython </ins> ]; # use locales from cinnamon-translations (not using --localedir because datadir is used)


patchShebangs src/data-to-c.pl ''; <ins> preFixup = '' # https://github.com/NixOS/nixpkgs/issues/101881 gappsWrapperArgs+=( --prefix XDG_DATA_DIRS : "${gnome.caribou}/share" ) # https://github.com/NixOS/nixpkgs/issues/129946 buildPythonPath "${python3.pkgs.xapp}" patchPythonScript $out/share/cinnamon/cinnamon-desktop-editor/cinnamon-desktop-editor.py ''; </ins> passthru = { providedSessions = [ "cinnamon" "cinnamon2d" ]; };


{ stdenv, fetchurl, pkgconfig, yasm <del> , freetype, fribidi </del> <ins> , freetype, fribidi, harfbuzz </ins> , encaSupport ? true, enca ? null # enca support , fontconfigSupport ? true, fontconfig ? null # fontconfig support <del> , harfbuzzSupport ? true, harfbuzz ? null # harfbuzz support </del> , rasterizerSupport ? false # Internal rasterizer , largeTilesSupport ? false # Use larger tiles in the rasterizer , libiconv


assert encaSupport -> enca != null; assert fontconfigSupport -> fontconfig != null; <del> assert harfbuzzSupport -> harfbuzz != null; </del> let mkFlag = optSet: flag: if optSet then "--enable-${flag}" else "--disable-${flag}";


with stdenv.lib; stdenv.mkDerivation rec { pname = "libass"; <del> version = "0.14.0"; </del> <ins> version = "0.15.0"; </ins> src = fetchurl { url = "https://github.com/libass/libass/releases/download/${version}/${pname}-${version}.tar.xz"; <del> sha256 = "18iqznl4mabhj9ywfsz4kwvbsplcv1jjxq50nxssvbj8my1267w8"; </del> <ins> sha256 = "0cz8v6kh3f2j5rdjrra2z0h715fa16vjm7kambvqx9hak86262cz"; </ins> }; configureFlags = [ (mkFlag encaSupport "enca") (mkFlag fontconfigSupport "fontconfig") <del> (mkFlag harfbuzzSupport "harfbuzz") </del> (mkFlag rasterizerSupport "rasterizer") (mkFlag largeTilesSupport "large-tiles") ]; nativeBuildInputs = [ pkgconfig yasm ]; <del> buildInputs = [ freetype fribidi ] </del> <ins> buildInputs = [ freetype fribidi harfbuzz ] </ins> ++ optional encaSupport enca ++ optional fontconfigSupport fontconfig <del> ++ optional harfbuzzSupport harfbuzz </del> ++ optional stdenv.isDarwin libiconv; meta = {


<del> diff -ru3 SDL2-2.0.4/sdl2-config.cmake.in SDL2-2.0.4-new/sdl2-config.cmake.in --- SDL2-2.0.4/sdl2-config.cmake.in	2016-01-02 22:56:31.000000000 +0300 +++ SDL2-2.0.4-new/sdl2-config.cmake.in	2016-08-22 05:26:42.420397323 +0300 @@ -6,5 +6,6 @@ </del> <ins> diff -ru3 SDL2-2.0.12/sdl2-config.cmake.in SDL2-2.0.12-new/sdl2-config.cmake.in --- SDL2-2.0.12/sdl2-config.cmake.in	2020-03-11 02:36:18.000000000 +0100 +++ SDL2-2.0.12-new/sdl2-config.cmake.in	2020-11-11 11:59:05.178703826 +0100 @@ -6,7 +6,8 @@ </ins> set(SDL2_PREFIX "@prefix@") set(SDL2_EXEC_PREFIX "@prefix@") set(SDL2_LIBDIR "@libdir@")


+set(SDL2_INCLUDE_DIRS "@includedir@/SDL2" $ENV{SDL2_PATH}) +separate_arguments(SDL2_INCLUDE_DIRS) set(SDL2_LIBRARIES "-L${SDL2_LIBDIR} @SDL_RLD_FLAGS@ @SDL_LIBS@") <del> diff -ru3 SDL2-2.0.4/sdl2-config.in SDL2-2.0.4-new/sdl2-config.in --- SDL2-2.0.4/sdl2-config.in	2016-01-02 22:56:31.000000000 +0300 +++ SDL2-2.0.4-new/sdl2-config.in	2016-08-22 05:32:02.256397839 +0300 </del> <ins> string(STRIP "${SDL2_LIBRARIES}" SDL2_LIBRARIES) @@ -20,14 +21,14 @@ add_library(SDL2::SDL2 SHARED IMPORTED) set_target_properties(SDL2::SDL2 PROPERTIES -    INTERFACE_INCLUDE_DIRECTORIES "@includedir@/SDL2" +    INTERFACE_INCLUDE_DIRECTORIES "${SDL2_INCLUDE_DIRS}" IMPORTED_LINK_INTERFACE_LANGUAGES "C" IMPORTED_LOCATION "@libdir@/libSDL2.so" INTERFACE_LINK_LIBRARIES "${SDL2_EXTRA_LINK_FLAGS}") add_library(SDL2::SDL2-static STATIC IMPORTED) set_target_properties(SDL2::SDL2-static PROPERTIES -    INTERFACE_INCLUDE_DIRECTORIES "@includedir@/SDL2" +    INTERFACE_INCLUDE_DIRECTORIES "${SDL2_INCLUDE_DIRS}" IMPORTED_LINK_INTERFACE_LANGUAGES "C" IMPORTED_LOCATION "@libdir@/libSDL2.a" INTERFACE_LINK_LIBRARIES "${SDL2_EXTRA_LINK_FLAGS_STATIC}") Només a SDL2-2.0.12-new/: sdl2-config.cmake.in.orig diff -ru3 SDL2-2.0.12/sdl2-config.in SDL2-2.0.12-new/sdl2-config.in --- SDL2-2.0.12/sdl2-config.in	2020-03-11 02:36:18.000000000 +0100 +++ SDL2-2.0.12-new/sdl2-config.in	2020-11-11 11:56:26.432955479 +0100 </ins> @@ -42,7 +42,11 @@ echo @SDL_VERSION@ ;;


in rustPlatform.buildRustPackage rec { pname = "alacritty"; <del> version = "0.5.0"; </del> <ins> # 0.5.0 is not compatible with gnome 3.38 version = "0.6.0-rc1"; </ins> src = fetchFromGitHub { owner = "alacritty"; repo = pname; rev = "v${version}"; <del> sha256 = "1948j57xhqvc5y876s929x9rhd6j0xnw5c91g1zqw2rfncn602g2"; </del> <ins> sha256 = "RuIJvB0J/BQFqemOkEUiqS1uz0gMS49Dd8UQt0nbrQ0="; </ins> }; <del> cargoSha256 = "17lyzcj07f0vyki3091vgjd0w8ki11sw5m8gb3bxdph1dl04rria"; </del> <ins> cargoSha256 = "+3iZywLvy+8C7j6g9bqij2DSLjBoE2u1GXgfV04cWRY="; </ins> nativeBuildInputs = [ cmake


example = "/run/keys/ssmtp-authpass"; description = '' Path to a file that contains the password used for SMTP auth. The file <del> should not contain a trailing newline, if the password does not contain one. </del> <ins> should not contain a trailing newline, if the password does not contain one (e.g. use <command>echo -n "password" > file</command>). </ins> This file should be readable by the users that need to execute ssmtp. ''; };


stdenv.mkDerivation rec { name = "nmap${optionalString graphicalSupport "-graphical"}-${version}"; <del> version = "7.90"; </del> <ins> version = "7.80"; </ins> src = fetchurl { url = "https://nmap.org/dist/nmap-${version}.tar.bz2"; <del> sha256 = "1s20i84m9bci70lrl0p2j7h3kpbi9snmvyhc3lzc9s3mh92w6msm"; </del> <ins> sha256 = "1aizfys6l9f9grm82bk878w56mg0zpkfns3spzj157h98875mypw"; </ins> }; patches = [ ./zenmap.patch ]


<para> This chapter describes tools for creating various types of images. </para> <del> <xi:include href="images/appimagetools.xml" /> </del> <ins> <xi:include href="images/appimagetools.section.xml" /> </ins> <xi:include href="images/dockertools.section.xml" /> <xi:include href="images/ocitools.section.xml" /> <del> <xi:include href="images/snaptools.xml" /> </del> <ins> <xi:include href="images/snaptools.section.xml" /> </ins> </chapter>


<ins> # pkgs.appimageTools {#sec-pkgs-appimageTools} `pkgs.appimageTools` is a set of functions for extracting and wrapping [AppImage](https://appimage.org/) files. They are meant to be used if traditional packaging from source is infeasible, or it would take too long. To quickly run an AppImage file, `pkgs.appimage-run` can be used as well. ::: warning The `appimageTools` API is unstable and may be subject to backwards-incompatible changes in the future. ::: ## AppImage formats {#ssec-pkgs-appimageTools-formats} There are different formats for AppImages, see [the specification](https://github.com/AppImage/AppImageSpec/blob/74ad9ca2f94bf864a4a0dac1f369dd4f00bd1c28/draft.md#image-format) for details. - Type 1 images are ISO 9660 files that are also ELF executables. - Type 2 images are ELF executables with an appended filesystem. They can be told apart with `file -k`: ```ShellSession $ file -k type1.AppImage type1.AppImage: ELF 64-bit LSB executable, x86-64, version 1 (SYSV) ISO 9660 CD-ROM filesystem data 'AppImage' (Lepton 3.x), scale 0-0, spot sensor temperature 0.000000, unit celsius, color scheme 0, calibration: offset 0.000000, slope 0.000000, dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.18, BuildID[sha1]=d629f6099d2344ad82818172add1d38c5e11bc6d, stripped012- data $ file -k type2.AppImage type2.AppImage: ELF 64-bit LSB executable, x86-64, version 1 (SYSV) (Lepton 3.x), scale 232-60668, spot sensor temperature -4.187500, color scheme 15, show scale bar, calibration: offset -0.000000, slope 0.000000 (Lepton 2.x), scale 4111-45000, spot sensor temperature 412442.250000, color scheme 3, minimum point enabled, calibration: offset -75402534979642766821519867692934234112.000000, slope 5815371847733706829839455140374904832.000000, dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.18, BuildID[sha1]=79dcc4e55a61c293c5e19edbd8d65b202842579f, stripped012- data ``` Note how the type 1 AppImage is described as an `ISO 9660 CD-ROM filesystem`, and the type 2 AppImage is not. ## Wrapping {#ssec-pkgs-appimageTools-wrapping} Depending on the type of AppImage you're wrapping, you'll have to use `wrapType1` or `wrapType2`. ```nix appimageTools.wrapType2 { # or wrapType1 name = "patchwork"; src = fetchurl { url = "https://github.com/ssbc/patchwork/releases/download/v3.11.4/Patchwork-3.11.4-linux-x86_64.AppImage"; sha256 = "1blsprpkvm0ws9b96gb36f0rbf8f5jgmw4x6dsb1kswr4ysf591s"; }; extraPkgs = pkgs: with pkgs; [ ]; } ``` - `name` specifies the name of the resulting image. - `src` specifies the AppImage file to extract. - `extraPkgs` allows you to pass a function to include additional packages inside the FHS environment your AppImage is going to run in. There are a few ways to learn which dependencies an application needs: - Looking through the extracted AppImage files, reading its scripts and running `patchelf` and `ldd` on its executables. This can also be done in `appimage-run`, by setting `APPIMAGE_DEBUG_EXEC=bash`. - Running `strace -vfefile` on the wrapped executable, looking for libraries that can't be found. </ins>


<del> <section xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xi="http://www.w3.org/2001/XInclude" xml:id="sec-pkgs-appimageTools"> <title>pkgs.appimageTools</title> <para> <varname>pkgs.appimageTools</varname> is a set of functions for extracting and wrapping <link xlink:href="https://appimage.org/">AppImage</link> files. They are meant to be used if traditional packaging from source is infeasible, or it would take too long. To quickly run an AppImage file, <literal>pkgs.appimage-run</literal> can be used as well. </para> <warning> <para> The <varname>appimageTools</varname> API is unstable and may be subject to backwards-incompatible changes in the future. </para> </warning> <section xml:id="ssec-pkgs-appimageTools-formats"> <title>AppImage formats</title> <para> There are different formats for AppImages, see <link xlink:href="https://github.com/AppImage/AppImageSpec/blob/74ad9ca2f94bf864a4a0dac1f369dd4f00bd1c28/draft.md#image-format">the specification</link> for details. </para> <itemizedlist> <listitem> <para> Type 1 images are ISO 9660 files that are also ELF executables. </para> </listitem> <listitem> <para> Type 2 images are ELF executables with an appended filesystem. </para> </listitem> </itemizedlist> <para> They can be told apart with <command>file -k</command>: </para> <screen> <prompt>$ </prompt>file -k type1.AppImage type1.AppImage: ELF 64-bit LSB executable, x86-64, version 1 (SYSV) ISO 9660 CD-ROM filesystem data 'AppImage' (Lepton 3.x), scale 0-0, spot sensor temperature 0.000000, unit celsius, color scheme 0, calibration: offset 0.000000, slope 0.000000, dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.18, BuildID[sha1]=d629f6099d2344ad82818172add1d38c5e11bc6d, stripped012- data <prompt>$ </prompt>file -k type2.AppImage type2.AppImage: ELF 64-bit LSB executable, x86-64, version 1 (SYSV) (Lepton 3.x), scale 232-60668, spot sensor temperature -4.187500, color scheme 15, show scale bar, calibration: offset -0.000000, slope 0.000000 (Lepton 2.x), scale 4111-45000, spot sensor temperature 412442.250000, color scheme 3, minimum point enabled, calibration: offset -75402534979642766821519867692934234112.000000, slope 5815371847733706829839455140374904832.000000, dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.18, BuildID[sha1]=79dcc4e55a61c293c5e19edbd8d65b202842579f, stripped012- data </screen> <para> Note how the type 1 AppImage is described as an <literal>ISO 9660 CD-ROM filesystem</literal>, and the type 2 AppImage is not. </para> </section> <section xml:id="ssec-pkgs-appimageTools-wrapping"> <title>Wrapping</title> <para> Depending on the type of AppImage you're wrapping, you'll have to use <varname>wrapType1</varname> or <varname>wrapType2</varname>. </para> <programlisting> appimageTools.wrapType2 { # or wrapType1 name = "patchwork"; <co xml:id='ex-appimageTools-wrapping-1' /> src = fetchurl { <co xml:id='ex-appimageTools-wrapping-2' /> url = "https://github.com/ssbc/patchwork/releases/download/v3.11.4/Patchwork-3.11.4-linux-x86_64.AppImage"; sha256 =  "1blsprpkvm0ws9b96gb36f0rbf8f5jgmw4x6dsb1kswr4ysf591s"; }; extraPkgs = pkgs: with pkgs; [ ]; <co xml:id='ex-appimageTools-wrapping-3' /> }</programlisting> <calloutlist> <callout arearefs='ex-appimageTools-wrapping-1'> <para> <varname>name</varname> specifies the name of the resulting image. </para> </callout> <callout arearefs='ex-appimageTools-wrapping-2'> <para> <varname>src</varname> specifies the AppImage file to extract. </para> </callout> <callout arearefs='ex-appimageTools-wrapping-3'> <para> <varname>extraPkgs</varname> allows you to pass a function to include additional packages inside the FHS environment your AppImage is going to run in. There are a few ways to learn which dependencies an application needs: <itemizedlist> <listitem> <para> Looking through the extracted AppImage files, reading its scripts and running <command>patchelf</command> and <command>ldd</command> on its executables. This can also be done in <command>appimage-run</command>, by setting <command>APPIMAGE_DEBUG_EXEC=bash</command>. </para> </listitem> <listitem> <para> Running <command>strace -vfefile</command> on the wrapped executable, looking for libraries that can't be found. </para> </listitem> </itemizedlist> </para> </callout> </calloutlist> </section> </section> </del>


<del> let inherit (import <nixpkgs> { }) snapTools firefox; in snapTools.makeSnap { meta = { name = "nix-example-firefox"; summary = firefox.meta.description; architectures = [ "amd64" ]; apps.nix-example-firefox = { command = "${firefox}/bin/firefox"; plugs = [ "pulseaudio" "camera" "browser-support" "avahi-observe" "cups-control" "desktop" "desktop-legacy" "gsettings" "home" "network" "mount-observe" "removable-media" "x11" ]; }; confinement = "strict"; }; } </del>


<del> let inherit (import <nixpkgs> { }) snapTools hello; in snapTools.makeSnap { meta = { name = "hello"; summary = hello.meta.description; description = hello.meta.longDescription; architectures = [ "amd64" ]; confinement = "strict"; apps.hello.command = "${hello}/bin/hello"; }; } </del>


<ins> # pkgs.snapTools {#sec-pkgs-snapTools} `pkgs.snapTools` is a set of functions for creating Snapcraft images. Snap and Snapcraft is not used to perform these operations. ## The makeSnap Function {#ssec-pkgs-snapTools-makeSnap-signature} `makeSnap` takes a single named argument, `meta`. This argument mirrors [the upstream `snap.yaml` format](https://docs.snapcraft.io/snap-format) exactly. The `base` should not be specified, as `makeSnap` will force set it. Currently, `makeSnap` does not support creating GUI stubs. ## Build a Hello World Snap {#ssec-pkgs-snapTools-build-a-snap-hello} The following expression packages GNU Hello as a Snapcraft snap. ```{#ex-snapTools-buildSnap-hello .nix} let inherit (import <nixpkgs> { }) snapTools hello; in snapTools.makeSnap { meta = { name = "hello"; summary = hello.meta.description; description = hello.meta.longDescription; architectures = [ "amd64" ]; confinement = "strict"; apps.hello.command = "${hello}/bin/hello"; }; } ``` `nix-build` this expression and install it with `snap install ./result --dangerous`. `hello` will now be the Snapcraft version of the package. ## Build a Graphical Snap {#ssec-pkgs-snapTools-build-a-snap-firefox} Graphical programs require many more integrations with the host. This example uses Firefox as an example, because it is one of the most complicated programs we could package. ```{#ex-snapTools-buildSnap-firefox .nix} let inherit (import <nixpkgs> { }) snapTools firefox; in snapTools.makeSnap { meta = { name = "nix-example-firefox"; summary = firefox.meta.description; architectures = [ "amd64" ]; apps.nix-example-firefox = { command = "${firefox}/bin/firefox"; plugs = [ "pulseaudio" "camera" "browser-support" "avahi-observe" "cups-control" "desktop" "desktop-legacy" "gsettings" "home" "network" "mount-observe" "removable-media" "x11" ]; }; confinement = "strict"; }; } ``` `nix-build` this expression and install it with `snap install ./result --dangerous`. `nix-example-firefox` will now be the Snapcraft version of the Firefox package. The specific meaning behind plugs can be looked up in the [Snapcraft interface documentation](https://docs.snapcraft.io/supported-interfaces). </ins>


<del> <section xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xi="http://www.w3.org/2001/XInclude" xml:id="sec-pkgs-snapTools"> <title>pkgs.snapTools</title> <para> <varname>pkgs.snapTools</varname> is a set of functions for creating Snapcraft images. Snap and Snapcraft is not used to perform these operations. </para> <section xml:id="ssec-pkgs-snapTools-makeSnap-signature"> <title>The makeSnap Function</title> <para> <function>makeSnap</function> takes a single named argument, <parameter>meta</parameter>. This argument mirrors <link xlink:href="https://docs.snapcraft.io/snap-format">the upstream <filename>snap.yaml</filename> format</link> exactly. </para> <para> The <parameter>base</parameter> should not be specified, as <function>makeSnap</function> will force set it. </para> <para> Currently, <function>makeSnap</function> does not support creating GUI stubs. </para> </section> <section xml:id="ssec-pkgs-snapTools-build-a-snap-hello"> <title>Build a Hello World Snap</title> <example xml:id="ex-snapTools-buildSnap-hello"> <title>Making a Hello World Snap</title> <para> The following expression packages GNU Hello as a Snapcraft snap. </para> <programlisting><xi:include href="./snap/example-hello.nix" parse="text" /></programlisting> <para> <command>nix-build</command> this expression and install it with <command>snap install ./result --dangerous</command>. <command>hello</command> will now be the Snapcraft version of the package. </para> </example> </section> <section xml:id="ssec-pkgs-snapTools-build-a-snap-firefox"> <title>Build a Hello World Snap</title> <example xml:id="ex-snapTools-buildSnap-firefox"> <title>Making a Graphical Snap</title> <para> Graphical programs require many more integrations with the host. This example uses Firefox as an example, because it is one of the most complicated programs we could package. </para> <programlisting><xi:include href="./snap/example-firefox.nix" parse="text" /></programlisting> <para> <command>nix-build</command> this expression and install it with <command>snap install ./result --dangerous</command>. <command>nix-example-firefox</command> will now be the Snapcraft version of the Firefox package. </para> <para> The specific meaning behind plugs can be looked up in the <link xlink:href="https://docs.snapcraft.io/supported-interfaces">Snapcraft interface documentation</link>. </para> </example> </section> </section> </del>


# Somehow this does not get set automatically cmakeFlags = [ "-DSDL2MAIN_LIBRARY=${SDL2}/lib/libSDL2.so" ]; <ins> postInstall = '' install -Dm644 $src/resources/milkytracker.desktop $out/share/applications/milkytracker.desktop install -Dm644 $src/resources/pictures/carton.png $out/share/pixmaps/milkytracker.png install -Dm644 $src/resources/milkytracker.appdata $out/share/appdata/milkytracker.appdata.xml ''; </ins> meta = with stdenv.lib; { description = "Music tracker application, similar to Fasttracker II"; homepage = "http://milkytracker.org";


<del> { stdenv, lib, buildPackages, buildGoPackage, fetchFromGitHub, installShellFiles }: </del> <ins> { stdenv, lib, buildPackages, buildGoModule, fetchFromGitHub, installShellFiles }: let isCrossBuild = stdenv.hostPlatform != stdenv.buildPlatform; </ins> <del> let isCrossBuild = stdenv.hostPlatform != stdenv.buildPlatform; in buildGoPackage rec { </del> <ins> in buildGoModule rec { </ins> pname = "stern"; <del> version = "1.11.0"; goPackagePath = "github.com/wercker/stern"; </del> <ins> version = "1.13.1"; </ins> src = fetchFromGitHub { <del> owner = "wercker"; </del> <ins> owner = "stern"; </ins> repo = "stern"; <del> rev = version; sha256 = "0xndlq0ks8flzx6rdd4lnkxpkbvdy9sj1jwys5yj7p989ls8by3n"; </del> <ins> rev = "v${version}"; sha256 = "0fj6a52wb0jv5bz2j2wq3ljnlxnsj9bg3kbzgkz0vh0b63zyn782"; </ins> }; <del> deleteVendor = true; goDeps = ./deps.nix; </del> <ins> vendorSha256 = "14nrdaaby74bjbk777hr82p0ybzk3spc59lbrjn9z0q3hc0p4vaf"; </ins> nativeBuildInputs = [ installShellFiles ]; <ins> buildFlagsArray = [ "-ldflags=-s -w -X github.com/stern/stern/cmd.version=${version}" ]; </ins> postInstall = <del> let stern = if isCrossBuild then buildPackages.stern else "$out"; in </del> <ins> let stern = if isCrossBuild then buildPackages.stern else "$out"; in </ins> '' for shell in bash zsh; do ${stern}/bin/stern --completion $shell > stern.$shell


''; meta = with lib; { <del> description      = "Multi pod and container log tailing for Kubernetes"; homepage         = "https://github.com/wercker/stern"; license          = licenses.asl20; maintainers      = with maintainers; [ mbode ]; platforms        = platforms.unix; </del> <ins> description = "Multi pod and container log tailing for Kubernetes"; homepage = "https://github.com/stern/stern"; license = licenses.asl20; maintainers = with maintainers; [ mbode preisschild ]; platforms = platforms.unix; </ins> }; }


<del> # file generated from Gopkg.lock using dep2nix (https://github.com/nixcloud/dep2nix) [ { goPackagePath  = "cloud.google.com/go"; fetch = { type = "git"; url = "https://code.googlesource.com/gocloud"; rev =  "dfffe386c33fb24c34ee501e5723df5b97b98514"; sha256 = "1g681yxz4mmzapzpzxfaz1nhcr1w526793yapfsnxlbs2skap3fy"; }; } { goPackagePath  = "github.com/Azure/go-autorest"; fetch = { type = "git"; url = "https://github.com/Azure/go-autorest"; rev =  "1ff28809256a84bb6966640ff3d0371af82ccba4"; sha256 = "0sxvj2j1833bqwxvhq3wq3jgq73rnb81pnzvl0x3y1m0hzpaf2zv"; }; } { goPackagePath  = "github.com/dgrijalva/jwt-go"; fetch = { type = "git"; url = "https://github.com/dgrijalva/jwt-go"; rev =  "06ea1031745cb8b3dab3f6a236daf2b0aa468b7e"; sha256 = "08m27vlms74pfy5z79w67f9lk9zkx6a9jd68k3c4msxy75ry36mp"; }; } { goPackagePath  = "github.com/fatih/color"; fetch = { type = "git"; url = "https://github.com/fatih/color"; rev =  "2d684516a8861da43017284349b7e303e809ac21"; sha256 = "1fcfmz4wji3gqmmsdx493r7d101s58hwjalqps6hy25nva5pvmfs"; }; } { goPackagePath  = "github.com/ghodss/yaml"; fetch = { type = "git"; url = "https://github.com/ghodss/yaml"; rev =  "73d445a93680fa1a78ae23a5839bad48f32ba1ee"; sha256 = "0pg53ky4sy3sp9j4n7vgf1p3gw4nbckwqfldcmmi9rf13kjh0mr7"; }; } { goPackagePath  = "github.com/gogo/protobuf"; fetch = { type = "git"; url = "https://github.com/gogo/protobuf"; rev =  "c0656edd0d9eab7c66d1eb0c568f9039345796f7"; sha256 = "0b943dhx571lhgcs3rqzy0092mi2x5mwy2kl7g8rryhy3r5rzrz9"; }; } { goPackagePath  = "github.com/golang/glog"; fetch = { type = "git"; url = "https://github.com/golang/glog"; rev =  "23def4e6c14b4da8ac2ed8007337bc5eb5007998"; sha256 = "0jb2834rw5sykfr937fxi8hxi2zy80sj2bdn9b3jb4b26ksqng30"; }; } { goPackagePath  = "github.com/golang/protobuf"; fetch = { type = "git"; url = "https://github.com/golang/protobuf"; rev =  "b4deda0973fb4c70b50d226b1af49f3da59f5265"; sha256 = "0ya4ha7m20bw048m1159ppqzlvda4x0vdprlbk5sdgmy74h3xcdq"; }; } { goPackagePath  = "github.com/google/btree"; fetch = { type = "git"; url = "https://github.com/google/btree"; rev =  "4030bb1f1f0c35b30ca7009e9ebd06849dd45306"; sha256 = "0ba430m9fbnagacp57krgidsyrgp3ycw5r7dj71brgp5r52g82p6"; }; } { goPackagePath  = "github.com/google/gofuzz"; fetch = { type = "git"; url = "https://github.com/google/gofuzz"; rev =  "24818f796faf91cd76ec7bddd72458fbced7a6c1"; sha256 = "0cq90m2lgalrdfrwwyycrrmn785rgnxa3l3vp9yxkvnv88bymmlm"; }; } { goPackagePath  = "github.com/googleapis/gnostic"; fetch = { type = "git"; url = "https://github.com/googleapis/gnostic"; rev =  "0c5108395e2debce0d731cf0287ddf7242066aba"; sha256 = "0jf3cp5clli88gpjf24r6wxbkvngnc1kf59d4cgjczsn2wasvsfc"; }; } { goPackagePath  = "github.com/gregjones/httpcache"; fetch = { type = "git"; url = "https://github.com/gregjones/httpcache"; rev =  "787624de3eb7bd915c329cba748687a3b22666a6"; sha256 = "1zqlg9pkj7r6fqw7wv3ywvbz3bh0hvzifs2scgcraj812q5189w5"; }; } { goPackagePath  = "github.com/imdario/mergo"; fetch = { type = "git"; url = "https://github.com/imdario/mergo"; rev =  "6633656539c1639d9d78127b7d47c622b5d7b6dc"; sha256 = "1fffbq1l17i0gynmvcxypl7d9h4v81g5vlimiph5bfgf4sp4db7g"; }; } { goPackagePath  = "github.com/inconshreveable/mousetrap"; fetch = { type = "git"; url = "https://github.com/inconshreveable/mousetrap"; rev =  "76626ae9c91c4f2a10f34cad8ce83ea42c93bb75"; sha256 = "1mn0kg48xkd74brf48qf5hzp0bc6g8cf5a77w895rl3qnlpfw152"; }; } { goPackagePath  = "github.com/json-iterator/go"; fetch = { type = "git"; url = "https://github.com/json-iterator/go"; rev =  "f2b4162afba35581b6d4a50d3b8f34e33c144682"; sha256 = "0siqfghsm2lkdwinvg8x5gls3p76rq3cdm59c1r4x0b2mdfhnvcd"; }; } { goPackagePath  = "github.com/mattn/go-colorable"; fetch = { type = "git"; url = "https://github.com/mattn/go-colorable"; rev =  "167de6bfdfba052fa6b2d3664c8f5272e23c9072"; sha256 = "1nwjmsppsjicr7anq8na6md7b1z84l9ppnlr045hhxjvbkqwalvx"; }; } { goPackagePath  = "github.com/mattn/go-isatty"; fetch = { type = "git"; url = "https://github.com/mattn/go-isatty"; rev =  "6ca4dbf54d38eea1a992b3c722a76a5d1c4cb25c"; sha256 = "0zs92j2cqaw9j8qx1sdxpv3ap0rgbs0vrvi72m40mg8aa36gd39w"; }; } { goPackagePath  = "github.com/mitchellh/go-homedir"; fetch = { type = "git"; url = "https://github.com/mitchellh/go-homedir"; rev =  "b8bc1bf767474819792c23f32d8286a45736f1c6"; sha256 = "13ry4lylalkh4g2vny9cxwvryslzyzwp9r92z0b10idhdq3wad1q"; }; } { goPackagePath  = "github.com/modern-go/concurrent"; fetch = { type = "git"; url = "https://github.com/modern-go/concurrent"; rev =  "bacd9c7ef1dd9b15be4a9909b8ac7a4e313eec94"; sha256 = "0s0fxccsyb8icjmiym5k7prcqx36hvgdwl588y0491gi18k5i4zs"; }; } { goPackagePath  = "github.com/modern-go/reflect2"; fetch = { type = "git"; url = "https://github.com/modern-go/reflect2"; rev =  "4b7aa43c6742a2c18fdef89dd197aaae7dac7ccd"; sha256 = "1721y3yr3dpx5dx5ashf063qczk2awy5zjir1jvp1h5hn7qz4i49"; }; } { goPackagePath  = "github.com/petar/GoLLRB"; fetch = { type = "git"; url = "https://github.com/petar/GoLLRB"; rev =  "53be0d36a84c2a886ca057d34b6aa4468df9ccb4"; sha256 = "01xp3lcamqkvl91jg6ly202gdsgf64j39rkrcqxi6v4pbrcv7hz0"; }; } { goPackagePath  = "github.com/peterbourgon/diskv"; fetch = { type = "git"; url = "https://github.com/peterbourgon/diskv"; rev =  "5f041e8faa004a95c88a202771f4cc3e991971e6"; sha256 = "1mxpa5aad08x30qcbffzk80g9540wvbca4blc1r2qyzl65b8929b"; }; } { goPackagePath  = "github.com/pkg/errors"; fetch = { type = "git"; url = "https://github.com/pkg/errors"; rev =  "816c9085562cd7ee03e7f8188a1cfd942858cded"; sha256 = "1ws5crb7c70wdicavl6qr4g03nn6m92zd6wwp9n2ygz5c8rmxh8k"; }; } { goPackagePath  = "github.com/spf13/cobra"; fetch = { type = "git"; url = "https://github.com/spf13/cobra"; rev =  "a114f312e075f65bf30d6d9a1430113f857e543b"; sha256 = "10lmi5ni06yijxg02fcic5b7ycjkia12yma4a4lz8a56j30wykx1"; }; } { goPackagePath  = "github.com/spf13/pflag"; fetch = { type = "git"; url = "https://github.com/spf13/pflag"; rev =  "3ebe029320b2676d667ae88da602a5f854788a8a"; sha256 = "11yxs0wqy70wj106fkz8r923yg4ncnc2mbw33v48zmlg4a1rasgp"; }; } { goPackagePath  = "golang.org/x/crypto"; fetch = { type = "git"; url = "https://go.googlesource.com/crypto"; rev =  "49796115aa4b964c318aad4f3084fdb41e9aa067"; sha256 = "0pcq2drkzsw585xi6rda8imd7a139prrmvgmv8nz0zgzk6g4dy59"; }; } { goPackagePath  = "golang.org/x/net"; fetch = { type = "git"; url = "https://go.googlesource.com/net"; rev =  "1c05540f6879653db88113bc4a2b70aec4bd491f"; sha256 = "0h8yqb0vcqgllgydrf9d3rzp83w8wlr8f0nm6r1rwf2qg30pq1pd"; }; } { goPackagePath  = "golang.org/x/oauth2"; fetch = { type = "git"; url = "https://go.googlesource.com/oauth2"; rev =  "a6bd8cefa1811bd24b86f8902872e4e8225f74c4"; sha256 = "151in8qcf5y97ziavl6b03vgw4r87zqx5kg4vjhjszjbh60cfswp"; }; } { goPackagePath  = "golang.org/x/sys"; fetch = { type = "git"; url = "https://go.googlesource.com/sys"; rev =  "8e24a49d80f82323e1c4db1b5da3e0f31171a151"; sha256 = "0zsdnyb8dy98jw6f9yn6g5gdhaqwk39hqridr0mh4dhwvwvlj724"; }; } { goPackagePath  = "golang.org/x/text"; fetch = { type = "git"; url = "https://go.googlesource.com/text"; rev =  "f21a4dfb5e38f5895301dc265a8def02365cc3d0"; sha256 = "0r6x6zjzhr8ksqlpiwm5gdd7s209kwk5p4lw54xjvz10cs3qlq19"; }; } { goPackagePath  = "golang.org/x/time"; fetch = { type = "git"; url = "https://go.googlesource.com/time"; rev =  "f51c12702a4d776e4c1fa9b0fabab841babae631"; sha256 = "07wc6g2fvafkr6djsscm0jpbpl4135khhb6kpyx1953hi5d1jvyy"; }; } { goPackagePath  = "google.golang.org/appengine"; fetch = { type = "git"; url = "https://github.com/golang/appengine"; rev =  "ae0ab99deb4dc413a2b4bd6c8bdd0eb67f1e4d06"; sha256 = "1iabxnqgxvvn1239i6fvfl375vlbvhfrc03m1x2rvalmx4d6w9c7"; }; } { goPackagePath  = "gopkg.in/inf.v0"; fetch = { type = "git"; url = "https://github.com/go-inf/inf"; rev =  "3887ee99ecf07df5b447e9b00d9c0b2adaa9f3e4"; sha256 = "0rf3vwyb8aqnac9x9d6ax7z5526c45a16yjm2pvkijr6qgqz8b82"; }; } { goPackagePath  = "gopkg.in/yaml.v2"; fetch = { type = "git"; url = "https://github.com/go-yaml/yaml"; rev =  "5420a8b6744d3b0345ab293f6fcba19c978f1183"; sha256 = "0dwjrs2lp2gdlscs7bsrmyc5yf6mm4fvgw71bzr9mv2qrd2q73s1"; }; } { goPackagePath  = "k8s.io/api"; fetch = { type = "git"; url = "https://github.com/kubernetes/api"; rev =  "8be2a0b24ed0dac9cfc1ac2d987ea16cfcdbecb6"; sha256 = "1dpmd59jlkxgrp5aaf8420344c6nq4kjlc1avgcp7690yrzc50v6"; }; } { goPackagePath  = "k8s.io/apimachinery"; fetch = { type = "git"; url = "https://github.com/kubernetes/apimachinery"; rev =  "594fc14b6f143d963ea2c8132e09e73fe244b6c9"; sha256 = "0xykhpmjgagyb0ac4y0ps4v1s9bd2b1sc0simh48c41a9fk3yvr7"; }; } { goPackagePath  = "k8s.io/client-go"; fetch = { type = "git"; url = "https://github.com/kubernetes/client-go"; rev =  "739dd8f9d4801eb23e2bc43423c0b4acaaded29a"; sha256 = "15psjmb14rz4kwysim9vfbbylx0khkw29b195rziv1vk202lh28k"; }; } ] </del>  No newline at end of file


sha256 = "089r6i40lxcwzp60553b18f130asspnzqldlpii53smz52kvpirx"; }; <del> patches = [ ./glibc-fix.patch ]; </del> <ins> patches = [ # fix compilation error due to missing include ./glibc-fix.patch # restrict GDK backends to only X11 ./x11-only.patch ]; </ins> configureFlags = [ "--with-bash-path=${pkgs.bash}/bin/bash"


<ins> --- a/src/main.c	2021-02-09 13:54:32.847364236 +0100 +++ b/src/main.c	2021-02-09 10:41:51.541203271 +0100 @@ -1350,6 +1351,7 @@ vfs_file_monitor_clean(); return 1; } +            gdk_set_allowed_backends("x11"); gtk_init (&argc, &argv); int ret = custom_dialog_init( argc, argv ); if ( ret != 0 ) </ins>


# indeed GHC will refuse to compile with a binutils suffering from it. See # this comment for more information: # https://gitlab.haskell.org/ghc/ghc/issues/4210#note_78333 <del> lib.optional stdenv.targetPlatform.isAarch32 ./R_ARM_COPY.patch; </del> <ins> lib.optional (stdenv.targetPlatform.isAarch32 && stdenv.hostPlatform.system != stdenv.targetPlatform.system) ./R_ARM_COPY.patch; </ins> outputs = [ "out" "info" "man" ];


"test_count_nonzero_str" "rolling_methods"  # floating percision error ~0.1*10^8 small "num_workers_config" # flaky <ins> "test_2args_with_array[pandas1-darray1-ldexp]"  # flaky </ins> ]; meta = {


# - https://github.com/NixOS/nixpkgs/issues/108772 # - https://github.com/NixOS/nixpkgs/pull/117555 print(machine.succeed("su - alice -c 'file ~/.config/Signal/sql/db.sqlite'")) <del> # TODO: The DB should be encrypted and the following should be machine.fail # instead of machine.succeed but the DB is currently unencrypted and we # want to notice if this isn't the case anymore as the transition to a # encrypted DB can cause data loss!: </del> machine.succeed( <del> "su - alice -c 'file ~/.config/Signal/sql/db.sqlite' | grep -i sqlite" </del> <ins> "su - alice -c 'file ~/.config/Signal/sql/db.sqlite' | grep 'db.sqlite: data'" ) machine.fail( "su - alice -c 'file ~/.config/Signal/sql/db.sqlite' | grep -e SQLite -e database" </ins> ) ''; })


<ins> #!@PYTHON@ import json import os import re import shlex import sqlite3 import subprocess import sys DB_PATH = os.path.join(os.environ['HOME'], '.config/Signal/sql/db.sqlite') DB_COPY = os.path.join(os.environ['HOME'], '.config/Signal/sql/db.tmp') CONFIG_PATH = os.path.join(os.environ['HOME'], '.config/Signal/config.json') def zenity_askyesno(title, text): args = [ '@ZENITY@', '--question', '--title', shlex.quote(title), '--text', shlex.quote(text) ] return subprocess.run(args).returncode == 0 def start_signal(): os.execvp('@SIGNAL-DESKTOP@', ['@SIGNAL-DESKTOP@'] + sys.argv[1:]) def copy_pragma(name): result = subprocess.run([ '@SQLCIPHER@', DB_PATH, f"PRAGMA {name};" ], check=True, capture_output=True).stdout result = re.search(r'[0-9]+', result.decode()).group(0) subprocess.run([ '@SQLCIPHER@', DB_COPY, f"PRAGMA key = "x'{key}'"; PRAGMA {name} = {result};" ], check=True, capture_output=True) try: # Test if DB is encrypted: con = sqlite3.connect(f'file:{DB_PATH}?mode=ro', uri=True) cursor = con.cursor() cursor.execute("SELECT name FROM sqlite_master WHERE type='table';") con.close() except: # DB is encrypted, everything ok: start_signal() # DB is unencrypted! answer = zenity_askyesno( "Error: Signal-Desktop database is not encrypted", "Should we try to fix this automatically?" + "You likely want to backup ~/.config/Signal/ first." ) if not answer: answer = zenity_askyesno( "Launch Signal-Desktop", "DB is unencrypted, should we still launch Signal-Desktop?" + "Warning: This could result in data loss!" ) if not answer: print('Aborted') sys.exit(0) start_signal() # Re-encrypt the DB: with open(CONFIG_PATH) as json_file: key = json.load(json_file)['key'] result = subprocess.run([ '@SQLCIPHER@', DB_PATH, f" ATTACH DATABASE '{DB_COPY}' AS signal_db KEY "x'{key}'";" + " SELECT sqlcipher_export('signal_db');" + " DETACH DATABASE signal_db;" ]).returncode if result != 0: print('DB encryption failed') sys.exit(1) # Need to copy user_version and schema_version manually: copy_pragma('user_version') copy_pragma('schema_version') os.rename(DB_COPY, DB_PATH) start_signal() </ins>


, hunspellDicts, spellcheckerLanguage ? null # E.g. "de_DE" # For a full list of available languages: # $ cat pkgs/development/libraries/hunspell/dictionaries.nix | grep "dictFileName =" | awk '{ print $3 }' <ins> , python3 , gnome , sqlcipher </ins> }: let


# Symlink to bin mkdir -p $out/bin <del> ln -s $out/lib/Signal/signal-desktop $out/bin/signal-desktop </del> <ins> ln -s $out/lib/Signal/signal-desktop $out/bin/signal-desktop-unwrapped </ins> runHook postInstall ''; <ins> # Required for $SQLCIPHER_LIB which contains "/build/" inside the path: noAuditTmpdir = true; </ins> preFixup = '' <ins> export SQLCIPHER_LIB="$out/lib/Signal/resources/app.asar.unpacked/node_modules/better-sqlite3/build/Release/better_sqlite3.node" test -x "$SQLCIPHER_LIB" # To ensure the location hasn't changed </ins> gappsWrapperArgs+=( --prefix LD_LIBRARY_PATH : "${lib.makeLibraryPath [ stdenv.cc.cc ] }" <ins> --prefix LD_PRELOAD : "$SQLCIPHER_LIB" </ins> ${customLanguageWrapperArgs} )


patchelf --add-needed ${libpulseaudio}/lib/libpulse.so $out/lib/Signal/resources/app.asar.unpacked/node_modules/ringrtc/build/linux/libringrtc.node ''; <ins> postFixup = '' # This hack is temporarily required to avoid data-loss for users: cp ${./db-reencryption-wrapper.py} $out/bin/signal-desktop substituteInPlace $out/bin/signal-desktop  --replace '@PYTHON@' '${python3}/bin/python3'  --replace '@ZENITY@' '${gnome.zenity}/bin/zenity'  --replace '@SQLCIPHER@' '${sqlcipher}/bin/sqlcipher'  --replace '@SIGNAL-DESKTOP@' "$out/bin/signal-desktop-unwrapped" ''; </ins> # Tests if the application launches and waits for "Link your phone to Signal Desktop": passthru.tests.application-launch = nixosTests.signal-desktop;


<itemizedlist> <listitem> <para> <ins> <literal>stdenv.lib</literal> has been deprecated and will break eval in 21.11.  Please use <literal>pkgs.lib</literal> instead. See <link xlink:href="https://github.com/NixOS/nixpkgs/issues/108938">#108938</link> for details. </para> </listitem> <listitem> <para> </ins> The Mailman NixOS module (<literal>services.mailman</literal>) has a new option <xref linkend="opt-services.mailman.enablePostfix" />, defaulting to true, that controls integration with Postfix.


}; patchPhase = "patchShebangs ."; <del> preBuild = stdenv.lib.optionalString (stdenv.hostPlatform != stdenv.buildPlatform) '' </del> <ins> preBuild = lib.optionalString (stdenv.hostPlatform != stdenv.buildPlatform) '' </ins> make CC=${buildPackages.stdenv.cc}/bin/cc find_sizes mv find_sizes find_sizes_build make clean substituteInPlace Makefile --replace "./find_sizes" "./find_sizes_build" <del> substituteInPlace Makefile --replace "ar cr" "${stdenv.lib.getBin stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}ar cr" substituteInPlace Makefile --replace "ranlib" "${stdenv.lib.getBin stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}ranlib" substituteInPlace Makefile --replace "STRIP=strip" "STRIP=${stdenv.lib.getBin stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}strip" </del> <ins> substituteInPlace Makefile --replace "ar cr" "${lib.getBin stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}ar cr" substituteInPlace Makefile --replace "ranlib" "${lib.getBin stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}ranlib" substituteInPlace Makefile --replace "STRIP=strip" "STRIP=${lib.getBin stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}strip" </ins> ''; nativeBuildInputs = [ perl zlib ]; #  buildInputs = [ zlib ];


<del> { stdenv </del> <ins> { lib , stdenv </ins> , rustPlatform , fetchFromGitHub , nix-update-script


nativeBuildInputs = [ makeWrapper ]; postInstall = '' <del> wrapProgram $out/bin/cargo-valgrind --prefix PATH : ${stdenv.lib.makeBinPath [ valgrind ]} </del> <ins> wrapProgram $out/bin/cargo-valgrind --prefix PATH : ${lib.makeBinPath [ valgrind ]} </ins> ''; <del> meta = with stdenv.lib; { </del> <ins> meta = with lib; { </ins> description = ''Cargo subcommand "valgrind": runs valgrind and collects its output in a helpful manner''; homepage = "https://github.com/jfrimmel/cargo-valgrind"; license = with licenses; [ asl20 /* or */ mit ];


<del> { stdenv </del> <ins> { lib , stdenv </ins> , autoPatchelfHook , fetchurl , file


pleroma = nixosTests.pleroma; }; <del> meta = { </del> <ins> meta = with lib; { </ins> description = "ActivityPub microblogging server"; homepage = https://git.pleroma.social/pleroma/pleroma; <del> license = stdenv.lib.licenses.agpl3; maintainers = with stdenv.lib.maintainers; [ ninjatrappeur ]; </del> <ins> license = licenses.agpl3; maintainers = with maintainers; [ ninjatrappeur ]; </ins> platforms = [ "x86_64-linux" "aarch64-linux" ]; }; }


inherit lib config stdenv; }) mkDerivation; <del> # For convenience, bring in the library functions in lib/ so # packages don't have to do that themselves. inherit lib; </del> <ins> # Slated for deprecation in 21.11 lib = builtins.trace ( "Warning: `stdenv.lib` is deprecated and will be removed in the next release." + " Please use `pkgs.lib` instead." + " For more information see https://github.com/NixOS/nixpkgs/issues/108938") lib; </ins> inherit fetchurlBoot;


<del> { lib, stdenv, fetchurl, makeWrapper, jre , version ? "1.6" }: let versionMap = { "1.5" = { flinkVersion = "1.5.5"; sha256 = "18wqcqi3gyqd40nspih99gq7ylfs20b35f4dcrspffagwkfp2l4z"; }; "1.6" = { flinkVersion = "1.11.1"; sha256 = "0338bg2sb427c1rrf2cmsz63sz0yk6gclpli2lskq0mpx72wxpl0"; }; }; in with versionMap.${version}; </del> <ins> { lib, stdenv, fetchurl, makeWrapper, jre }: </ins> stdenv.mkDerivation rec { <del> name = "flink-${flinkVersion}"; </del> <ins> pname = "flink"; version = "1.12.1"; </ins> src = fetchurl { <del> url = "mirror://apache/flink/${name}/${name}-bin-scala_2.11.tgz"; inherit sha256; </del> <ins> url = "mirror://apache/flink/${pname}-${version}/${pname}-${version}-bin-scala_2.11.tgz"; sha256 = "146azc5wg1xby3nqz8mha959qy99z2h8032rfgs2mcl3d5rrsm2l"; </ins> }; nativeBuildInputs = [ makeWrapper ];


firestr = throw "firestr has been removed."; # added 2019-12-08 fish-foreign-env = throw "fish-foreign-env has been replaced with fishPlugins.foreign-env"; # added 2020-12-29, modified 2021-01-10 flameGraph = flamegraph; # added 2018-04-25 <ins> flink_1_5 = throw "flink_1_5 was removed, use flink instead"; # added 2021-01-25 </ins> flvtool2 = throw "flvtool2 has been removed."; # added 2020-11-03 foldingathome = fahclient; # added 2020-09-03 font-awesome-ttf = font-awesome; # 2018-02-25


fldigi = callPackage ../applications/radio/fldigi { }; flink = callPackage ../applications/networking/cluster/flink { }; <del> flink_1_5 = flink.override { version = "1.5"; }; </del> fllog = callPackage ../applications/radio/fllog { };


stdenv.mkDerivation rec { pname = "p11-kit"; <del> version = "0.23.21"; </del> <ins> version = "0.23.22"; </ins> src = fetchFromGitHub { owner = "p11-glue"; repo = pname; rev = version; <del> sha256 = "1w24brn8j3vwfp07p2hldw2ci06pk1cx1dvjk8jjxkccp20fk958"; </del> <ins> sha256 = "sha256-erWqElJr0iESNUk9EZiJRmSMYhns8GxuFLNw7mIIIWs="; </ins> }; outputs = [ "out" "dev"];


buildGoPackage rec { pname = "vault"; <del> version = "1.6.0"; </del> <ins> version = "1.6.1"; </ins> src = fetchFromGitHub { owner = "hashicorp"; repo = "vault"; rev = "v${version}"; <del> sha256 = "13fasdiijxy87m33wfyd8gylyz556i0bdd7xp706ip2fcckrmz7a"; </del> <ins> sha256 = "1pgyyl2zgnr3wy4k8c5xsk2s5dpl97xdfq67lpfss7fz1bij8x47"; </ins> }; goPackagePath = "github.com/hashicorp/vault";


{ stdenv, fetchurl, unzip }: let <del> version = "1.6.0"; </del> <ins> version = "1.6.1"; </ins> sources = let base = "https://releases.hashicorp.com/vault/${version}"; in { x86_64-linux = fetchurl { url = "${base}/vault_${version}_linux_amd64.zip"; <del> sha256 = "0fay6bw31x9kxmc52sh5qp63nfkwji74fbnlx8pj3smz3qnqw143"; </del> <ins> sha256 = "1la2pylcj9y5gr7hr4aaa49427y3lgxi2phhl46pqmr7an62pkbm"; </ins> }; i686-linux = fetchurl { url = "${base}/vault_${version}_linux_386.zip"; <del> sha256 = "0bjks9lpgl39cq55c9cyc0glhmyxzs37a2an8ynzza94gv5mgcxa"; </del> <ins> sha256 = "1a2rhv5bpv43qp74a49msrwr7djzy86irsn73jl0xnkh0k6ijci1"; </ins> }; x86_64-darwin = fetchurl { url = "${base}/vault_${version}_darwin_amd64.zip"; <del> sha256 = "0hl1k35x78y0hi3y5xjnzby1ygisqjyvdak7s61m9f363nsr1shh"; </del> <ins> sha256 = "0snswwai2ya26crm3ksifrmbdnajr36v4vamh7g65plg6vzban9a"; </ins> }; aarch64-linux = fetchurl { url = "${base}/vault_${version}_linux_arm64.zip"; <del> sha256 = "018a5i14x6phhx1axvx0bvqn4ggsimfizs48xbmykgiyfmzkrwgz"; </del> <ins> sha256 = "0ix99da3xd4z200dgvpfc2h1sfx6l8cipichvfjlj39md45grs89"; </ins> }; };


description = "A tool for managing secrets, this binary includes the UI"; platforms = [ "x86_64-linux" "i686-linux" "x86_64-darwin" "aarch64-linux" ]; license = licenses.mpl20; <del> maintainers = with maintainers; [ offline psyanticy mkaito ]; </del> <ins> maintainers = with maintainers; [ offline psyanticy mkaito Chili-Man ]; </ins> }; }


<del> { stdenv, fetchurl, libiconv }: </del> <ins> { lib, stdenv, fetchFromGitHub, autoreconfHook, libiconv }: </ins> stdenv.mkDerivation rec { pname = "wavpack"; <del> version = "5.3.0"; </del> <ins> version = "5.4.0"; </ins> enableParallelBuilding = true; <ins> nativeBuildInputs = [ autoreconfHook ]; </ins> buildInputs = stdenv.lib.optional stdenv.isDarwin libiconv; <del> src = fetchurl { url = "http://www.wavpack.com/${pname}-${version}.tar.bz2"; sha256 = "00baiag7rlkzc6545dqdp4p5sr7xc3n97n7qdkgx58c544x0pw5n"; </del> <ins> src = fetchFromGitHub { owner = "dbry"; repo = "WavPack"; rev = version; sha256 = "1b6szk2vmnqnv5w7h8yc1iazjlidlraq1lwjbmc3fi0snbn6qj44"; </ins> }; <del> meta = with stdenv.lib; { </del> <ins> meta = with lib; { </ins> description = "Hybrid audio compression format"; <del> homepage    = "http://www.wavpack.com/"; </del> <ins> homepage    = "https://www.wavpack.com/"; changelog   = "https://github.com/dbry/WavPack/releases/tag/${version}"; </ins> license     = licenses.bsd3; platforms   = platforms.unix; maintainers = with maintainers; [ codyopel ];


{ lib, fetchzip }: let <del> version = "2013.06.07"; # date of most recent file in distribution </del> <ins> version = "2014.08.16"; # date of most recent file in distribution </ins> in fetchzip { name = "helvetica-neue-lt-std-${version}"; <del> url = "http://www.ephifonts.com/downloads/helvetica-neue-lt-std.zip"; </del> <ins> url = "https://web.archive.org/web/20190823153624/http://ephifonts.com/downloads/helvetica-neue-lt-std.zip"; </ins> postFetch = '' mkdir -p $out/share/fonts <del> unzip -j $downloadedFile Helvetica Neue LT Std/*.otf -d $out/share/fonts/opentype </del> <ins> unzip -j $downloadedFile "Helvetica Neue LT Std/*.otf" -d $out/share/fonts/opentype </ins> ''; sha256 = "0ampp9vf9xw0sdppl4lb9i9h75ywljhdcqmzh45mx2x9m7h6xgg9"; <del> meta = { homepage = "http://www.ephifonts.com/free-helvetica-font-helvetica-neue-lt-std.html"; </del> <ins> meta = with lib; { homepage = "https://web.archive.org/web/20190926040940/http://www.ephifonts.com/free-helvetica-font-helvetica-neue-lt-std.html"; </ins> description = "Helvetica Neue LT Std font"; longDescription = '' Helvetica Neue Lt Std is one of the most highly rated and complete


font. The numbers are well spaced and defined with high accuracy. The punctuation marks are heavily detailed as well. ''; <del> license = lib.licenses.unfree; maintainers = [ lib.maintainers.romildo ]; platforms = lib.platforms.all; </del> <ins> license = licenses.unfree; platforms = platforms.all; maintainers = with maintainers; [ romildo ]; </ins> }; }


# Enable recursion into attribute sets that nix-env normally doesn't look into # so that we can get a more complete picture of the available packages for the # purposes of the index. <del> packageOverrides = super: let recurseIntoAttrs = sets: super.lib.genAttrs (builtins.filter (set: builtins.hasAttr set super) sets) (set: super.recurseIntoAttrs (builtins.getAttr set super)); in recurseIntoAttrs [ "roundcubePlugins" "emscriptenfastcompPackages" "fdbPackages" "nodePackages_latest" "nodePackages" "platformioPackages" "haskellPackages" "idrisPackages" "sconsPackages" "gns3Packages" "quicklispPackagesClisp" "quicklispPackagesSBCL" "rPackages" "apacheHttpdPackages_2_4" "zabbix50" "zabbix40" "zabbix30" "fusePackages" "nvidiaPackages" "sourceHanPackages" "atomPackages" "emacs27.pkgs" "steamPackages" "ut2004Packages" "zeroadPackages" ]; </del> <ins> packageOverrides = super: with super; lib.mapAttrs (_: set: recurseIntoAttrs set) { inherit (super) apacheHttpdPackages atomPackages fdbPackages fusePackages gns3Packages haskellPackages idrisPackages nodePackages nodePackages_latest platformioPackages quicklispPackagesClisp quicklispPackagesSBCL rPackages roundcubePlugins sconsPackages sourceHanPackages steamPackages ut2004Packages zabbix40 zabbix50 zeroadPackages ; # This is an alias which we disallow by default; explicitly allow it emacs27Packages = emacs27.pkgs; }; </ins> }


stdenv.mkDerivation rec { pname = "radvd"; <del> version = "2.18"; </del> <ins> version = "2.19"; </ins> src = fetchurl { url = "http://www.litech.org/radvd/dist/${pname}-${version}.tar.xz"; <del> sha256 = "1p2wlv3djvla0r84hdncc3wfa530xigs7z9ssc2v5r1pcpzgxgz1"; </del> <ins> sha256 = "0h722f17h7cra1sjgrxhrrvx54mm47fs039909yhbabigxch8kjn"; </ins> }; nativeBuildInputs = [ pkg-config bison flex check ];


{ stdenv , lib , fetchFromGitHub <ins> , removeReferencesTo </ins> , makeWrapper , which , writeTextFile


, installShellFiles , git , unzip <del> , dmd_bin ? "${callPackage ./bootstrap.nix { }}/bin" </del> <ins> , dmdBootstrap ? callPackage ./bootstrap.nix { } , dmd_bin ? "${dmdBootstrap}/bin" </ins> }: let


runHook postInstall ''; <ins> preFixup = '' find $out/bin -type f -exec ${removeReferencesTo}/bin/remove-references-to -t ${dmd_bin}/dmd '{}' + ''; disallowedReferences = [ dmdBootstrap ]; </ins> meta = with lib; { description = "Official reference compiler for the D language"; homepage = "https://dlang.org/";


<del> { config, ... }: { imports = [ ../sd-card/sd-image-raspberrypi4-installer.nix ]; config = { warnings = [ '' .../cd-dvd/sd-image-raspberrypi4.nix is deprecated and will eventually be removed. Please switch to .../sd-card/sd-image-raspberrypi4-installer.nix, instead. '' ]; }; } </del>


<del> { imports = [ ../../profiles/installation-device.nix ./sd-image-raspberrypi4.nix ]; # the installation media is also the installation target, # so we don't want to provide the installation configuration.nix. installer.cloneConfig = false; } </del>


<del> # To build, use: # nix-build nixos -I nixos-config=nixos/modules/installer/sd-card/sd-image-raspberrypi4.nix -A config.system.build.sdImage { config, lib, pkgs, ... }: { imports = [ ./sd-image-aarch64.nix ]; boot.kernelPackages = pkgs.linuxPackages_rpi4; } </del>


inherit system; }); <del> sd_image_raspberrypi4 = forMatchingSystems [ "aarch64-linux" ] (system: makeSdImage { module = ./modules/installer/sd-card/sd-image-raspberrypi4-installer.nix; inherit system; }); </del> # A bootable VirtualBox virtual appliance as an OVA file (i.e. packaged OVF). ova = forMatchingSystems [ "x86_64-linux" ] (system:


<ins> { lib , stdenv , fetchFromGitHub , libaio }: stdenv.mkDerivation rec { pname = "stressapptest"; version = "1.0.9"; src = fetchFromGitHub { owner = pname; repo = pname; rev = "v${version}"; sha256 = "1qzj6h6adx042rb9aiz916jna269whibvj5ys4p5nwdp17fqh922"; }; buildInputs = [ libaio ]; meta = with lib; { description = "Userspace memory and IO stress test tool"; homepage = "https://github.com/stressapptest/stressapptest"; license = with licenses; [ asl20 ]; maintainers = with lib.maintainers; [ fab ]; platforms = platforms.unix; }; } </ins>


stress-ng = callPackage ../tools/system/stress-ng { }; <ins> stressapptest = callPackage ../tools/system/stressapptest { }; </ins> stoken = callPackage ../tools/security/stoken (config.stoken or {}); storeBackup = callPackage ../tools/backup/store-backup { };


let cfg = config.services.caddy; <del> vhostToConfig = vhostName: vhostAttrs: '' ${vhostName} ${builtins.concatStringsSep " " vhostAttrs.serverAliases} { ${vhostAttrs.extraConfig} } ''; configFile = pkgs.writeText "Caddyfile" (builtins.concatStringsSep "n" ([ cfg.config ] ++ (mapAttrsToList vhostToConfig cfg.virtualHosts))); formattedConfig = pkgs.runCommand "formattedCaddyFile" { } '' ${cfg.package}/bin/caddy fmt ${configFile} > $out ''; tlsConfig = { apps.tls.automation.policies = [{ issuers = [{ inherit (cfg) ca email; module = "acme"; }]; }]; }; adaptedConfig = pkgs.runCommand "caddy-config-adapted.json" { } '' ${cfg.package}/bin/caddy adapt  --config ${formattedConfig} --adapter ${cfg.adapter} > $out ''; tlsJSON = pkgs.writeText "tls.json" (builtins.toJSON tlsConfig); # merge the TLS config options we expose with the ones originating in the Caddyfile configJSON = if cfg.ca != null then let tlsConfigMerge = '' {"apps": {"tls": {"automation": {"policies": (if .[0].apps.tls.automation.policies == .[1]?.apps.tls.automation.policies then .[0].apps.tls.automation.policies else (.[0].apps.tls.automation.policies + .[1]?.apps.tls.automation.policies) end) } } } }''; in pkgs.runCommand "caddy-config.json" { } '' ${pkgs.jq}/bin/jq -s '.[0] * ${tlsConfigMerge}' ${adaptedConfig} ${tlsJSON} > $out </del> <ins> virtualHosts = attrValues cfg.virtualHosts; acmeVHosts = filter (hostOpts: hostOpts.useACMEHost != null) virtualHosts; mkVHostConf = hostOpts: let sslCertDir = config.security.acme.certs.${hostOpts.useACMEHost}.directory; in </ins> '' <del> else adaptedConfig; </del> <ins> ${hostOpts.hostName} ${concatStringsSep " " hostOpts.serverAliases} { bind ${concatStringsSep " " hostOpts.listenAddresses} ${optionalString (hostOpts.useACMEHost != null) "tls ${sslCertDir}/cert.pem ${sslCertDir}/key.pem"} log { ${hostOpts.logFormat} } ${hostOpts.extraConfig} } ''; configFile = let Caddyfile = pkgs.writeText "Caddyfile" '' { ${optionalString (cfg.email != null) "email ${cfg.email}"} ${optionalString (cfg.acmeCA != null) "acme_ca ${cfg.acmeCA}"} log { ${cfg.logFormat} } } ${cfg.extraConfig} ''; Caddyfile-formatted = pkgs.runCommand "Caddyfile-formatted" { nativeBuildInputs = [ cfg.package ]; } '' ${cfg.package}/bin/caddy fmt ${Caddyfile} > $out ''; in if pkgs.stdenv.buildPlatform == pkgs.stdenv.hostPlatform then Caddyfile-formatted else Caddyfile; </ins> in { imports = [ (mkRemovedOptionModule [ "services" "caddy" "agree" ] "this option is no longer necessary for Caddy 2") <ins> (mkRenamedOptionModule [ "services" "caddy" "ca" ] [ "services" "caddy" "acmeCA" ]) (mkRenamedOptionModule [ "services" "caddy" "config" ] [ "services" "caddy" "extraConfig" ]) </ins> ]; <ins> # interface </ins> options.services.caddy = { enable = mkEnableOption "Caddy web server"; <del> config = mkOption { default = ""; example = '' example.com { encode gzip log root /srv/http } </del> <ins> user = mkOption { default = "caddy"; type = types.str; description = '' User account under which caddy runs. <note><para> If left as the default value this user will automatically be created on system activation, otherwise you are responsible for ensuring the user exists before the Caddy service starts. </para></note> </ins> ''; <del> type = types.lines; </del> <ins> }; group = mkOption { default = "caddy"; type = types.str; </ins> description = '' <del> Verbatim Caddyfile to use. Caddy v2 supports multiple config formats via adapters (see <option>services.caddy.adapter</option>). </del> <ins> Group account under which caddy runs. <note><para> If left as the default value this user will automatically be created on system activation, otherwise you are responsible for ensuring the user exists before the Caddy service starts. </para></note> </ins> ''; }; <del> virtualHosts = mkOption { type = types.attrsOf (types.submodule (import ./vhost-options.nix { inherit config lib; })); default = { }; example = literalExpression '' { "hydra.example.com" = { serverAliases = [ "www.hydra.example.com" ]; extraConfig = '''''' encode gzip log root /srv/http ''''''; }; }; </del> <ins> package = mkOption { default = pkgs.caddy; defaultText = literalExpression "pkgs.caddy"; type = types.package; description = '' Caddy package to use. </ins> ''; <del> description = "Declarative vhost config"; </del> }; <ins> dataDir = mkOption { type = types.path; default = "/var/lib/caddy"; description = '' The data directory for caddy. </ins> <del> user = mkOption { default = "caddy"; type = types.str; description = "User account under which caddy runs."; </del> <ins> <note> <para> If left as the default value this directory will automatically be created before the Caddy server starts, otherwise you are responsible for ensuring the directory exists with appropriate ownership and permissions. </para> <para> Caddy v2 replaced <literal>CADDYPATH</literal> with XDG directories. See <link xlink:href="https://caddyserver.com/docs/conventions#file-locations"/>. </para> </note> ''; </ins> }; <del> group = mkOption { default = "caddy"; type = types.str; description = "Group account under which caddy runs."; </del> <ins> logDir = mkOption { type = types.path; default = "/var/log/caddy"; description = '' Directory for storing Caddy access logs. <note><para> If left as the default value this directory will automatically be created before the Caddy server starts, otherwise the sysadmin is responsible for ensuring the directory exists with appropriate ownership and permissions. </para></note> ''; }; logFormat = mkOption { type = types.lines; default = '' level ERROR ''; example = literalExpression '' mkForce "level INFO"; ''; description = '' Configuration for the default logger. See <link xlink:href="https://caddyserver.com/docs/caddyfile/options#log"/> for details. ''; }; configFile = mkOption { type = types.path; default = configFile; defaultText = "A Caddyfile automatically generated by values from services.caddy.*"; example = literalExpression '' pkgs.writeText "Caddyfile" ''' example.com root * /var/www/wordpress php_fastcgi unix//run/php/php-version-fpm.sock file_server '''; ''; description = '' Override the configuration file used by Caddy. By default, NixOS generates one automatically. ''; </ins> }; adapter = mkOption {


type = types.str; description = '' Name of the config adapter to use. <del> See https://caddyserver.com/docs/config-adapters for the full list. </del> <ins> See <link xlink:href="https://caddyserver.com/docs/config-adapters"/> for the full list. <note><para> Any value other than <literal>caddyfile</literal> is only valid when providing your own <option>configFile</option>. </para></note> </ins> ''; };


default = false; type = types.bool; description = '' <del> Use saved config, if any (and prefer over configuration passed with <option>services.caddy.config</option>). </del> <ins> Use saved config, if any (and prefer over any specified configuration passed with <literal>--config</literal>). </ins> ''; }; <del> ca = mkOption { default = "https://acme-v02.api.letsencrypt.org/directory"; example = "https://acme-staging-v02.api.letsencrypt.org/directory"; type = types.nullOr types.str; </del> <ins> extraConfig = mkOption { type = types.lines; default = ""; example = '' example.com { encode gzip log root /srv/http } ''; </ins> description = '' <del> Certificate authority ACME server. The default (Let's Encrypt production server) should be fine for most people. Set it to null if you don't want to include any authority (or if you want to write a more fine-graned configuration manually) </del> <ins> Additional lines of configuration appended to the automatically generated <literal>Caddyfile</literal>. </ins> ''; }; <del> email = mkOption { default = ""; type = types.str; description = "Email address (for Let's Encrypt certificate)"; </del> <ins> virtualHosts = mkOption { type = with types; attrsOf (submodule (import ./vhost-options.nix { inherit cfg; })); default = {}; example = literalExpression '' { "hydra.example.com" = { serverAliases = [ "www.hydra.example.com" ]; extraConfig = ''' encode gzip root /srv/http '''; }; }; ''; description = '' Declarative specification of virtual hosts served by Caddy. ''; </ins> }; <del> dataDir = mkOption { default = "/var/lib/caddy"; type = types.path; </del> <ins> acmeCA = mkOption { default = "https://acme-v02.api.letsencrypt.org/directory"; example = "https://acme-staging-v02.api.letsencrypt.org/directory"; type = with types; nullOr str; </ins> description = '' <del> The data directory, for storing certificates. Before 17.09, this would create a .caddy directory. With 17.09 the contents of the .caddy directory are in the specified data directory instead. </del> <ins> The URL to the ACME CA's directory. It is strongly recommended to set this to Let's Encrypt's staging endpoint for testing or development. </ins> <del> Caddy v2 replaced CADDYPATH with XDG directories. See https://caddyserver.com/docs/conventions#file-locations. </del> <ins> Set it to <literal>null</literal> if you want to write a more fine-grained configuration manually. </ins> ''; }; <del> package = mkOption { default = pkgs.caddy; defaultText = literalExpression "pkgs.caddy"; type = types.package; </del> <ins> email = mkOption { default = null; type = with types; nullOr str; </ins> description = '' <del> Caddy package to use. </del> <ins> Your email address. Mainly used when creating an ACME account with your CA, and is highly recommended in case there are problems with your certificates. </ins> ''; }; }; <ins> # implementation </ins> config = mkIf cfg.enable { <ins> assertions = [ { assertion = cfg.adapter != "caddyfile" -> cfg.configFile != configFile; message = "Any value other than 'caddyfile' is only valid when providing your own `services.caddy.configFile`"; } ]; services.caddy.extraConfig = concatMapStringsSep "n" mkVHostConf virtualHosts; </ins> systemd.packages = [ cfg.package ]; systemd.services.caddy = { <ins> wants = map (hostOpts: "acme-finished-${hostOpts.useACMEHost}.target") acmeVHosts; after = map (hostOpts: "acme-selfsigned-${hostOpts.useACMEHost}.service") acmeVHosts; before = map (hostOpts: "acme-${hostOpts.useACMEHost}.service") acmeVHosts; </ins> wantedBy = [ "multi-user.target" ]; startLimitIntervalSec = 14400; startLimitBurst = 10;


serviceConfig = { # https://www.freedesktop.org/software/systemd/man/systemd.service.html#ExecStart= # If the empty string is assigned to this option, the list of commands to start is reset, prior assignments of this option will have no effect. <del> ExecStart = [ "" "${cfg.package}/bin/caddy run ${optionalString cfg.resume "--resume"} --config ${configJSON}" ]; ExecReload = [ "" "${cfg.package}/bin/caddy reload --config ${configJSON}" ]; </del> <ins> ExecStart = [ "" "${cfg.package}/bin/caddy run --config ${cfg.configFile} --adapter ${cfg.adapter} ${optionalString cfg.resume "--resume"}" ]; ExecReload = [ "" "${cfg.package}/bin/caddy reload --config ${cfg.configFile} --adapter ${cfg.adapter}" ]; ExecStartPre = "${cfg.package}/bin/caddy validate --config ${cfg.configFile} --adapter ${cfg.adapter}"; </ins> User = cfg.user; Group = cfg.group; ReadWriteDirectories = cfg.dataDir; <ins> StateDirectory = mkIf (cfg.dataDir == "/var/lib/caddy") [ "caddy" ]; LogsDirectory = mkIf (cfg.logDir == "/var/log/caddy") [ "caddy" ]; </ins> Restart = "on-abnormal"; <ins> SupplementaryGroups = mkIf (length acmeVHosts != 0) [ "acme" ]; </ins> # TODO: attempt to upstream these options NoNewPrivileges = true;


group = cfg.group; uid = config.ids.uids.caddy; home = cfg.dataDir; <del> createHome = true; </del> }; };


caddy.gid = config.ids.gids.caddy; }; <ins> security.acme.certs = let eachACMEHost = unique (catAttrs "useACMEHost" acmeVHosts); reloads = map (useACMEHost: nameValuePair useACMEHost { reloadServices = [ "caddy.service" ]; }) eachACMEHost; in listToAttrs reloads; </ins> }; }


<del> # This file defines the options that can be used both for the Nginx # main server configuration, and for the virtual hosts.  (The latter # has additional options that affect the web server as a whole, like # the user/group to run under.) { lib, ... }: with lib; </del> <ins> { cfg }: { config, lib, name, ... }: let inherit (lib) literalExpression mkOption types; in </ins> { options = { <ins> hostName = mkOption { type = types.str; default = name; description = "Canonical hostname for the server."; }; </ins> serverAliases = mkOption { <del> type = types.listOf types.str; </del> <ins> type = with types; listOf str; </ins> default = [ ]; example = [ "www.example.org" "example.org" ]; description = ''


''; }; <ins> listenAddresses = mkOption { type = with types; listOf str; description = '' A list of host interfaces to bind to for this virtual host. ''; default = [ ]; example = [ "127.0.0.1" "::1" ]; }; useACMEHost = mkOption { type = types.nullOr types.str; default = null; description = '' A host of an existing Let's Encrypt certificate to use. This is mostly useful if you use DNS challenges but Caddy does not currently support your provider. <emphasis>Note that this option does not create any certificates, nor does it add subdomains to existing ones – you will need to create them manually using <xref linkend="opt-security.acme.certs"/>. Additionally, you should probably add the <literal>caddy</literal> user to the <literal>acme</literal> group to grant access to the certificates.</emphasis> ''; }; logFormat = mkOption { type = types.lines; default = '' output file ${cfg.logDir}/access-${config.hostName}.log ''; defaultText = '' output file ''${config.services.caddy.logDir}/access-''${hostName}.log ''; example = literalExpression '' mkForce ''' output discard '''; ''; description = '' Configuration for HTTP request logging (also known as access logs). See <link xlink:href="https://caddyserver.com/docs/caddyfile/directives/log#log"/> for details. ''; }; </ins> extraConfig = mkOption { type = types.lines; default = ""; description = '' <del> These lines go into the vhost verbatim </del> <ins> Additional lines of configuration appended to this virtual host in the automatically generated <literal>Caddyfile</literal>. </ins> ''; }; }; }


let version = "7.2"; <del> dbrev = "5164"; </del> <ins> dbrev = "5171"; </ins> drivedbBranch = "RELEASE_7_2_DRIVEDB"; driverdb = fetchurl { url    = "https://sourceforge.net/p/smartmontools/code/${dbrev}/tree/branches/${drivedbBranch}/smartmontools/drivedb.h?format=raw"; <del> sha256 = "1vj0sv3bgcd0lwk5x450brfyxksa5fn1mjgvmj994ab8spmicc43"; </del> <ins> sha256 = "0vncr98xagbcfsxgfgxsip2qrl9q3y8va19qhv6yknlwbdfap4mn"; </ins> name   = "smartmontools-drivedb.h"; };


}; }; <del> PkgConfig = buildPerlPackage { </del> <ins> PkgConfig = buildPerlPackage rec { </ins> pname = "PkgConfig"; version = "0.25026"; src = fetchurl { url = "mirror://cpan/authors/id/P/PL/PLICEASE/PkgConfig-0.25026.tar.gz"; sha256 = "1862hzlkibqsgynrnwg43acycp4rlsv19gsybjwq39nnqb9mxfjd"; }; <ins> # support cross-compilation by simplifying the way we get version during build postPatch = '' substituteInPlace Makefile.PL --replace  'do { require "./lib/PkgConfig.pm"; $PkgConfig::VERSION; }'  '"${version}"' ''; </ins> meta = { description = "Pure-Perl Core-Only replacement for pkg-config"; license = with lib.licenses; [ artistic1 gpl1Plus ];


license = licenses.asl20; platforms = platforms.linux ++ platforms.darwin; maintainers = [ maintainers.bjornfor ]; <ins> knownVulnerabilities = [ "CVE-2018-1320" "CVE-2018-11798" "CVE-2019-0205" "CVE-2019-0210" "CVE-2020-13949" ]; </ins> }; }


license = licenses.asl20; platforms = platforms.linux ++ platforms.darwin; maintainers = [ maintainers.bjornfor ]; <ins> knownVulnerabilities = [ "CVE-2020-13949" ]; </ins> }; }


<ins> { lib , stdenv , fetchurl , installShellFiles , python3 }: stdenv.mkDerivation rec { pname = "flawfinder"; version = "2.0.15"; src = fetchurl { url = "https://dwheeler.com/flawfinder/flawfinder-${version}.tar.gz"; sha256 = "01j4szy8gwvikrfzfayfayjnc1za0jxsnxp5fsa6d06kn69wyr8a"; }; nativeBuildInputs = [ installShellFiles ]; buildInputs = [ python3 ]; installPhase = '' runHook preInstall mkdir -p $out/bin cp ${pname} $out/bin installManPage flawfinder.1 runHook postInstall ''; meta = with lib; { description = "Tool to examines C/C++ source code for security flaws"; homepage = "https://dwheeler.com/flawfinder/"; license = with licenses; [ gpl2Only ]; maintainers = with maintainers; [ fab ]; }; } </ins>


flamegraph = callPackage ../development/tools/flamegraph { }; <ins> flawfinder = callPackage ../development/tools/flawfinder { }; </ins> flips = callPackage ../tools/compression/flips { }; fmbt = callPackage ../development/tools/fmbt {


++ lib.optionals config.hardware.bluetooth.enable [ bluedevil bluez-qt pkgs.openobex pkgs.obexftp ] ++ lib.optional config.networking.networkmanager.enable plasma-nm ++ lib.optional config.hardware.pulseaudio.enable plasma-pa <ins> ++ lib.optional config.services.pipewire.pulse.enable plasma-pa </ins> ++ lib.optional config.powerManagement.enable powerdevil ++ lib.optional config.services.colord.enable pkgs.colord-kde ++ lib.optionals config.services.samba.enable [ kdenetwork-filesharing pkgs.samba ]


}; checkInputs = [ python3.pkgs.pytest ]; <ins> nativeBuildInputs = with python3.pkgs; [ setuptools-scm ]; </ins> propagatedBuildInputs = with python3.pkgs; [ Babel


++ lib.optionals (!withGui) [ "--disable-qtgui" "--disable-x11mon" ] ++ (if stdenv.isLinux then [ "--with-inotify" ] else [ "--without-inotify" ]); <del> nativeBuildInputs = [ pkg-config ]; </del> <ins> nativeBuildInputs = [ file pkg-config python3Packages.setuptools which ]; </ins> <del> buildInputs = with python3Packages; [ bison chmlib file python setuptools which xapian zlib </del> <ins> buildInputs = [ bison chmlib python3Packages.python xapian zlib </ins> ] ++ lib.optional withGui qtbase ++ lib.optional stdenv.isDarwin libiconv;


homepage = "https://www.lesbonscomptes.com/recoll/"; license = licenses.gpl2; platforms = platforms.unix; <del> maintainers = [ maintainers.jcumming ]; </del> <ins> maintainers = with maintainers; [ jcumming kiyengar ]; </ins> }; }


recaptcha_client = callPackage ../development/python-modules/recaptcha_client { }; <ins> recoll = disabledIf (!isPy3k) (toPythonModule (pkgs.recoll.override { python3Packages = self; })); </ins> recommonmark = callPackage ../development/python-modules/recommonmark { }; redbaron = callPackage ../development/python-modules/redbaron { };


config = mkIf cfg.enable (mkMerge [{ boot.kernelModules = [ "bridge" "veth" ]; <ins> boot.kernel.sysctl = { "net.ipv4.conf.all.forwarding" = mkOverride 99 true; "net.ipv4.conf.default.forwarding" = mkOverride 99 true; }; </ins> environment.systemPackages = [ cfg.package ] ++ optional cfg.enableNvidia pkgs.nvidia-docker; users.groups.docker.gid = config.ids.gids.docker;


# Must match version 4 times to ensure client and server git commits and versions are correct docker.succeed('[ $(docker version | grep ${pkgs.docker.version} | wc -l) = "4" ]') <ins> docker.succeed("systemctl restart systemd-sysctl") docker.succeed("grep 1 /proc/sys/net/ipv4/conf/all/forwarding") docker.succeed("grep 1 /proc/sys/net/ipv4/conf/default/forwarding") </ins> ''; })


<del> {   lib, buildPythonApplication, fetchPypi , altair, astor, base58, blinker, boto3, botocore, click, enum-compat , future, pillow, protobuf, requests, toml, tornado_5, tzlocal, validators, watchdog , jinja2, setuptools </del> <ins> { # Nix lib, buildPythonApplication, fetchPypi, # Build inputs altair, astor, base58, blinker, boto3, botocore, click, cachetools, enum-compat, future, GitPython, jinja2, pillow, pyarrow, pydeck, pympler, protobuf, requests, setuptools, toml, tornado, tzlocal, validators, watchdog, </ins> }: <del> buildPythonApplication rec { </del> <ins> let click_7 = click.overridePythonAttrs(old: rec { version = "7.1.2"; src = old.src.override { inherit version; sha256 = "d2b5255c7c6349bc1bd1e59e08cd12acbbd63ce649f2588755783aa94dfb6b1a"; }; }); in buildPythonApplication rec { </ins> pname = "streamlit"; <del> version = "0.50.2"; </del> <ins> version = "1.2.0"; </ins> format = "wheel"; # the only distribution available src = fetchPypi { inherit pname version format; <del> sha256 = "1wymv7qckafs0p2jdjlxjaf1xrhm3iyd185jkldanbb0na5n3ndz"; </del> <ins> sha256 = "1dzb68a8n8wvjppcmqdaqnh925b2dg6rywv51ac9q09zjxb6z11n"; </ins> }; propagatedBuildInputs = [ <del> altair astor base58 blinker boto3 botocore click enum-compat future pillow protobuf requests toml tornado_5 tzlocal validators watchdog jinja2 setuptools </del> <ins> altair astor base58 blinker boto3 botocore cachetools click_7 enum-compat future GitPython jinja2 pillow protobuf pyarrow pydeck pympler requests setuptools toml tornado tzlocal validators watchdog </ins> ]; postInstall = ''


maintainers = with maintainers; [ yrashk ]; license = licenses.asl20; }; }


, nukeReferences, patchelf, llvmPackages , makeRustPlatform, buildPgxExtension, cargo, rustc <ins> # PL/Python , pythonSupport ? false , python3 </ins> # detection of crypt fails when using llvm stdenv, so we add it manually # for <13 (where it got removed: https://github.com/postgres/postgres/commit/c45643d618e35ec2fe91438df15abd4f3c0d85ca) , libxcrypt


++ lib.optionals lz4Enabled [ lz4 ] ++ lib.optionals zstdEnabled [ zstd ] ++ lib.optionals enableSystemd [ systemd ] <ins> ++ lib.optionals pythonSupport [ python3 ] </ins> ++ lib.optionals gssSupport [ libkrb5 ] ++ lib.optionals stdenv'.isLinux [ linux-pam ] ++ lib.optionals (!stdenv'.isDarwin) [ libossp_uuid ];


] ++ lib.optionals lz4Enabled [ "--with-lz4" ] ++ lib.optionals zstdEnabled [ "--with-zstd" ] ++ lib.optionals gssSupport [ "--with-gssapi" ] <ins> ++ lib.optionals pythonSupport [ "--with-python" ] </ins> ++ lib.optionals stdenv'.hostPlatform.isRiscV [ "--disable-spinlocks" ] ++ lib.optionals jitSupport [ "--with-llvm" ] ++ lib.optionals stdenv'.isLinux [ "--with-pam" ];


, rust , rustPlatform , installShellFiles <ins> , libiconv </ins> , libobjc , Security , CoreServices


# Install completions post-install nativeBuildInputs = [ installShellFiles ]; <del> buildInputs = lib.optionals stdenv.isDarwin [ libobjc Security CoreServices Metal Foundation ]; </del> <ins> buildInputs = lib.optionals stdenv.isDarwin [ libiconv libobjc Security CoreServices Metal Foundation ]; </ins> # The rusty_v8 package will try to download a `librusty_v8.a` release at build time to our read-only filesystem # To avoid this we pre-download the file and place it in the locations it will require it in advance


{ lib , bokeh , buildPythonPackage <ins> , fetchpatch </ins> , fetchFromGitHub , fsspec , pytestCheckHook


distributed ]; <del> doCheck = false; </del> <ins> doCheck = true; </ins> checkInputs = [ pytestCheckHook


dontUseSetuptoolsCheck = true; <ins> patches = [ # dask dataframe cannot be imported in sandboxed builds # See https://github.com/dask/dask/pull/7601 (fetchpatch { url = "https://github.com/dask/dask/commit/9ce5b0d258cecb3ef38fd844135ad1f7ac3cea5f.patch"; sha256 = "sha256-1EVRYwAdTSEEH9jp+UOnrijzezZN3iYR6q6ieYJM3kY="; name = "fix-dask-dataframe-imports-in-sandbox.patch"; }) ]; </ins> postPatch = '' # versioneer hack to set version of github package echo "def get_versions(): return {'dirty': False, 'error': None, 'full-revisionid': None, 'version': '${version}'}" > dask/_version.py


disabledTests = [ "test_annotation_pack_unpack" "test_annotations_blockwise_unpack" <ins> # this test requires features of python3Packages.psutil that are # blocked in sandboxed-builds "test_auto_blocksize_csv" </ins> ]; <ins> pythonImportsCheck = [ "dask.dataframe" "dask" "dask.array" ]; </ins> meta = with lib; { description = "Minimal task scheduling abstraction"; homepage = "https://dask.org/";


options = { isoImage.isoName = mkOption { <del> default = "${config.isoImage.isoName}.iso"; </del> <ins> default = "${config.isoImage.isoBaseName}.iso"; </ins> description = '' Name of the generated ISO image file. '';


branch = "3.4.8"; sha256 = "1d0r4yja2dkkyhdwx1migq46gsrcbajiv66263a5sq5bfr9dqkch"; darwinFrameworks = [ Cocoa CoreMedia ]; <ins> knownVulnerabilities = [ "CVE-2021-30123" ]; </ins> } // args)


stdenv.mkDerivation rec { pname = "jasper"; <del> version = "2.0.28"; </del> <ins> version = "2.0.32"; </ins> src = fetchFromGitHub { owner = "jasper-software"; repo = pname; rev = "version-${version}"; <del> hash = "sha256-f3UG5w8GbwZcsFBaQN6v8kdEkKIGgizcAgaVZtKwS78="; </del> <ins> hash = "sha256-Uwgtex0MWC/pOmEr8itHMIa4wxd97c/tsTzcLgV8D0I="; </ins> }; nativeBuildInputs = [


stdenv.mkDerivation rec { pname = "libnbd"; <del> version = "1.7.5"; </del> <ins> version = "1.7.7"; </ins> src = fetchurl { url = "https://download.libguestfs.org/libnbd/${lib.versions.majorMinor version}-development/${pname}-${version}.tar.gz"; <del> sha256 = "sha256-UxQx/wnKnCB3uC9xEfq1F0l3kHAJjp9GzbeRugKyFsk="; </del> <ins> hash = "sha256-fNeu1qx+EbKitv2I8nJAmGMF5jxN2RZGPR/LJYnOjG8="; </ins> }; nativeBuildInputs = [


<del> { lib, stdenv </del> <ins> { stdenv , lib , substituteAll </ins> , fetchurl , pkg-config , which


sha256 = "161050sx3sdxqcpjkjcpf6wl4kx0jydihga7mcvrj9c2f8ly0g07"; }; <ins> patches = [ # Make PyGObject’s gi library available. (substituteAll { src = ./fix-paths.patch; pythonPaths = lib.concatMapStringsSep ", " (pkg: "'${pkg}/${python3.sitePackages}'") [ python3.pkgs.pygobject3 ]; }) ]; </ins> nativeBuildInputs = [ pkg-config which


<ins> diff --git a/src/nautilus-python.c b/src/nautilus-python.c index 843e3c6..466a513 100644 --- a/src/nautilus-python.c +++ b/src/nautilus-python.c @@ -184,6 +184,9 @@ nautilus_python_init_python (void) { return FALSE; } +    debug("Add PyGObject to path"); +    PyRun_SimpleString("import site;import functools; functools.reduce(lambda k, p: site.addsitedir(p, k), [@pythonPaths@], site._init_pathinfo())"); + /* import gobject */ debug("init_pygobject"); if (!np_init_pygobject()) { </ins>


# https://downloads.haskell.org/~ghc/8.10.2/ src = fetchurl ({ i686-linux = { <del> url = "http://haskell.org/ghc/dist/${version}/ghc-${version}-i386-deb9-linux.tar.xz"; </del> <ins> url = "${downloadsUrl}/${version}/ghc-${version}-i386-deb9-linux.tar.xz"; </ins> sha256 = "0bvwisl4w0z5z8z0da10m9sv0mhm9na2qm43qxr8zl23mn32mblx"; }; x86_64-linux = { <del> url = "http://haskell.org/ghc/dist/${version}/ghc-${version}-x86_64-deb10-linux.tar.xz"; </del> <ins> url = "${downloadsUrl}/${version}/ghc-${version}-x86_64-deb10-linux.tar.xz"; </ins> sha256 = "0chnzy9j23b2wa8clx5arwz8wnjfxyjmz9qkj548z14cqf13slcl"; }; armv7l-linux = { <del> url = "http://haskell.org/ghc/dist/${version}/ghc-${version}-armv7-deb10-linux.tar.xz"; </del> <ins> url = "${downloadsUrl}/${version}/ghc-${version}-armv7-deb10-linux.tar.xz"; </ins> sha256 = "1j41cq5d3rmlgz7hzw8f908fs79gc5mn3q5wz277lk8zdf19g75v"; }; aarch64-linux = { <del> url = "http://haskell.org/ghc/dist/${version}/ghc-${version}-aarch64-deb10-linux.tar.xz"; </del> <ins> url = "${downloadsUrl}/${version}/ghc-${version}-aarch64-deb10-linux.tar.xz"; </ins> sha256 = "14smwl3741ixnbgi0l51a7kh7xjkiannfqx15b72svky0y4l3wjw"; }; x86_64-darwin = { <del> url = "http://haskell.org/ghc/dist/${version}/ghc-${version}-x86_64-apple-darwin.tar.xz"; </del> <ins> url = "${downloadsUrl}/${version}/ghc-${version}-x86_64-apple-darwin.tar.xz"; </ins> sha256 = "1hngyq14l4f950hzhh2d204ca2gfc98pc9xdasxihzqd1jq75dzd"; }; }.${stdenv.hostPlatform.system}


else "${lib.getLib glibc}/lib/ld-linux*"; <ins> downloadsUrl = "https://downloads.haskell.org/ghc"; </ins> in stdenv.mkDerivation rec {


src = fetchurl ({ i686-linux = { # Don't use the Fedora27 build (as below) because there isn't one! <del> url = "http://haskell.org/ghc/dist/${version}/ghc-${version}-i386-deb9-linux.tar.xz"; </del> <ins> url = "${downloadsUrl}/${version}/ghc-${version}-i386-deb9-linux.tar.xz"; </ins> sha256 = "1p2h29qghql19ajk755xa0yxkn85slbds8m9n5196ris743vkp8w"; }; x86_64-linux = { # This is the Fedora build because it links against ncurses6 where the # deb9 one links against ncurses5, see here # https://github.com/NixOS/nixpkgs/issues/85924 for a discussion <del> url = "http://haskell.org/ghc/dist/${version}/ghc-${version}-x86_64-fedora27-linux.tar.xz"; </del> <ins> url = "${downloadsUrl}/${version}/ghc-${version}-x86_64-fedora27-linux.tar.xz"; </ins> sha256 = "18dlqm5d028fqh6ghzn7pgjspr5smw030jjzl3kq6q1kmwzbay6g"; }; aarch64-linux = { <del> url = "http://haskell.org/ghc/dist/${version}/ghc-${version}-aarch64-ubuntu18.04-linux.tar.xz"; </del> <ins> url = "${downloadsUrl}/${version}/ghc-${version}-aarch64-ubuntu18.04-linux.tar.xz"; </ins> sha256 = "11n7l2a36i5vxzzp85la2555q4m34l747g0pnmd81cp46y85hlhq"; }; x86_64-darwin = { <del> url = "http://haskell.org/ghc/dist/${version}/ghc-${version}-x86_64-apple-darwin.tar.xz"; </del> <ins> url = "${downloadsUrl}/${version}/ghc-${version}-x86_64-apple-darwin.tar.xz"; </ins> sha256 = "0s9188vhhgf23q3rjarwhbr524z6h2qga5xaaa2pma03sfqvvhfz"; }; }.${stdenv.hostPlatform.system}


license = licenses.agpl3; maintainers = with maintainers; [ mmahut _1000101 ]; platforms = platforms.unix; <ins> # go dependency tecbot/gorocksdb requires rocksdb 5.x but nixpkgs has only rocksdb 6.x # issue in upstream can be tracked here: https://github.com/trezor/blockbook/issues/617 broken = true; </ins> }; }


}; extraConfig = '' index index.php index.html /index.php$request_uri; <del> expires 1m; </del> add_header X-Content-Type-Options nosniff; add_header X-XSS-Protection "1; mode=block"; add_header X-Robots-Tag none;


programs.feedbackd.enable = true; <del> # https://source.puri.sm/Librem5/phosh/-/issues/303 security.pam.services.phosh = { text = '' auth    requisite       pam_nologin.so auth    required        pam_succeed_if.so user != root quiet_success auth    required        pam_securetty.so auth    requisite       pam_nologin.so ''; }; </del> <ins> security.pam.services.phosh = {}; </ins> services.gnome.core-shell.enable = true; services.gnome.core-os-services.enable = true;


gst_all_1.gstreamer gst_all_1.gst-plugins-ugly gst_all_1.gst-plugins-base <ins> json-glib # paradox launcher (Stellaris) </ins> libdrm libxkbcommon # paradox launcher mono


nativeBuildInputs = [ pkgconfig gettext perl python ]; <del> propagatedBuildInputs = [ pcre zlib libffi ] ++ libiconvOrEmpty ++ libintlOrEmpty; </del> <ins> propagatedBuildInputs = [ pcre zlib libffi ] ++ optional (!stdenv.isDarwin) libiconvOrEmpty ++ libintlOrEmpty; </ins> configureFlags = optional stdenv.isDarwin "--disable-compile-warnings"


propagatedBuildInputs = with xlibs; with stdenv.lib; [ glib cairo pango gdk_pixbuf atk ] <del> ++ optionals stdenv.isLinux [ libXrandr libXrender libXcomposite libXi libXcursor ] ++ optional stdenv.isDarwin x11 </del> <ins> ++ optionals (stdenv.isLinux || stdenv.isDarwin) [ libXrandr libXrender libXcomposite libXi libXcursor ] ++ optionals stdenv.isDarwin [ x11 libXdamage ] </ins> ++ libintlOrEmpty ++ optional xineramaSupport libXinerama ++ optionals cupsSupport [ cups ]; <del> configureFlags = "--with-xinput=yes"; </del> <ins> configureFlags = if stdenv.isDarwin then "--disable-glibtest --disable-introspection --disable-visibility" else "--with-xinput=yes"; </ins> postInstall = "rm -rf $out/share/gtk-doc";


{ stdenv, fetchurl, pkgconfig, glib, freetype, cairo, libintlOrEmpty , icu, graphite2 , withIcu ? false # recommended by upstream as default, but most don't needed and it's big <del> , withGraphite2 ? true # it is small and major distros do include it </del> <ins> , withGraphite2 ? !stdenv.isDarwin # it is small and major distros do include it </ins> }: # TODO: split non-icu and icu lib into different outputs?


enableParallelBuilding = true; <del> doCheck = true; </del> <ins> # jww (2014-05-05): The tests currently fail on Darwin: # # ERROR:testiter.c:139:iter_char_test: assertion failed: (extents.width == x1 - x0) # .../bin/sh: line 5: 14823 Abort trap: 6 srcdir=. PANGO_RC_FILE=./pangorc ${dir}$tst # FAIL: testiter doCheck = !stdenv.isDarwin; </ins> postInstall = "rm -rf $out/share/gtk-doc"; meta = {


libXmu libXext xextproto libSM libICE; ghostscript = ghostscriptX; harfbuzz = harfbuzz.override { <del> withIcu = true; withGraphite2 = true; </del> <ins> withIcu = true; withGraphite2 = !stdenv.isDarwin; </ins> }; };


buildCommand = "sed s/dot_root/agroot/g ${raw_patch} > $out"; }; # 2.42 has the patch included <del> patches = optional (lib.versionOlder version "2.42") patchToUse; </del> <ins> patches = optional (lib.versionOlder version "2.42") patchToUse ++ optionals (lib.versionOlder version "2.46.0") [ (fetchpatch { name = "CVE-2020-18032.patch"; url = "https://gitlab.com/graphviz/graphviz/-/commit/784411ca3655c80da0f6025ab20634b2a6ff696b.patch"; sha256 = "1nkw9ism8lkfvxsp5fh95i2l5s5cbjsidbb3g1kjfv10rxkyb41m"; }) ]; </ins> in stdenv.mkDerivation {


in { openvpn_24 = generic { <del> version = "2.4.9"; sha256 = "1qpbllwlha7cffsd5dlddb8rl22g9rar5zflkz1wrcllhvfkl7v4"; </del> <ins> version = "2.4.11"; sha256 = "06s4m0xvixjhd3azrzbsf4j86kah4xwr2jp6cmcpc7db33rfyyg5"; </ins> }; openvpn = generic { <del> version = "2.5.0"; sha256 = "sha256-AppCbkTWVstOEYkxnJX+b8mGQkdyT1WZ2Z35xMNHj70="; </del> <ins> version = "2.5.2"; sha256 = "sha256-sSdDg2kB82Xvr4KrJJOWfhshwh60POmo2hACoXycHcg="; </ins> }; }


<ins> diff --color -ur a/CMakeLists.txt b/CMakeLists.txt --- a/CMakeLists.txt	2021-05-30 13:46:22.256040282 +0200 +++ b/CMakeLists.txt	2021-05-30 14:15:42.530181216 +0200 @@ -333,7 +333,7 @@ # So, try first to find the CMake module provided by libxml2 package, then fallback # on the CMake's FindLibXml2.cmake module (which can lack some definition, especially # in static build case). -find_package(LibXml2 QUIET NO_MODULE) +find_package(LibXml2 QUIET MODULE) if(DEFINED LIBXML2_VERSION_STRING) set(LIBXML2_FOUND ON) set(LIBXML2_INCLUDE_DIR ${LIBXML2_INCLUDE_DIRS}) Seulement dans b: good.patch </ins>


sha256 = "0psw67mzysdb8fkh8xpcwicm7z94k8plkcc8ymxyvl6inshq0mc7"; }; <ins> # Revert after https://github.com/NixOS/nixpkgs/issues/125008 is # fixed properly patches = [ ./cmake-fix-libxml2-find-package.patch ]; </ins> nativeBuildInputs = [ cmake flex


Rglpk = [ pkgs.glpk ]; RGtk2 = [ pkgs.gtk2.dev ]; rhdf5 = [ pkgs.zlib ]; <del> Rhdf5lib = [ pkgs.zlib ]; </del> <ins> Rhdf5lib = [ pkgs.zlib.dev ]; </ins> Rhpc = [ pkgs.zlib pkgs.bzip2.dev pkgs.icu pkgs.xz.dev pkgs.mpi pkgs.pcre.dev ]; Rhtslib = [ pkgs.zlib.dev pkgs.automake pkgs.autoconf pkgs.bzip2.dev pkgs.xz.dev pkgs.curl.dev ]; rjags = [ pkgs.jags ];


index e2d292e..b13c0db 100755 --- a/configure +++ b/configure <del> @@ -2880,6 +2880,7 @@ $MAKE </del> <ins> @@ -3874,6 +3874,7 @@ </ins> echo "building the hdf5 library..."; cd ../; <del> ## we add the '-w' flag to suppress all the warnings hdf5 prints </del> +sed -i 's#/bin/mv#mv#' configure <del> ./configure --with-pic --enable-shared=no --enable-cxx  --with-szlib  CXX="${CXX}" CXFLAGS="${CXXFLAGS} -w"  </del> <ins> ./configure --with-pic --enable-shared=no --enable-cxx --enable-hl  --with-szlib=${SZIP_HOME} --with-zlib=${ZLIB_HOME}  ${WITH_S3_VFD}  </ins>


config = mkIf cfg.enable { environment.systemPackages = [ pkgs.auto-cpufreq ]; <del> systemd.packages = [ pkgs.auto-cpufreq ]; systemd.services.auto-cpufreq.path = with pkgs; [ bash coreutils ]; </del> <ins> systemd = { packages = [ pkgs.auto-cpufreq ]; services.auto-cpufreq = { # Workaround for https://github.com/NixOS/nixpkgs/issues/81138 wantedBy = [ "multi-user.target" ]; path = with pkgs; [ bash coreutils ]; }; }; </ins> }; }


python3Packages.buildPythonPackage rec { pname = "auto-cpufreq"; <del> version = "1.6.1"; </del> <ins> version = "1.6.4"; </ins> src = fetchFromGitHub { owner = "AdnanHodzic"; repo = pname; rev = "v${version}"; <del> sha256 = "sha256-oz3C1150CPfT0kkx1x7VIX/Rm06dkjyxeDPFCRJaWNc="; </del> <ins> sha256 = "sha256-9WYuAWcJGosYEsnnkqvZLXXvqF+1nBEozh6F84Kit6w="; </ins> }; propagatedBuildInputs = with python3Packages; [ click distro psutil ];


diff --git a/auto_cpufreq/core.py b/auto_cpufreq/core.py <del> index a685db8..1ca1ca1 100644 </del> <ins> index 83d0d64..04b5035 100644 </ins> --- a/auto_cpufreq/core.py +++ b/auto_cpufreq/core.py <del> @@ -72,7 +72,7 @@ def app_version(): print("Git commit:", check_output(["git", "describe", "--always"]).strip().decode()) else: print(getoutput("pacman -Qi auto-cpufreq | grep Version")) -    else: +    else: # source code (auto-cpufreq-installer) try: print("Git commit:", check_output(["git", "describe", "--always"]).strip().decode()) @@ -179,31 +179,13 @@ def get_current_gov(): return print("Currently using:", getoutput("cpufreqctl.auto-cpufreq --governor").strip().split(" ")[0], "governor") </del> <ins> @@ -204,35 +204,13 @@ def get_current_gov(): </ins> def cpufreqctl(): -    """


-    """ - -    # detect if running on a SNAP <del> -    if os.getenv('PKG_MARKER') == "SNAP": </del> <ins> -    if os.getenv("PKG_MARKER") == "SNAP": </ins> -        pass -    else: -        # deploy cpufreqctl.auto-cpufreq script -        if os.path.isfile("/usr/bin/cpufreqctl"): <del> -            shutil.copy(SCRIPTS_DIR / "cpufreqctl.sh", "/usr/bin/cpufreqctl.auto-cpufreq") </del> <ins> -            shutil.copy( -                SCRIPTS_DIR / "cpufreqctl.sh", "/usr/bin/cpufreqctl.auto-cpufreq" -            ) </ins> -        else: <del> -            shutil.copy(SCRIPTS_DIR / "cpufreqctl.sh", "/usr/bin/cpufreqctl.auto-cpufreq") </del> <ins> -            shutil.copy( -                SCRIPTS_DIR / "cpufreqctl.sh", "/usr/bin/cpufreqctl.auto-cpufreq" -            ) </ins> +    # scripts are already in the correct place +    pass


-    remove cpufreqctl.auto-cpufreq script -    """ -    # detect if running on a SNAP <del> -    if os.getenv('PKG_MARKER') == "SNAP": </del> <ins> -    if os.getenv("PKG_MARKER") == "SNAP": </ins> -        pass -    else: -        if os.path.isfile("/usr/bin/cpufreqctl.auto-cpufreq"):


+    # no need to restore +    pass def footer(l=79): <del> print("n" + "-" * l + "n") @@ -233,74 +215,12 @@ def remove_complete_msg(): footer() </del> <ins> @@ -276,76 +254,13 @@ def remove_complete_msg(): </ins> def deploy_daemon(): -    print("n" + "-" * 21 + " Deploying auto-cpufreq as a daemon " + "-" * 22 + "n")


-            f.seek(0) -            f.truncate() -            f.write(content.replace(orig_set, change_set)) <del> -    except: -        print("nERROR:nWas unable to turn off bluetooth on boot") </del> <ins> -    except Exception as e: -        print(f"nERROR:nWas unable to turn off bluetooth on bootn{repr(e)}") </ins> - -    auto_cpufreq_stats_path.touch(exist_ok=True) - -    print("n* Deploy auto-cpufreq install script") <del> -    shutil.copy(SCRIPTS_DIR / "auto-cpufreq-install.sh", "/usr/bin/auto-cpufreq-install") </del> <ins> -    shutil.copy( -        SCRIPTS_DIR / "auto-cpufreq-install.sh", "/usr/bin/auto-cpufreq-install" -    ) </ins> - -    print("n* Deploy auto-cpufreq remove script") -    shutil.copy(SCRIPTS_DIR / "auto-cpufreq-remove.sh", "/usr/bin/auto-cpufreq-remove") - -    call("/usr/bin/auto-cpufreq-install", shell=True) <del> - </del> +    # prevent needless copying and system changes +    pass # remove auto-cpufreq daemon def remove(): -


-            f.seek(0) -            f.truncate() -            f.write(content.replace(change_set, orig_set)) <del> -    except: -        print("nERROR:nWas unable to turn on bluetooth on boot") </del> <ins> -    except Exception as e: -        print(f"nERROR:nWas unable to turn on bluetooth on bootn{repr(e)}") </ins> - -    # run auto-cpufreq daemon install script -    call("/usr/bin/auto-cpufreq-remove", shell=True)


def gov_check(): for gov in get_avail_gov(): <del> @@ -331,7 +251,7 @@ def countdown(s): if auto_cpufreq_stats_file is not None: auto_cpufreq_stats_file.seek(0) auto_cpufreq_stats_file.truncate(0) - + # execution timestamp from datetime import datetime now = datetime.now() </del> diff --git a/scripts/cpufreqctl.sh b/scripts/cpufreqctl.sh index 63a2b5b..e157efe 100755 --- a/scripts/cpufreqctl.sh


]; in stdenv.mkDerivation rec { pname = "bluez"; <del> version = "5.59"; </del> <ins> version = "5.60"; </ins> src = fetchurl { url = "mirror://kernel/linux/bluetooth/${pname}-${version}.tar.xz"; <del> sha256 = "05kk8zdh3msf5j88jbai8m877rvya6fpkzhicfhv5gyhhsrrasq4"; </del> <ins> sha256 = "sha256-cQmZWA0B7lnsWF5efAf9lO3e3AAaom/nRkxUb52UUwQ="; </ins> }; buildInputs = [


patches = [ # https://phab.mercurial-scm.org/D10638, needed for below patch to apply (fetchpatch { <del> url = "https://phab.mercurial-scm.org/file/data/oymk4awh2dd7q6cwjbzu/PHID-FILE-bfcr7qrp5spg42wspxpd/D10638.diff"; </del> <ins> url = "https://phab.mercurial-scm.org/file/data/l7p2r4zcctcr3pzlybv2/PHID-FILE-bwjzxlz6sbegk3s4irik/D10638.diff"; </ins> sha256 = "0mfi324is02l7cnd3j0gbmg5rpyyqn3afg3f73flnfwmz5njqa5f"; }) # https://phab.mercurial-scm.org/D10639, fixes https://bz.mercurial-scm.org/show_bug.cgi?id=6514 (fetchpatch { <del> url = "https://phab.mercurial-scm.org/file/data/re4uqdhtknjiacx2ogwu/PHID-FILE-4m26id65dno5gzix2ngh/D10639.diff"; </del> <ins> url = "https://phab.mercurial-scm.org/file/data/v53nhburhtkhpccyecei/PHID-FILE-6v34oll6r2gkqo4ng5nt/D10639.diff"; </ins> sha256 = "0h5ilrd2x1789fr6sf4k1mcvxdh0xdyr94yawdacw87v3x12c8cb"; }) ];


# Enable libfabric support (necessary for Omnipath networks) on x86_64 linux , fabricSupport ? stdenv.isLinux && stdenv.isx86_64 <ins> # Enable Fortran support , fortranSupport ? !(stdenv.isDarwin && stdenv.isAarch64) </ins> }: assert !cudaSupport || cudatoolkit != null; let <del> version = "4.1.1"; </del> cudatoolkit_joined = symlinkJoin { name = "${cudatoolkit.name}-unsplit"; paths = [ cudatoolkit.out cudatoolkit.lib ]; }; in stdenv.mkDerivation rec { pname = "openmpi"; <del> inherit version; </del> <ins> version = "4.1.1"; </ins> src = with lib.versions; fetchurl { url = "https://www.open-mpi.org/software/ompi/v${major version}.${minor version}/downloads/${pname}-${version}.tar.bz2";


find -name "Makefile.in" -exec sed -i "s/`date`/$ts/" {} ; ''; <del> buildInputs = with stdenv; [ gfortran zlib ] ++ lib.optionals isLinux [ libnl numactl pmix ucx ] </del> <ins> buildInputs = [ zlib ] ++ lib.optionals fortranSupport [ gfortran ] ++ lib.optionals stdenv.isLinux [ libnl numactl pmix ucx ] </ins> ++ lib.optionals cudaSupport [ cudatoolkit ] ++ [ libevent hwloc ] <del> ++ lib.optional (isLinux || isFreeBSD) rdma-core </del> <ins> ++ lib.optional (stdenv.isLinux || stdenv.isFreeBSD) rdma-core </ins> ++ lib.optional fabricSupport [ libpsm2 libfabric ]; nativeBuildInputs = [ perl ]; <del> configureFlags = with stdenv; lib.optional (!cudaSupport) "--disable-mca-dso" ++ lib.optionals isLinux  [ </del> <ins> configureFlags = lib.optional (!cudaSupport) "--disable-mca-dso" ++ lib.optional (!fortranSupport) "--disable-mpi-fortran" ++ lib.optionals stdenv.isLinux  [ </ins> "--with-libnl=${libnl.dev}" "--with-pmix=${pmix}" "--with-pmix-libdir=${pmix}/lib"


sed -i 's:compiler=.*:compiler=${targetPackages.stdenv.cc}/bin/${targetPackages.stdenv.cc.targetPrefix}c++:'  $out/share/openmpi/mpic++-wrapper-data.txt <ins> '' + lib.optionalString fortranSupport '' </ins> sed -i 's:compiler=.*:compiler=${gfortran}/bin/${gfortran.targetPrefix}gfortran:'   $out/share/openmpi/mpifort-wrapper-data.txt


# fails to configure on darwin due to gmp not found configureFlags = [ "LIBS=-L${gmp}/lib" "CXXFLAGS=-I${gmp.dev}/include" ]; <del> # disable stackprotector on aarch64-darwin for now # https://github.com/NixOS/nixpkgs/issues/127608 hardeningDisable = lib.optionals (stdenv.isAarch64 && stdenv.isDarwin) [ "stackprotector" ]; </del> postPatch = '' sed -e "s@ /bin/bash@bash@g" -i Makefile.std find . -exec sed -e "s@/usr/bin/perl@${perl}/bin/perl@g" -i '{}' ';'


install_name_tool -change libblas.dylib ${blas}/lib/libblas.dylib $out/lib/libarpack.dylib ''; <del> # disable stackprotector on aarch64-darwin for now # https://github.com/NixOS/nixpkgs/issues/127608 hardeningDisable = lib.optionals (stdenv.isAarch64 && stdenv.isDarwin) [ "stackprotector" ]; </del> meta = { homepage = "https://github.com/opencollab/arpack-ng"; description = ''


)] ; <del> # disable stackprotector on aarch64-darwin for now # https://github.com/NixOS/nixpkgs/issues/127608 # # build error: # # /private/tmp/nix-build-sundials-6.3.0.drv-0/ccD2dUtR.s:21:15: error: index must be an integer in range [-256, 255]. #         ldr     x0, [x0, ___stack_chk_guard];momd #                          ^ # /private/tmp/nix-build-sundials-6.3.0.drv-0/ccD2dUtR.s:46:15: error: index must be an integer in range [-256, 255]. #         ldr     x0, [x0, ___stack_chk_guard];momd # # See also a proposed solution: https://github.com/NixOS/nixpkgs/pull/151983 hardeningDisable = lib.optionals (stdenv.isAarch64 && stdenv.isDarwin) [ "stackprotector" ]; </del> doCheck = true; checkTarget = "test";


<ins> # Adding Custom Packages {#sec-custom-packages} It's possible that a package you need is not available in NixOS. In that case, you can do two things. First, you can clone the Nixpkgs repository, add the package to your clone, and (optionally) submit a patch or pull request to have it accepted into the main Nixpkgs repository. This is described in detail in the [Nixpkgs manual](https://nixos.org/nixpkgs/manual). In short, you clone Nixpkgs: ```ShellSession $ git clone https://github.com/NixOS/nixpkgs $ cd nixpkgs ``` Then you write and test the package as described in the Nixpkgs manual. Finally, you add it to [](#opt-environment.systemPackages), e.g. ```nix environment.systemPackages = [ pkgs.my-package ]; ``` and you run `nixos-rebuild`, specifying your own Nixpkgs tree: ```ShellSession # nixos-rebuild switch -I nixpkgs=/path/to/my/nixpkgs ``` The second possibility is to add the package outside of the Nixpkgs tree. For instance, here is how you specify a build of the [GNU Hello](https://www.gnu.org/software/hello/) package directly in `configuration.nix`: ```nix environment.systemPackages = let my-hello = with pkgs; stdenv.mkDerivation rec { name = "hello-2.8"; src = fetchurl { url = "mirror://gnu/hello/${name}.tar.gz"; sha256 = "0wqd8sjmxfskrflaxywc7gqw7sfawrfvdxd9skxawzfgyy0pzdz6"; }; }; in [ my-hello ]; ``` Of course, you can also move the definition of `my-hello` into a separate Nix expression, e.g. ```nix environment.systemPackages = [ (import ./my-hello.nix) ]; ``` where `my-hello.nix` contains: ```nix with import <nixpkgs> {}; # bring all of Nixpkgs into scope stdenv.mkDerivation rec { name = "hello-2.8"; src = fetchurl { url = "mirror://gnu/hello/${name}.tar.gz"; sha256 = "0wqd8sjmxfskrflaxywc7gqw7sfawrfvdxd9skxawzfgyy0pzdz6"; }; } ``` This allows testing the package easily: ```ShellSession $ nix-build my-hello.nix $ ./result/bin/hello Hello, world! ``` </ins>