changed debian/source/format to native

This commit is contained in:
openKylinBot 2022-05-14 03:32:49 +08:00
parent 38a009af5a
commit 5dc529e997
8 changed files with 1 additions and 319 deletions

View File

@ -1,57 +0,0 @@
From: Michael Schmitz <schmitz@zirkon.biophys.uni-duesseldorf.de>
Date: Sat, 14 May 2022 03:32:49 +0800
Subject: Fix testsuite for m68k (Closes: #478548).
Bug-Debian: http://bugs.debian.org/478548
Last-Update: 2013-02-02
---
HalfTest/testBitPatterns.cpp | 4 ++++
HalfTest/testClassification.cpp | 2 ++
2 files changed, 6 insertions(+)
diff --git a/HalfTest/testBitPatterns.cpp b/HalfTest/testBitPatterns.cpp
index 422836d..5b8173b 100644
--- a/HalfTest/testBitPatterns.cpp
+++ b/HalfTest/testBitPatterns.cpp
@@ -305,9 +305,11 @@ testBitPatterns()
testBits (floatPosQNan1(),
"0 11111 1111111111", // nan
"0 11111111 11111111110000000000000"); // nan
+#ifndef __mc68000__
testBits (floatPosQNan2(),
"0 11111 1010101010", // nan
"0 11111111 10101010100000000000000"); // nan
+#endif
//
// Numbers close to -1.0
@@ -473,12 +475,14 @@ testBitPatterns()
testBits (floatNegInfinity(),
"1 11111 0000000000", // +infinity
"1 11111111 00000000000000000000000"); // +infinity
+#ifndef __mc68000__
testBits (floatNegQNan1(),
"1 11111 1111111111", // nan
"1 11111111 11111111110000000000000"); // nan
testBits (floatNegQNan2(),
"1 11111 1010101010", // nan
"1 11111111 10101010100000000000000"); // nan
+#endif
cout << "ok\n\n" << flush;
}
diff --git a/HalfTest/testClassification.cpp b/HalfTest/testClassification.cpp
index a9713e6..04877bc 100644
--- a/HalfTest/testClassification.cpp
+++ b/HalfTest/testClassification.cpp
@@ -156,8 +156,10 @@ testClassification()
testClass (-0.3f, 1, 1, 0, 0, 0, 0, 1);
testClass (-HALF_MAX, 1, 1, 0, 0, 0, 0, 1);
testClass (floatNegInfinity(), 0, 0, 0, 0, 0, 1, 1);
+#ifndef __mc68000__
testClass (floatNegQNan1(), 0, 0, 0, 0, 1, 0, 1);
testClass (floatNegQNan2(), 0, 0, 0, 0, 1, 0, 1);
+#endif
cout << "\n";

View File

@ -1,36 +0,0 @@
From: Samuel Thibault <sthibault@debian.org>
Date: Sat, 14 May 2022 03:32:49 +0800
Subject: fatal error: asm/sigcontext.h: No such file or directory
Bug-Debian: http://bugs.debian.org/788102
---
IexMath/IexMathFpu.cpp | 2 +-
configure.ac | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/IexMath/IexMathFpu.cpp b/IexMath/IexMathFpu.cpp
index 5543046..bff948c 100644
--- a/IexMath/IexMathFpu.cpp
+++ b/IexMath/IexMathFpu.cpp
@@ -52,7 +52,7 @@
#define debug(x)
#endif
-#if defined(HAVE_UCONTEXT_H) && (defined(__x86_64__) || defined(_M_X64) || defined(__i386__) || defined(_M_IX86))
+#if defined(HAVE_UCONTEXT_H) && (defined(__x86_64__) || defined(_M_X64) || defined(__i386__) || defined(_M_IX86)) && (defined(ILMBASE_HAVE_CONTROL_REGISTER_SUPPORT) || defined(__FreeBSD_kernel__) || defined(HAVE_ASM_SIGCONTEXT_H))
#include <ucontext.h>
#include <signal.h>
diff --git a/configure.ac b/configure.ac
index c6f4913..75c8f2e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -105,7 +105,7 @@ dnl
dnl Checks for header files.
dnl
AC_HEADER_STDC
-AC_CHECK_HEADERS(limits.h unistd.h ucontext.h)
+AC_CHECK_HEADERS(limits.h unistd.h ucontext.h asm/sigcontext.h)
dnl Checks for typedefs, structures, and compiler characteristics.
AC_C_CONST

