summary refs log blame commit diff
path: root/pkgs/applications/graphics/nomacs/default.nix
blob: e955515d2245d0bc4aa31c0c7f61ae7c181e7047 (plain) (tree)
1
2
3
4
5
        
              

                 
           












                         
                   

                   


                         
                  
                                                                    

    



                           

                                


                                    
 
                            
                                  







                        
                         
 














                                                            
{ stdenv
, mkDerivation
, fetchFromGitHub
, cmake
, pkgconfig

, qtbase
, qttools
, qtsvg

, exiv2
, opencv
, libraw
, libtiff
, quazip
}:

stdenv.mkDerivation rec {
  pname = "nomacs";
  version = "3.12";

  src = fetchFromGitHub {
    owner = "nomacs";
    repo = "nomacs";
    rev = version;
    sha256 = "12582i5v85da7vwjxj8grj99hxg34ij5cn3b1578wspdfw1xfy1i";
  };

  patches = [
    ./nomacs-iostream.patch
  ];

  enableParallelBuilding = true;

  setSourceRoot = ''
    sourceRoot=$(echo */ImageLounge)
  '';

  nativeBuildInputs = [cmake
                       pkgconfig];

  buildInputs = [qtbase
                 qttools
                 qtsvg
                 exiv2
                 opencv
                 libraw
                 libtiff
                 quazip];

  cmakeFlags = ["-DENABLE_OPENCV=ON"
                "-DENABLE_RAW=ON"
                "-DENABLE_TIFF=ON"
                "-DENABLE_QUAZIP=ON"
                "-DUSE_SYSTEM_QUAZIP=ON"];

  meta = with stdenv.lib; {
    homepage = https://nomacs.org;
    description = "Qt-based image viewer";
    maintainers = [maintainers.ahmedtd];
    license = licenses.gpl3Plus;
    repositories.git = https://github.com/nomacs/nomacs.git;
    inherit (qtbase.meta) platforms;
  };
}