Merge pull request #274555 from wegank/photoqt-bump

photoqt: 3.4 -> 4.0.1
This commit is contained in:
Weijia Wang 2023-12-18 00:17:28 +01:00 committed by GitHub
commit 8fd713e76b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 22 additions and 22 deletions

View File

@ -7,40 +7,31 @@
, wrapQtAppsHook
, exiv2
, graphicsmagick
, kimageformats
, libarchive
, libraw
, mpv
, poppler
, pugixml
, qtbase
, qtcharts
, qtdeclarative
, qtgraphicaleffects
, qtimageformats
, qtlocation
, qtmultimedia
, qtquickcontrols
, qtquickcontrols2
, qtpositioning
, qtsvg
, qtwayland
}:
stdenv.mkDerivation rec {
pname = "photoqt";
version = "3.4";
version = "4.0.1";
src = fetchurl {
url = "https://photoqt.org/pkgs/photoqt-${version}.tar.gz";
hash = "sha256-kVf9+zI9rtEMmS0N4qrN673T/1fnqfcV3hQPnMXMLas=";
hash = "sha256-nmEipzatselwtBR//ayajqgmhaUnAMKW7JBLKdzutHg=";
};
postPatch = ''
# exiv2 0.28.1
substituteInPlace CMakeLists.txt \
--replace "exiv2lib" "exiv2"
''
# error: no member named 'setlocale' in namespace 'std'; did you mean simply 'setlocale'?
+ lib.optionalString stdenv.isDarwin ''
substituteInPlace cplusplus/main.cpp \
--replace "std::setlocale" "setlocale"
'';
nativeBuildInputs = [
cmake
extra-cmake-modules
@ -51,18 +42,21 @@ stdenv.mkDerivation rec {
buildInputs = [
exiv2
graphicsmagick
kimageformats
libarchive
libraw
mpv
poppler
pugixml
qtbase
qtcharts
qtdeclarative
qtgraphicaleffects
qtimageformats
qtlocation
qtmultimedia
qtquickcontrols
qtquickcontrols2
qtpositioning
qtsvg
] ++ lib.optionals stdenv.isLinux [
qtwayland
];
cmakeFlags = [
@ -76,6 +70,12 @@ stdenv.mkDerivation rec {
export MAGICK_LOCATION="${graphicsmagick}/include/GraphicsMagick"
'';
postInstall = lib.optionalString stdenv.isDarwin ''
mkdir -p $out/Applications
mv $out/bin/photoqt.app $out/Applications
makeWrapper $out/{Applications/photoqt.app/Contents/MacOS,bin}/photoqt
'';
meta = {
description = "Simple, yet powerful and good looking image viewer";
homepage = "https://photoqt.org/";

View File

@ -34669,7 +34669,7 @@ with pkgs;
phantomsocks = callPackage ../tools/networking/phantomsocks { };
photoqt = libsForQt5.callPackage ../applications/graphics/photoqt { };
photoqt = qt6Packages.callPackage ../applications/graphics/photoqt { };
photoflare = libsForQt5.callPackage ../applications/graphics/photoflare { };