diff options
author | Weijia Wang <9713184+wegank@users.noreply.github.com> | 2023-09-30 23:51:27 +0200 |
---|---|---|
committer | Weijia Wang <9713184+wegank@users.noreply.github.com> | 2023-09-30 23:51:27 +0200 |
commit | 5a9a7eb345d9975526ee145737cbdf8dfb615aff (patch) | |
tree | 7f75a0afbcd3d5fcafae1c8416f9db1931d30b59 | |
parent | d90e8fdfb7ea4885907c1570877197160cff2d44 (diff) |
photoqt: 3.1 -> 3.3
-rw-r--r-- | pkgs/applications/graphics/photoqt/default.nix | 70 |
1 files changed, 57 insertions, 13 deletions
diff --git a/pkgs/applications/graphics/photoqt/default.nix b/pkgs/applications/graphics/photoqt/default.nix index 3b17ce8fd4f87..fed2c944e5c58 100644 --- a/pkgs/applications/graphics/photoqt/default.nix +++ b/pkgs/applications/graphics/photoqt/default.nix @@ -1,28 +1,70 @@ -{ mkDerivation, lib, fetchurl, cmake, exiv2, graphicsmagick, libraw -, qtbase, qtdeclarative, qtmultimedia, qtquickcontrols2, qttools, qtgraphicaleffects -, extra-cmake-modules, poppler, kimageformats, libarchive, pugixml, wrapQtAppsHook}: +{ lib +, stdenv +, fetchurl +, cmake +, extra-cmake-modules +, qttools +, wrapQtAppsHook +, exiv2 +, graphicsmagick +, kimageformats +, libarchive +, libraw +, mpv +, poppler +, pugixml +, qtbase +, qtdeclarative +, qtgraphicaleffects +, qtmultimedia +, qtquickcontrols +, qtquickcontrols2 +}: -mkDerivation rec { +stdenv.mkDerivation rec { pname = "photoqt"; - version = "3.1"; + version = "3.3"; src = fetchurl { - url = "https://${pname}.org/pkgs/${pname}-${version}.tar.gz"; - hash = "sha256-hihfqE7XIlSAxPg3Kzld3LrYS97wDH//GGqpBpBwFm0="; + url = "https://photoqt.org/pkgs/photoqt-${version}.tar.gz"; + hash = "sha256-AD+Uww/tmXRiAkmeuHBBollE6Y9L7c+fB882ALVtSXQ="; }; - nativeBuildInputs = [ cmake extra-cmake-modules qttools wrapQtAppsHook ]; + # error: no member named 'setlocale' in namespace 'std'; did you mean simply 'setlocale'? + postPatch = lib.optionalString stdenv.isDarwin '' + substituteInPlace cplusplus/main.cpp \ + --replace "std::setlocale" "setlocale" + ''; + + nativeBuildInputs = [ + cmake + extra-cmake-modules + qttools + wrapQtAppsHook + ]; buildInputs = [ - qtbase qtquickcontrols2 exiv2 graphicsmagick poppler - qtmultimedia qtdeclarative libraw qtgraphicaleffects - kimageformats libarchive pugixml + exiv2 + graphicsmagick + kimageformats + libarchive + libraw + mpv + poppler + pugixml + qtbase + qtdeclarative + qtgraphicaleffects + qtmultimedia + qtquickcontrols + qtquickcontrols2 ]; cmakeFlags = [ - "-DFREEIMAGE=OFF" "-DDEVIL=OFF" "-DCHROMECAST=OFF" + "-DFREEIMAGE=OFF" + "-DIMAGEMAGICK=OFF" ]; preConfigure = '' @@ -30,9 +72,11 @@ mkDerivation rec { ''; meta = { - homepage = "https://photoqt.org/"; description = "Simple, yet powerful and good looking image viewer"; + homepage = "https://photoqt.org/"; license = lib.licenses.gpl2Plus; + mainProgram = "photoqt"; + maintainers = with lib.maintainers; [ wegank ]; platforms = lib.platforms.unix; }; } |