View File

@ -1,42 +0,0 @@
From: Helmut Grohne <helmut@subdivi.de>
Date: Sat, 27 Oct 2018 16:01:43 +0200
Subject: Fix_FTCBFS
- Use CXX_FOR_BUILD for compiling build tools
- Thus add AX_PROG_CXX_FOR_BUILD to configure.ac
- Thus autoreconf
---
Half/Makefile.am | 6 ++++--
configure.ac | 1 +
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/Half/Makefile.am b/Half/Makefile.am
index 6d420a6..114a5ca 100644
--- a/Half/Makefile.am
+++ b/Half/Makefile.am
@@ -17,9 +17,11 @@ EXTRA_DIST = eLut.cpp toFloat.cpp CMakeLists.txt
CLEANFILES = eLut eLut.h toFloat toFloat.h
-eLut_SOURCES = eLut.cpp
+eLut$(EXEEXT): eLut.cpp
+ $(CXX_FOR_BUILD) $(CXXFLAGS_FOR_BUILD) $< -o $@
-toFloat_SOURCES = toFloat.cpp
+toFloat$(EXEEXT): toFloat.cpp
+ $(CXX_FOR_BUILD) $(CXXFLAGS_FOR_BUILD) $< -o $@
eLut.h: eLut
./eLut > eLut.h
diff --git a/configure.ac b/configure.ac
index 75c8f2e..53ab59c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -28,6 +28,7 @@ AC_PROG_CC
AC_PROG_LN_S
AC_PROG_LIBTOOL
AC_PROG_MAKE_SET
+AX_PROG_CXX_FOR_BUILD
dnl
dnl PKGCONFIG preparations

View File

@ -1,43 +0,0 @@
From: Steven Chamberlain <steven@pyro.eu.org>
Date: Sat, 14 May 2022 03:32:49 +0800
Subject: fatal error: asm/sigcontext.h: No such file or directory
Bug-Debian: http://bugs.debian.org/788102
---
IexMath/IexMathFpu.cpp | 15 ++++++++++++++-
1 file changed, 14 insertions(+), 1 deletion(-)
diff --git a/IexMath/IexMathFpu.cpp b/IexMath/IexMathFpu.cpp
index bff948c..c45737f 100644
--- a/IexMath/IexMathFpu.cpp
+++ b/IexMath/IexMathFpu.cpp
@@ -264,6 +264,18 @@ restoreControlRegs (const ucontext_t & ucon, bool clearExceptions)
setMxcsr (ucon.uc_mcontext.fpregs->mxcsr, clearExceptions);
}
+#elif defined(__FreeBSD_kernel__)
+
+#include <machine/npx.h>
+
+inline void
+restoreControlRegs (const ucontext_t & ucon, bool clearExceptions)
+{
+ struct envxmm *ex = (struct envxmm *)(ucon.uc_mcontext.mc_fpstate);
+ setCw ((ex->en_cw & cwRestoreMask) | cwRestoreVal);
+ setMxcsr (ex->en_mxcsr, clearExceptions);
+}
+
#else
//
@@ -463,8 +475,9 @@ setFpExceptionHandler (FpExceptionHandler handler)
sigemptyset (&action.sa_mask);
action.sa_flags = SA_SIGINFO | SA_NOMASK;
action.sa_sigaction = (void (*) (int, siginfo_t *, void *)) catchSigFpe;
+#ifndef __FreeBSD_kernel__
action.sa_restorer = 0;
-
+#endif
sigaction (SIGFPE, &action, 0);
}

View File

@ -1,6 +0,0 @@
10_fix_testsuite_for_m68k
bug788102.patch
kfreebsd-support.patch
testBoxAlgo.patch
testBox.patch
fix_FTCBFS.patch

View File

