aboutsummaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
authorRaghav Gururajan <raghavgururajan@disroot.org>2020-09-24 10:48:08 -0400
committerLeo Famulari <leo@famulari.name>2021-01-31 17:22:13 -0500
commitce5f9afcd1b3f79f254de6a77775f2c2fe6800fe (patch)
tree6be7cf770418b5d172191768d0507b8b2ff16b21 /gnu
parent0ad27959d827e54b8af3d214cfed7ef23920e39f (diff)
downloadguix-ce5f9afcd1b3f79f254de6a77775f2c2fe6800fe.tar
guix-ce5f9afcd1b3f79f254de6a77775f2c2fe6800fe.tar.gz
gnu: openjpeg: Enable tests.
* gnu/packages/image.scm (openjpeg)[arguments]: Enable the test suite. Pass -DBUILD_UNIT_TESTS, -DBUILD_TESTING, and -DOPJ_DATA_ROOT to #:configure-flags. Add a new 'disable-failing-tests' phase. [native-inputs]: Add openjpeg-data. Signed-off-by: Leo Famulari <leo@famulari.name>
Diffstat (limited to 'gnu')
-rw-r--r--gnu/packages/image.scm21
1 files changed, 19 insertions, 2 deletions
diff --git a/gnu/packages/image.scm b/gnu/packages/image.scm
index bf7c104eef..5e7f13e155 100644
--- a/gnu/packages/image.scm
+++ b/gnu/packages/image.scm
@@ -830,8 +830,25 @@ test suite, including conformance tests (following Rec. ITU-T T.803 | ISO/IEC
(base32 "1dn98d2dfa1lqyxxmab6rrcv52dyhjr4g7i4xf2w54fqsx14ynrb"))))
(build-system cmake-build-system)
(arguments
- '(#:tests? #f ;TODO: requires a 1.1 GiB data repository
- #:configure-flags '("-DBUILD_STATIC_LIBS=OFF")))
+ `(#:configure-flags
+ (list
+ "-DBUILD_STATIC_LIBS=OFF"
+ "-DBUILD_UNIT_TESTS=ON"
+ "-DBUILD_TESTING=ON"
+ (string-append "-DOPJ_DATA_ROOT="
+ (assoc-ref %build-inputs "openjpeg-data")))
+ #:phases
+ (modify-phases %standard-phases
+ ;; To be re-enabled after upstream fixes the bug,
+ ;; https://github.com/uclouvain/openjpeg/issues/1264
+ (add-after 'unpack 'disable-failing-tests
+ (lambda _
+ (substitute* "tests/CMakeLists.txt"
+ (("add_subdirectory\\(nonregression\\)")
+ ""))
+ #t)))))
+ (native-inputs
+ `(("openjpeg-data" ,openjpeg-data))) ; Files for test-suite
(inputs
`(("lcms" ,lcms)
("libpng" ,libpng)