Browse Source

gnu: Add OpenEXR and IlmBase.

* gnu/packages/graphics.scm (ilmbase, openexr): New variables.
* gnu/packages/patches/openexr-missing-samples.patch: New file.
* gnu-system.am (dist_patch_DATA): Add it.
version-0.8.3
Ludovic Courtès 8 years ago
parent
commit
cab6a2535a
  1. 1
      gnu-system.am
  2. 56
      gnu/packages/graphics.scm
  3. 23
      gnu/packages/patches/openexr-missing-samples.patch

1
gnu-system.am

@ -460,6 +460,7 @@ dist_patch_DATA = \
gnu/packages/patches/nvi-assume-preserve-path.patch \
gnu/packages/patches/nvi-dbpagesize-binpower.patch \
gnu/packages/patches/nvi-db4.patch \
gnu/packages/patches/openexr-missing-samples.patch \
gnu/packages/patches/orpheus-cast-errors-and-includes.patch \
gnu/packages/patches/ots-no-include-missing-file.patch \
gnu/packages/patches/patchelf-page-size.patch \

56
gnu/packages/graphics.scm

@ -22,6 +22,9 @@
#:use-module (guix build-system gnu)
#:use-module (guix build-system cmake)
#:use-module ((guix licenses) #:prefix license:)
#:use-module (gnu packages)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages compression)
#:use-module (gnu packages multiprecision)
#:use-module (gnu packages boost))
@ -63,3 +66,56 @@ many more.")
;; The 'LICENSE' file explains that a subset is available under more
;; permissive licenses.
(license license:gpl3+)))
(define-public ilmbase
(package
(name "ilmbase")
(version "2.2.0")
(source (origin
(method url-fetch)
(uri (string-append "mirror://savannah/openexr/ilmbase-"
version ".tar.gz"))
(sha256
(base32
"1izddjwbh1grs8080vmaix72z469qy29wrvkphgmqmcm0sv1by7c"))))
(build-system gnu-build-system)
(home-page "http://www.openexr.com/")
(synopsis "Utility C++ libraries for threads, maths, and exceptions")
(description
"IlmBase provides several utility libraries for C++. Half is a class
that encapsulates ILM's 16-bit floating-point format. IlmThread is a thread
abstraction. Imath implements 2D and 3D vectors, 3x3 and 4x4 matrices,
quaternions and other useful 2D and 3D math functions. Iex is an
exception-handling library.")
(license license:bsd-3)))
(define-public openexr
(package
(name "openexr")
(version "2.2.0")
(source (origin
(method url-fetch)
(uri (string-append "mirror://savannah/openexr/openexr-"
version ".tar.gz"))
(sha256
(base32
"0ca2j526n4wlamrxb85y2jrgcv0gf21b3a19rr0gh4rjqkv1581n"))
(modules '((guix build utils)))
(snippet
'(substitute* (find-files "." "tmpDir\\.h")
(("\"/var/tmp/\"")
"\"/tmp/\"")))
(patches (list (search-patch "openexr-missing-samples.patch")))))
(build-system gnu-build-system)
(native-inputs
`(("pkg-config" ,pkg-config)))
(propagated-inputs
`(("ilmbase" ,ilmbase) ;used in public headers
("zlib" ,zlib))) ;OpenEXR.pc reads "-lz"
(home-page "http://www.openexr.com")
(synopsis #f)
(description
"OpenEXR is a high dynamic-range (HDR) image file format developed for
use in computer imaging applications. The IlmImf libraries supports storage
of the \"EXR\" file format for storing 16-bit floating-point images.")
(license license:bsd-3)))

23
gnu/packages/patches/openexr-missing-samples.patch

@ -0,0 +1,23 @@
This patch comments out tests that rely on files that are missing
from the source tarball.
--- openexr-2.2.0/IlmImfTest/testSampleImages.cpp 2015-02-25 16:19:21.565105625 +0100
+++ openexr-2.2.0/IlmImfTest/testSampleImages.cpp 2015-02-25 16:21:46.394128206 +0100
@@ -162,16 +162,6 @@ testSampleImages (const std::string&)
compareImages (ILM_IMF_TEST_IMAGEDIR "comp_b44.exr",
ILM_IMF_TEST_IMAGEDIR "comp_b44_piz.exr");
- compareImages (ILM_IMF_TEST_IMAGEDIR "comp_dwaa_v1.exr",
- ILM_IMF_TEST_IMAGEDIR "comp_dwaa_piz.exr");
- compareImages (ILM_IMF_TEST_IMAGEDIR "comp_dwaa_v2.exr",
- ILM_IMF_TEST_IMAGEDIR "comp_dwaa_piz.exr");
-
- compareImages (ILM_IMF_TEST_IMAGEDIR "comp_dwab_v1.exr",
- ILM_IMF_TEST_IMAGEDIR "comp_dwab_piz.exr");
- compareImages (ILM_IMF_TEST_IMAGEDIR "comp_dwab_v2.exr",
- ILM_IMF_TEST_IMAGEDIR "comp_dwab_piz.exr");
-
cout << "ok\n" << endl;
}
Loading…
Cancel
Save