[packages/openscad] - use cmake for building the main project

baggins baggins at pld-linux.org
Tue Jun 7 22:19:27 CEST 2022


commit 63a4dc28c3d12b83c212cc774d702365a24b2da3
Author: Jan Rękorajski <baggins at pld-linux.org>
Date:   Tue Jun 7 22:19:08 2022 +0200

    - use cmake for building the main project

 openscad-polyclipping.patch | 20 ++++++++++++++++++++
 openscad.spec               |  9 ++++++---
 2 files changed, 26 insertions(+), 3 deletions(-)
---
diff --git a/openscad.spec b/openscad.spec
index 34b1d9a..a23846b 100644
--- a/openscad.spec
+++ b/openscad.spec
@@ -151,12 +151,15 @@ expect some API changes, however many things are already working.
 %{__rm} -r src/ext/polyclipping
 
 %build
-qmake-qt5 \
-	PREFIX=%{_prefix}
+mkdir -p build
+cd build
+%cmake ../ \
+	-DEXPERIMENTAL=ON
 %{__make}
 
 %if %{with tests}
-cd tests
+export OPENSCAD_BINARY=$(pwd)/openscad
+cd ../tests
 %cmake .
 %{__make}
 %{__make} -j1 test
diff --git a/openscad-polyclipping.patch b/openscad-polyclipping.patch
index 296bb99..907430f 100644
--- a/openscad-polyclipping.patch
+++ b/openscad-polyclipping.patch
@@ -35,3 +35,23 @@ index 0dc7cd0..c98cda0 100644
  
  namespace libsvg {
  
+--- openscad-2021.01/CMakeLists.txt.orig	2021-01-31 21:17:41.000000000 +0100
++++ openscad-2021.01/CMakeLists.txt	2022-06-07 21:45:07.303640010 +0200
+@@ -403,6 +403,9 @@
+   endif()
+ endif()
+ 
++pkg_check_modules(polyclipping REQUIRED polyclipping)
++list(APPEND COMMON_LIBRARIES ${polyclipping_LIBRARIES})
++
+ include_directories("src/ext/libtess2/Include")
+ 
+ # NOTE: To keep HEADLESS builds working, do NOT add Qt-dependent sources here,
+@@ -495,7 +497,6 @@
+   src/UserModule.cc
+   src/Tree.cc
+   src/ext/lodepng/lodepng.cpp
+-  src/ext/polyclipping/clipper.cpp
+   src/ext/libtess2/Source/bucketalloc.c
+   src/ext/libtess2/Source/dict.c
+   src/ext/libtess2/Source/geom.c
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/openscad.git/commitdiff/63a4dc28c3d12b83c212cc774d702365a24b2da3



More information about the pld-cvs-commit mailing list