diff --git a/doc/stdenv/stdenv.chapter.md b/doc/stdenv/stdenv.chapter.md index f4b659bb00a9..1c6391472735 100644 --- a/doc/stdenv/stdenv.chapter.md +++ b/doc/stdenv/stdenv.chapter.md @@ -1138,6 +1138,12 @@ Example removing all references to the compiler in the output: } ``` +### `runHook` \ {#fun-runHook} + +Execute \ and the values in the array associated with it. The array's name is determined by removing `Hook` from the end of \ and appending `Hooks`. + +For example, `runHook postHook` would run the hook `postHook` and all of the values contained in the `postHooks` array, if it exists. + ### `substitute` \ \ \ {#fun-substitute} Performs string substitution on the contents of \, writing the result to \. The substitutions in \ are of the following form: diff --git a/pkgs/applications/audio/musescore/default.nix b/pkgs/applications/audio/musescore/default.nix index cfb50546b705..b756ca5dfde2 100644 --- a/pkgs/applications/audio/musescore/default.nix +++ b/pkgs/applications/audio/musescore/default.nix @@ -3,7 +3,7 @@ , fetchFromGitHub , fetchpatch , cmake -, wrapGAppsHook3 +, wrapGAppsNoGuiHook , wrapQtAppsHook , pkg-config , ninja @@ -103,7 +103,9 @@ in stdenv'.mkDerivation (finalAttrs: { dontWrapGApps = true; nativeBuildInputs = [ - wrapGAppsHook3 + # Just to make it not crash when looking up Gschemas when opening external + # files + wrapGAppsNoGuiHook wrapQtAppsHook cmake qttools diff --git a/pkgs/applications/editors/emacs/elisp-packages/elpa-common-overrides.nix b/pkgs/applications/editors/emacs/elisp-packages/elpa-common-overrides.nix index 1b33f0455316..56cdd8ad733e 100644 --- a/pkgs/applications/editors/emacs/elisp-packages/elpa-common-overrides.nix +++ b/pkgs/applications/editors/emacs/elisp-packages/elpa-common-overrides.nix @@ -54,19 +54,21 @@ in } ); - # TODO delete this when we get upstream fix https://debbugs.gnu.org/cgi/bugreport.cgi?bug=73241 - eglot = super.eglot.overrideAttrs (old: { - postInstall = - old.postInstall or "" - + '' - local info_file=eglot.info - pushd $out/share/emacs/site-lisp/elpa/eglot-* - # specify output info file to override the one defined in eglot.texi - makeinfo --output=$info_file eglot.texi - install-info $info_file dir - popd - ''; - }); + eglot = super.eglot.overrideAttrs ( + finalAttrs: previousAttrs: { + postInstall = + previousAttrs.postInstall or "" + # old versions do not include an info manual + + lib.optionalString (lib.versionAtLeast "1.17.0.20240829.5352" finalAttrs.version) '' + local info_file=eglot.info + pushd $out/share/emacs/site-lisp/elpa/eglot-* + # specify output info file to override the one defined in eglot.texi + makeinfo --output=$info_file eglot.texi + install-info $info_file dir + popd + ''; + } + ); jinx = super.jinx.overrideAttrs (old: { dontUnpack = false; diff --git a/pkgs/applications/misc/iptsd/default.nix b/pkgs/applications/misc/iptsd/default.nix index b6885374ef06..d4294a985a70 100644 --- a/pkgs/applications/misc/iptsd/default.nix +++ b/pkgs/applications/misc/iptsd/default.nix @@ -16,13 +16,13 @@ stdenv.mkDerivation rec { pname = "iptsd"; - version = "2"; + version = "3"; src = fetchFromGitHub { owner = "linux-surface"; - repo = pname; - rev = "v${version}"; - hash = "sha256-zTXTyDgSa1akViDZlYLtJk1yCREGCSJKxzF+HZAWx0c="; + repo = "iptsd"; + rev = "refs/tags/v${version}"; + hash = "sha256-3z3A9qywmsSW1tlJ6LePC5wudM/FITTAFyuPkbHlid0="; }; nativeBuildInputs = [ @@ -47,13 +47,12 @@ stdenv.mkDerivation rec { # Original installs udev rules and service config into global paths postPatch = '' substituteInPlace etc/meson.build \ - --replace "install_dir: unitdir" "install_dir: '$out/etc/systemd/system'" \ - --replace "install_dir: rulesdir" "install_dir: '$out/etc/udev/rules.d'" - substituteInPlace etc/systemd/iptsd-find-service \ - --replace "iptsd-find-hidraw" "$out/bin/iptsd-find-hidraw" \ - --replace "systemd-escape" "${lib.getExe' systemd "systemd-escape"}" + --replace-fail "install_dir: unitdir" "install_dir: '$out/etc/systemd/system'" \ + --replace-fail "install_dir: rulesdir" "install_dir: '$out/etc/udev/rules.d'" + substituteInPlace etc/scripts/iptsd-find-service \ + --replace-fail "systemd-escape" "${lib.getExe' systemd "systemd-escape"}" substituteInPlace etc/udev/50-iptsd.rules.in \ - --replace "/bin/systemd-escape" "${lib.getExe' systemd "systemd-escape"}" + --replace-fail "/bin/systemd-escape" "${lib.getExe' systemd "systemd-escape"}" ''; mesonFlags = [ diff --git a/pkgs/applications/networking/irc/ircdog/default.nix b/pkgs/applications/networking/irc/ircdog/default.nix index 1ff1f0413d2b..c2b1d5b2ee53 100644 --- a/pkgs/applications/networking/irc/ircdog/default.nix +++ b/pkgs/applications/networking/irc/ircdog/default.nix @@ -5,13 +5,13 @@ buildGoModule rec { pname = "ircdog"; - version = "0.5.4"; + version = "0.5.5"; src = fetchFromGitHub { owner = "goshuirc"; repo = "ircdog"; rev = "refs/tags/v${version}"; - hash = "sha256-X8DTwudgQyQQIpXCG7d+tdXMV33HG6ETzHsvIp3KFDo="; + hash = "sha256-maF53Z0FHAhGmnOnMsX0dDnmckPNBY4Bcm4OBM/x4hQ="; }; vendorHash = null; diff --git a/pkgs/by-name/ha/hackgregator/package.nix b/pkgs/by-name/ha/hackgregator/package.nix new file mode 100644 index 000000000000..d914a9fc9fa9 --- /dev/null +++ b/pkgs/by-name/ha/hackgregator/package.nix @@ -0,0 +1,65 @@ +{ + lib, + rustPlatform, + fetchFromGitLab, + pkg-config, + wrapGAppsHook4, + libadwaita, + openssl, + webkitgtk_6_0, + sqlite, + glib-networking, +}: + +rustPlatform.buildRustPackage { + pname = "hackgregator"; + version = "0.5.0-unstable-2023-12-05"; + + src = fetchFromGitLab { + owner = "gunibert"; + repo = "hackgregator"; + rev = "594bdcdc3919c7216d611ddbbc77ab4d0c1f4f2b"; + hash = "sha256-RE0x4YWquWAcQzxGk9zdNjEp1pijrBtjV1EMBu9c5cs="; + }; + + cargoHash = "sha256-OPlYFUhAFRHqXS2vad0QYlhcwyyxdxi1kjpTxVlgyxs="; + + nativeBuildInputs = [ + pkg-config + wrapGAppsHook4 + ]; + + buildInputs = [ + libadwaita + openssl + webkitgtk_6_0 + sqlite + glib-networking + ]; + + # 'error[E0432]: unresolved import' when compiling checks + doCheck = false; + + postInstall = '' + rm $out/bin/xtask + mkdir -p $out/share + pushd hackgregator/data + cp -r icons $out/share/icons + install -Dm644 de.gunibert.Hackgregator.desktop -t $out/share/applications + install -Dm644 de.gunibert.Hackgregator.appdata.xml -t $out/share/appdata + popd + ''; + + meta = { + description = "Comfortable GTK reader application for news.ycombinator.com"; + homepage = "https://gitlab.com/gunibert/hackgregator"; + license = with lib.licenses; [ + gpl3Plus + # and + cc0 + ]; + mainProgram = "hackgregator"; + maintainers = with lib.maintainers; [ aleksana ]; + platforms = lib.platforms.unix; + }; +} diff --git a/pkgs/by-name/hy/hydra/package.nix b/pkgs/by-name/hy/hydra/package.nix index dc125a94c67f..ca09fcee4868 100644 --- a/pkgs/by-name/hy/hydra/package.nix +++ b/pkgs/by-name/hy/hydra/package.nix @@ -44,6 +44,7 @@ , glibcLocales , fetchFromGitHub , nixosTests +, unstableGitUpdater }: let @@ -123,13 +124,13 @@ let in stdenv.mkDerivation (finalAttrs: { pname = "hydra"; - version = "0-unstable-2024-08-27"; + version = "0-unstable-2024-09-15"; src = fetchFromGitHub { owner = "NixOS"; repo = "hydra"; - rev = "2d79b0a4da9e2a8ff97c1173aa56fe92e1f4629b"; - hash = "sha256-ZU8/LzdZ0nbUxVxTsRZyMpTGEtps9oG0Yx2cpS9J8I4="; + rev = "b6f44b5cd020d95c405e149e4c3a0e9dc785e31a"; + hash = "sha256-dXDOX6IvAeznNoh73P2QWstBJ/jqfzEKjgNvdfsGTuY="; }; buildInputs = [ @@ -232,6 +233,7 @@ stdenv.mkDerivation (finalAttrs: { passthru = { inherit nix perlDeps; tests.basic = nixosTests.hydra.hydra; + updateScript = unstableGitUpdater {}; }; meta = with lib; { diff --git a/pkgs/by-name/no/nomad-driver-containerd/package.nix b/pkgs/by-name/no/nomad-driver-containerd/package.nix new file mode 100644 index 000000000000..bf50bd1aeb62 --- /dev/null +++ b/pkgs/by-name/no/nomad-driver-containerd/package.nix @@ -0,0 +1,57 @@ +{ + lib, + buildGoModule, + fetchFromGitHub, + fetchpatch, + containerd, +}: + +buildGoModule rec { + pname = "nomad-driver-containerd"; + version = "0.9.4"; + + src = fetchFromGitHub { + owner = "Roblox"; + repo = pname; + rev = "v${version}"; + sha256 = "sha256-11K1ACk2hhEi+sAlI932eKpyy82Md7j1edRWH2JJ8sI="; + }; + + # bump deps to fix CVE that isn't in a tagged release yet + patches = [ + (fetchpatch { + url = "https://github.com/Roblox/nomad-driver-containerd/commit/80b9be1353f701b9d47d874923a9e8ffed4dbd98.patch"; + hash = "sha256-d4C/YwemmZQAt0fTAnQkJVKn8cK4kmxB+wQEHycdn9U="; + }) + (fetchpatch { + url = "https://github.com/Roblox/nomad-driver-containerd/commit/cc0da224669a8f85a8b695288fe5ea748fb270c2.patch"; + hash = "sha256-W8ZOKMkv1814cPNyqTaXUGhh44WfMizZNL4cNX+FOqg="; + }) + ]; + + # replace version in file as it's defined using const, and thus cannot be overriden by ldflags + postPatch = '' + substituteInPlace containerd/driver.go --replace-warn 'PluginVersion = "v0.9.3"' 'PluginVersion = "v${version}"' + ''; + + CGO_ENABLED = "1"; + + vendorHash = "sha256-OO+a5AqhB0tf6lyodhYl9HUSaWvtXWwevRHYy1Q6VoU="; + subPackages = [ "." ]; + + buildInputs = [ containerd ]; + + ldflags = [ + "-s" + "-w" + ]; + + meta = with lib; { + homepage = "https://www.github.com/Roblox/nomad-driver-containerd"; + description = "Containerd task driver for Nomad"; + mainProgram = "nomad-driver-containerd"; + platforms = platforms.linux; + license = licenses.asl20; + maintainers = with maintainers; [ techknowlogick ]; + }; +} diff --git a/pkgs/by-name/sd/SDL1/package.nix b/pkgs/by-name/sd/SDL1/package.nix index 8ce29877438a..7abff886d509 100644 --- a/pkgs/by-name/sd/SDL1/package.nix +++ b/pkgs/by-name/sd/SDL1/package.nix @@ -72,7 +72,8 @@ stdenv.mkDerivation (finalAttrs: { # Please try revert the change that introduced this comment when updating SDL. ] ++ lib.optional stdenv.isDarwin "--disable-x11-shared" ++ lib.optional (!x11Support) "--without-x" - ++ lib.optional alsaSupport "--with-alsa-prefix=${alsa-lib.out}/lib"; + ++ lib.optional alsaSupport "--with-alsa-prefix=${alsa-lib.out}/lib" + ++ lib.optional stdenv.hostPlatform.isMusl "CFLAGS=-DICONV_INBUF_NONCONST"; patches = [ ./find-headers.patch diff --git a/pkgs/by-name/si/simdutf/package.nix b/pkgs/by-name/si/simdutf/package.nix index 42ee43f22ae3..8e841ac44636 100644 --- a/pkgs/by-name/si/simdutf/package.nix +++ b/pkgs/by-name/si/simdutf/package.nix @@ -7,13 +7,13 @@ stdenv.mkDerivation (finalAttrs: { pname = "simdutf"; - version = "5.4.15"; + version = "5.5.0"; src = fetchFromGitHub { owner = "simdutf"; repo = "simdutf"; rev = "v${finalAttrs.version}"; - hash = "sha256-oIrrI0Z5x1AvT9y0Ldg8zrkFJj1PZtebhJaL2UtEoB8="; + hash = "sha256-LEXx/b0DJZ9xxQX9+4YHjQCLFp2aXCE78Z6iPlXJjAw="; }; # Fix build on darwin diff --git a/pkgs/by-name/sn/sn0int/package.nix b/pkgs/by-name/sn/sn0int/package.nix index 43eadd2c3940..974f6a298d1e 100644 --- a/pkgs/by-name/sn/sn0int/package.nix +++ b/pkgs/by-name/sn/sn0int/package.nix @@ -12,16 +12,16 @@ rustPlatform.buildRustPackage rec { pname = "sn0int"; - version = "0.26.0"; + version = "0.26.1"; src = fetchFromGitHub { owner = "kpcyrd"; repo = pname; rev = "refs/tags/v${version}"; - hash = "sha256-ze4OFKUuc/t6tXgmoWFFDjpAQraSY6RIekkcDBctPJo="; + hash = "sha256-tiJLwlxZ9ndircgkH23ew+3QJeuuqt93JahAtFPcuG8="; }; - cargoHash = "sha256-PAKmoifqB1YC02fVF2SRbXAAGrMcB+Wlvr3FwuqmPVU="; + cargoHash = "sha256-3FrUlv6UxULsrvgyV5mlry9j3wFMiXZVoxk6z6pRM3I="; nativeBuildInputs = [ pkg-config diff --git a/pkgs/by-name/to/tocpdf/package.nix b/pkgs/by-name/to/tocpdf/package.nix new file mode 100644 index 000000000000..ac830f7d1c9f --- /dev/null +++ b/pkgs/by-name/to/tocpdf/package.nix @@ -0,0 +1,42 @@ +{ + lib, + python3Packages, + fetchPypi, +}: + +python3Packages.buildPythonApplication rec { + pname = "tocpdf"; + version = "0.3.3"; + pyproject = true; + + src = fetchPypi { + pname = "tocPDF"; + inherit version; + hash = "sha256-B+UcvyjWceVErf1uDyGGTGwKBCGHmSOF19Vbk15cPp8="; + }; + + build-system = with python3Packages; [ + setuptools + ]; + + dependencies = with python3Packages; [ + click + pdfplumber + pypdf + tika + tqdm + ]; + + # no test + doCheck = false; + + pythonImportsCheck = [ "tocPDF" ]; + + meta = { + description = "Automatic CLI tool for generating outline of PDFs based on the table of contents"; + homepage = "https://github.com/kszenes/tocPDF"; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ dansbandit ]; + mainProgram = "tocPDF"; + }; +} diff --git a/pkgs/development/python-modules/datafusion/default.nix b/pkgs/development/python-modules/datafusion/default.nix index 6343937d0d1e..e73d37c4486c 100644 --- a/pkgs/development/python-modules/datafusion/default.nix +++ b/pkgs/development/python-modules/datafusion/default.nix @@ -11,6 +11,7 @@ pyarrow, Security, SystemConfiguration, + typing-extensions, }: let @@ -33,7 +34,7 @@ in buildPythonPackage rec { pname = "datafusion"; - version = "38.0.1"; + version = "40.1.0"; pyproject = true; src = fetchFromGitHub { @@ -41,13 +42,13 @@ buildPythonPackage rec { owner = "apache"; repo = "arrow-datafusion-python"; rev = "refs/tags/${version}"; - hash = "sha256-rBS6i2HqpdhnhZZfO0ywL/e4a+rnUZkHzezKd8PuG80="; + hash = "sha256-5WOSlx4XW9zO6oTY16lWQElShLv0ubflVPfSSEGrFgg="; }; cargoDeps = rustPlatform.fetchCargoTarball { name = "datafusion-cargo-deps"; inherit src; - hash = "sha256-M2ZNAFWdsnN9C4+YbqFxZVH9fHR10Bimf1Xzrd9oy9E="; + hash = "sha256-hN03tbnH77VsMDxSMddMHIH00t7lUs5h8rTHbiMIExw="; }; nativeBuildInputs = with rustPlatform; [ @@ -63,13 +64,18 @@ buildPythonPackage rec { SystemConfiguration ]; - propagatedBuildInputs = [ pyarrow ]; + dependencies = [ + pyarrow + typing-extensions + ]; nativeCheckInputs = [ pytestCheckHook numpy ]; + pythonImportsCheck = [ "datafusion" ]; + pytestFlagsArray = [ "--pyargs" pname diff --git a/pkgs/tools/package-management/dnf5/default.nix b/pkgs/tools/package-management/dnf5/default.nix index b0cbba31bfce..1258813dffbc 100644 --- a/pkgs/tools/package-management/dnf5/default.nix +++ b/pkgs/tools/package-management/dnf5/default.nix @@ -32,7 +32,7 @@ stdenv.mkDerivation (finalAttrs: { pname = "dnf5"; - version = "5.2.5.0"; + version = "5.2.6.0"; outputs = [ "out" @@ -43,7 +43,7 @@ stdenv.mkDerivation (finalAttrs: { owner = "rpm-software-management"; repo = "dnf5"; rev = finalAttrs.version; - hash = "sha256-zH+TDtVMEsgKZR0EA+G8SB1PZyiTfhnG7n6lupeoWyI="; + hash = "sha256-tzGpZ6Pip6SIak0L3npoh31TxVJJ0mn+jVkeNGq24N0="; }; nativeBuildInputs =