$ git diff --patch-with-stat --summary d95123cadfa9f87cc501f5f6aa18d77385865784..b690011a849c29542b0848bf3cd8eba698e5481a
oce-7.5.0-clang.patch | 12 ++++++++++++
opencascade.spec | 8 ++++++--
2 files changed, 18 insertions(+), 2 deletions(-)
create mode 100644 oce-7.5.0-clang.patch
diff --git a/oce-7.5.0-clang.patch b/oce-7.5.0-clang.patch
new file mode 100644
index 0000000..4a2a30f
--- /dev/null
+++ b/oce-7.5.0-clang.patch
@@ -0,0 +1,12 @@
+diff -up oce-upstream-V7_5_0/src/Standard/Standard_Type.hxx.omv~ oce-upstream-V7_5_0/src/Standard/Standard_Type.hxx
+--- oce-upstream-V7_5_0/src/Standard/Standard_Type.hxx.omv~ 2022-01-09 01:03:31.512273977 +0100
++++ oce-upstream-V7_5_0/src/Standard/Standard_Type.hxx 2022-01-09 01:03:38.866283692 +0100
+@@ -26,7 +26,7 @@
+ // DEFINE_STANDARD_RTTI* macro is actually a base class.
+ #if ! defined(OCCT_CHECK_BASE_CLASS)
+
+-#if (defined(__GNUC__) && ((__GNUC__ == 4 && __GNUC_MINOR__ >= 7) || (__GNUC__ > 4)))
++#if (defined(__GNUC__) && ((__GNUC__ == 4 && __GNUC_MINOR__ >= 7) || (__GNUC__ > 4))) && !defined(__clang__)
+
+ // For GCC 4.7+, more strict check is possible -- ensuring that base class
+ // is direct base -- using non-standard C++ reflection functionality.
diff --git a/opencascade.spec b/opencascade.spec
index 9ee3f54..7fa1431 100644
--- a/opencascade.spec
+++ b/opencascade.spec
@@ -16,7 +16,7 @@
Name: opencascade
Group: Sciences/Physics
Version: %{version}
-Release: 4
+Release: 6
Summary: 3D modeling & numerical simulation
License: LGPLv2 with exceptions
URL: https://github.com/tpaviot/oce
@@ -32,6 +32,7 @@ Patch1: opencascade-fix_externlib.patch
Patch2: opencascade-compile.patch
# (fedora)
Patch3: opencascade-cmake.patch
+Patch4: oce-7.5.0-clang.patch
# (upstream)
Patch100: opencascade-7.5.0-fix_tbb.patch
BuildRequires: cmake
@@ -90,7 +91,6 @@ edition to heavy industry.
%package -n %{libname}
Summary: 3D modeling & numerical simulation
Group: System/Libraries
-Obsoletes: %{libname} < %{EVRD}
%description -n %{libname}
Open CASCADE Technology is software development platform freely available
@@ -165,6 +165,10 @@ export CXX=g++
%install
ninja install -C build
+# Draw binary should not be versioned.
+mv %{buildroot}%{_bindir}/DRAWEXE-%{version} \
+ %{buildroot}%{_bindir}/DRAWEXE
+
# adjust environment/directories to avoid (too much) script patching
#ln -sf %{_libdir} %{buildroot}%{_datadir}/%{name}/lib
#ln -sf %{_includedir}/%{name} %{buildroot}%{_datadir}/%{name}/inc