diff options
Diffstat (limited to 'pkgs/tools/graphics')
45 files changed, 379 insertions, 531 deletions
diff --git a/pkgs/tools/graphics/adriconf/default.nix b/pkgs/tools/graphics/adriconf/default.nix index e7ae7c28194..35de292a36c 100644 --- a/pkgs/tools/graphics/adriconf/default.nix +++ b/pkgs/tools/graphics/adriconf/default.nix @@ -7,7 +7,7 @@ , libGL , atkmm , pcre -, gtkmm3 +, gtkmm4 , pugixml , mesa , pciutils @@ -15,21 +15,30 @@ stdenv.mkDerivation rec { pname = "adriconf"; - version = "2.5.1"; + version = "2.7.1"; src = fetchFromGitLab { domain = "gitlab.freedesktop.org"; owner = "mesa"; repo = pname; rev = "v${version}"; - sha256 = "sha256-RhHmrjb5TvJnZ6R0aefqdmwMBpu4iTrxSHru7JAwrgs="; + sha256 = "sha256-GRmra4P30EW9/WrG84HXYC3Rk4RD+BhuWtsSXvY/5Rk="; }; nativeBuildInputs = [ cmake pkg-config ]; - buildInputs = [ libdrm libGL atkmm pcre gtkmm3 pugixml mesa pciutils ]; + buildInputs = [ libdrm libGL atkmm pcre gtkmm4 pugixml mesa pciutils ]; cmakeFlags = [ "-DENABLE_UNIT_TESTS=off" ]; + postInstall = '' + install -Dm444 ../flatpak/org.freedesktop.adriconf.metainfo.xml \ + -t $out/share/metainfo/ + install -Dm444 ../flatpak/org.freedesktop.adriconf.desktop \ + -t $out/share/applications/ + install -Dm444 ../flatpak/org.freedesktop.adriconf.png \ + -t $out/share/icons/hicolor/256x256/apps/ + ''; + meta = with lib; { homepage = "https://gitlab.freedesktop.org/mesa/adriconf/"; description = "A GUI tool used to configure open source graphics drivers"; diff --git a/pkgs/tools/graphics/argyllcms/default.nix b/pkgs/tools/graphics/argyllcms/default.nix index f0602169350..271d5a5754f 100644 --- a/pkgs/tools/graphics/argyllcms/default.nix +++ b/pkgs/tools/graphics/argyllcms/default.nix @@ -1,16 +1,18 @@ { stdenv, fetchzip, jam, unzip, libX11, libXxf86vm, libXrandr, libXinerama , libXrender, libXext, libtiff, libjpeg, libpng, libXScrnSaver, writeText -, libXdmcp, libXau, lib, openssl }: +, libXdmcp, libXau, lib, openssl +, writeScript +}: stdenv.mkDerivation rec { pname = "argyllcms"; - version = "2.3.1"; + version = "3.0.2"; src = fetchzip { # Kind of flacky URL, it was reaturning 406 and inconsistent binaries for a # while on me. It might be good to find a mirror url = "https://www.argyllcms.com/Argyll_V${version}_src.zip"; - sha256 = "sha256-XWsubjdD1tg0o7x/aoAalemAChehWkwh4fkP2WRvhAw="; + hash = "sha256-9+rUhZVwSzAM9Ko6FYyl2OVvsOFBaUCA1PJs9kaLWaE="; }; nativeBuildInputs = [ jam unzip ]; @@ -120,8 +122,22 @@ stdenv.mkDerivation rec { ''; + passthru = { + updateScript = writeScript "update-argyllcms" '' + #!/usr/bin/env nix-shell + #!nix-shell -i bash -p curl pcre common-updater-scripts + + set -eu -o pipefail + + # Expect the text in format of 'Current Version 3.0.1 (19th October 2023)' + new_version="$(curl -s https://www.argyllcms.com/ | + pcregrep -o1 '>Current Version ([0-9.]+) ')" + update-source-version ${pname} "$new_version" + ''; + }; + meta = with lib; { - homepage = "http://www.argyllcms.com"; + homepage = "https://www.argyllcms.com/"; description = "Color management system (compatible with ICC)"; license = licenses.gpl3; maintainers = []; diff --git a/pkgs/tools/graphics/astc-encoder/default.nix b/pkgs/tools/graphics/astc-encoder/default.nix index 5e63038e67d..dd7ebc6f3b4 100644 --- a/pkgs/tools/graphics/astc-encoder/default.nix +++ b/pkgs/tools/graphics/astc-encoder/default.nix @@ -29,19 +29,20 @@ with rec { stdenv.mkDerivation rec { pname = "astc-encoder"; - version = "4.5.0"; + version = "4.6.0"; src = fetchFromGitHub { owner = "ARM-software"; repo = "astc-encoder"; rev = version; - sha256 = "sha256-pNoBOp//xa5F6/T1cwtdHsAWLZeIHgxZ7UKaB60fg4M="; + sha256 = "sha256-COZO4LTrM/kZp85uNGwB9eaF27Xf7NVg4hcshaCJBwI="; }; nativeBuildInputs = [ cmake ]; + cmakeBuildType = "RelWithDebInfo"; + cmakeFlags = isaFlags ++ [ - "-DCMAKE_BUILD_TYPE=RelWithDebInfo" "-DASTCENC_UNIVERSAL_BUILD=OFF" ]; diff --git a/pkgs/tools/graphics/asymptote/default.nix b/pkgs/tools/graphics/asymptote/default.nix index a03799b5ed8..a5968425f5d 100644 --- a/pkgs/tools/graphics/asymptote/default.nix +++ b/pkgs/tools/graphics/asymptote/default.nix @@ -4,7 +4,7 @@ , boehmgc, libGLU, libGL, mesa, ncurses, readline, gsl, libsigsegv , python3, qtbase, qtsvg, boost , zlib, perl, curl -, texLive, texinfo +, texliveSmall, texinfo , darwin }: @@ -33,7 +33,7 @@ stdenv.mkDerivation rec { ghostscriptX imagemagick fftw boehmgc ncurses readline gsl libsigsegv zlib perl curl qtbase qtsvg boost - texLive + (texliveSmall.withPackages (ps: with ps; [ epsf cm-super ps.texinfo media9 ocgx2 collection-latexextra ])) (python3.withPackages (ps: with ps; [ cson numpy pyqt5 ])) ]; diff --git a/pkgs/tools/graphics/blockhash/default.nix b/pkgs/tools/graphics/blockhash/default.nix index 4f63cf90a3a..0a08e0cd31f 100644 --- a/pkgs/tools/graphics/blockhash/default.nix +++ b/pkgs/tools/graphics/blockhash/default.nix @@ -2,13 +2,13 @@ stdenv.mkDerivation rec { pname = "blockhash"; - version = "0.3.2"; + version = "0.3.3"; src = fetchFromGitHub { owner = "commonsmachinery"; repo = "blockhash"; rev = "v${version}"; - sha256 = "0x3lvhnkb4c3pyq6p81qnnqimz35wpippiac506dgjx3b1848v35"; + sha256 = "sha256-QoqFTCfWtXIrFF3Yx4NfOa9cSjHtCSKz3k3i0u9Qx9M="; }; nativeBuildInputs = [ python3 pkg-config wafHook ]; diff --git a/pkgs/tools/graphics/enblend-enfuse/default.nix b/pkgs/tools/graphics/enblend-enfuse/default.nix index 2fffa3bfa9c..f47a2aa961e 100644 --- a/pkgs/tools/graphics/enblend-enfuse/default.nix +++ b/pkgs/tools/graphics/enblend-enfuse/default.nix @@ -13,7 +13,7 @@ , help2man , pkg-config , perl -, texlive +, texliveSmall }: stdenv.mkDerivation rec { @@ -28,7 +28,7 @@ stdenv.mkDerivation rec { buildInputs = [ boost freeglut glew gsl lcms2 libpng libtiff libGLU libGL vigra ]; - nativeBuildInputs = [ autoreconfHook help2man perl pkg-config texlive.combined.scheme-small ]; + nativeBuildInputs = [ autoreconfHook help2man perl pkg-config texliveSmall ]; preConfigure = '' patchShebangs src/embrace diff --git a/pkgs/tools/graphics/escrotum/default.nix b/pkgs/tools/graphics/escrotum/default.nix index 08136f57ef8..04c245dbd9a 100644 --- a/pkgs/tools/graphics/escrotum/default.nix +++ b/pkgs/tools/graphics/escrotum/default.nix @@ -1,4 +1,5 @@ { lib, python3Packages, fetchFromGitHub +, ffmpeg-full , gtk3 , pango , gobject-introspection @@ -33,6 +34,8 @@ with python3Packages; buildPythonApplication { outputs = [ "out" "man" ]; + makeWrapperArgs = ["--prefix PATH : ${lib.makeBinPath [ ffmpeg-full ]}"]; + postInstall = '' mkdir -p $man/share/man/man1 cp man/escrotum.1 $man/share/man/man1/ diff --git a/pkgs/tools/graphics/fim/default.nix b/pkgs/tools/graphics/fim/default.nix index 6722e1d7819..0f2e11ba59b 100644 --- a/pkgs/tools/graphics/fim/default.nix +++ b/pkgs/tools/graphics/fim/default.nix @@ -11,11 +11,11 @@ gcc9Stdenv.mkDerivation rec { pname = "fim"; - version = "0.6"; + version = "0.7"; src = fetchurl { url = "mirror://savannah/fbi-improved/${pname}-${version}-trunk.tar.gz"; - sha256 = "124b7c4flx5ygmy5sqq0gpvxqzafnknbcj6f45ddnbdxik9lazzp"; + sha256 = "sha256-/p7bjeZM46DJOQ9sgtebhkNpBPj2RJYY3dMXhzHnNmg="; }; postPatch = '' diff --git a/pkgs/tools/graphics/gfxreconstruct/default.nix b/pkgs/tools/graphics/gfxreconstruct/default.nix index fe678ba0671..633c1202faf 100644 --- a/pkgs/tools/graphics/gfxreconstruct/default.nix +++ b/pkgs/tools/graphics/gfxreconstruct/default.nix @@ -17,13 +17,13 @@ stdenv.mkDerivation rec { pname = "gfxreconstruct"; - version = "1.0.0"; + version = "1.0.1"; src = fetchFromGitHub { owner = "LunarG"; repo = "gfxreconstruct"; rev = "v${version}"; - hash = "sha256-dOmkNKURYgphbDHOmzcWf9PsIKMkPyN7ve579BE7fR0="; + hash = "sha256-+h7r6uLRw08c1CHRHxGCdkPYqI10i2Q/Oep617rLhx0="; fetchSubmodules = true; }; diff --git a/pkgs/tools/graphics/gifski/Cargo.lock b/pkgs/tools/graphics/gifski/Cargo.lock index bc5b95bc75a..ee579a5e979 100644 --- a/pkgs/tools/graphics/gifski/Cargo.lock +++ b/pkgs/tools/graphics/gifski/Cargo.lock @@ -10,29 +10,30 @@ checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" [[package]] name = "ahash" -version = "0.8.3" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c99f64d1e06488f620f932677e24bc6e2897582980441ae90a671415bd7ec2f" +checksum = "cd7d5a2cecb58716e47d67d5703a249964b14c7be1ec3cad3affc295b2d1c35d" dependencies = [ "cfg-if", "once_cell", "version_check", + "zerocopy", ] [[package]] name = "aho-corasick" -version = "1.1.1" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea5d730647d4fadd988536d06fecce94b7b4f2a7efdae548f1cf4b63205518ab" +checksum = "b2969dcb958b36655471fc61f7e416fa76033bdd4bfed0678d8fee1e2d07a1f0" dependencies = [ "memchr", ] [[package]] name = "anstream" -version = "0.5.0" +version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1f58811cfac344940f1a400b6e6231ce35171f614f26439e80f8c1465c5cc0c" +checksum = "2ab91ebe16eb252986481c5b62f6098f3b698a45e34b5b98200cf20dd2484a44" dependencies = [ "anstyle", "anstyle-parse", @@ -44,15 +45,15 @@ dependencies = [ [[package]] name = "anstyle" -version = "1.0.3" +version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b84bf0a05bbb2a83e5eb6fa36bb6e87baa08193c35ff52bbf6b38d8af2890e46" +checksum = "7079075b41f533b8c61d2a4d073c4676e1f8b249ff94a393b0595db304e0dd87" [[package]] name = "anstyle-parse" -version = "0.2.1" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "938874ff5980b03a87c5524b3ae5b59cf99b1d6bc836848df7bc5ada9643c333" +checksum = "317b9a89c1868f5ea6ff1d9539a69f45dffc21ce321ac1fd1160dfa48c8e2140" dependencies = [ "utf8parse", ] @@ -68,9 +69,9 @@ dependencies = [ [[package]] name = "anstyle-wincon" -version = "2.1.0" +version = "3.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58f54d10c6dfa51283a066ceab3ec1ab78d13fae00aa49243a45e4571fb79dfd" +checksum = "f0699d10d2f4d628a98ee7b57b289abbc98ff3bad977cb3152709d4bf2330628" dependencies = [ "anstyle", "windows-sys", @@ -105,7 +106,7 @@ dependencies = [ "regex", "rustc-hash", "shlex", - "syn", + "syn 1.0.109", ] [[package]] @@ -157,18 +158,18 @@ dependencies = [ [[package]] name = "clap" -version = "4.4.4" +version = "4.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1d7b8d5ec32af0fadc644bf1fd509a688c2103b185644bb1e29d164e0703136" +checksum = "d04704f56c2cde07f43e8e2c154b43f216dc5c92fc98ada720177362f953b956" dependencies = [ "clap_builder", ] [[package]] name = "clap_builder" -version = "4.4.4" +version = "4.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5179bb514e4d7c2051749d8fcefa2ed6d06a9f4e6d69faf3805f5d80b8cf8d56" +checksum = "0e231faeaca65ebd1ea3c737966bf858971cd38c3849107aa3ea7de90a804e45" dependencies = [ "anstream", "anstyle", @@ -287,9 +288,9 @@ dependencies = [ [[package]] name = "flate2" -version = "1.0.27" +version = "1.0.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6c98ee8095e9d1dcbf2fcc6d95acccb90d1c81db1e44725c6a984b1dbdfb010" +checksum = "46303f565772937ffe1d394a4fac6f411c6013172fadde9dcdb1e147a086940e" dependencies = [ "crc32fast", "miniz_oxide", @@ -316,18 +317,8 @@ dependencies = [ ] [[package]] -name = "gifsicle" -version = "1.93.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d2c35b9670c2a3313343ce54d00669ca18a8236fe727f52e0cf8c5a77acac07" -dependencies = [ - "cc", - "libc", -] - -[[package]] name = "gifski" -version = "1.12.2" +version = "1.13.0" dependencies = [ "clap", "crossbeam-channel", @@ -336,7 +327,6 @@ dependencies = [ "ffmpeg-next", "gif", "gif-dispose", - "gifsicle", "imagequant", "imgref", "lodepng", @@ -347,7 +337,6 @@ dependencies = [ "quick-error", "resize", "rgb", - "scopeguard", "wild", ] @@ -374,12 +363,11 @@ checksum = "d77f7ec81a6d05a3abb01ab6eb7590f6083d08449fe5a1c8b1e620283546ccb7" [[package]] name = "imagequant" -version = "4.2.1" +version = "4.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9427afad20d287aad11e5981db8beb68d0a20e2e4cbd8280e05f95e05b31668a" +checksum = "84d51957ac48371e8e2eaaeb4eba56150ff2109c1c8c200002afb7dd6e2d260f" dependencies = [ "arrayvec", - "num_cpus", "once_cell", "rayon", "rgb", @@ -388,9 +376,9 @@ dependencies = [ [[package]] name = "imgref" -version = "1.9.4" +version = "1.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2cf49df1085dcfb171460e4592597b84abe50d900fb83efb6e41b20fefd6c2c" +checksum = "90d944e334f00f4449c9640b440a171f816be0152305c12ef90424fc35fd035c" [[package]] name = "lazy_static" @@ -406,9 +394,9 @@ checksum = "830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55" [[package]] name = "libc" -version = "0.2.148" +version = "0.2.149" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cdc71e17332e86d2e1d38c1f99edcb6288ee11b815fb1a4b049eaa2114d369b" +checksum = "a08173bc88b7955d1b3145aa561539096c421ac8debde8cbc3612ec635fee29b" [[package]] name = "libloading" @@ -422,9 +410,9 @@ dependencies = [ [[package]] name = "lodepng" -version = "3.8.2" +version = "3.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73c81862c9e16a943631de5160969379758f13fb3c788110db4ab49430b4feab" +checksum = "a3cdccd0cf57a5d456f0656ebcff72c2e19503287e1afbf3b84382812adc0606" dependencies = [ "crc32fast", "fallible_collections", @@ -444,9 +432,9 @@ dependencies = [ [[package]] name = "memchr" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f232d6ef707e1956a43342693d2a31e72989554d58299d7a88738cc95b0d35c" +checksum = "f665ee40bc4a3c5590afb1e9677db74a508659dfd71e126420da8274909a0167" [[package]] name = "memoffset" @@ -490,9 +478,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.16" +version = "0.2.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f30b0abd723be7e2ffca1272140fac1a2f084c77ec3e123c192b66af1ee9e6c2" +checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" dependencies = [ "autocfg", ] @@ -538,9 +526,9 @@ checksum = "26072860ba924cbfa98ea39c8c19b4dd6a4a25423dbdf219c1eca91aa0cf6964" [[package]] name = "proc-macro2" -version = "1.0.67" +version = "1.0.69" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d433d9f1a3e8c1263d9456598b16fec66f4acc9a74dacffd35c7bb09b3a1328" +checksum = "134c189feb4956b20f6f547d2cf727d4c0fe06722b20a0eec87ed445a97f92da" dependencies = [ "unicode-ident", ] @@ -582,9 +570,9 @@ dependencies = [ [[package]] name = "regex" -version = "1.9.5" +version = "1.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "697061221ea1b4a94a624f67d0ae2bfe4e22b8a17b6a192afb11046542cc8c47" +checksum = "380b951a9c5e80ddfd6136919eef32310721aa4aacd4889a8d39124b026ab343" dependencies = [ "aho-corasick", "memchr", @@ -594,9 +582,9 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.3.8" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2f401f4955220693b56f8ec66ee9c78abffd8d1c4f23dc41a23839eb88f0795" +checksum = "5f804c7828047e88b2d32e2d7fe5a105da8ee3264f01902f796c8e067dc2483f" dependencies = [ "aho-corasick", "memchr", @@ -605,9 +593,9 @@ dependencies = [ [[package]] name = "regex-syntax" -version = "0.7.5" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbb5fb1acd8a1a18b3dd5be62d25485eb770e05afb408a9627d14d451bae12da" +checksum = "c08c74e62047bb2de4ff487b251e4a92e24f48745648451635cec7d591162d9f" [[package]] name = "resize" @@ -664,6 +652,17 @@ dependencies = [ ] [[package]] +name = "syn" +version = "2.0.38" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e96b79aaa137db8f61e26363a0c9b47d8b4ec75da28b7d1d614c2303e232408b" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] name = "thread_local" version = "1.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -799,3 +798,23 @@ name = "windows_x86_64_msvc" version = "0.48.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" + +[[package]] +name = "zerocopy" +version = "0.7.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4c19fae0c8a9efc6a8281f2e623db8af1db9e57852e04cde3e754dd2dc29340f" +dependencies = [ + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fc56589e9ddd1f1c28d4b4b5c773ce232910a6bb67a70133d61c9e347585efe9" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] diff --git a/pkgs/tools/graphics/gifski/default.nix b/pkgs/tools/graphics/gifski/default.nix index ed3c332cc45..53180d0094a 100644 --- a/pkgs/tools/graphics/gifski/default.nix +++ b/pkgs/tools/graphics/gifski/default.nix @@ -7,13 +7,13 @@ rustPlatform.buildRustPackage rec { pname = "gifski"; - version = "1.12.2"; + version = "1.13.0"; src = fetchFromGitHub { owner = "ImageOptim"; repo = "gifski"; rev = version; - hash = "sha256-KiedPhlPcFkTiZZfOBlTKqtzU2ND1HXdsfhq+F1MtdU="; + hash = "sha256-Ij+bgL935uLCZeh8GQnTFlPIuUloNCn8LUdvMd+6okM="; }; cargoLock = { diff --git a/pkgs/tools/graphics/gmic-qt/default.nix b/pkgs/tools/graphics/gmic-qt/default.nix index 535a7cdd74f..fdff56a446d 100644 --- a/pkgs/tools/graphics/gmic-qt/default.nix +++ b/pkgs/tools/graphics/gmic-qt/default.nix @@ -17,7 +17,6 @@ , libtiff , ninja , nix-update -, opencv3 , openexr , pkg-config , qtbase @@ -55,11 +54,11 @@ assert lib.assertMsg stdenv.mkDerivation (finalAttrs: { pname = "gmic-qt${lib.optionalString (variant != "standalone") "-${variant}"}"; - version = "3.2.6"; + version = "3.3.1"; src = fetchzip { url = "https://gmic.eu/files/source/gmic_${finalAttrs.version}.tar.gz"; - hash = "sha256-asB1YftHfdb7JG87WJ+ggyMCu7qb0f+aCanl5LLi9VE="; + hash = "sha256-d9FRNW/MXM9ZJ1xgIZvGTUPDDnHgTJU0DuWyPkzNAmo="; }; nativeBuildInputs = [ @@ -78,7 +77,6 @@ stdenv.mkDerivation (finalAttrs: { libjpeg libtiff libpng - opencv3 openexr graphicsmagick curl @@ -95,9 +93,9 @@ stdenv.mkDerivation (finalAttrs: { ''; cmakeFlags = [ - "-DGMIC_QT_HOST=${if variant == "standalone" then "none" else variant}" - "-DENABLE_SYSTEM_GMIC=ON" - "-DENABLE_DYNAMIC_LINKING=ON" + (lib.cmakeFeature "GMIC_QT_HOST" (if variant == "standalone" then "none" else variant)) + (lib.cmakeBool "ENABLE_SYSTEM_GMIC" true) + (lib.cmakeBool "ENABLE_DYNAMIC_LINKING" true) ]; postFixup = lib.optionalString (variant == "gimp") '' @@ -135,8 +133,11 @@ stdenv.mkDerivation (finalAttrs: { homepage = "http://gmic.eu/"; inherit (variants.${variant}) description; license = lib.licenses.gpl3Plus; - maintainers = [ lib.maintainers.lilyinstarlight ]; - platforms = lib.platforms.unix; mainProgram = "gmic_qt"; + maintainers = [ + lib.maintainers.AndersonTorres + lib.maintainers.lilyinstarlight + ]; + platforms = lib.platforms.unix; }; }) diff --git a/pkgs/tools/graphics/gmic/default.nix b/pkgs/tools/graphics/gmic/default.nix deleted file mode 100644 index a5d3b53b5ec..00000000000 --- a/pkgs/tools/graphics/gmic/default.nix +++ /dev/null @@ -1,121 +0,0 @@ -{ lib -, stdenv -, fetchFromGitHub -, fetchurl -, cimg -, cmake -, common-updater-scripts -, coreutils -, curl -, fftw -, gmic-qt -, gnugrep -, gnused -, graphicsmagick -, jq -, libjpeg -, libpng -, libtiff -, ninja -, opencv -, openexr -, pkg-config -, writeShellScript -, zlib -}: - -stdenv.mkDerivation (finalAttrs: { - pname = "gmic"; - version = "3.2.6"; - - outputs = [ "out" "lib" "dev" "man" ]; - - src = fetchFromGitHub { - owner = "GreycLab"; - repo = "gmic"; - rev = "v.${finalAttrs.version}"; - hash = "sha256-kaI5rcAz3Cw/xzWgJhMRu/cQwVrvLRAPiB5BhzPMOHY="; - }; - - # TODO: build this from source - # Reference: src/Makefile, directive gmic_stdlib.h - gmic_stdlib = fetchurl { - name = "gmic_stdlib.h"; - url = "http://gmic.eu/gmic_stdlib${lib.replaceStrings ["."] [""] finalAttrs.version}.h"; - hash = "sha256-7JzFU4HvAtC5Nz5vusKCnJ8VMuKfSi1yFmjj0Hh+vA4="; - }; - - nativeBuildInputs = [ - cmake - ninja - pkg-config - ]; - - buildInputs = [ - cimg - fftw - graphicsmagick - libjpeg - libpng - libtiff - opencv - openexr - zlib - ]; - - cmakeFlags = [ - "-DBUILD_LIB_STATIC=OFF" - "-DENABLE_CURL=OFF" - "-DENABLE_DYNAMIC_LINKING=ON" - "-DUSE_SYSTEM_CIMG=ON" - ]; - - postPatch = '' - cp -r ${finalAttrs.gmic_stdlib} src/gmic_stdlib.h - - # CMake build files were moved to subdirectory. - mv resources/CMakeLists.txt resources/cmake . - '' - + lib.optionalString stdenv.isDarwin '' - substituteInPlace CMakeLists.txt \ - --replace "LD_LIBRARY_PATH" "DYLD_LIBRARY_PATH" - ''; - - passthru = { - tests = { - # Needs to update them all in lockstep. - inherit cimg gmic-qt; - }; - - updateScript = writeShellScript "gmic-update-script" '' - set -o errexit - PATH=${lib.makeBinPath [ common-updater-scripts coreutils curl gnugrep gnused jq ]} - - latestVersion=$(curl 'https://gmic.eu/files/source/' \ - | grep -E 'gmic_[^"]+\.tar\.gz' \ - | sed -E 's/.+<a href="gmic_([^"]+)\.tar\.gz".+/\1/g' \ - | sort --numeric-sort --reverse | head -n1) - - if [[ "${finalAttrs.version}" = "$latestVersion" ]]; then - echo "The new version same as the old version." - exit 0 - fi - - for component in src gmic_stdlib; do - # The script will not perform an update when the version attribute is - # up to date from previous platform run; we need to clear it before - # each run - update-source-version "--source-key=$component" "gmic" 0 "${lib.fakeHash}" - update-source-version "--source-key=$component" "gmic" $latestVersion - done - ''; - }; - - meta = { - homepage = "https://gmic.eu/"; - description = "Open and full-featured framework for image processing"; - license = lib.licenses.cecill21; - maintainers = [ lib.maintainers.lilyinstarlight ]; - platforms = lib.platforms.unix; - }; -}) diff --git a/pkgs/tools/graphics/gnuplot/default.nix b/pkgs/tools/graphics/gnuplot/default.nix index ec5dde5d4c8..f0fa45e59e4 100644 --- a/pkgs/tools/graphics/gnuplot/default.nix +++ b/pkgs/tools/graphics/gnuplot/default.nix @@ -1,6 +1,6 @@ { lib, stdenv, fetchurl, makeWrapper, pkg-config, texinfo , cairo, gd, libcerf, pango, readline, zlib -, withTeXLive ? false, texlive +, withTeXLive ? false, texliveSmall , withLua ? false, lua , withCaca ? false, libcaca , libX11 ? null @@ -21,18 +21,18 @@ let in (if withQt then mkDerivation else stdenv.mkDerivation) rec { pname = "gnuplot"; - version = "5.4.8"; + version = "5.4.9"; src = fetchurl { url = "mirror://sourceforge/gnuplot/${pname}-${version}.tar.gz"; - sha256 = "sha256-kxJ5x8qtGv99RstHZvH/QcJtm+na8Lzwx53u7j2R9c8="; + sha256 = "sha256-oyigIfU9wFRZvmBmAg6acejqtiVdM4HiJpYSDUZcapc="; }; nativeBuildInputs = [ makeWrapper pkg-config texinfo ] ++ lib.optional withQt qttools; buildInputs = [ cairo gd libcerf pango readline zlib ] - ++ lib.optional withTeXLive (texlive.combine { inherit (texlive) scheme-small; }) + ++ lib.optional withTeXLive texliveSmall ++ lib.optional withLua lua ++ lib.optional withCaca libcaca ++ lib.optionals withX [ libX11 libXpm libXt libXaw ] diff --git a/pkgs/tools/graphics/graphviz/default.nix b/pkgs/tools/graphics/graphviz/default.nix index 71892916ad7..20b296de802 100644 --- a/pkgs/tools/graphics/graphviz/default.nix +++ b/pkgs/tools/graphics/graphviz/default.nix @@ -28,13 +28,13 @@ let in stdenv.mkDerivation rec { pname = "graphviz"; - version = "8.1.0"; + version = "9.0.0"; src = fetchFromGitLab { owner = "graphviz"; repo = "graphviz"; rev = version; - hash = "sha256-xTdrtwSpizqf5tNRX0Q0w10mEk4S0X7cmxHj3Us14kY="; + hash = "sha256-lLESaULvHkWJjbKjjG9VIcVInqsDmY1OAAKfjCFDThQ="; }; nativeBuildInputs = [ diff --git a/pkgs/tools/graphics/gromit-mpx/default.nix b/pkgs/tools/graphics/gromit-mpx/default.nix index 09050275fe4..d98ee8733a0 100644 --- a/pkgs/tools/graphics/gromit-mpx/default.nix +++ b/pkgs/tools/graphics/gromit-mpx/default.nix @@ -6,13 +6,13 @@ stdenv.mkDerivation rec { pname = "gromit-mpx"; - version = "1.4.3"; + version = "1.5.1"; src = fetchFromGitHub { owner = "bk138"; repo = "gromit-mpx"; rev = version; - sha256 = "sha256-nbSyWcccu07FZbvOESFhlnuxgTNgJ+/6ujVQvEyQGGo="; + sha256 = "sha256-6sjps0wbB0sTaQtehRmz2KBWxqk3pqJmQs9htqxmJwo="; }; nativeBuildInputs = [ cmake pkg-config wrapGAppsHook ]; diff --git a/pkgs/tools/graphics/lsix/default.nix b/pkgs/tools/graphics/lsix/default.nix index a9f8aa21bf1..dcf078654b8 100644 --- a/pkgs/tools/graphics/lsix/default.nix +++ b/pkgs/tools/graphics/lsix/default.nix @@ -2,13 +2,13 @@ stdenvNoCC.mkDerivation rec { pname = "lsix"; - version = "1.8"; + version = "1.8.2"; src = fetchFromGitHub { owner = "hackerb9"; repo = pname; rev = version; - sha256 = "sha256-Qx6/PFm1XBmEI6iI+Ref9jNe6sXIhsVL4VQ1CX+caZE="; + sha256 = "sha256-xlOlAfZonSo/RERt5WxPqMvppVrY5/Yhh7SgCCsYDQE="; }; nativeBuildInputs = [ makeWrapper ]; diff --git a/pkgs/tools/graphics/mangohud/default.nix b/pkgs/tools/graphics/mangohud/default.nix index e64d2b457ba..e42ca26cfb0 100644 --- a/pkgs/tools/graphics/mangohud/default.nix +++ b/pkgs/tools/graphics/mangohud/default.nix @@ -3,7 +3,6 @@ , fetchFromGitLab , fetchFromGitHub , fetchurl -, fetchpatch , substituteAll , coreutils , curl @@ -16,6 +15,7 @@ , mangohud32 , addOpenGLRunpath , appstream +, git , glslang , mako , meson @@ -31,13 +31,13 @@ , glfw , xorg , gamescopeSupport ? true # build mangoapp and mangohudctl -, lowerBitnessSupport ? stdenv.hostPlatform.is64bit # Support 32 bit on 64bit +, lowerBitnessSupport ? stdenv.hostPlatform.isx86_64 # Support 32 bit on 64bit , nix-update-script }: let # Derived from subprojects/cmocka.wrap - cmocka = rec { + cmocka = { version = "1.81"; src = fetchFromGitLab { owner = "cmocka"; @@ -79,14 +79,14 @@ let in stdenv.mkDerivation (finalAttrs: { pname = "mangohud"; - version = "0.6.9-1"; + version = "0.7.0"; src = fetchFromGitHub { owner = "flightlessmango"; repo = "MangoHud"; rev = "refs/tags/v${finalAttrs.version}"; fetchSubmodules = true; - hash = "sha256-AX4m1XZ+yXp74E3slFGyI3CGu2eYU+eXNN2EY+ivdfk="; + hash = "sha256-KkMN7A3AcS/v+b9GCs0pI6MBBk3WwOMciaoiBzL5xOQ="; }; outputs = [ "out" "doc" "man" ]; @@ -124,13 +124,6 @@ stdenv.mkDerivation (finalAttrs: { libdbus = dbus.lib; inherit hwdata; }) - - # Pull gcc-13 build fix for nissing <cstdint> - (fetchpatch { - name = "gcc-13.patch"; - url = "https://github.com/flightlessmango/MangoHud/commit/3f8f036ee8773ae1af23dd0848b6ab487b5ac7de.patch"; - hash = "sha256-qbNywAXAStGiVZ1LA5qZyNp4n28iNUuE4N69zXv2gmM="; - }) ]; postPatch = '' @@ -140,6 +133,7 @@ stdenv.mkDerivation (finalAttrs: { ] ++ lib.optionals lowerBitnessSupport [ mangohud32 ])} \ + --subst-var-by version "${finalAttrs.version}" \ --subst-var-by dataDir ${placeholder "out"}/share ( @@ -161,6 +155,7 @@ stdenv.mkDerivation (finalAttrs: { nativeBuildInputs = [ addOpenGLRunpath + git glslang mako meson diff --git a/pkgs/tools/graphics/mangohud/preload-nix-workaround.patch b/pkgs/tools/graphics/mangohud/preload-nix-workaround.patch index e360d8c1876..f38e1703973 100644 --- a/pkgs/tools/graphics/mangohud/preload-nix-workaround.patch +++ b/pkgs/tools/graphics/mangohud/preload-nix-workaround.patch @@ -1,24 +1,24 @@ diff --git a/bin/mangohud.in b/bin/mangohud.in -index f975224..24936eb 100755 +index 6c3c6e8..8847cdc 100755 --- a/bin/mangohud.in +++ b/bin/mangohud.in -@@ -8,16 +8,18 @@ if [ "$#" -eq 0 ]; then +@@ -8,10 +8,10 @@ if [ "$#" -eq 0 ]; then exit 1 fi --MANGOHUD_LIB_NAME="@ld_libdir_mangohud@libMangoHud.so" -+MANGOHUD_LIB_NAME="libMangoHud.so" +-MANGOHUD_LIB_NAME="@ld_libdir_mangohud@libMangoHud_opengl.so" ++MANGOHUD_LIB_NAME="libMangoHud_opengl.so" if [ "$1" = "--dlsym" ]; then - MANGOHUD_DLSYM=1 - MANGOHUD_LIB_NAME="@ld_libdir_mangohud@libMangoHud_dlsym.so:${MANGOHUD_LIB_NAME}" + MANGOHUD_LIB_NAME="libMangoHud_dlsym.so:${MANGOHUD_LIB_NAME}" shift fi - # Preload using the plain filenames of the libs, the dynamic linker will - # figure out whether the 32 or 64 bit version should be used - LD_PRELOAD="${LD_PRELOAD:+$LD_PRELOAD:}${MANGOHUD_LIB_NAME}" +@@ -31,5 +31,7 @@ case ":${LD_PRELOAD-}:" in + LD_PRELOAD="${LD_PRELOAD:+$LD_PRELOAD:}${MANGOHUD_LIB_NAME}" + esac + +LD_LIBRARY_PATH="@libraryPath@${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" +XDG_DATA_DIRS="@dataDir@${XDG_DATA_DIRS:+:$XDG_DATA_DIRS}" diff --git a/pkgs/tools/graphics/netpbm/default.nix b/pkgs/tools/graphics/netpbm/default.nix index f4fc086d86a..105169c5e03 100644 --- a/pkgs/tools/graphics/netpbm/default.nix +++ b/pkgs/tools/graphics/netpbm/default.nix @@ -20,14 +20,14 @@ stdenv.mkDerivation { # Determine version and revision from: # https://sourceforge.net/p/netpbm/code/HEAD/log/?path=/advanced pname = "netpbm"; - version = "11.3.5"; + version = "11.4.4"; outputs = [ "bin" "out" "dev" ]; src = fetchsvn { url = "https://svn.code.sf.net/p/netpbm/code/advanced"; - rev = "4636"; - sha256 = "x9q7xhBhpWJfS3fbSEZE7ctnv+gL8U2IMy3GLiTEqag="; + rev = "4784"; + sha256 = "GoO32AWu2s/s1IzehPynCJctc1F98dQhz5cQSXQhu2A="; }; nativeBuildInputs = [ @@ -95,6 +95,10 @@ stdenv.mkDerivation { runHook postConfigure ''; + env = lib.optionalAttrs stdenv.cc.isClang { + NIX_CFLAGS_COMPILE = "-Wno-implicit-function-declaration"; + }; + installPhase = '' runHook preInstall diff --git a/pkgs/tools/graphics/oxipng/default.nix b/pkgs/tools/graphics/oxipng/default.nix index a48f18af51e..8f4793edb45 100644 --- a/pkgs/tools/graphics/oxipng/default.nix +++ b/pkgs/tools/graphics/oxipng/default.nix @@ -1,22 +1,22 @@ { lib, stdenv, fetchCrate, rustPlatform }: rustPlatform.buildRustPackage rec { - version = "8.0.0"; + version = "9.0.0"; pname = "oxipng"; src = fetchCrate { inherit version pname; - hash = "sha256-stTwsU9XK3lF4q2sDgb9A1KG1NnhCfVxYWRiBvlmiqQ="; + hash = "sha256-1OpSweosYiqtLqCcAw1EsAtBAYVc/VH8kRtVSpmTytM="; }; - cargoHash = "sha256-XMIsdv2AHMGs0tDEWe3cfplZU9CbqEkHd7L5eS+V7j0="; + cargoHash = "sha256-kPdAfqMNOoQPSdv+VLRDUr6AXGPy47UnldXwvpwKp6s="; doCheck = !stdenv.isAarch64 && !stdenv.isDarwin; - meta = with lib; { + meta = { homepage = "https://github.com/shssoichiro/oxipng"; description = "A multithreaded lossless PNG compression optimizer"; - license = licenses.mit; - maintainers = with maintainers; [ dywedir ]; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ dywedir ]; }; } diff --git a/pkgs/tools/graphics/pikchr/default.nix b/pkgs/tools/graphics/pikchr/default.nix index 5e390ce12cd..3216790590e 100644 --- a/pkgs/tools/graphics/pikchr/default.nix +++ b/pkgs/tools/graphics/pikchr/default.nix @@ -9,12 +9,12 @@ stdenv.mkDerivation { pname = "pikchr"; # To update, use the last check-in in https://pikchr.org/home/timeline?r=trunk - version = "unstable-2022-12-07"; + version = "unstable-2023-08-30"; src = fetchfossil { url = "https://pikchr.org/home"; - rev = "21ca6b843d65c404"; - sha256 = "sha256-fp06GqpLa/szRCS54KJ+SkT602oWvK3KyDFFjTmpNfI="; + rev = "d6f80b1ab30654d5"; + sha256 = "sha256-GEH1qFiMYmNFJnZzLG5rxpl+F7OSRMoVcdo94+mvrlY="; }; # can't open generated html files @@ -44,7 +44,6 @@ stdenv.mkDerivation { dontWrapTclBinaries = true; doCheck = true; - checkTarget = "test"; meta = with lib; { description = "A PIC-like markup language for diagrams in technical documentation"; diff --git a/pkgs/tools/graphics/plotutils/c++17-register-usage-fix.patch b/pkgs/tools/graphics/plotutils/c++17-register-usage-fix.patch new file mode 100644 index 00000000000..c83409221ac --- /dev/null +++ b/pkgs/tools/graphics/plotutils/c++17-register-usage-fix.patch @@ -0,0 +1,44 @@ +diff -ur a/pic2plot/gram.cc b/pic2plot/gram.cc +--- a/pic2plot/gram.cc 2000-06-28 00:23:21.000000000 -0400 ++++ b/pic2plot/gram.cc 2023-09-07 22:59:47.004460065 -0400 +@@ -1229,9 +1229,9 @@ + char *from; + unsigned int count; + { +- register char *f = from; +- register char *t = to; +- register int i = count; ++ char *f = from; ++ char *t = to; ++ int i = count; + + while (i-- > 0) + *t++ = *f++; +@@ -1244,9 +1244,9 @@ + static void + __yy_memcpy (char *to, char *from, unsigned int count) + { +- register char *t = to; +- register char *f = from; +- register int i = count; ++ char *t = to; ++ char *f = from; ++ int i = count; + + while (i-- > 0) + *t++ = *f++; +@@ -1289,10 +1289,10 @@ + yyparse(YYPARSE_PARAM_ARG) + YYPARSE_PARAM_DECL + { +- register int yystate; +- register int yyn; +- register short *yyssp; +- register YYSTYPE *yyvsp; ++ int yystate; ++ int yyn; ++ short *yyssp; ++ YYSTYPE *yyvsp; + int yyerrstatus; /* number of tokens to shift before error messages enabled */ + int yychar1 = 0; /* lookahead token as an internal (translated) token number */ + diff --git a/pkgs/tools/graphics/plotutils/default.nix b/pkgs/tools/graphics/plotutils/default.nix index 57cfe988b0b..29b4c4b35fe 100644 --- a/pkgs/tools/graphics/plotutils/default.nix +++ b/pkgs/tools/graphics/plotutils/default.nix @@ -16,7 +16,10 @@ stdenv.mkDerivation rec { nativeBuildInputs = [ autoreconfHook ]; buildInputs = [ libpng ]; - patches = map fetchurl (import ./debian-patches.nix); + patches = map fetchurl (import ./debian-patches.nix) + # `pic2plot/gram.cc` uses the register storage class specifier, which is not supported in C++17. + # This prevents clang 16 from building plotutils because it defaults to C++17. + ++ [ ./c++17-register-usage-fix.patch ]; preBuild = '' # Fix parallel building. diff --git a/pkgs/tools/graphics/pngquant/default.nix b/pkgs/tools/graphics/pngquant/default.nix index 908ad26fa6a..73fa81ad602 100644 --- a/pkgs/tools/graphics/pngquant/default.nix +++ b/pkgs/tools/graphics/pngquant/default.nix @@ -27,6 +27,7 @@ stdenv.mkDerivation rec { changelog = "https://github.com/kornelski/pngquant/raw/${version}/CHANGELOG"; platforms = platforms.unix; license = with licenses; [ gpl3Plus hpnd bsd2 ]; - maintainers = [ maintainers.srapenne ]; + mainProgram = "pngquant"; + maintainers = [ ]; }; } diff --git a/pkgs/tools/graphics/resvg/default.nix b/pkgs/tools/graphics/resvg/default.nix index af86e9d46ba..539e3faebfd 100644 --- a/pkgs/tools/graphics/resvg/default.nix +++ b/pkgs/tools/graphics/resvg/default.nix @@ -2,16 +2,16 @@ rustPlatform.buildRustPackage rec { pname = "resvg"; - version = "0.35.0"; + version = "0.36.0"; src = fetchFromGitHub { owner = "RazrFalcon"; repo = pname; rev = "v${version}"; - hash = "sha256-iZY0t8GssM4doPnPiI+FdAdjmfXDxSUT7K9YUHBs8rQ="; + hash = "sha256-KxEeC9E1XG5ascIWzSAoNXtdJyPiEsXcQGebmhs/qkE="; }; - cargoHash = "sha256-F7XeBto+vqfhucG7fygRkQWTQe7iwUuVyPTzdyXI7Lc="; + cargoHash = "sha256-iiPtf1xEBB80Cs31uUEbxG9YgKItdZCNGS6TTgrj4uM="; cargoBuildFlags = [ "--package=resvg" @@ -26,7 +26,7 @@ rustPlatform.buildRustPackage rec { meta = with lib; { description = "An SVG rendering library"; homepage = "https://github.com/RazrFalcon/resvg"; - changelog = "https://github.com/RazrFalcon/resvg/raw/v${version}/CHANGELOG.md"; + changelog = "https://github.com/RazrFalcon/resvg/blob/v${version}/CHANGELOG.md"; license = licenses.mpl20; maintainers = [ maintainers.marsam ]; }; diff --git a/pkgs/tools/graphics/scrot/default.nix b/pkgs/tools/graphics/scrot/default.nix index c2da0da0b13..7d0b1abae1b 100644 --- a/pkgs/tools/graphics/scrot/default.nix +++ b/pkgs/tools/graphics/scrot/default.nix @@ -45,7 +45,7 @@ stdenv.mkDerivation rec { description = "A command-line screen capture utility"; mainProgram = "scrot"; platforms = platforms.linux; - maintainers = with maintainers; [ globin ]; + maintainers = with maintainers; [ ]; license = licenses.mitAdvertising; }; } diff --git a/pkgs/tools/graphics/spirv-cross/default.nix b/pkgs/tools/graphics/spirv-cross/default.nix index 1bf20910cf5..642a49c39b8 100644 --- a/pkgs/tools/graphics/spirv-cross/default.nix +++ b/pkgs/tools/graphics/spirv-cross/default.nix @@ -2,13 +2,13 @@ stdenv.mkDerivation (finalAttrs: { pname = "spirv-cross"; - version = "1.3.261.0"; + version = "1.3.268.0"; src = fetchFromGitHub { owner = "KhronosGroup"; repo = "SPIRV-Cross"; - rev = "sdk-${finalAttrs.version}"; - hash = "sha256-abVqLovvcKBJhGhSCbyD5mc1DSfvh4TWssGxi52ukQ8="; + rev = "vulkan-sdk-${finalAttrs.version}"; + hash = "sha256-UIk5hihUPjXNzEeO2laS4dUef/rEExxXAZjMcftx+3A="; }; nativeBuildInputs = [ cmake python3 ]; diff --git a/pkgs/tools/graphics/svg2pdf/default.nix b/pkgs/tools/graphics/svg2pdf/default.nix index 764ab301ed6..27ef2edd0fa 100644 --- a/pkgs/tools/graphics/svg2pdf/default.nix +++ b/pkgs/tools/graphics/svg2pdf/default.nix @@ -5,15 +5,15 @@ rustPlatform.buildRustPackage rec { pname = "svg2pdf"; - version = "0.7.1"; + version = "0.9.0"; src = fetchFromGitHub { owner = "typst"; repo = "svg2pdf"; rev = "v${version}"; - hash = "sha256-XTOGxuytbkaq4ZV6rXKJF9A/KSX6naYQ3kdICDQU4JA="; + hash = "sha256-Xy1ID2/M3v9/ZEo8fWEDlJ8+cmgAMdHhs27xDfe8IYQ="; }; - cargoHash = "sha256-CQPkVJ3quQlnIS05tAj+i7kGk2l0RvGM/FRNvgQ0mHM="; + cargoHash = "sha256-l3671zvqSM4CY7lOXOur0Q6PBDVf6jXnhZ/8kADWQz4="; buildFeatures = [ "cli" ]; meta = with lib; { diff --git a/pkgs/tools/graphics/ueberzugpp/default.nix b/pkgs/tools/graphics/ueberzugpp/default.nix index 60e7e7221a1..81598312645 100644 --- a/pkgs/tools/graphics/ueberzugpp/default.nix +++ b/pkgs/tools/graphics/ueberzugpp/default.nix @@ -24,8 +24,6 @@ , wayland-protocols , enableX11 ? stdenv.isLinux , xorg -, withoutStdRanges ? stdenv.isDarwin -, range-v3 }: stdenv.mkDerivation rec { @@ -69,8 +67,6 @@ stdenv.mkDerivation rec { ] ++ lib.optionals enableX11 [ xorg.libX11 xorg.xcbutilimage - ] ++ lib.optionals withoutStdRanges [ - range-v3 ]; cmakeFlags = lib.optionals (!enableOpencv) [ diff --git a/pkgs/tools/graphics/unpaper/default.nix b/pkgs/tools/graphics/unpaper/default.nix index b7fe0f6955c..b4f298fadce 100644 --- a/pkgs/tools/graphics/unpaper/default.nix +++ b/pkgs/tools/graphics/unpaper/default.nix @@ -53,6 +53,7 @@ stdenv.mkDerivation rec { description = "Post-processing tool for scanned sheets of paper"; license = licenses.gpl2; platforms = platforms.all; + mainProgram = "unpaper"; maintainers = [ maintainers.rycee ]; }; } diff --git a/pkgs/tools/graphics/vips/default.nix b/pkgs/tools/graphics/vips/default.nix index 8fd66f284cf..c16ba635f50 100644 --- a/pkgs/tools/graphics/vips/default.nix +++ b/pkgs/tools/graphics/vips/default.nix @@ -18,7 +18,6 @@ , libexif , librsvg , poppler -, libgsf , libtiff , fftw , lcms2 @@ -26,7 +25,6 @@ , libimagequant , imagemagick , pango -, orc , matio , cfitsio , libwebp @@ -36,19 +34,23 @@ , openslide , libheif , cgif +, libarchive +, libhwy +, testers +, nix-update-script }: -stdenv.mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { pname = "vips"; - version = "8.14.4"; + version = "8.15.0"; outputs = [ "bin" "out" "man" "dev" ] ++ lib.optionals (!stdenv.isDarwin) [ "devdoc" ]; src = fetchFromGitHub { owner = "libvips"; repo = "libvips"; - rev = "v${version}"; - hash = "sha256-y2Tyi8rxal3s3jLURRGPuCAUuHITRPl1+zJZDp557+I="; + rev = "refs/tags/v${finalAttrs.version}"; + hash = "sha256-WfKq+maLcAXyjk1sq66wSU92ALv4MfRDPKe4Mki0KRQ="; # Remove unicode file names which leads to different checksums on HFS+ # vs. other filesystems because of unicode normalisation. postFetch = '' @@ -76,7 +78,6 @@ stdenv.mkDerivation rec { libexif librsvg poppler - libgsf libtiff fftw lcms2 @@ -84,7 +85,6 @@ stdenv.mkDerivation rec { libimagequant imagemagick pango - orc matio cfitsio libwebp @@ -94,6 +94,8 @@ stdenv.mkDerivation rec { openslide libheif cgif + libarchive + libhwy ] ++ lib.optionals stdenv.isDarwin [ ApplicationServices Foundation ]; # Required by .pc file @@ -109,12 +111,29 @@ stdenv.mkDerivation rec { ++ lib.optional (imagemagick == null) "-Dmagick=disabled" ; + passthru = { + tests = { + pkg-config = testers.hasPkgConfigModules { + package = finalAttrs.finalPackage; + }; + version = testers.testVersion { + package = finalAttrs.finalPackage; + command = "vips --version"; + }; + }; + updateScript = nix-update-script { + extraArgs = [ "--version-regex" "v([0-9.]+)" ]; + }; + }; + meta = with lib; { - changelog = "https://github.com/libvips/libvips/blob/${src.rev}/ChangeLog"; - homepage = "https://libvips.github.io/libvips/"; + changelog = "https://github.com/libvips/libvips/blob/${finalAttrs.src.rev}/ChangeLog"; + homepage = "https://www.libvips.org/"; description = "Image processing system for large images"; license = licenses.lgpl2Plus; - maintainers = with maintainers; [ kovirobi ]; + maintainers = with maintainers; [ kovirobi anthonyroussel ]; + pkgConfigModules = [ "vips" "vips-cpp" ]; platforms = platforms.unix; + mainProgram = "vips"; }; -} +}) diff --git a/pkgs/tools/graphics/vulkan-cts/default.nix b/pkgs/tools/graphics/vulkan-cts/default.nix index e448160f2a8..aba088a1128 100644 --- a/pkgs/tools/graphics/vulkan-cts/default.nix +++ b/pkgs/tools/graphics/vulkan-cts/default.nix @@ -37,17 +37,15 @@ let in stdenv.mkDerivation (finalAttrs: { pname = "vulkan-cts"; - version = "1.3.6.3"; + version = "1.3.7.0"; src = fetchFromGitHub { owner = "KhronosGroup"; repo = "VK-GL-CTS"; rev = "${finalAttrs.pname}-${finalAttrs.version}"; - hash = "sha256-jpKPmUduH3IuUYzBAZJFl/w1FqjGC8sXSTnet8YEZ0I="; + hash = "sha256-f7i7gytk3cKeFQD0FR+nrUR2o0FWaJWKG7OpDz9u42E="; }; - outputs = [ "out" "lib" ]; - prePatch = '' mkdir -p external/renderdoc/src @@ -92,7 +90,8 @@ stdenv.mkDerivation (finalAttrs: { ]; postInstall = '' - mv $out $lib + # Check that nothing was installed so far + ! test -e $out mkdir -p $out/bin $out/archive-dir cp -a external/vulkancts/modules/vulkan/deqp-vk external/vulkancts/modules/vulkan/deqp-vksc $out/bin/ diff --git a/pkgs/tools/graphics/vulkan-cts/sources.nix b/pkgs/tools/graphics/vulkan-cts/sources.nix index 24d2c9de387..59480657da0 100644 --- a/pkgs/tools/graphics/vulkan-cts/sources.nix +++ b/pkgs/tools/graphics/vulkan-cts/sources.nix @@ -4,8 +4,8 @@ rec { ESExtractor = fetchFromGitHub { owner = "Igalia"; repo = "ESExtractor"; - rev = "v0.2.5"; - hash = "sha256-A3lyTTarR1ZJrXcrLDR5D7H1kBwJNyrPPjEklRM9YBY="; + rev = "v0.3.3"; + hash = "sha256-qqhDv08cLQlLaEj0qfghByK+IohdvQdI2ePfUNFEArQ="; }; amber = fetchFromGitHub { @@ -18,8 +18,8 @@ rec { glslang = fetchFromGitHub { owner = "KhronosGroup"; repo = "glslang"; - rev = "77417d5c9e0a5d4c79ddd0285d530b45f7259f0d"; - hash = "sha256-BNgnhTl7/+nC5D7Jl7QME5+qIbm+I0Wh/tf9F4WhW3U="; + rev = "c5117b328afc86e16edff6ed6afe0fe7872a7cf3"; + hash = "sha256-4SoET76fCfutttK00JGCKVQUn0ivGdTw6GhndvxbIDU="; }; jsoncpp = fetchFromGitHub { @@ -29,45 +29,45 @@ rec { hash = "sha256-m0tz8w8HbtDitx3Qkn3Rxj/XhASiJVkThdeBxIwv3WI="; }; + nvidia-video-samples = fetchFromGitHub { + owner = "Igalia"; + repo = "vk_video_samples"; + rev = "cts-integration-0.9.9-1"; + hash = "sha256-vHUyGAx/n8yTnrFjeefbb8LsHxONxsjH3BG2D/RO99E="; + }; + spirv-headers = fetchFromGitHub { owner = "KhronosGroup"; repo = "SPIRV-Headers"; - rev = "1feaf4414eb2b353764d01d88f8aa4bcc67b60db"; - hash = "sha256-VOq3r6ZcbDGGxjqC4IoPMGC5n1APUPUAs9xcRzxdyfk="; + rev = "b8b9eb8640c8c0107ba580fbcb10f969022ca32c"; + hash = "sha256-gcKwML5ItccAhX+QtR9G86h0JnaiVQEmOQzQpL005dg="; }; spirv-tools = fetchFromGitHub { owner = "KhronosGroup"; repo = "SPIRV-Tools"; - rev = "01828dac778d08f4ebafd2e06bd419f6c84e5984"; - hash = "sha256-i1rDMVpUiNdacDe20DsN67/rzK5V434EzfSv97y+xGU="; - }; - - video-parser = fetchFromGitHub { - owner = "nvpro-samples"; - repo = "vk_video_samples"; - rev = "7d68747d3524842afaf050c5e00a10f5b8c07904"; - hash = "sha256-L5IYDm0bLq+NlNrzozu0VQx8zL1na6AhrkjZKxOWSnU="; + rev = "bfc94f63a7adbcf8ae166f5f108ac9f69079efc0"; + hash = "sha256-gju6hJSIWOswGnRxKeJZsU1jgp3HSZAf7wFRxswY+Js="; }; vulkan-docs = fetchFromGitHub { owner = "KhronosGroup"; repo = "Vulkan-Docs"; - rev = "9fff8b252a3688c0231fa78709084bbe677d3bf7"; - hash = "sha256-KpKsKTY5xCSZ5Y92roa0fq/iqc1hVJNS7l87RFcxyRQ="; + rev = "b9aad705f0d9e5e6734ac2ad671d5d1de57b05e0"; + hash = "sha256-bJ2C1+zjvLiYp5A5AHTevFPU9Yka99imqLwH+uApuoY="; }; prePatch = '' - mkdir -p external/ESExtractor external/amber external/glslang external/jsoncpp external/spirv-headers external/spirv-tools external/video-parser external/vulkan-docs + mkdir -p external/ESExtractor external/amber external/glslang external/jsoncpp external/nvidia-video-samples external/spirv-headers external/spirv-tools external/vulkan-docs cp -r ${ESExtractor} external/ESExtractor/src cp -r ${amber} external/amber/src cp -r ${glslang} external/glslang/src cp -r ${jsoncpp} external/jsoncpp/src + cp -r ${nvidia-video-samples} external/nvidia-video-samples/src cp -r ${spirv-headers} external/spirv-headers/src cp -r ${spirv-tools} external/spirv-tools/src - cp -r ${video-parser} external/video-parser/src cp -r ${vulkan-docs} external/vulkan-docs/src ''; } diff --git a/pkgs/tools/graphics/vulkan-extension-layer/default.nix b/pkgs/tools/graphics/vulkan-extension-layer/default.nix index 96edbcad83f..dae55225a0b 100644 --- a/pkgs/tools/graphics/vulkan-extension-layer/default.nix +++ b/pkgs/tools/graphics/vulkan-extension-layer/default.nix @@ -1,19 +1,19 @@ -{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, writeText, vulkan-headers, jq, libX11, libXrandr, libxcb, wayland }: +{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, writeText, vulkan-headers, vulkan-utility-libraries, jq, libX11, libXrandr, libxcb, wayland }: stdenv.mkDerivation rec { pname = "vulkan-extension-layer"; - version = "1.3.261"; + version = "1.3.268.0"; src = fetchFromGitHub { owner = "KhronosGroup"; repo = "Vulkan-ExtensionLayer"; - rev = "v${version}"; - hash = "sha256-MeW7mmbjgqEvXEnAYzTNu4omC4fqq1fplIVjDpV2LcA="; + rev = "vulkan-sdk-${version}"; + hash = "sha256-rSKPTeTDOz6IeJGRt9aIu1VH8VfVzXNYZfjdiSXEJxg="; }; nativeBuildInputs = [ cmake pkg-config jq ]; - buildInputs = [ vulkan-headers libX11 libXrandr libxcb wayland ]; + buildInputs = [ vulkan-headers vulkan-utility-libraries libX11 libXrandr libxcb wayland ]; # Help vulkan-loader find the validation layers setupHook = writeText "setup-hook" '' diff --git a/pkgs/tools/graphics/vulkan-tools-lunarg/default.nix b/pkgs/tools/graphics/vulkan-tools-lunarg/default.nix index 072876e46de..ab593a9bc4d 100644 --- a/pkgs/tools/graphics/vulkan-tools-lunarg/default.nix +++ b/pkgs/tools/graphics/vulkan-tools-lunarg/default.nix @@ -16,23 +16,22 @@ , which , xcbutilkeysyms , xcbutilwm +, valijson , vulkan-headers , vulkan-loader -, symlinkJoin -, vulkan-validation-layers +, vulkan-utility-libraries , writeText }: stdenv.mkDerivation rec { pname = "vulkan-tools-lunarg"; - version = "1.3.261"; + version = "1.3.268.0"; src = fetchFromGitHub { owner = "LunarG"; repo = "VulkanTools"; - rev = "v${version}"; - hash = "sha256-Kem3nWVaMeDEsidKYMsWr9Bu0yBgjjennDB0sKBDogA="; - fetchSubmodules = true; + rev = "vulkan-sdk-${version}"; + hash = "sha256-2ZUD+RBsl35QV3250JOPCIoJb4sJcBsiRE4SZaS6ROs="; }; nativeBuildInputs = [ cmake python3 jq which pkg-config ]; @@ -45,6 +44,10 @@ stdenv.mkDerivation rec { libXrandr libffi libxcb + valijson + vulkan-headers + vulkan-loader + vulkan-utility-libraries wayland xcbutilkeysyms xcbutilwm @@ -52,27 +55,10 @@ stdenv.mkDerivation rec { cmakeFlags = [ "-DVULKAN_HEADERS_INSTALL_DIR=${vulkan-headers}" - "-DVULKAN_LOADER_INSTALL_DIR=${vulkan-loader}" - "-DVULKAN_VALIDATIONLAYERS_INSTALL_DIR=${ - symlinkJoin { - name = "vulkan-validation-layers-merged"; - paths = [ vulkan-validation-layers.headers vulkan-validation-layers ]; - } - }" - # Hide dev warnings that are useless for packaging - "-Wno-dev" ]; preConfigure = '' - # We need to run this update script which generates some source files, - # Remove the line in it which calls 'git submodule update' though. - # Also patch the scripts in ./scripts - update=update_external_sources.sh - patchShebangs $update patchShebangs scripts/* - sed -i '/^git /d' $update - ./$update - substituteInPlace via/CMakeLists.txt --replace "jsoncpp_static" "jsoncpp" ''; @@ -85,13 +71,6 @@ stdenv.mkDerivation rec { done ''; - patches = [ - ./gtest.patch - ]; - - # Same as vulkan-validation-layers - dontPatchELF = true; - # Help vulkan-loader find the validation layers setupHook = writeText "setup-hook" '' export XDG_CONFIG_DIRS=@out@/etc''${XDG_CONFIG_DIRS:+:''${XDG_CONFIG_DIRS}} diff --git a/pkgs/tools/graphics/vulkan-tools-lunarg/gtest.patch b/pkgs/tools/graphics/vulkan-tools-lunarg/gtest.patch deleted file mode 100644 index cf062a8591f..00000000000 --- a/pkgs/tools/graphics/vulkan-tools-lunarg/gtest.patch +++ /dev/null @@ -1,34 +0,0 @@ -diff --git a/external/googletest/googlemock/CMakeLists.txt b/external/googletest/googlemock/CMakeLists.txt -index e7df8ec53d..869bfcb716 100644 ---- a/external/googletest/googlemock/CMakeLists.txt -+++ b/external/googletest/googlemock/CMakeLists.txt -@@ -111,10 +111,10 @@ endif() - if (DEFINED CMAKE_VERSION AND NOT "${CMAKE_VERSION}" VERSION_LESS "2.8.11") - target_include_directories(gmock SYSTEM INTERFACE - "$<BUILD_INTERFACE:${gmock_build_include_dirs}>" -- "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/${CMAKE_INSTALL_INCLUDEDIR}>") -+ "$<INSTALL_INTERFACE:${CMAKE_INSTALL_FULL_INCLUDEDIR}>") - target_include_directories(gmock_main SYSTEM INTERFACE - "$<BUILD_INTERFACE:${gmock_build_include_dirs}>" -- "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/${CMAKE_INSTALL_INCLUDEDIR}>") -+ "$<INSTALL_INTERFACE:${CMAKE_INSTALL_FULL_INCLUDEDIR}>") - endif() - - ######################################################################## -diff --git a/external/googletest/googletest/CMakeLists.txt b/external/googletest/googletest/CMakeLists.txt -index abdd98b79a..7ae174d566 100644 ---- a/external/googletest/googletest/CMakeLists.txt -+++ b/external/googletest/googletest/CMakeLists.txt -@@ -138,10 +138,10 @@ set_target_properties(gtest_main PROPERTIES VERSION ${GOOGLETEST_VERSION}) - if (DEFINED CMAKE_VERSION AND NOT "${CMAKE_VERSION}" VERSION_LESS "2.8.11") - target_include_directories(gtest SYSTEM INTERFACE - "$<BUILD_INTERFACE:${gtest_build_include_dirs}>" -- "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/${CMAKE_INSTALL_INCLUDEDIR}>") -+ "$<INSTALL_INTERFACE:${CMAKE_INSTALL_FULL_INCLUDEDIR}>") - target_include_directories(gtest_main SYSTEM INTERFACE - "$<BUILD_INTERFACE:${gtest_build_include_dirs}>" -- "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/${CMAKE_INSTALL_INCLUDEDIR}>") -+ "$<INSTALL_INTERFACE:${CMAKE_INSTALL_FULL_INCLUDEDIR}>") - endif() - target_link_libraries(gtest_main PUBLIC gtest) - diff --git a/pkgs/tools/graphics/vulkan-tools/default.nix b/pkgs/tools/graphics/vulkan-tools/default.nix index 9327bd9c9d6..e148f51d868 100644 --- a/pkgs/tools/graphics/vulkan-tools/default.nix +++ b/pkgs/tools/graphics/vulkan-tools/default.nix @@ -22,13 +22,13 @@ stdenv.mkDerivation rec { pname = "vulkan-tools"; - version = "1.3.261"; + version = "1.3.268.0"; src = fetchFromGitHub { owner = "KhronosGroup"; repo = "Vulkan-Tools"; - rev = "v${version}"; - hash = "sha256-C5FVkI9F/dgIS8qp7VaOn9J2zoNLb1PnmgAemsVO6zM="; + rev = "vulkan-sdk-${version}"; + hash = "sha256-IsMxiAR4ak6kC3BNYhtI+JVNkEka4ZceSElxk39THXg="; }; nativeBuildInputs = [ @@ -57,27 +57,19 @@ stdenv.mkDerivation rec { Cocoa ]; - libraryPath = lib.strings.makeLibraryPath [ vulkan-loader ]; - - patches = [ - # Vulkan-Tools expects to find the MoltenVK ICD and `libMoltenVK.dylib` in its source repo. - # Patch it to use the already-built binaries and ICD in nixpkgs. - ./use-nix-moltenvk.patch - ]; - - # vkcube.app and vkcubepp.app require `ibtool`, but the version in `xib2nib` is not capable of - # building these apps. Build them using `ibtool` from Xcode, but don’t allow any other binaries - # into the sandbox. Note that the CLT are not supported because `ibtool` requires Xcode. - sandboxProfile = lib.optionalString stdenv.isDarwin '' - (allow process-exec - (literal "/usr/bin/ibtool") - (regex "/Xcode.app/Contents/Developer/usr/bin/ibtool") - (regex "/Xcode.app/Contents/Developer/usr/bin/xcodebuild")) - (allow file-read*) - (deny file-read* (subpath "/usr/local") (with no-log)) - (allow file-write* (subpath "/private/var/folders")) + postPatch = lib.optionalString stdenv.isDarwin '' + # Modify mac_common.cmake to find the ICD where nixpkgs puts it. + substituteInPlace mac_common.cmake \ + --replace MoltenVK/icd/MoltenVK_icd.json MoltenVK_icd.json + # Remove the unconditional check for `ibtool` since the cube demo that needs it won’t be built. + sed -e '/#.*Interface Builder/,/^endif()/d' -i mac_common.cmake + # Install `vulkaninfo` to $out/bin even on Darwin. + substituteInPlace vulkaninfo/CMakeLists.txt \ + --replace 'install(TARGETS vulkaninfo RUNTIME DESTINATION "vulkaninfo")' 'install(TARGETS vulkaninfo)' ''; + libraryPath = lib.strings.makeLibraryPath [ vulkan-loader ]; + dontPatchELF = true; cmakeFlags = [ @@ -91,7 +83,8 @@ stdenv.mkDerivation rec { "-Wno-dev" ] ++ lib.optionals stdenv.isDarwin [ "-DMOLTENVK_REPO_ROOT=${moltenvk}/share/vulkan/icd.d" - "-DIBTOOL=/usr/bin/ibtool" + # Don’t build the cube demo because it requires `ibtool`, which is not available in nixpkgs. + "-DBUILD_CUBE=OFF" ]; meta = with lib; { @@ -102,7 +95,6 @@ stdenv.mkDerivation rec { use of the Vulkan API. ''; homepage = "https://github.com/KhronosGroup/Vulkan-Tools"; - hydraPlatforms = [ "x86_64-linux" "i686-linux" ]; platforms = platforms.unix; license = licenses.asl20; maintainers = [ maintainers.ralith ]; diff --git a/pkgs/tools/graphics/vulkan-tools/use-nix-moltenvk.patch b/pkgs/tools/graphics/vulkan-tools/use-nix-moltenvk.patch deleted file mode 100644 index 5d09bff9c95..00000000000 --- a/pkgs/tools/graphics/vulkan-tools/use-nix-moltenvk.patch +++ /dev/null @@ -1,123 +0,0 @@ -diff --git a/cube/CMakeLists.txt b/cube/CMakeLists.txt -index a2f026e7..327f5dba 100644 ---- a/cube/CMakeLists.txt -+++ b/cube/CMakeLists.txt -@@ -257,14 +257,7 @@ else() - endif() - - if(APPLE) -- # Keep RPATH so fixup_bundle can use it to find libraries -- set_target_properties(vkcube PROPERTIES INSTALL_RPATH_USE_LINK_PATH TRUE) -- install(TARGETS vkcube BUNDLE DESTINATION "cube") -- # Fix up the library references to be self-contained within the bundle. -- install(CODE " -- include(BundleUtilities) -- fixup_bundle(\${CMAKE_INSTALL_PREFIX}/cube/vkcube.app \"\" \"${Vulkan_LIBRARY_DIR}\") -- ") -+ install(TARGETS vkcube BUNDLE DESTINATION "Applications") - else() - install(TARGETS vkcube RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) - endif() -@@ -302,14 +295,7 @@ else() - endif() - - if(APPLE) -- # Keep RPATH so fixup_bundle can use it to find libraries -- set_target_properties(vkcubepp PROPERTIES INSTALL_RPATH_USE_LINK_PATH TRUE) -- install(TARGETS vkcubepp BUNDLE DESTINATION "cube") -- # Fix up the library references to be self-contained within the bundle. -- install(CODE " -- include(BundleUtilities) -- fixup_bundle(\${CMAKE_INSTALL_PREFIX}/cube/vkcubepp.app \"\" \"${Vulkan_LIBRARY_DIR}\") -- ") -+ install(TARGETS vkcubepp BUNDLE DESTINATION "Applications") - else() - install(TARGETS vkcubepp RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) - endif() -diff --git a/cube/macOS/cube/cube.cmake b/cube/macOS/cube/cube.cmake -index 9b823f95..0c43a2c9 100644 ---- a/cube/macOS/cube/cube.cmake -+++ b/cube/macOS/cube/cube.cmake -@@ -72,12 +72,14 @@ set_source_files_properties("${CMAKE_BINARY_DIR}/staging-json/MoltenVK_icd.json" - # Copy the MoltenVK lib into the bundle. - if(${CMAKE_GENERATOR} MATCHES "^Xcode.*") - add_custom_command(TARGET vkcube POST_BUILD -- COMMAND ${CMAKE_COMMAND} -E copy "${MOLTENVK_DIR}/MoltenVK/dylib/macOS/libMoltenVK.dylib" -+ COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_CURRENT_BINARY_DIR}/$<CONFIG>/vkcube.app/Contents/Frameworks -+ COMMAND ${CMAKE_COMMAND} -E create_symlink "${MOLTENVK_DIR}/lib/libMoltenVK.dylib" - ${CMAKE_CURRENT_BINARY_DIR}/$<CONFIG>/vkcube.app/Contents/Frameworks/libMoltenVK.dylib - DEPENDS vulkan) - else() - add_custom_command(TARGET vkcube POST_BUILD -- COMMAND ${CMAKE_COMMAND} -E copy "${MOLTENVK_DIR}/MoltenVK/dylib/macOS/libMoltenVK.dylib" -+ COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_CURRENT_BINARY_DIR}/vkcube.app/Contents/Frameworks -+ COMMAND ${CMAKE_COMMAND} -E create_symlink "${MOLTENVK_DIR}/lib/libMoltenVK.dylib" - ${CMAKE_CURRENT_BINARY_DIR}/vkcube.app/Contents/Frameworks/libMoltenVK.dylib - DEPENDS vulkan) - endif() -diff --git a/cube/macOS/cubepp/cubepp.cmake b/cube/macOS/cubepp/cubepp.cmake -index eae4de3c..e528ae26 100644 ---- a/cube/macOS/cubepp/cubepp.cmake -+++ b/cube/macOS/cubepp/cubepp.cmake -@@ -74,12 +74,14 @@ set_source_files_properties("${CMAKE_BINARY_DIR}/staging-json/MoltenVK_icd.json" - # Copy the MoltenVK lib into the bundle. - if(${CMAKE_GENERATOR} MATCHES "^Xcode.*") - add_custom_command(TARGET vkcubepp POST_BUILD -- COMMAND ${CMAKE_COMMAND} -E copy "${MOLTENVK_DIR}/MoltenVK/dylib/macOS/libMoltenVK.dylib" -+ COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_CURRENT_BINARY_DIR}/$<CONFIG>/vkcubepp.app/Contents/Frameworks -+ COMMAND ${CMAKE_COMMAND} -E create_symlink "${MOLTENVK_DIR}/lib/libMoltenVK.dylib" - ${CMAKE_CURRENT_BINARY_DIR}/$<CONFIG>/vkcubepp.app/Contents/Frameworks/libMoltenVK.dylib - DEPENDS vulkan) - else() - add_custom_command(TARGET vkcubepp POST_BUILD -- COMMAND ${CMAKE_COMMAND} -E copy "${MOLTENVK_DIR}/MoltenVK/dylib/macOS/libMoltenVK.dylib" -+ COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_CURRENT_BINARY_DIR}/vkcubepp.app/Contents/Frameworks -+ COMMAND ${CMAKE_COMMAND} -E create_symlink "${MOLTENVK_DIR}/lib/libMoltenVK.dylib" - ${CMAKE_CURRENT_BINARY_DIR}/vkcubepp.app/Contents/Frameworks/libMoltenVK.dylib - DEPENDS vulkan) - endif() -diff --git a/mac_common.cmake b/mac_common.cmake -index bad3c414..b498906d 100644 ---- a/mac_common.cmake -+++ b/mac_common.cmake -@@ -23,9 +23,8 @@ set(MOLTENVK_DIR ${MOLTENVK_REPO_ROOT}) - # MoltenVK JSON File - - execute_process(COMMAND mkdir -p ${CMAKE_BINARY_DIR}/staging-json) --execute_process(COMMAND sed -e "/\"library_path\":/s$:[[:space:]]*\"[[:space:]]*[\\.\\/]*$: \"..\\/..\\/..\\/Frameworks\\/$" -- ${MOLTENVK_DIR}/MoltenVK/icd/MoltenVK_icd.json -- OUTPUT_FILE ${CMAKE_BINARY_DIR}/staging-json/MoltenVK_icd.json) -+execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink ${MOLTENVK_DIR}/MoltenVK_icd.json -+ ${CMAKE_BINARY_DIR}/staging-json/MoltenVK_icd.json) - - # ~~~ - # Modify the ICD JSON file to adjust the library path. -@@ -36,10 +35,9 @@ execute_process(COMMAND sed -e "/\"library_path\":/s$:[[:space:]]*\"[[:space:]]* - # ~~~ - add_custom_target(MoltenVK_icd-staging-json ALL - COMMAND mkdir -p ${CMAKE_BINARY_DIR}/staging-json -- COMMAND sed -e "/\"library_path\":/s$:[[:space:]]*\"[[:space:]]*[\\.\\/]*$: \"..\\/..\\/..\\/Frameworks\\/$" -- ${MOLTENVK_DIR}/MoltenVK/icd/MoltenVK_icd.json > ${CMAKE_BINARY_DIR}/staging-json/MoltenVK_icd.json -- VERBATIM -- DEPENDS "${MOLTENVK_DIR}/MoltenVK/icd/MoltenVK_icd.json") -+ COMMAND ${CMAKE_COMMAND} -E create_symlink ${MOLTENVK_DIR}/MoltenVK_icd.json -+ ${CMAKE_BINARY_DIR}/staging-json/MoltenVK_icd.json -+ DEPENDS "${MOLTENVK_DIR}/MoltenVK_icd.json") - set_source_files_properties(${CMAKE_BINARY_DIR}/staging-json/MoltenVK_icd.json PROPERTIES GENERATED TRUE) - - find_library(COCOA NAMES Cocoa) -diff --git a/vulkaninfo/CMakeLists.txt b/vulkaninfo/CMakeLists.txt -index d23dcf89..32aa0ebb 100644 ---- a/vulkaninfo/CMakeLists.txt -+++ b/vulkaninfo/CMakeLists.txt -@@ -136,9 +136,5 @@ elseif(APPLE) - add_definitions(-DVK_USE_PLATFORM_MACOS_MVK -DVK_USE_PLATFORM_METAL_EXT) - endif() - --if(APPLE) -- install(TARGETS vulkaninfo RUNTIME DESTINATION "vulkaninfo") --else() -- install(TARGETS vulkaninfo RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) --endif() -+install(TARGETS vulkaninfo RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) - diff --git a/pkgs/tools/graphics/waifu2x-converter-cpp/default.nix b/pkgs/tools/graphics/waifu2x-converter-cpp/default.nix index 56fe4e122e5..f936ab83fb5 100644 --- a/pkgs/tools/graphics/waifu2x-converter-cpp/default.nix +++ b/pkgs/tools/graphics/waifu2x-converter-cpp/default.nix @@ -1,4 +1,4 @@ -{ cmake, fetchFromGitHub, makeWrapper, opencv3, lib, stdenv, ocl-icd, opencl-headers, OpenCL +{ cmake, fetchFromGitHub, makeWrapper, opencv4, lib, stdenv, ocl-icd, opencl-headers, OpenCL , config , cudaSupport ? config.cudaSupport, cudatoolkit ? null }: @@ -20,7 +20,7 @@ stdenv.mkDerivation rec { ]; buildInputs = [ - opencv3 + opencv4 ] ++ lib.optional cudaSupport cudatoolkit ++ lib.optional stdenv.isDarwin OpenCL ++ lib.optionals stdenv.isLinux [ ocl-icd opencl-headers ]; diff --git a/pkgs/tools/graphics/wdisplays/default.nix b/pkgs/tools/graphics/wdisplays/default.nix index b05aa13ea60..9c7093b58f8 100644 --- a/pkgs/tools/graphics/wdisplays/default.nix +++ b/pkgs/tools/graphics/wdisplays/default.nix @@ -1,24 +1,20 @@ { lib, stdenv, fetchFromGitHub, meson, ninja, pkg-config, gtk3, libepoxy, wayland, wrapGAppsHook }: -stdenv.mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { pname = "wdisplays"; - version = "unstable-2021-04-03"; + version = "1.1.1"; nativeBuildInputs = [ meson ninja pkg-config wrapGAppsHook ]; buildInputs = [ gtk3 libepoxy wayland ]; src = fetchFromGitHub { - owner = "luispabon"; + owner = "artizirk"; repo = "wdisplays"; - rev = "7f2eac0d2aa81b5f495da7950fd5a94683f7868e"; - sha256 = "sha256-cOF3+T34zPro58maWUouGG+vlLm2C5NfcH7PZhSvApE="; + rev = finalAttrs.version; + sha256 = "sha256-dtvP930ChiDRT60xq6xBDU6k+zHnkrAkxkKz2FxlzRs="; }; - patchPhase = '' - substituteInPlace ./resources/wdisplays.desktop.in --replace "@app_id@" "wdisplays" - ''; - meta = with lib; { description = "A graphical application for configuring displays in Wayland compositors"; homepage = "https://github.com/luispabon/wdisplays"; @@ -27,4 +23,4 @@ stdenv.mkDerivation rec { platforms = platforms.linux; mainProgram = "wdisplays"; }; -} +}) diff --git a/pkgs/tools/graphics/xcolor/default.nix b/pkgs/tools/graphics/xcolor/default.nix index 1ef2c807bde..dabe14d895f 100644 --- a/pkgs/tools/graphics/xcolor/default.nix +++ b/pkgs/tools/graphics/xcolor/default.nix @@ -41,7 +41,7 @@ rustPlatform.buildRustPackage rec { meta = with lib; { description = "Lightweight color picker for X11"; homepage = "https://github.com/Soft/xcolor"; - maintainers = with lib.maintainers; [ fortuneteller2k ]; + maintainers = with lib.maintainers; [ moni ]; license = licenses.mit; }; } diff --git a/pkgs/tools/graphics/zbar/0.23.92-CVE-2023-40889.patch b/pkgs/tools/graphics/zbar/0.23.92-CVE-2023-40889.patch new file mode 100644 index 00000000000..7b7ca5a0bef --- /dev/null +++ b/pkgs/tools/graphics/zbar/0.23.92-CVE-2023-40889.patch @@ -0,0 +1,17 @@ +Simple bounds checks for CVE-2023-40889, based on third-party +fix by Remi Meier @ +https://github.com/Raemi/zbar/commit/5e8acc6974f17e56c3ddaa5509870beb8d7a599c + +--- a/zbar/qrcode/qrdec.c ++++ b/zbar/qrcode/qrdec.c +@@ -3900,8 +3900,8 @@ void qr_reader_match_centers(qr_reader *_reader,qr_code_data_list *_qrlist, + /*TODO: We might be able to accelerate this step significantly by + considering the remaining finder centers in a more intelligent order, + based on the first finder center we just chose.*/ +- for(j=i+1;!mark[i]&&j<_ncenters;j++){ +- for(k=j+1;!mark[j]&&k<_ncenters;k++)if(!mark[k]){ ++ for(j=i+1; i < _ncenters && !mark[i]&&j<_ncenters;j++){ ++ for(k=j+1; j < _ncenters && !mark[j]&&k<_ncenters;k++)if(!mark[k]){ + qr_finder_center *c[3]; + qr_code_data qrdata; + int version; diff --git a/pkgs/tools/graphics/zbar/0.23.92-CVE-2023-40890.patch b/pkgs/tools/graphics/zbar/0.23.92-CVE-2023-40890.patch new file mode 100644 index 00000000000..3576df214ae --- /dev/null +++ b/pkgs/tools/graphics/zbar/0.23.92-CVE-2023-40890.patch @@ -0,0 +1,26 @@ +Simple bounds checks for CVE-2023-40890 + +--- a/zbar/decoder/databar.c ++++ b/zbar/decoder/databar.c +@@ -23,6 +23,8 @@ + + #include <config.h> + #include <zbar.h> ++#include <stdlib.h> ++#include <stdio.h> + + #ifdef DEBUG_DATABAR + # define DEBUG_LEVEL (DEBUG_DATABAR) +@@ -691,6 +693,12 @@ lookup_sequence (databar_segment_t *seg, + fixed = -1; + s <<= 1; + dbprintf(2, "%x", s); ++ ++ if (i > 20) { ++ fprintf(stderr, "Bug: Out-of-bounds condition detected\n"); ++ exit(99); ++ } ++ + seq[i++] = s++; + seq[i++] = s; + } diff --git a/pkgs/tools/graphics/zbar/default.nix b/pkgs/tools/graphics/zbar/default.nix index f9b84d2656a..5a1d7e94fdf 100644 --- a/pkgs/tools/graphics/zbar/default.nix +++ b/pkgs/tools/graphics/zbar/default.nix @@ -1,6 +1,7 @@ { stdenv , lib , fetchFromGitHub +, fetchpatch , imagemagickBig , pkg-config , withXorg ? true @@ -42,6 +43,11 @@ stdenv.mkDerivation rec { sha256 = "sha256-VhVrngAX7pXZp+szqv95R6RGAJojp3svdbaRKigGb0w="; }; + patches = [ + ./0.23.92-CVE-2023-40889.patch + ./0.23.92-CVE-2023-40890.patch + ]; + nativeBuildInputs = [ pkg-config xmlto |