]> git.pld-linux.org Git - packages/OCE.git/commitdiff
- up to 0.18.3, use openmp as threading lib auto/th/OCE-0.18.3-1
authorJan Rękorajski <baggins@pld-linux.org>
Mon, 20 Dec 2021 14:30:21 +0000 (15:30 +0100)
committerJan Rękorajski <baggins@pld-linux.org>
Mon, 20 Dec 2021 14:30:21 +0000 (15:30 +0100)
OCE.spec
oce-build.patch [deleted file]

index 24287192c0a2816adc5047dc0d682629ccda73ec..f59aaad661a51e3a0eebbc6004ed2f0c0c329ef0 100644 (file)
--- a/OCE.spec
+++ b/OCE.spec
@@ -1,15 +1,18 @@
-%bcond_without tests
+#
+# Conditional build:
+%bcond_without tests           # build with tests
+%bcond_with    tbb             # Use tbb for multithreading
+%bcond_without openmp          # Use openmp for multithreading
 #
 Summary:       OpenCASCADE Community Edition
 Name:          OCE
-Version:       0.18.2
-Release:       2
+Version:       0.18.3
+Release:       1
 License:       LGPLv2 with exception
 Group:         Applications/Engineering
 URL:           https://github.com/tpaviot/oce
 Source0:       https://github.com/tpaviot/oce/archive/%{name}-%{version}.tar.gz
-# Source0-md5: 6dfd68e459e2c62387579888a867281f
-Patch0:                oce-build.patch
+# Source0-md5: 1686393c8493bbbb2f3f242330b33cba
 Source1:       DRAWEXE.1
 Source2:       opencascade-draw.desktop
 Source3:       oce-256.png
@@ -26,7 +29,8 @@ BuildRequires:        Mesa-libGLU-devel
 BuildRequires: ftgl-devel
 BuildRequires: gl2ps-devel
 BuildRequires: libgomp
-BuildRequires: tbb-devel
+%{?with_openmp:BuildRequires:  libopenmpt-devel}
+%{?with_tbb:BuildRequires:     tbb-devel}
 BuildRequires: tcl-devel
 BuildRequires: tk-devel
 BuildRequires: xorg-lib-libXScrnSaver-devel
@@ -149,7 +153,6 @@ OpenCASCADE CAE platform library development files
 
 %prep
 %setup -q -n oce-%{name}-%{version}
-%patch0 -p1
 
 %build
 install -d build
@@ -159,7 +162,7 @@ cd build
                -DOCE_INSTALL_LIB_DIR=%{_lib} \
                -DOCE_WITH_FREEIMAGE=ON \
                -DOCE_WITH_GL2PS=ON \
-               -DOCE_MULTITHREAD_LIBRARY:STRING=TBB \
+               -DOCE_MULTITHREAD_LIBRARY:STRING=%{?with_tbb:TBB}%{!?with_tbb:%{?with_openmp:OPENMP}%{!?with_openmp:NONE}} \
                -DOCE_DRAW=ON \
                -DOCE_TESTING=ON \
                ../
diff --git a/oce-build.patch b/oce-build.patch
deleted file mode 100644 (file)
index b7cc7fa..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
---- oce-OCE-0.18.2/src/Standard/Standard_CLocaleSentry.hxx~    2017-08-11 07:51:11.000000000 +0200
-+++ oce-OCE-0.18.2/src/Standard/Standard_CLocaleSentry.hxx     2017-08-15 21:40:16.105343307 +0200
-@@ -28,11 +28,6 @@
-   #if defined(__APPLE__)
-     #define HAVE_XLOCALE_H
-   #endif
--
--  //! We check _GNU_SOURCE for glibc extensions here and it is always defined by g++ compiler.
--  #if defined(_GNU_SOURCE) && !defined(__ANDROID__)
--    #define HAVE_XLOCALE_H
--  #endif
- #endif // ifndef HAVE_LOCALE_H
- #ifdef HAVE_XLOCALE_H
This page took 0.142078 seconds and 4 git commands to generate.