aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/image.scm
diff options
context:
space:
mode:
authorMark H Weaver <mhw@netris.org>2019-09-06 20:46:00 -0400
committerMark H Weaver <mhw@netris.org>2019-09-06 20:46:00 -0400
commit65542a8852759f35e19959149ac92297c8b54be5 (patch)
treebc8f398c7b10a4725b20aa59ab1452d30f358ea3 /gnu/packages/image.scm
parentbc60349b5bc58a0b803df5adce1de6db82453744 (diff)
parentf66aee3d0d2f573187ed5d44ae7c13d73cd4097a (diff)
downloadguix-65542a8852759f35e19959149ac92297c8b54be5.tar
guix-65542a8852759f35e19959149ac92297c8b54be5.tar.gz
Merge branch 'master' into core-updates
Diffstat (limited to 'gnu/packages/image.scm')
-rw-r--r--gnu/packages/image.scm85
1 files changed, 80 insertions, 5 deletions
diff --git a/gnu/packages/image.scm b/gnu/packages/image.scm
index 93eccf842d..4463007c74 100644
--- a/gnu/packages/image.scm
+++ b/gnu/packages/image.scm
@@ -625,6 +625,81 @@ work.")
(home-page "https://jbig2dec.com")
(license license:gpl2+)))
+(define-public jbigkit
+ (package
+ (name "jbigkit")
+ (version "2.1")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append "https://www.cl.cam.ac.uk/~mgk25/jbigkit/"
+ "download/jbigkit-" version ".tar.gz"))
+ (sha256
+ (base32 "0cnrcdr1dwp7h7m0a56qw09bv08krb37mpf7cml5sjdgpyv0cwfy"))
+ (modules '((guix build utils)))
+ (snippet
+ '(begin
+ ;; Remove files without clear licence information.
+ (for-each delete-file-recursively
+ (list "contrib" "examples"))
+ #t))))
+ (build-system gnu-build-system)
+ (outputs (list "out" "pbmtools"))
+ (arguments
+ `(#:modules ((srfi srfi-26)
+ ,@%gnu-build-system-modules)
+ #:phases
+ (modify-phases %standard-phases
+ (delete 'configure) ; no configure script
+ (replace 'install ; no ‘make install’ target
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (lib (string-append out "/lib"))
+ (include (string-append out "/include")))
+ (with-directory-excursion "libjbig"
+ (for-each (cut install-file <> include)
+ (find-files "." "\\.h$"))
+ (for-each (cut install-file <> lib)
+ (find-files "." "\\.a$")))
+ #t)))
+ (add-after 'install 'install-pbmtools
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "pbmtools"))
+ (bin (string-append out "/bin"))
+ (man1 (string-append out "/share/man/man1"))
+ (man5 (string-append out "/share/man/man5")))
+ (with-directory-excursion "pbmtools"
+ (for-each (cut install-file <> bin)
+ (list "jbgtopbm" "jbgtopbm85"
+ "pbmtojbg" "pbmtojbg85"))
+
+ (for-each (cut install-file <> man1)
+ (find-files "." "\\.1$"))
+ (for-each (cut install-file <> man5)
+ (find-files "." "\\.5$"))
+ #t)))))
+ #:test-target "test"
+ #:tests? #f)) ; tests depend on examples/
+ (home-page "https://www.cl.cam.ac.uk/~mgk25/jbigkit/")
+ (synopsis "Lossless compression for bi-level high-resolution images")
+ (description
+ "JBIG-KIT implements the JBIG1 data compression standard (ITU-T T.82 and
+ISO/IEC 11544:1993), designed for bi-level (one bit per pixel) images such as
+black-and-white scanned documents. It is widely used in fax products, printer
+firmware and drivers, document management systems, and imaging software.
+
+This package provides a static C library of (de)compression functions and some
+simple command-line converters similar to those provided by netpbm.
+
+Two JBIG1 variants are available. One (@file{jbig.c}) implements nearly all
+options of the standard but has to keep the full uncompressed image in memory.
+The other (@file{jbig85.c}) implements just the ITU-T T.85 profile, with
+memory management optimized for embedded and fax applications. It buffers
+only a few lines of the uncompressed image in memory and is able to stream
+images of initially unknown height.")
+ (license (list license:isc ; pbmtools/p?m.5
+ license:gpl2+)))) ; the rest
+
(define-public openjpeg
(package
(name "openjpeg")
@@ -966,12 +1041,11 @@ multi-dimensional image processing.")
(home-page "https://ukoethe.github.io/vigra/")))
(define-public vigra-c
- (let* ((commit "a2ff675f42079e2623318d8ff8b4288dbe7a7f06")
- (revision "0")
- (version (git-version "0.0.0" revision commit)))
+ (let* ((commit "66ff4fa5a7d4a77415caa676a45c2c6ea16562e7")
+ (revision "1"))
(package
(name "vigra-c")
- (version version)
+ (version (git-version "0.0.0" revision commit))
(home-page "https://github.com/BSeppke/vigra_c")
(source (origin
(method git-fetch)
@@ -980,7 +1054,7 @@ multi-dimensional image processing.")
(commit commit)))
(sha256
(base32
- "1f1phmfbbz3dsq9330rd6bjmdg29hxskxi9l17cyx1f4mdqpgdgl"))
+ "1pnd92s284dvsg8zp6md7p8ck55bmcsryz58gzic7jh6m72hg689"))
(file-name (git-file-name name version))))
(build-system cmake-build-system)
(arguments
@@ -990,6 +1064,7 @@ multi-dimensional image processing.")
(inputs
`(("fftw" ,fftw)
("fftwf" ,fftwf)
+ ("hdf5" ,hdf5)
("vigra" ,vigra)))
(synopsis "C interface to the VIGRA computer vision library")
(description