mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-09-24 04:59:14 -07:00
media-libs/openexr: Multiple test fixes from Debian
Closes: https://bugs.gentoo.org/656680 Package-Manager: Portage-2.3.62, Repoman-2.3.12 Signed-off-by: Pacho Ramos <pacho@gentoo.org>
This commit is contained in:
71
media-libs/openexr/files/openexr-2.3.0-bigendian.patch
Normal file
71
media-libs/openexr/files/openexr-2.3.0-bigendian.patch
Normal file
@@ -0,0 +1,71 @@
|
||||
Description: Fix test-suite on some big-endian archs
|
||||
Author: Dennis Gilmore <dennis@ausil.us>
|
||||
Bug-Debian: https://bugs.debian.org/793040
|
||||
Origin: vendor, https://github.com/openexr/openexr/issues/81
|
||||
Reviewed-by: Mathieu Malaterre <malat@debian.org>
|
||||
|
||||
Index: openexr/IlmImfTest/testFutureProofing.cpp
|
||||
===================================================================
|
||||
--- openexr.orig/IlmImfTest/testFutureProofing.cpp
|
||||
+++ openexr/IlmImfTest/testFutureProofing.cpp
|
||||
@@ -40,6 +40,7 @@
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <assert.h>
|
||||
+#include <byteswap.h>
|
||||
|
||||
#include "tmpDir.h"
|
||||
#include "testFutureProofing.h"
|
||||
@@ -64,6 +65,7 @@
|
||||
#include <ImfNamespace.h>
|
||||
#include <ImathNamespace.h>
|
||||
#include <IlmThreadNamespace.h>
|
||||
+#include <ImfSystemSpecific.h>
|
||||
|
||||
namespace IMF = OPENEXR_IMF_NAMESPACE;
|
||||
using namespace IMF;
|
||||
@@ -1234,6 +1236,12 @@ modifyType (bool modify_version)
|
||||
|
||||
//length of attribute
|
||||
fread(&length,4,1,f);
|
||||
+ if (!GLOBAL_SYSTEM_LITTLE_ENDIAN)
|
||||
+ {
|
||||
+ int tmp = bswap_32(length);
|
||||
+ length = tmp;
|
||||
+ }
|
||||
+
|
||||
if(!modify_version && attrib_name=="type")
|
||||
{
|
||||
// modify the type of part 1 to be 'X<whatevever>'
|
||||
Index: openexr/IlmImfTest/testMultiPartFileMixingBasic.cpp
|
||||
===================================================================
|
||||
--- openexr.orig/IlmImfTest/testMultiPartFileMixingBasic.cpp
|
||||
+++ openexr/IlmImfTest/testMultiPartFileMixingBasic.cpp
|
||||
@@ -40,6 +40,7 @@
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <assert.h>
|
||||
+#include <byteswap.h>
|
||||
|
||||
#include "tmpDir.h"
|
||||
#include "testMultiPartFileMixingBasic.h"
|
||||
@@ -59,6 +60,7 @@
|
||||
#include <ImfDeepScanLineInputPart.h>
|
||||
#include <ImfPartType.h>
|
||||
#include <ImfMisc.h>
|
||||
+#include <ImfSystemSpecific.h>
|
||||
|
||||
namespace IMF = OPENEXR_IMF_NAMESPACE;
|
||||
using namespace IMF;
|
||||
@@ -1383,6 +1385,11 @@ killOffsetTables (const std::string & fn
|
||||
|
||||
//length of attribute
|
||||
fread(&length,4,1,f);
|
||||
+ if (!GLOBAL_SYSTEM_LITTLE_ENDIAN)
|
||||
+ {
|
||||
+ int tmp = bswap_32(length);
|
||||
+ length = tmp;
|
||||
+ }
|
||||
|
||||
//value of attribute
|
||||
for(int i=0;i<length;i++)
|
||||
17
media-libs/openexr/files/openexr-2.3.0-bigendian2.patch
Normal file
17
media-libs/openexr/files/openexr-2.3.0-bigendian2.patch
Normal file
@@ -0,0 +1,17 @@
|
||||
Description: Upstream is not interested in big endian arch
|
||||
Seems to only affect the test suite.
|
||||
Author: Mathieu Malaterre <malat@debian.org>
|
||||
|
||||
Index: openexr/IlmImfTest/main.cpp
|
||||
===================================================================
|
||||
--- openexr.orig/IlmImfTest/main.cpp
|
||||
+++ openexr/IlmImfTest/main.cpp
|
||||
@@ -153,7 +153,7 @@ main (int argc, char *argv[])
|
||||
TEST (testHuf, "core");
|
||||
TEST (testWav, "core");
|
||||
TEST (testRgba, "basic");
|
||||
- TEST (testSharedFrameBuffer, "basic");
|
||||
+ //TEST (testSharedFrameBuffer, "basic");
|
||||
TEST (testRgbaThreading, "basic");
|
||||
TEST (testChannels, "basic");
|
||||
TEST (testAttributes, "core");
|
||||
@@ -0,0 +1,31 @@
|
||||
Description: Remove bogus test from suite
|
||||
Author: Mathieu Malaterre <malat@debian.org>
|
||||
Bug-Debian: https://bugs.debian.org/790495
|
||||
Forwarded: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=790495#15
|
||||
|
||||
--- openexr-2.2.0.orig/IlmImfTest/testSampleImages.cpp
|
||||
+++ openexr-2.2.0/IlmImfTest/testSampleImages.cpp
|
||||
@@ -162,15 +162,15 @@ 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_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");
|
||||
+// 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;
|
||||
17
media-libs/openexr/files/openexr-2.3.0-tests-32bits-2.patch
Normal file
17
media-libs/openexr/files/openexr-2.3.0-tests-32bits-2.patch
Normal file
@@ -0,0 +1,17 @@
|
||||
Description: Usual double rounding issue with x87
|
||||
Author: Mathieu Malaterre <malat@debian.org>
|
||||
Bug-Debian: https://bugs.debian.org/909865
|
||||
Forwarded: https://github.com/openexr/openexr/issues/346
|
||||
Last-Update: 2018-12-19
|
||||
|
||||
--- openexr-2.3.0.orig/IlmImfTest/Makefile.am
|
||||
+++ openexr-2.3.0/IlmImfTest/Makefile.am
|
||||
@@ -54,6 +54,8 @@ IlmImfTest_SOURCES = main.cpp tmpDir.h t
|
||||
|
||||
AM_CPPFLAGS = -DILM_IMF_TEST_IMAGEDIR=\"$(srcdir)/\"
|
||||
|
||||
+AM_CPPFLAGS += -ffloat-store
|
||||
+
|
||||
if BUILD_IMFHUGETEST
|
||||
IlmImfTest_SOURCES += testDeepScanLineHuge.cpp testDeepScanLineHuge.h
|
||||
AM_CPPFLAGS += -DENABLE_IMFHUGETEST
|
||||
36
media-libs/openexr/files/openexr-2.3.0-tests-32bits.patch
Normal file
36
media-libs/openexr/files/openexr-2.3.0-tests-32bits.patch
Normal file
@@ -0,0 +1,36 @@
|
||||
Description: Fix test-suite on some 32bits archs
|
||||
Author: Mathieu Malaterre <malat@debian.org>
|
||||
Bug-Debian: https://bugs.debian.org/791478
|
||||
|
||||
Index: openexr/IlmImfTest/Makefile.am
|
||||
===================================================================
|
||||
--- openexr.orig/IlmImfTest/Makefile.am
|
||||
+++ openexr/IlmImfTest/Makefile.am
|
||||
@@ -44,7 +44,6 @@ IlmImfTest_SOURCES = main.cpp tmpDir.h t
|
||||
testDeepScanLineMultipleRead.h testDeepScanLineMultipleRead.cpp \
|
||||
testPartHelper.h testPartHelper.cpp \
|
||||
testOptimized.cpp testOptimized.h \
|
||||
- testOptimizedInterleavePatterns.cpp testOptimizedInterleavePatterns.h \
|
||||
testBadTypeAttributes.cpp testBadTypeAttributes.h \
|
||||
testFutureProofing.cpp testFutureProofing.h \
|
||||
compareDwa.cpp compareDwa.h \
|
||||
Index: openexr/IlmImfTest/main.cpp
|
||||
===================================================================
|
||||
--- openexr.orig/IlmImfTest/main.cpp
|
||||
+++ openexr/IlmImfTest/main.cpp
|
||||
@@ -82,7 +82,6 @@
|
||||
#include "testCopyMultiPartFile.h"
|
||||
#include "testPartHelper.h"
|
||||
#include "testOptimized.h"
|
||||
-#include "testOptimizedInterleavePatterns.h"
|
||||
#include "testBadTypeAttributes.h"
|
||||
#include "testFutureProofing.h"
|
||||
#include "testPartHelper.h"
|
||||
@@ -174,7 +173,6 @@ main (int argc, char *argv[])
|
||||
TEST (testExistingStreams, "core");
|
||||
TEST (testStandardAttributes, "core");
|
||||
TEST (testOptimized, "basic");
|
||||
- TEST (testOptimizedInterleavePatterns, "basic");
|
||||
TEST (testYca, "basic");
|
||||
TEST (testTiledYa, "basic");
|
||||
TEST (testNativeFormat, "basic");
|
||||
@@ -31,6 +31,12 @@ PATCHES=(
|
||||
"${FILESDIR}/${PN}-2.2.0-fix-config.h-collision.patch"
|
||||
"${FILESDIR}/${PN}-2.2.0-Install-missing-header-files.patch"
|
||||
"${FILESDIR}/${P}-fix-build-system.patch"
|
||||
# From Debian
|
||||
"${FILESDIR}/${PN}-2.3.0-tests-32bits.patch"
|
||||
"${FILESDIR}/${PN}-2.3.0-skip-bogus-tests.patch"
|
||||
"${FILESDIR}/${PN}-2.3.0-bigendian.patch"
|
||||
"${FILESDIR}/${PN}-2.3.0-bigendian2.patch"
|
||||
"${FILESDIR}/${PN}-2.3.0-tests-32bits-2.patch"
|
||||
)
|
||||
|
||||
src_prepare() {
|
||||
@@ -66,6 +72,5 @@ multilib_src_install_all() {
|
||||
rm -rf "${ED%/}"/usr/share/doc/${PF}/examples || die
|
||||
fi
|
||||
|
||||
# package provides .pc files
|
||||
find "${D}" -name '*.la' -delete || die
|
||||
find "${D}" -name '*.la' -type f -delete || die
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user