@ -1,107 +0,0 @@
From: Steven Chamberlain <steven@pyro.eu.org>
Date: Wed, 24 Feb 2016 01:10:11 +0000
Subject: testBox: allow fuzzy comparison of floats, doubles
Allow for inexact values, as long as the error is smaller than the
epsilon of the data type.
On 32-bit x86, allow even greater discrepency at double
precision, due to possible double-rounding. See
https://lists.nongnu.org/archive/html/openexr-devel/2015-12/msg00001.html
---
ImathTest/testBox.cpp | 61 ++++++++++++++++++++++++++++++++++++++++++++++++---
1 file changed, 58 insertions(+), 3 deletions(-)
diff --git a/ImathTest/testBox.cpp b/ImathTest/testBox.cpp
index 0727a4b..3f23554 100644
--- a/ImathTest/testBox.cpp
+++ b/ImathTest/testBox.cpp
@@ -47,6 +47,58 @@ using namespace IMATH_INTERNAL_NAMESPACE;
namespace {
+template <class T>
+bool
+approximatelyEqual (const T &p1, const T &p2)
+{
+ /* int and short should be exact */
+ return (p1 == p2);
+}
+
+bool
+approximatelyEqual (const Vec2<float> &p1, const Vec2<float> &p2)
+{
+ float e = limits<float>::epsilon();
+ float m = 0;
+
+ for (int i = 0; i < 2; ++i)
+ {
+ m = max (m, abs (p1[i]));
+ m = max (m, abs (p2[i]));
+ }
+
+ for (int i = 0; i < 2; ++i)
+ if (!equalWithAbsError (p1[i], p2[i], m * e))
+ return false;
+
+ return true;
+}
+
+bool
+approximatelyEqual (const Vec2<double> &p1, const Vec2<double> &p2)
+{
+#if defined(__i386__) || defined(_M_IX86)
+ /* double-rounding on 32-bit x86 may cause larger error:
+ use epsilon of float rather than double */
+ double e = limits<float>::epsilon();
+#else
+ double e = limits<double>::epsilon();
+#endif
+ double m = 0;
+
+ for (int i = 0; i < 2; ++i)
+ {
+ m = max (m, abs (p1[i]));
+ m = max (m, abs (p2[i]));
+ }
+
+ for (int i = 0; i < 2; ++i)
+ if (!equalWithAbsError (p1[i], p2[i], m * e))
+ return false;
+
+ return true;
+}
+
//
// Test case generation utility - create a vector of IMATH_INTERNAL_NAMESPACE::Vec{2,3,4}
// with all permutations of integers 1..T::dimensions().
@@ -250,7 +302,8 @@ testExtendByPoint(const char *type)
IMATH_INTERNAL_NAMESPACE::Box<T> b;
b.extendBy(p);
- assert(b.min == p && b.max == p);
+ assert (approximatelyEqual (b.min, p));
+ assert (approximatelyEqual (b.max, p));
}
//
@@ -283,7 +336,8 @@ testExtendByPoint(const char *type)
b.extendBy(p);
- assert(b.min == min && b.max == max);
+ assert (approximatelyEqual (b.min, min));
+ assert (approximatelyEqual (b.max, max));
}
}
}
@@ -358,7 +412,8 @@ testExtendByBox(const char *type)
}
b.extendBy(IMATH_INTERNAL_NAMESPACE::Box<T>(p0, p1));
- assert(b.min == min && b.max == max);
+ assert (approximatelyEqual (b.min, min));
+ assert (approximatelyEqual (b.max, max));
}
}
}

View File

@ -1,27 +0,0 @@
From: Steven Chamberlain <steven@pyro.eu.org>
Date: Wed, 24 Feb 2016 01:04:11 +0000
Subject: testBoxAlgo: allow fuzzy match of b12 == b2
Also fix a pre-existing typo.
---
ImathTest/testBoxAlgo.cpp | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/ImathTest/testBoxAlgo.cpp b/ImathTest/testBoxAlgo.cpp
index 9be1b7c..d61963c 100644
--- a/ImathTest/testBoxAlgo.cpp
+++ b/ImathTest/testBoxAlgo.cpp
@@ -886,10 +886,11 @@ boxMatrixTransform ()
assert (approximatelyEqual (b2.min, b4.min, e));
assert (approximatelyEqual (b2.max, b4.max, e));
- assert (approximatelyEqual (b3.max, b4.max, e));
+ assert (approximatelyEqual (b3.min, b4.min, e));
assert (approximatelyEqual (b3.max, b4.max, e));
- assert (b21 == b2);
+ assert (approximatelyEqual (b2.min, b21.min, e));
+ assert (approximatelyEqual (b2.max, b21.max, e));
assert (b31 == b3);
M[0][3] = 1;

View File

@ -1 +1 @@
3.0 (quilt)
3.0 (native)