;;; Copyright © 2016, 2017, 2018, 2019, 2020 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
;;; Copyright © 2016 Eric Bavier <bavier@member.fsf.org>
-;;; Copyright © 2016, 2017 Arun Isaac <arunisaac@systemreboot.net>
+;;; Copyright © 2016, 2017, 2020 Arun Isaac <arunisaac@systemreboot.net>
;;; Copyright © 2016, 2017 Kei Kebreau <kkebreau@posteo.net>
;;; Copyright © 2017 Nikita <nikita@n0.is>
;;; Copyright © 2017,2019,2020 Hartmut Goebel <h.goebel@crazy-compilers.com>
#:use-module (guix utils)
#:use-module (guix build-system gnu)
#:use-module (guix build-system cmake)
+ #:use-module (guix build-system copy)
#:use-module (guix build-system meson)
#:use-module (guix build-system python)
#:use-module (guix build-system scons)
#:use-module (guix deprecation)
#:use-module (srfi srfi-1))
+(define-public iqa
+ (package
+ (name "iqa")
+ (version "1.1.2")
+ (source
+ (origin
+ (method url-fetch)
+ (uri
+ (string-append "https://sourceforge.net/projects/iqa/files/"
+ "1.1.2%20Release/iqa_1.1.2_src.tar.gz/download"))
+ (sha256
+ (base32 "00mgwy031ammab6bwmd1whhvqv3fxy1cs1igabq0n3ag12zhjs77"))))
+ (build-system gnu-build-system)
+ (arguments
+ `(#:test-target "test"
+ #:phases
+ (modify-phases %standard-phases
+ (delete 'configure)
+ (replace 'install
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (lib (string-append out "/lib")))
+ (install-file "build/debug/libiqa.a" lib)
+ #t))))))
+ (synopsis "Image Quality Assessment")
+ (description "IQA is a C library for objectively measuring image/video
+quality. It implements many popular algorithms, such as MS-SSIM, MS-SSIM*,
+SIMM, MSE, and PSNR. It is designed to be fast, accurate, and reliable. All
+code is Valgrind-clean and unit tested.")
+ (home-page "https://sourceforge.net/projects/iqa/")
+ (license license:bsd-4)))
+
(define-public libpng
(package
(name "libpng")
(origin
(method git-fetch)
(uri (git-reference
- (url "https://github.com/ImageOptim/libimagequant.git")
+ (url "https://github.com/ImageOptim/libimagequant")
(commit version)))
(file-name (git-file-name name version))
(sha256
(origin
(method git-fetch)
(uri (git-reference
- (url "https://github.com/kornelski/pngquant.git")
+ (url "https://github.com/kornelski/pngquant")
(commit version)))
(file-name (git-file-name name version))
(sha256
(define-public ijg-libjpeg
(package
(name "libjpeg")
- (version "9c")
+ (version "9d")
(source (origin
(method url-fetch)
(uri (string-append "https://www.ijg.org/files/jpegsrc.v"
version ".tar.gz"))
(sha256 (base32
- "08kixcf3a7s9x91174abjnk1xbvj4v8crdc73zi4k9h3jfbm00k5"))))
+ "0clwys9lcqlxqgcw8s1gwfm5ix2zjlqpklmd3mbvqmj5ibj51jwr"))))
(build-system gnu-build-system)
(synopsis "Library for handling JPEG files")
(description
(license license:ijg)
(home-page "https://www.ijg.org/")))
-(define-public ijg-libjpeg-8
- (package (inherit ijg-libjpeg)
- (version "8d")
- (source (origin
- (method url-fetch)
- (uri (string-append "https://www.ijg.org/files/jpegsrc.v"
- version ".tar.gz"))
- (sha256 (base32
- "1cz0dy05mgxqdgjf52p54yxpyy95rgl30cnazdrfmw7hfca9n0h0"))))))
-
(define-public libjxr
(package
(name "libjxr")
(source
(origin
(method url-fetch)
- (uri (string-append "http://download.osgeo.org/libtiff/tiff-"
+ (uri (string-append "https://download.osgeo.org/libtiff/tiff-"
version ".tar.gz"))
(sha256
(base32
(origin
(method git-fetch)
(uri (git-reference
- (url "https://github.com/DanBloomberg/leptonica.git")
+ (url "https://github.com/DanBloomberg/leptonica")
(commit version)))
(file-name (git-file-name name version))
(sha256
(license (list license:isc ; pbmtools/p?m.5
license:gpl2+)))) ; the rest
+(define-public openjpeg-data
+ (package
+ (name "openjpeg-data")
+ (version "2020.05.19")
+ (source
+ (origin
+ (method git-fetch)
+ (uri
+ (git-reference
+ (url "https://github.com/uclouvain/openjpeg-data.git")
+ (commit "c5c4a8c")))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1jp84gbhw8q5b8mhc322ql9410hjf32w9hg10x4isfa9j59mnncb"))))
+ (build-system copy-build-system)
+ (synopsis "Test files for OpenJPEG")
+ (description "OpenJPEG-Data contains all files required to run the openjpeg
+test suite, including conformance tests (following Rec. ITU-T T.803 | ISO/IEC
+15444-4 procedures), non-regression tests and unit tests.")
+ (home-page "https://github.com/uclouvain/openjpeg-data")
+ (license license:bsd-2)))
+
(define-public openjpeg
(package
(name "openjpeg")
(home-page
;; This vanished page is universally accepted as giblib's home despite not
;; mentioning the package once.
- (string-append "https://web.archive.org/web/20140907071208"
+ (string-append "https://web.archive.org/web/20140907071208/"
"https://linuxbrit.co.uk/software/"))
(synopsis "Wrapper library for imlib2")
(description
(delete-file-recursively (string-append "Source/" dir)))
'("LibJPEG" "LibOpenJPEG" "LibPNG" "LibRawLite"
"LibJXR" "LibWebP" "OpenEXR" "ZLib"))))
- (patches (search-patches "freeimage-unbundle.patch"))))
+ (patches
+ (append
+ (search-patches "freeimage-unbundle.patch")
+ ;; Take one patch from Arch Linux that adds LibRaw 0.20 compatibility.
+ (list (origin
+ (method url-fetch)
+ (uri "https://raw.githubusercontent.com/archlinux\
+/svntogit-community/ca3e6a52f5a46dec87cbf85e9d84fe370e282c8c/trunk\
+/freeimage-libraw-0.20.patch")
+ (file-name "freeimage-libraw-compat.patch")
+ (sha256
+ (base32
+ "0cwjxjz0f4gs6igvwqg0p99mnrsrwzkal1l2n08yvz2xq9s5khki"))))))))
(build-system gnu-build-system)
(arguments
'(#:phases
(define-public exiv2
(package
(name "exiv2")
- (version "0.27.2")
+ (version "0.27.3")
(source
(origin
(method url-fetch)
(uri (string-append "https://www.exiv2.org/builds/exiv2-" version
"-Source.tar.gz"))
(sha256
- (base32 "0gqminvj14xm3rgbnydbywf22608js80rp7nmxxk4497j5mzali6"))))
+ (base32 "0y77wfadjsrcxijdqgkr3q88b6mm9y3rg8kqsmaig8iah49md7x7"))))
(build-system cmake-build-system)
(arguments '(#:tests? #f)) ; no test suite
(propagated-inputs
(define-public jasper
(package
(name "jasper")
- (version "2.0.16")
+ (version "2.0.20")
(source (origin
(method git-fetch)
(uri (git-reference
- (url "https://github.com/mdadams/jasper.git")
+ (url "https://github.com/mdadams/jasper")
(commit (string-append "version-" version))))
(file-name (git-file-name name version))
(sha256
(base32
- "05l75yd1zsxwv25ykwwwjs8961szv7iywf16nc6vc6qpby27ckv6"))))
+ "1bn4mg6l5afryrlyk3y7p3accdq113fis8hpwywy5g51ycablz3h"))))
(build-system cmake-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'disable-checking-disabled-things
+ (lambda _
+ ;; The MIF codec was disabled for security reasons in JasPer 2.0.20
+ ;; but its test suite still assumes that the format is supported.
+ (for-each delete-file
+ (find-files "data/test" "\\.mif$")) ; for run_test_1
+ (substitute* "test/bin/run_test_2"
+ (("image_formats\\+=\\(mif\\)") ""))
+ #t)))))
(inputs `(("libjpeg" ,libjpeg-turbo)))
(synopsis "JPEG-2000 library")
(description "The JasPer Project is an initiative to provide a reference
(origin
(method git-fetch)
(uri (git-reference
- (url "https://github.com/sekrit-twc/zimg.git")
+ (url "https://github.com/sekrit-twc/zimg")
(commit (string-append "release-" version))))
(file-name (git-file-name name version))
(sha256
(origin
(method git-fetch)
(uri (git-reference
- (url "https://github.com/myint/perceptualdiff.git")
+ (url "https://github.com/myint/perceptualdiff")
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
(source
(origin (method git-fetch)
(uri (git-reference
- (url "https://github.com/extemporelang/stb.git")
+ (url "https://github.com/extemporelang/stb")
(commit commit)))
(sha256
(base32
(package
(name "libjpeg-turbo")
(version "2.0.4")
+ (replacement libjpeg-turbo/fixed)
(source (origin
(method url-fetch)
(uri (string-append "mirror://sourceforge/libjpeg-turbo/"
license:ijg ;the libjpeg library and associated tools
license:zlib)))) ;the libjpeg-turbo SIMD extensions
+(define libjpeg-turbo/fixed
+ (package
+ (inherit libjpeg-turbo)
+ (version "2.0.5")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://sourceforge/libjpeg-turbo/"
+ version "/libjpeg-turbo-" version ".tar.gz"))
+ (sha256
+ (base32
+ "0pbv6pc97kbj7ib31qcwi7lnmm9xg5y3b11aasmkhfjvf7rgdy0n"))))))
+
(define-deprecated libjpeg libjpeg-turbo)
(export libjpeg)
(source (origin
(method git-fetch)
(uri (git-reference
- (url "https://github.com/thezbyg/gpick.git")
+ (url "https://github.com/thezbyg/gpick")
(commit (string-append name "-" version))))
(file-name (git-file-name name version))
(sha256
(origin
(method git-fetch)
(uri (git-reference
- (url "https://github.com/lupoDharkael/flameshot.git")
+ (url "https://github.com/lupoDharkael/flameshot")
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
(define-public grim
(package
(name "grim")
- (version "1.2.0")
+ (version "1.3.1")
(source
(origin
(method git-fetch)
(uri (git-reference
- (url "https://github.com/emersion/grim.git")
+ (url "https://github.com/emersion/grim")
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
- (base32 "0brljl4zfbn5mh9hkfrfkvd27c5y9vdkgap9r1hrfy9r1x20sskn"))))
+ (base32 "0fjmjq0ws9rlblkcqxxw2lv7zvvyi618jqzlnz5z9zb477jwdfib"))))
(build-system meson-build-system)
(native-inputs `(("pkg-config" ,pkg-config)
("scdoc" ,scdoc)))
(origin
(method git-fetch)
(uri (git-reference
- (url "https://github.com/emersion/slurp.git")
+ (url "https://github.com/emersion/slurp")
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
painting and palette manipulation tools. It also handles JPEG, JPEG2000,
GIF, TIFF, WEBP, BMP, PNG, XPM formats.")
(license license:gpl3+)))
+
+(define-public phockup
+ (package
+ (name "phockup")
+ (version "1.5.9")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/ivandokov/phockup")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "13ajj0xch7yfqaaxbw0awxs0fz17n1rxir4gqh2wcgxjysqk1j2y"))))
+ (build-system copy-build-system)
+ (arguments
+ `(#:install-plan '(("src" "share/phockup/")
+ ("phockup.py" "share/phockup/"))
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'configure
+ (lambda* (#:key inputs #:allow-other-keys)
+ (substitute* (list "src/dependency.py" "src/exif.py")
+ (("exiftool")
+ (string-append (assoc-ref inputs "perl-image-exiftool")
+ "/bin/exiftool")))
+ #t))
+ (add-before 'install 'check
+ (lambda _
+ (invoke "pytest")))
+ (add-after 'install 'install-bin
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let ((out (assoc-ref outputs "out")))
+ (mkdir (string-append out "/bin"))
+ (symlink (string-append out "/share/phockup/phockup.py")
+ (string-append out "/bin/phockup")))
+ #t)))))
+ (inputs
+ `(("perl-image-exiftool" ,perl-image-exiftool)
+ ("python" ,python)))
+ (native-inputs
+ `(("python-pytest" ,python-pytest)
+ ("python-pytest-mock" ,python-pytest-mock)))
+ (home-page "https://github.com/ivandokov/phockup")
+ (synopsis "Organize photos and videos in folders")
+ (description "Phockup is a media sorting tool that uses creation date and
+time information in photos and videos to organize them into folders by year,
+month and day. All files which are not images or videos or those which do not
+have creation date information will be placed in a folder called
+@file{unknown}.")
+ (license license:expat)))