From 193fb497522e7dd064c264bb769fb906089aba07 Mon Sep 17 00:00:00 2001 From: Lukas1818 Date: Fri, 1 Apr 2022 19:39:49 +0200 Subject: [PATCH 1/8] update to 2.4.58.2 --- .SRCINFO | 8 ++++---- PKGBUILD | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.SRCINFO b/.SRCINFO index 8faec98..a78c8f9 100644 --- a/.SRCINFO +++ b/.SRCINFO @@ -1,6 +1,6 @@ pkgbase = superslicer-prerelease pkgdesc = G-code generator for 3D printers (RepRap, Makerbot, Ultimaker etc.) - pkgver = 2.4.58.1 + pkgver = 2.4.58.2 pkgrel = 1 epoch = 1 url = https://github.com/supermerill/SuperSlicer @@ -24,15 +24,15 @@ pkgbase = superslicer-prerelease depends = qhull>=2020.2-4 depends = wxgtk3-dev-314-opt optdepends = superslicer-profiles: Predefined printer profiles - provides = superslicer=1:2.4.58.1 + provides = superslicer=1:2.4.58.2 conflicts = superslicer conflicts = superslicer-git options = !emptydirs - source = https://github.com/supermerill/SuperSlicer/archive/2.4.58.1.tar.gz + source = https://github.com/supermerill/SuperSlicer/archive/2.4.58.2.tar.gz source = 0001-wxgtk3-is-broken-on-wayland.patch source = 0002-fix-cereal.patch source = 0003-openexr3.patch - sha512sums = 332d36b1069ea2652c3ef527670f4fe2aead4d06f4c38fb4e833cf85cbf267577c4663dc2474fbcc2827226babf1fc78d7fe629c16a555f082784410da4e006d + sha512sums = c5038bd13482a2a164ce7f3b126b9f0183b4220b2d46d84e86a0ad29624eb9e000c5b8ad876506e4042a80c7c57b7f34bbf2bf5affc385334e00da416c22fd27 sha512sums = acf35ebe467e9fb30f1b77d15348f1a7b82dcf45a5b829e375e972b5d6b49968603b3fa090c4d1f56e8b5148e2b820e79afa269da60ace70de1ceadcf6e820c5 sha512sums = c3ba2d16140d445168681ff442bda12e87de22f8b94d59c32576bd7079ffe5864cce8e62cddd1ed47458f9eddcbd3e1a02645b0645aad6f2e0cb08a876bf783f sha512sums = 840e51b8feb3568ff46d309ece063f7188018fcaa43d19ec50ede408fdf2c237a3b7eaa11ba24409d8c3f7d6f5fb270181508cc56e0b2b0fef68b766130ef1eb diff --git a/PKGBUILD b/PKGBUILD index 6e9f59d..9a7a92e 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -1,7 +1,7 @@ # Maintainer: Lukas1818 aur at lukas1818 dot de pkgname=superslicer-prerelease -pkgver=2.4.58.1 +pkgver=2.4.58.2 _pkgtag=$pkgver pkgrel=1 epoch=1 @@ -19,7 +19,7 @@ source=("https://github.com/supermerill/SuperSlicer/archive/$_pkgtag.tar.gz" "0001-wxgtk3-is-broken-on-wayland.patch" "0002-fix-cereal.patch" "0003-openexr3.patch") -sha512sums=('332d36b1069ea2652c3ef527670f4fe2aead4d06f4c38fb4e833cf85cbf267577c4663dc2474fbcc2827226babf1fc78d7fe629c16a555f082784410da4e006d' +sha512sums=('c5038bd13482a2a164ce7f3b126b9f0183b4220b2d46d84e86a0ad29624eb9e000c5b8ad876506e4042a80c7c57b7f34bbf2bf5affc385334e00da416c22fd27' 'acf35ebe467e9fb30f1b77d15348f1a7b82dcf45a5b829e375e972b5d6b49968603b3fa090c4d1f56e8b5148e2b820e79afa269da60ace70de1ceadcf6e820c5' 'c3ba2d16140d445168681ff442bda12e87de22f8b94d59c32576bd7079ffe5864cce8e62cddd1ed47458f9eddcbd3e1a02645b0645aad6f2e0cb08a876bf783f' '840e51b8feb3568ff46d309ece063f7188018fcaa43d19ec50ede408fdf2c237a3b7eaa11ba24409d8c3f7d6f5fb270181508cc56e0b2b0fef68b766130ef1eb') From b4286551fd240bcf7a8fa6f6e0f80d31aff51308 Mon Sep 17 00:00:00 2001 From: Lukas1818 Date: Sat, 2 Apr 2022 17:53:20 +0200 Subject: [PATCH 2/8] use wxgtk instead of wxgtk-dev-314-opt --- .SRCINFO | 4 ++-- PKGBUILD | 9 ++++----- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/.SRCINFO b/.SRCINFO index a78c8f9..a14732b 100644 --- a/.SRCINFO +++ b/.SRCINFO @@ -13,7 +13,7 @@ pkgbase = superslicer-prerelease makedepends = libigl makedepends = openvdb makedepends = samurai - makedepends = wxgtk2-dev-314-opt + makedepends = wxgtk2 depends = boost-libs>=1.73.0 depends = cgal depends = glew @@ -22,7 +22,7 @@ pkgbase = superslicer-prerelease depends = nlopt depends = openvdb depends = qhull>=2020.2-4 - depends = wxgtk3-dev-314-opt + depends = wxgtk3 optdepends = superslicer-profiles: Predefined printer profiles provides = superslicer=1:2.4.58.2 conflicts = superslicer diff --git a/PKGBUILD b/PKGBUILD index 9a7a92e..5281288 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -10,8 +10,8 @@ arch=("$CARCH") url="https://github.com/supermerill/SuperSlicer" license=('AGPL3') options=(!emptydirs) -depends=('boost-libs>=1.73.0' 'cgal' 'glew' 'imath' 'libspnav' 'nlopt' 'openvdb' 'qhull>=2020.2-4' 'wxgtk3-dev-314-opt') -makedepends=('boost>=1.73.0' 'cereal>=1.3.0' 'cmake' 'eigen' 'libigl' 'openvdb' 'samurai' 'wxgtk2-dev-314-opt') # cmake doesn't detect wx if not both gtk2 and gtk3 are installed +depends=('boost-libs>=1.73.0' 'cgal' 'glew' 'imath' 'libspnav' 'nlopt' 'openvdb' 'qhull>=2020.2-4' 'wxgtk3') +makedepends=('boost>=1.73.0' 'cereal>=1.3.0' 'cmake' 'eigen' 'libigl' 'openvdb' 'samurai' 'wxgtk2') # cmake doesn't detect wx if not both gtk2 and gtk3 are installed optdepends=('superslicer-profiles: Predefined printer profiles') provides=("superslicer=$epoch:$pkgver") conflicts=('superslicer' 'superslicer-git') @@ -28,6 +28,7 @@ prepare() { cd "$srcdir/SuperSlicer-$_pkgtag" [ ! -f build/Makefile ] || rm -rf build + rm -rf build # build does fail everytime if it is not clean build ? mkdir -p build # disabling tests is not enough, we need to remove them explicitly @@ -54,9 +55,7 @@ build() -DSLIC3R_WX_STABLE=ON \ -DSLIC3R_GTK=3 \ -DSLIC3R_BUILD_TESTS=OFF \ - -DSLIC3R_ALPHA=ON \ - -DwxWidgets_CONFIG_EXECUTABLE=/opt/wxgtk-dev-314/bin/wx-config \ - -DCMAKE_CXX_FLAGS="-Wno-unused-command-line-argument -Wl,-rpath=/opt/wxgtk-dev-314/lib" + -DSLIC3R_ALPHA=ON samu } From 968d0c35a4e8af5aa190a66e4221190f103b0a49 Mon Sep 17 00:00:00 2001 From: Lukas1818 Date: Sat, 2 Apr 2022 17:54:25 +0200 Subject: [PATCH 3/8] forget pkgrel --- .SRCINFO | 2 +- PKGBUILD | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.SRCINFO b/.SRCINFO index a14732b..b02b2a7 100644 --- a/.SRCINFO +++ b/.SRCINFO @@ -1,7 +1,7 @@ pkgbase = superslicer-prerelease pkgdesc = G-code generator for 3D printers (RepRap, Makerbot, Ultimaker etc.) pkgver = 2.4.58.2 - pkgrel = 1 + pkgrel = 2 epoch = 1 url = https://github.com/supermerill/SuperSlicer arch = x86_64 diff --git a/PKGBUILD b/PKGBUILD index 5281288..b76151b 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -3,7 +3,7 @@ pkgname=superslicer-prerelease pkgver=2.4.58.2 _pkgtag=$pkgver -pkgrel=1 +pkgrel=2 epoch=1 pkgdesc="G-code generator for 3D printers (RepRap, Makerbot, Ultimaker etc.)" arch=("$CARCH") From 4606866dad99ff3b98593420ee84438530542b26 Mon Sep 17 00:00:00 2001 From: Dominic Date: Wed, 20 Nov 2024 13:13:09 +0100 Subject: [PATCH 4/8] uncommitted changes --- PKGBUILD | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/PKGBUILD b/PKGBUILD index 6e9f59d..792ef92 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -1,7 +1,7 @@ # Maintainer: Lukas1818 aur at lukas1818 dot de pkgname=superslicer-prerelease -pkgver=2.4.58.1 +pkgver=nightly_dev _pkgtag=$pkgver pkgrel=1 epoch=1 @@ -9,18 +9,16 @@ pkgdesc="G-code generator for 3D printers (RepRap, Makerbot, Ultimaker etc.)" arch=("$CARCH") url="https://github.com/supermerill/SuperSlicer" license=('AGPL3') -options=(!emptydirs) -depends=('boost-libs>=1.73.0' 'cgal' 'glew' 'imath' 'libspnav' 'nlopt' 'openvdb' 'qhull>=2020.2-4' 'wxgtk3-dev-314-opt') -makedepends=('boost>=1.73.0' 'cereal>=1.3.0' 'cmake' 'eigen' 'libigl' 'openvdb' 'samurai' 'wxgtk2-dev-314-opt') # cmake doesn't detect wx if not both gtk2 and gtk3 are installed +options=(!emptydirs debug !strip) +depends=('boost-libs>=1.73.0' 'cgal' 'glew' 'imath' 'libspnav' 'nlopt' 'openvdb' 'qhull>=2020.2-4' 'wxgtk3-dev-opt') +makedepends=('boost>=1.73.0' 'cereal>=1.3.0' 'cmake' 'eigen' 'libigl' 'openvdb' 'samurai' 'wxgtk2-dev-opt') # cmake doesn't detect wx if not both gtk2 and gtk3 are installed optdepends=('superslicer-profiles: Predefined printer profiles') provides=("superslicer=$epoch:$pkgver") conflicts=('superslicer' 'superslicer-git') -source=("https://github.com/supermerill/SuperSlicer/archive/$_pkgtag.tar.gz" - "0001-wxgtk3-is-broken-on-wayland.patch" +source=("https://github.com/supermerill/SuperSlicer/archive/refs/heads/nightly_dev.tar.gz" "0002-fix-cereal.patch" "0003-openexr3.patch") -sha512sums=('332d36b1069ea2652c3ef527670f4fe2aead4d06f4c38fb4e833cf85cbf267577c4663dc2474fbcc2827226babf1fc78d7fe629c16a555f082784410da4e006d' - 'acf35ebe467e9fb30f1b77d15348f1a7b82dcf45a5b829e375e972b5d6b49968603b3fa090c4d1f56e8b5148e2b820e79afa269da60ace70de1ceadcf6e820c5' +sha512sums=(SKIP 'c3ba2d16140d445168681ff442bda12e87de22f8b94d59c32576bd7079ffe5864cce8e62cddd1ed47458f9eddcbd3e1a02645b0645aad6f2e0cb08a876bf783f' '840e51b8feb3568ff46d309ece063f7188018fcaa43d19ec50ede408fdf2c237a3b7eaa11ba24409d8c3f7d6f5fb270181508cc56e0b2b0fef68b766130ef1eb') @@ -34,7 +32,6 @@ prepare() sed -i 's,add_subdirectory(test),,g' src/CMakeLists.txt # apply patches - patch -Np1 -i "$srcdir/0001-wxgtk3-is-broken-on-wayland.patch" patch -Np1 -i "$srcdir/0002-fix-cereal.patch" patch -Np1 -i "$srcdir/0003-openexr3.patch" } @@ -46,7 +43,7 @@ build() cmake .. \ -G Ninja \ - -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_BUILD_TYPE=RelWithDebInfo \ -DCMAKE_INSTALL_PREFIX=/usr \ -DOpenGL_GL_PREFERENCE=GLVND \ -DSLIC3R_FHS=ON \ @@ -55,8 +52,8 @@ build() -DSLIC3R_GTK=3 \ -DSLIC3R_BUILD_TESTS=OFF \ -DSLIC3R_ALPHA=ON \ - -DwxWidgets_CONFIG_EXECUTABLE=/opt/wxgtk-dev-314/bin/wx-config \ - -DCMAKE_CXX_FLAGS="-Wno-unused-command-line-argument -Wl,-rpath=/opt/wxgtk-dev-314/lib" + -DwxWidgets_CONFIG_EXECUTABLE=/opt/wxgtk-dev/bin/wx-config \ + -DCMAKE_CXX_FLAGS="$CXXFLAGS -Wno-unused-command-line-argument -Wl,-rpath=/opt/wxgtk-dev/lib" samu } From 2b9cd5ceb7d4e571e30954eee08231c76de675ec Mon Sep 17 00:00:00 2001 From: Dominic Date: Wed, 20 Nov 2024 14:28:13 +0100 Subject: [PATCH 5/8] Try to update to 2.5.60.0-1 Currently fails to launch with $ superslicer superslicer: symbol lookup error: superslicer: undefined symbol: _ZN3tbb6detail2r127get_thread_reference_vertexEPNS0_2d126wait_tree_vertex_interfaceE --- .SRCINFO | 32 +++++++--- 0001-boost1.79.patch | 81 ++++++++++++++++++++++++ 0001-wxgtk3-is-broken-on-wayland.patch | 21 ------ 0002-fix-cereal.patch | 3 +- 0004-fix-opencascade-version-check.patch | 18 ++++++ 0005-fix-opencascade-libs.patch | 17 +++++ 0006-fix-non-const-lvalue.patch | 19 ++++++ 0007-boost1.84.patch | 34 ++++++++++ 0008-boost1.85.patch | 12 ++++ 0009-fix-multiple-choice.patch | 14 ++++ PKGBUILD | 46 ++++++++++---- 11 files changed, 253 insertions(+), 44 deletions(-) create mode 100644 0001-boost1.79.patch delete mode 100644 0001-wxgtk3-is-broken-on-wayland.patch create mode 100644 0004-fix-opencascade-version-check.patch create mode 100644 0005-fix-opencascade-libs.patch create mode 100644 0006-fix-non-const-lvalue.patch create mode 100644 0007-boost1.84.patch create mode 100644 0008-boost1.85.patch create mode 100644 0009-fix-multiple-choice.patch diff --git a/.SRCINFO b/.SRCINFO index b02b2a7..0a90765 100644 --- a/.SRCINFO +++ b/.SRCINFO @@ -1,7 +1,7 @@ pkgbase = superslicer-prerelease pkgdesc = G-code generator for 3D printers (RepRap, Makerbot, Ultimaker etc.) - pkgver = 2.4.58.2 - pkgrel = 2 + pkgver = 2.5.60.0 + pkgrel = 1 epoch = 1 url = https://github.com/supermerill/SuperSlicer arch = x86_64 @@ -13,7 +13,6 @@ pkgbase = superslicer-prerelease makedepends = libigl makedepends = openvdb makedepends = samurai - makedepends = wxgtk2 depends = boost-libs>=1.73.0 depends = cgal depends = glew @@ -22,19 +21,32 @@ pkgbase = superslicer-prerelease depends = nlopt depends = openvdb depends = qhull>=2020.2-4 - depends = wxgtk3 + depends = slicer-udev + depends = wxwidgets-gtk3 optdepends = superslicer-profiles: Predefined printer profiles - provides = superslicer=1:2.4.58.2 + provides = superslicer=1:2.5.60.0 conflicts = superslicer conflicts = superslicer-git options = !emptydirs - source = https://github.com/supermerill/SuperSlicer/archive/2.4.58.2.tar.gz - source = 0001-wxgtk3-is-broken-on-wayland.patch + source = https://github.com/supermerill/SuperSlicer/archive/2.5.60.0.tar.gz + source = 0001-boost1.79.patch source = 0002-fix-cereal.patch source = 0003-openexr3.patch - sha512sums = c5038bd13482a2a164ce7f3b126b9f0183b4220b2d46d84e86a0ad29624eb9e000c5b8ad876506e4042a80c7c57b7f34bbf2bf5affc385334e00da416c22fd27 - sha512sums = acf35ebe467e9fb30f1b77d15348f1a7b82dcf45a5b829e375e972b5d6b49968603b3fa090c4d1f56e8b5148e2b820e79afa269da60ace70de1ceadcf6e820c5 - sha512sums = c3ba2d16140d445168681ff442bda12e87de22f8b94d59c32576bd7079ffe5864cce8e62cddd1ed47458f9eddcbd3e1a02645b0645aad6f2e0cb08a876bf783f + source = 0004-fix-opencascade-version-check.patch + source = 0005-fix-opencascade-libs.patch + source = 0006-fix-non-const-lvalue.patch + source = 0007-boost1.84.patch + source = 0008-boost1.85.patch + source = 0009-fix-multiple-choice.patch + sha512sums = a53f4cc9b5a20f3f60d38553d47bfd19ce8bd739a8a16493bbcf64f75825fa760b8c107d7f927d49d967f7d067fac8c428c8f6e67219e74b0970d9ab7aa5b9e6 + sha512sums = fc18e8edf516f9479c3b0e201d1c74b42289f15ef8a64ff3a88c2bb14613978a9dcf7be50ff8b79faf054c7721a095a70715b0fb0747be48757f9502ba0eb859 + sha512sums = 58467732161eb0abe58cfb1e64e080f64f9f2221032b0d6176739fc81a61fe7838fa6479e9aac7fa0ee9805898f9293081c5e35a146df103830199b46354b97e sha512sums = 840e51b8feb3568ff46d309ece063f7188018fcaa43d19ec50ede408fdf2c237a3b7eaa11ba24409d8c3f7d6f5fb270181508cc56e0b2b0fef68b766130ef1eb + sha512sums = 4efb6dd48c8184f47b838228cf624a74429f35d133fb85316ddcde9d78bd462d64009ec9fe0b3f34232ddf4971f81ea03385ed661c771de9f0fd5bffcbe2a74c + sha512sums = a01abf748f82bc423f2c012ac430f78cfd5e56dede1d5999376e780267d0302d9a2a80c3eb15226c2f82102dda4c567c721ff99ab1fdeef504cbf9d9cb63ca53 + sha512sums = aca3a028eaab63baf83dd80d82615394435c97b9b45c99764ca84995d246096e3e5c2b564ed29e194652c8e221a80cf6abdc165cb3009fd20af586b0432b2bc9 + sha512sums = a92af974cb62901aab5a5c8c34672e9a7c90ea7246bbd7423421a9b7ee12a7b17073d90a6f36f994328c7dc9c2d0a6e4fd18c980a71863bc530d873ebaa80433 + sha512sums = ca9f407d87d8dd0181077bc2da5a8e2f8995eed88a4787b73ee6c62ef6d2380fd1394fe5412cdc34276d4182bce6f272173e9ccb653d1e28978e16f379114002 + sha512sums = 6d7ab93042a75f04e1c3c8f294d19dd39abaf22aa75caf996c6a0cf753f6472134a3d4fa443b73924800b2d3a710416a931745c168911c0df3709fb71ec00570 pkgname = superslicer-prerelease diff --git a/0001-boost1.79.patch b/0001-boost1.79.patch new file mode 100644 index 0000000..f3ad855 --- /dev/null +++ b/0001-boost1.79.patch @@ -0,0 +1,81 @@ +From 408e56f0390f20aaf793e0aa0c70c4d9544401d4 Mon Sep 17 00:00:00 2001 +From: Vojtech Bubnik +Date: Mon, 25 Apr 2022 08:33:48 +0200 +Subject: [PATCH] Fix of Boost 1.79 deprecated boost::filesystem::ofstream + #8238 Replacing boost::filesystem::fstream with boost::nowide::fstream + variants with the unfortunate cost of string path conversion on Windows from + 16 bits to UTF8 and back to 16 bits. + +Unfortunately we cannot use std::filesystem yet as it is missing +on older MACs and because the interface is crooked minefield on Windows +see https://github.com/microsoft/STL/issues/909 +--- + src/hints/HintsToPot.cpp | 2 +- + src/libslic3r/Preset.cpp | 2 +- + src/slic3r/GUI/HintNotification.cpp | 8 +++++--- + 3 files changed, 7 insertions(+), 5 deletions(-) + +diff --git a/src/hints/HintsToPot.cpp b/src/hints/HintsToPot.cpp +index 7c8029cdeb..4791f0612f 100644 +--- a/src/hints/HintsToPot.cpp ++++ b/src/hints/HintsToPot.cpp +@@ -9,7 +9,7 @@ + + bool write_to_pot(boost::filesystem::path path, const std::vector>& data) + { +- boost::filesystem::ofstream file(std::move(path), std::ios_base::app); ++ boost::nowide::ofstream file(path.string(), std::ios_base::app); + for (const auto& element : data) + { + //Example of .pot element +diff --git a/src/libslic3r/Preset.cpp b/src/libslic3r/Preset.cpp +index f3a1c15b3e..f171cb14dd 100644 +--- a/src/libslic3r/Preset.cpp ++++ b/src/libslic3r/Preset.cpp +@@ -84,7 +84,7 @@ ConfigFileType guess_config_file_type(const ptree &tree) + VendorProfile VendorProfile::from_ini(const boost::filesystem::path &path, bool load_all) + { + ptree tree; +- boost::filesystem::ifstream ifs(path); ++ boost::nowide::ifstream ifs(path.string()); + boost::property_tree::read_ini(ifs, tree); + return VendorProfile::from_ini(tree, path, load_all); + } +diff --git a/src/slic3r/GUI/HintNotification.cpp b/src/slic3r/GUI/HintNotification.cpp +index 93e0fb3259..820b74eedb 100644 +--- a/src/slic3r/GUI/HintNotification.cpp ++++ b/src/slic3r/GUI/HintNotification.cpp +@@ -14,12 +14,14 @@ + #include "libslic3r/Config.hpp" + #include "libslic3r/PrintConfig.hpp" + ++#include ++ + #include + #include + #include + #include + #include +-#include ++ + #include + #include + #include +@@ -65,7 +67,7 @@ inline void push_style_color(ImGuiCol idx, const ImVec4& col, bool fading_out, f + + void write_used_binary(const std::vector& ids) + { +- boost::filesystem::ofstream file((boost::filesystem::path(data_dir()) / "cache" / "hints.cereal"), std::ios::binary); ++ boost::nowide::ofstream file((boost::filesystem::path(data_dir()) / "cache" / "hints.cereal").string(), std::ios::binary); + cereal::BinaryOutputArchive archive(file); + HintsCerealData cd { ids }; + try +@@ -84,7 +86,7 @@ void read_used_binary(std::vector& ids) + BOOST_LOG_TRIVIAL(warning) << "Failed to load to hints.cereal. File does not exists. " << path.string(); + return; + } +- boost::filesystem::ifstream file(path); ++ boost::nowide::ifstream file(path.string()); + cereal::BinaryInputArchive archive(file); + HintsCerealData cd; + try diff --git a/0001-wxgtk3-is-broken-on-wayland.patch b/0001-wxgtk3-is-broken-on-wayland.patch deleted file mode 100644 index b0371b4..0000000 --- a/0001-wxgtk3-is-broken-on-wayland.patch +++ /dev/null @@ -1,21 +0,0 @@ -diff --git a/src/slic3r/GUI/GUI.cpp b/src/slic3r/GUI/GUI.cpp -index 4e85967a5..f141aabb5 100644 ---- a/src/slic3r/GUI/GUI.cpp -+++ b/src/slic3r/GUI/GUI.cpp -@@ -35,6 +35,16 @@ - - namespace Slic3r { namespace GUI { - -+// wxgtk3 is broken on wayland: https://trac.wxwidgets.org/ticket/17702 -+#ifdef __WXGTK3__ -+struct ForceX11 { -+ ForceX11() { -+ setenv("GDK_BACKEND", "x11", 1); -+ } -+}; -+static struct ForceX11 forcex11; -+#endif -+ - #if __APPLE__ - IOPMAssertionID assertionID; - #endif diff --git a/0002-fix-cereal.patch b/0002-fix-cereal.patch index 839b0ec..f3d52a0 100644 --- a/0002-fix-cereal.patch +++ b/0002-fix-cereal.patch @@ -34,12 +34,13 @@ diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 01ef37905..98dbafa01 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt -@@ -139,7 +139,7 @@ if (NOT WIN32) +@@ -139,8 +139,8 @@ if (NOT WIN32) set_target_properties(Slic3r PROPERTIES OUTPUT_NAME "${SLIC3R_APP_CMD}") endif () -target_link_libraries(Slic3r libslic3r cereal) +target_link_libraries(Slic3r libslic3r) + if (APPLE) # add_compile_options(-stdlib=libc++) # add_definitions(-DBOOST_THREAD_DONT_USE_CHRONO -DBOOST_NO_CXX11_RVALUE_REFERENCES -DBOOST_THREAD_USES_MOVE) diff --git a/0004-fix-opencascade-version-check.patch b/0004-fix-opencascade-version-check.patch new file mode 100644 index 0000000..2fa784a --- /dev/null +++ b/0004-fix-opencascade-version-check.patch @@ -0,0 +1,18 @@ +https://github.com/supermerill/SuperSlicer/issues/3912#issuecomment-1675135988 + +--- src/occt_wrapper/CMakeLists.txt.bak 2024-11-20 13:23:45.624527309 +0100 ++++ src/occt_wrapper/CMakeLists.txt 2024-11-20 13:23:56.347478724 +0100 +@@ -19,7 +19,12 @@ + + generate_export_header(OCCTWrapper) + +-find_package(OpenCASCADE 7.6.2 REQUIRED) ++find_package(OpenCASCADE REQUIRED) ++if (OpenCASCADE_VERSION VERSION_LESS 7.6.2) ++ message(FATAL_ERROR "OpenCASCADE v7 >= v7.6.2 must be used") ++elseif (OpenCASCADE_VERSION VERSION_GREATER_EQUAL 8.0.0) ++ message(FATAL_ERROR "OpenCASCADE v7 >= v7.6.2 must be used") ++endif () + + set(OCCT_LIBS + TKXDESTEP diff --git a/0005-fix-opencascade-libs.patch b/0005-fix-opencascade-libs.patch new file mode 100644 index 0000000..ebb023a --- /dev/null +++ b/0005-fix-opencascade-libs.patch @@ -0,0 +1,17 @@ +diff --git a/src/occt_wrapper/CMakeLists.txt b/src/occt_wrapper/CMakeLists.txt +index bde365264f..feea9ae66d 100644 +--- a/src/occt_wrapper/CMakeLists.txt ++++ b/src/occt_wrapper/CMakeLists.txt +@@ -27,11 +27,7 @@ elseif (OpenCASCADE_VERSION VERSION_GREATER_EQUAL 8.0.0) + endif () + + set(OCCT_LIBS +- TKXDESTEP +- TKSTEP +- TKSTEP209 +- TKSTEPAttr +- TKSTEPBase ++ TKDESTEP + TKXCAF + TKXSBase + TKVCAF diff --git a/0006-fix-non-const-lvalue.patch b/0006-fix-non-const-lvalue.patch new file mode 100644 index 0000000..0ccd25c --- /dev/null +++ b/0006-fix-non-const-lvalue.patch @@ -0,0 +1,19 @@ +diff --git a/src/libslic3r/MeshBoolean.cpp b/src/libslic3r/MeshBoolean.cpp +index 31fdc35de5..6e5e48e0f7 100644 +--- a/src/libslic3r/MeshBoolean.cpp ++++ b/src/libslic3r/MeshBoolean.cpp +@@ -147,12 +147,12 @@ template TriangleMesh cgal_to_triangle_mesh(const _Mesh &cgalmesh) + const auto &vertices = cgalmesh.vertices(); + int vsize = int(vertices.size()); + +- for (auto &vi : vertices) { ++ for (const auto &vi : vertices) { + auto &v = cgalmesh.point(vi); // Don't ask... + its.vertices.emplace_back(to_vec3f(v)); + } + +- for (auto &face : faces) { ++ for (const auto &face : faces) { + auto vtc = cgalmesh.vertices_around_face(cgalmesh.halfedge(face)); + + int i = 0; diff --git a/0007-boost1.84.patch b/0007-boost1.84.patch new file mode 100644 index 0000000..4ac2dfc --- /dev/null +++ b/0007-boost1.84.patch @@ -0,0 +1,34 @@ +diff --git a/src/slic3r/GUI/ScriptExecutor.cpp b/src/slic3r/GUI/ScriptExecutor.cpp +index 3e10680e46..3dcbf9643f 100644 +--- a/src/slic3r/GUI/ScriptExecutor.cpp ++++ b/src/slic3r/GUI/ScriptExecutor.cpp +@@ -827,6 +827,20 @@ void as_back_custom_initial_value(int preset_type, std::string& key) { + + /////// main script fucntions ////// + ++// stolen from https://www.boost.org/doc/libs/1_79_0/boost/filesystem/string_file.hpp ++static inline void load_string_file(boost::filesystem::path const& p, std::string& str) ++{ ++ boost::filesystem::ifstream file; ++ file.exceptions(std::ios_base::failbit | std::ios_base::badbit); ++ file.open(p, std::ios_base::binary); ++ const boost::uintmax_t sz = boost::filesystem::file_size(p); ++ if (BOOST_UNLIKELY(sz > static_cast< boost::uintmax_t >((std::numeric_limits< std::streamsize >::max)()))) ++ BOOST_FILESYSTEM_THROW(std::length_error("File size exceeds max read size")); ++ str.resize(static_cast< std::size_t >(sz), '\0'); ++ if (sz > 0u) ++ file.read(&str[0], static_cast< std::streamsize >(sz)); ++} ++ + //TODO: add "unset" function, that revert to last value (befoer a scripted set) if a set has been made since last not-scripted change. + void ScriptContainer::init(const std::string& tab_key, Tab* tab) + { +@@ -960,7 +974,7 @@ void ScriptContainer::init(const std::string& tab_key, Tab* tab) + //res = builder.AddSectionFromFile(ui_script_file.string().c_str()); //seems to be problematic on cyrillic locale + { + std::string all_file; +- boost::filesystem::load_string_file(ui_script_file, all_file); ++ load_string_file(ui_script_file, all_file); + res = builder.AddSectionFromMemory(ui_script_file.string().c_str(), all_file.c_str(), (unsigned int)(all_file.length()), 0); + } + if (res < 0) throw CompileErrorException("Error, can't build the script for tab " + tab_key); diff --git a/0008-boost1.85.patch b/0008-boost1.85.patch new file mode 100644 index 0000000..c57a224 --- /dev/null +++ b/0008-boost1.85.patch @@ -0,0 +1,12 @@ +diff --git a/src/slic3r/GUI/RemovableDriveManager.cpp b/src/slic3r/GUI/RemovableDriveManager.cpp +index 2f8ac96a1a..ed615c8d3e 100644 +--- a/src/slic3r/GUI/RemovableDriveManager.cpp ++++ b/src/slic3r/GUI/RemovableDriveManager.cpp +@@ -22,7 +22,6 @@ + #include + #include + #include +-#include + #include + #endif + diff --git a/0009-fix-multiple-choice.patch b/0009-fix-multiple-choice.patch new file mode 100644 index 0000000..91f9ad7 --- /dev/null +++ b/0009-fix-multiple-choice.patch @@ -0,0 +1,14 @@ +diff --git a/src/slic3r/GUI/PhysicalPrinterDialog.cpp b/src/slic3r/GUI/PhysicalPrinterDialog.cpp +index 7ca307ff9d..11fdea36b1 100644 +--- a/src/slic3r/GUI/PhysicalPrinterDialog.cpp ++++ b/src/slic3r/GUI/PhysicalPrinterDialog.cpp +@@ -564,7 +564,8 @@ void PhysicalPrinterDialog::build_printhost_settings(ConfigOptionsGroup* m_optgr + // Always fill in the "printhost_port" combo box from the config and select it. + { + Choice* choice = dynamic_cast(m_optgroup->get_field("printhost_port")); +- choice->set_values({ m_config->opt_string("printhost_port") }); ++ const std::vector choice_values = { m_config->opt_string("printhost_port") }; ++ choice->set_values(choice_values); + choice->set_selection(); + } + diff --git a/PKGBUILD b/PKGBUILD index b76151b..eddfbaa 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -1,28 +1,42 @@ +# SPDX-License-Identifier: APGL-3.0 +# Maintainer: Dominic git at msrd0 dot de # Maintainer: Lukas1818 aur at lukas1818 dot de pkgname=superslicer-prerelease -pkgver=2.4.58.2 +pkgver=2.5.60.0 _pkgtag=$pkgver -pkgrel=2 +pkgrel=1 epoch=1 pkgdesc="G-code generator for 3D printers (RepRap, Makerbot, Ultimaker etc.)" arch=("$CARCH") url="https://github.com/supermerill/SuperSlicer" license=('AGPL3') options=(!emptydirs) -depends=('boost-libs>=1.73.0' 'cgal' 'glew' 'imath' 'libspnav' 'nlopt' 'openvdb' 'qhull>=2020.2-4' 'wxgtk3') -makedepends=('boost>=1.73.0' 'cereal>=1.3.0' 'cmake' 'eigen' 'libigl' 'openvdb' 'samurai' 'wxgtk2') # cmake doesn't detect wx if not both gtk2 and gtk3 are installed +depends=('boost-libs>=1.73.0' 'cgal' 'glew' 'imath' 'libspnav' 'nlopt' 'openvdb' 'qhull>=2020.2-4' 'slicer-udev' 'wxwidgets-gtk3') +makedepends=('boost>=1.73.0' 'cereal>=1.3.0' 'cmake' 'eigen' 'libigl' 'openvdb' 'samurai') optdepends=('superslicer-profiles: Predefined printer profiles') provides=("superslicer=$epoch:$pkgver") conflicts=('superslicer' 'superslicer-git') source=("https://github.com/supermerill/SuperSlicer/archive/$_pkgtag.tar.gz" - "0001-wxgtk3-is-broken-on-wayland.patch" + "0001-boost1.79.patch" "0002-fix-cereal.patch" - "0003-openexr3.patch") -sha512sums=('c5038bd13482a2a164ce7f3b126b9f0183b4220b2d46d84e86a0ad29624eb9e000c5b8ad876506e4042a80c7c57b7f34bbf2bf5affc385334e00da416c22fd27' - 'acf35ebe467e9fb30f1b77d15348f1a7b82dcf45a5b829e375e972b5d6b49968603b3fa090c4d1f56e8b5148e2b820e79afa269da60ace70de1ceadcf6e820c5' - 'c3ba2d16140d445168681ff442bda12e87de22f8b94d59c32576bd7079ffe5864cce8e62cddd1ed47458f9eddcbd3e1a02645b0645aad6f2e0cb08a876bf783f' - '840e51b8feb3568ff46d309ece063f7188018fcaa43d19ec50ede408fdf2c237a3b7eaa11ba24409d8c3f7d6f5fb270181508cc56e0b2b0fef68b766130ef1eb') + "0003-openexr3.patch" + "0004-fix-opencascade-version-check.patch" + "0005-fix-opencascade-libs.patch" + "0006-fix-non-const-lvalue.patch" + "0007-boost1.84.patch" + "0008-boost1.85.patch" + "0009-fix-multiple-choice.patch") +sha512sums=('a53f4cc9b5a20f3f60d38553d47bfd19ce8bd739a8a16493bbcf64f75825fa760b8c107d7f927d49d967f7d067fac8c428c8f6e67219e74b0970d9ab7aa5b9e6' + 'fc18e8edf516f9479c3b0e201d1c74b42289f15ef8a64ff3a88c2bb14613978a9dcf7be50ff8b79faf054c7721a095a70715b0fb0747be48757f9502ba0eb859' + '58467732161eb0abe58cfb1e64e080f64f9f2221032b0d6176739fc81a61fe7838fa6479e9aac7fa0ee9805898f9293081c5e35a146df103830199b46354b97e' + '840e51b8feb3568ff46d309ece063f7188018fcaa43d19ec50ede408fdf2c237a3b7eaa11ba24409d8c3f7d6f5fb270181508cc56e0b2b0fef68b766130ef1eb' + '4efb6dd48c8184f47b838228cf624a74429f35d133fb85316ddcde9d78bd462d64009ec9fe0b3f34232ddf4971f81ea03385ed661c771de9f0fd5bffcbe2a74c' + 'a01abf748f82bc423f2c012ac430f78cfd5e56dede1d5999376e780267d0302d9a2a80c3eb15226c2f82102dda4c567c721ff99ab1fdeef504cbf9d9cb63ca53' + 'aca3a028eaab63baf83dd80d82615394435c97b9b45c99764ca84995d246096e3e5c2b564ed29e194652c8e221a80cf6abdc165cb3009fd20af586b0432b2bc9' + 'a92af974cb62901aab5a5c8c34672e9a7c90ea7246bbd7423421a9b7ee12a7b17073d90a6f36f994328c7dc9c2d0a6e4fd18c980a71863bc530d873ebaa80433' + 'ca9f407d87d8dd0181077bc2da5a8e2f8995eed88a4787b73ee6c62ef6d2380fd1394fe5412cdc34276d4182bce6f272173e9ccb653d1e28978e16f379114002' + '6d7ab93042a75f04e1c3c8f294d19dd39abaf22aa75caf996c6a0cf753f6472134a3d4fa443b73924800b2d3a710416a931745c168911c0df3709fb71ec00570') prepare() { @@ -35,9 +49,15 @@ prepare() sed -i 's,add_subdirectory(test),,g' src/CMakeLists.txt # apply patches - patch -Np1 -i "$srcdir/0001-wxgtk3-is-broken-on-wayland.patch" + patch -Np1 -i "$srcdir/0001-boost1.79.patch" patch -Np1 -i "$srcdir/0002-fix-cereal.patch" patch -Np1 -i "$srcdir/0003-openexr3.patch" + patch -Np0 -i "$srcdir/0004-fix-opencascade-version-check.patch" + patch -Np1 -i "$srcdir/0005-fix-opencascade-libs.patch" + patch -Np1 -i "$srcdir/0006-fix-non-const-lvalue.patch" + patch -Np1 -i "$srcdir/0007-boost1.84.patch" + patch -Np1 -i "$srcdir/0008-boost1.85.patch" + patch -Np1 -i "$srcdir/0009-fix-multiple-choice.patch" } build() @@ -55,7 +75,8 @@ build() -DSLIC3R_WX_STABLE=ON \ -DSLIC3R_GTK=3 \ -DSLIC3R_BUILD_TESTS=OFF \ - -DSLIC3R_ALPHA=ON + -DSLIC3R_ALPHA=ON \ + -Wno-dev samu } @@ -66,4 +87,5 @@ package() DESTDIR="$pkgdir" samu install test ! -h "$pkgdir/usr/share/SuperSlicer/resources" || rm "$pkgdir/usr/share/SuperSlicer/resources" + rm -r "$pkgdir/usr/lib/udev" # provided by slicer-udev } From 5355a535ef45e31d74d54090f8dd89c1266d203d Mon Sep 17 00:00:00 2001 From: Dominic Date: Fri, 22 Nov 2024 17:31:34 +0100 Subject: [PATCH 6/8] superslicer-prerelease 1:2.5.60.0-2 fix conflict with prusa-slicer package --- .SRCINFO | 4 +++- 0010-occtwrapper-install-dir.patch | 25 +++++++++++++++++++++++++ PKGBUILD | 9 ++++++--- 3 files changed, 34 insertions(+), 4 deletions(-) create mode 100644 0010-occtwrapper-install-dir.patch diff --git a/.SRCINFO b/.SRCINFO index 0a90765..c913c9c 100644 --- a/.SRCINFO +++ b/.SRCINFO @@ -1,7 +1,7 @@ pkgbase = superslicer-prerelease pkgdesc = G-code generator for 3D printers (RepRap, Makerbot, Ultimaker etc.) pkgver = 2.5.60.0 - pkgrel = 1 + pkgrel = 2 epoch = 1 url = https://github.com/supermerill/SuperSlicer arch = x86_64 @@ -38,6 +38,7 @@ pkgbase = superslicer-prerelease source = 0007-boost1.84.patch source = 0008-boost1.85.patch source = 0009-fix-multiple-choice.patch + source = 0010-occtwrapper-install-dir.patch sha512sums = a53f4cc9b5a20f3f60d38553d47bfd19ce8bd739a8a16493bbcf64f75825fa760b8c107d7f927d49d967f7d067fac8c428c8f6e67219e74b0970d9ab7aa5b9e6 sha512sums = fc18e8edf516f9479c3b0e201d1c74b42289f15ef8a64ff3a88c2bb14613978a9dcf7be50ff8b79faf054c7721a095a70715b0fb0747be48757f9502ba0eb859 sha512sums = 58467732161eb0abe58cfb1e64e080f64f9f2221032b0d6176739fc81a61fe7838fa6479e9aac7fa0ee9805898f9293081c5e35a146df103830199b46354b97e @@ -48,5 +49,6 @@ pkgbase = superslicer-prerelease sha512sums = a92af974cb62901aab5a5c8c34672e9a7c90ea7246bbd7423421a9b7ee12a7b17073d90a6f36f994328c7dc9c2d0a6e4fd18c980a71863bc530d873ebaa80433 sha512sums = ca9f407d87d8dd0181077bc2da5a8e2f8995eed88a4787b73ee6c62ef6d2380fd1394fe5412cdc34276d4182bce6f272173e9ccb653d1e28978e16f379114002 sha512sums = 6d7ab93042a75f04e1c3c8f294d19dd39abaf22aa75caf996c6a0cf753f6472134a3d4fa443b73924800b2d3a710416a931745c168911c0df3709fb71ec00570 + sha512sums = 92929ba1cb6ee104a10f34a649eba3789ca02f1725104a57412279ff68c46614b1812b13e7dcdf0d235618b9f2a868b4798b1404d9e712d9f1efd46e6c71fcb5 pkgname = superslicer-prerelease diff --git a/0010-occtwrapper-install-dir.patch b/0010-occtwrapper-install-dir.patch new file mode 100644 index 0000000..e3728bc --- /dev/null +++ b/0010-occtwrapper-install-dir.patch @@ -0,0 +1,25 @@ +diff --git a/src/libslic3r/Format/STEP.cpp b/src/libslic3r/Format/STEP.cpp +index 5165bb7015..9d76c23dca 100644 +--- a/src/libslic3r/Format/STEP.cpp ++++ b/src/libslic3r/Format/STEP.cpp +@@ -57,6 +57,9 @@ LoadStepFn get_load_step_fn() + #elif __APPLE__ + load_step_fn = &load_step_internal; + #else ++ libpath = libpath.parent_path(); ++ libpath /= "lib"; ++ libpath /= "superslicer"; + libpath /= "OCCTWrapper.so"; + void *plugin_ptr = dlopen(libpath.c_str(), RTLD_NOW | RTLD_GLOBAL); + +diff --git a/src/occt_wrapper/CMakeLists.txt b/src/occt_wrapper/CMakeLists.txt +index ed75531a96..6dc45bae9f 100644 +--- a/src/occt_wrapper/CMakeLists.txt ++++ b/src/occt_wrapper/CMakeLists.txt +@@ -56,5 +56,5 @@ target_link_libraries(OCCTWrapper ${OCCT_LIBS}) + + include(GNUInstallDirs) + +-install(TARGETS OCCTWrapper DESTINATION "${CMAKE_INSTALL_BINDIR}") ++install(TARGETS OCCTWrapper DESTINATION "${CMAKE_INSTALL_LIBDIR}/superslicer") + diff --git a/PKGBUILD b/PKGBUILD index eddfbaa..c22e8f5 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -5,7 +5,7 @@ pkgname=superslicer-prerelease pkgver=2.5.60.0 _pkgtag=$pkgver -pkgrel=1 +pkgrel=2 epoch=1 pkgdesc="G-code generator for 3D printers (RepRap, Makerbot, Ultimaker etc.)" arch=("$CARCH") @@ -26,7 +26,8 @@ source=("https://github.com/supermerill/SuperSlicer/archive/$_pkgtag.tar.gz" "0006-fix-non-const-lvalue.patch" "0007-boost1.84.patch" "0008-boost1.85.patch" - "0009-fix-multiple-choice.patch") + "0009-fix-multiple-choice.patch" + "0010-occtwrapper-install-dir.patch") sha512sums=('a53f4cc9b5a20f3f60d38553d47bfd19ce8bd739a8a16493bbcf64f75825fa760b8c107d7f927d49d967f7d067fac8c428c8f6e67219e74b0970d9ab7aa5b9e6' 'fc18e8edf516f9479c3b0e201d1c74b42289f15ef8a64ff3a88c2bb14613978a9dcf7be50ff8b79faf054c7721a095a70715b0fb0747be48757f9502ba0eb859' '58467732161eb0abe58cfb1e64e080f64f9f2221032b0d6176739fc81a61fe7838fa6479e9aac7fa0ee9805898f9293081c5e35a146df103830199b46354b97e' @@ -36,7 +37,8 @@ sha512sums=('a53f4cc9b5a20f3f60d38553d47bfd19ce8bd739a8a16493bbcf64f75825fa760b8 'aca3a028eaab63baf83dd80d82615394435c97b9b45c99764ca84995d246096e3e5c2b564ed29e194652c8e221a80cf6abdc165cb3009fd20af586b0432b2bc9' 'a92af974cb62901aab5a5c8c34672e9a7c90ea7246bbd7423421a9b7ee12a7b17073d90a6f36f994328c7dc9c2d0a6e4fd18c980a71863bc530d873ebaa80433' 'ca9f407d87d8dd0181077bc2da5a8e2f8995eed88a4787b73ee6c62ef6d2380fd1394fe5412cdc34276d4182bce6f272173e9ccb653d1e28978e16f379114002' - '6d7ab93042a75f04e1c3c8f294d19dd39abaf22aa75caf996c6a0cf753f6472134a3d4fa443b73924800b2d3a710416a931745c168911c0df3709fb71ec00570') + '6d7ab93042a75f04e1c3c8f294d19dd39abaf22aa75caf996c6a0cf753f6472134a3d4fa443b73924800b2d3a710416a931745c168911c0df3709fb71ec00570' + '92929ba1cb6ee104a10f34a649eba3789ca02f1725104a57412279ff68c46614b1812b13e7dcdf0d235618b9f2a868b4798b1404d9e712d9f1efd46e6c71fcb5') prepare() { @@ -58,6 +60,7 @@ prepare() patch -Np1 -i "$srcdir/0007-boost1.84.patch" patch -Np1 -i "$srcdir/0008-boost1.85.patch" patch -Np1 -i "$srcdir/0009-fix-multiple-choice.patch" + patch -Np1 -i "$srcdir/0010-occtwrapper-install-dir.patch" } build() From 0a122b64d3851e0dc8cfabf2352ff8c1538f6dc2 Mon Sep 17 00:00:00 2001 From: Dominic Date: Fri, 28 Mar 2025 23:35:09 +0100 Subject: [PATCH 7/8] superslicer-prerelease 2.7.61.0 --- .SRCINFO | 46 ++++-- 0001-boost1.79.patch | 81 --------- 0001-findwxwidgets.patch | 34 ++++ 0001-libbgcode-binarize-public-deps.patch | 13 ++ 0002-addlib-expat.patch | 13 ++ 0002-fix-cereal.patch | 71 -------- 0004-fix-opencascade-version-check.patch | 4 +- 0006-fix-non-const-lvalue.patch | 19 --- 0007-boost1.84.patch | 34 ---- 0011-fix-constructible-svgfile.patch | 17 ++ 0012-boost1.87.patch | 15 ++ 0013-fix-missing-template-args.patch | 13 ++ PKGBUILD | 142 +++++++++++----- prusaslicer-2.8.1-cgal-6.0.patch | 190 ++++++++++++++++++++++ 14 files changed, 429 insertions(+), 263 deletions(-) delete mode 100644 0001-boost1.79.patch create mode 100644 0001-findwxwidgets.patch create mode 100644 0001-libbgcode-binarize-public-deps.patch create mode 100644 0002-addlib-expat.patch delete mode 100644 0002-fix-cereal.patch delete mode 100644 0006-fix-non-const-lvalue.patch delete mode 100644 0007-boost1.84.patch create mode 100644 0011-fix-constructible-svgfile.patch create mode 100644 0012-boost1.87.patch create mode 100644 0013-fix-missing-template-args.patch create mode 100644 prusaslicer-2.8.1-cgal-6.0.patch diff --git a/.SRCINFO b/.SRCINFO index c913c9c..cde3c85 100644 --- a/.SRCINFO +++ b/.SRCINFO @@ -1,54 +1,66 @@ pkgbase = superslicer-prerelease pkgdesc = G-code generator for 3D printers (RepRap, Makerbot, Ultimaker etc.) - pkgver = 2.5.60.0 - pkgrel = 2 + pkgver = 2.7.61.0 + pkgrel = 1 epoch = 1 url = https://github.com/supermerill/SuperSlicer arch = x86_64 license = AGPL3 - makedepends = boost>=1.73.0 + makedepends = boost makedepends = cereal>=1.3.0 makedepends = cmake makedepends = eigen makedepends = libigl + makedepends = ninja makedepends = openvdb - makedepends = samurai - depends = boost-libs>=1.73.0 + depends = boost-libs depends = cgal depends = glew depends = imath + depends = heatshrink depends = libspnav + depends = nanosvg depends = nlopt depends = openvdb depends = qhull>=2020.2-4 depends = slicer-udev depends = wxwidgets-gtk3 optdepends = superslicer-profiles: Predefined printer profiles - provides = superslicer=1:2.5.60.0 + provides = superslicer=1:2.7.61.0 conflicts = superslicer conflicts = superslicer-git options = !emptydirs - source = https://github.com/supermerill/SuperSlicer/archive/2.5.60.0.tar.gz - source = 0001-boost1.79.patch - source = 0002-fix-cereal.patch + source = https://github.com/supermerill/SuperSlicer/archive/2.7.61.0.tar.gz + source = https://github.com/prusa3d/libbgcode/archive/6f43cb004ef3d3bda37dde49f6235e24d2717629.tar.gz + source = prusaslicer-2.8.1-boost-1.87.0-asio.patch::https://bugs.gentoo.org/attachment.cgi?id=914594 + source = prusaslicer-2.8.1-cgal-6.0.patch + source = 0001-libbgcode-binarize-public-deps.patch + source = 0001-findwxwidgets.patch + source = 0002-addlib-expat.patch source = 0003-openexr3.patch source = 0004-fix-opencascade-version-check.patch source = 0005-fix-opencascade-libs.patch - source = 0006-fix-non-const-lvalue.patch - source = 0007-boost1.84.patch source = 0008-boost1.85.patch source = 0009-fix-multiple-choice.patch source = 0010-occtwrapper-install-dir.patch - sha512sums = a53f4cc9b5a20f3f60d38553d47bfd19ce8bd739a8a16493bbcf64f75825fa760b8c107d7f927d49d967f7d067fac8c428c8f6e67219e74b0970d9ab7aa5b9e6 - sha512sums = fc18e8edf516f9479c3b0e201d1c74b42289f15ef8a64ff3a88c2bb14613978a9dcf7be50ff8b79faf054c7721a095a70715b0fb0747be48757f9502ba0eb859 - sha512sums = 58467732161eb0abe58cfb1e64e080f64f9f2221032b0d6176739fc81a61fe7838fa6479e9aac7fa0ee9805898f9293081c5e35a146df103830199b46354b97e + source = 0011-fix-constructible-svgfile.patch + source = 0012-boost1.87.patch + source = 0013-fix-missing-template-args.patch + sha512sums = 0d72bf61adcafe8eef2ed860449dc25ca295ba0732d956bff8c0ae50b381387b803fd88241ab855a9b38daf8f5eaa4c41d17241b8c15c66d63576874179aa1c0 + sha512sums = 04cb7cb69d887e1fa5ced5c0219b0ee6cab81f09d1bc1226ebd26563e2ce60b85fb6e5aef11a36dffd3e00779849906fc5c19ad2cdd22d45360226912b6af31b + sha512sums = 3466fbbb00a4b9295c4c6a8fc5a983b5c5a78c7f091cd4502137301e10d0087abb50d5994ceba717a435693d8e4b6f5e4b084bd950b82ec91a33b1981d13226b + sha512sums = 188a5efa0128f848c6b3d882c2e472b3fbdd9db8c130735083b3410095197bc69dea855f4622d1011c8540cdfbfc25dc4a14e81fd28f2510067293ae5de15fce + sha512sums = ecbe9bdec72a372dfdc25b32dee382a9937c544567fa2da42a30467ddff2594495bf244a773401f655930301a2debc94636a362383239fa08808d0e51bc687a4 + sha512sums = d910cf1fc07219b6c776240eae0f203813368e69b6a0215bcdcabba385531744093b6214b21d0dffbafa8992d3549c96bbdb02e939c52a4e81dbce98389397f9 + sha512sums = 93a943eb9be52085a811d7cc8379dc5a3942befdc3d19eecf6310f8dfcfdef72bfa15dfcb85ac1f4f9d7731c973b9815a532ae444e3fe275f8f624825fe8e98b sha512sums = 840e51b8feb3568ff46d309ece063f7188018fcaa43d19ec50ede408fdf2c237a3b7eaa11ba24409d8c3f7d6f5fb270181508cc56e0b2b0fef68b766130ef1eb - sha512sums = 4efb6dd48c8184f47b838228cf624a74429f35d133fb85316ddcde9d78bd462d64009ec9fe0b3f34232ddf4971f81ea03385ed661c771de9f0fd5bffcbe2a74c + sha512sums = 8512ace14c71b04eb98532e71592447475cf7feccf1c85f376487615c8a95f6afa645e4581f577ee26d91532c57f389eac7534a875d5a24e871f3ef593af33c9 sha512sums = a01abf748f82bc423f2c012ac430f78cfd5e56dede1d5999376e780267d0302d9a2a80c3eb15226c2f82102dda4c567c721ff99ab1fdeef504cbf9d9cb63ca53 - sha512sums = aca3a028eaab63baf83dd80d82615394435c97b9b45c99764ca84995d246096e3e5c2b564ed29e194652c8e221a80cf6abdc165cb3009fd20af586b0432b2bc9 - sha512sums = a92af974cb62901aab5a5c8c34672e9a7c90ea7246bbd7423421a9b7ee12a7b17073d90a6f36f994328c7dc9c2d0a6e4fd18c980a71863bc530d873ebaa80433 sha512sums = ca9f407d87d8dd0181077bc2da5a8e2f8995eed88a4787b73ee6c62ef6d2380fd1394fe5412cdc34276d4182bce6f272173e9ccb653d1e28978e16f379114002 sha512sums = 6d7ab93042a75f04e1c3c8f294d19dd39abaf22aa75caf996c6a0cf753f6472134a3d4fa443b73924800b2d3a710416a931745c168911c0df3709fb71ec00570 sha512sums = 92929ba1cb6ee104a10f34a649eba3789ca02f1725104a57412279ff68c46614b1812b13e7dcdf0d235618b9f2a868b4798b1404d9e712d9f1efd46e6c71fcb5 + sha512sums = 6b677b68ebc7eda67d2f378c4d1cb5aca0a92fcecb04f685ae04aa4975655c36a606887526c4ff34b7e0b0ae2627eaf759fdeda896dffa0e0925132be36881ca + sha512sums = 559b52ed83f4032b00e2daaf22e2f86c66ce016bd4f1368f216cffed38fd5436ae12ddea427655d39c969e7de35cdcec06a0be317e58cf3d8ba1388a29664164 + sha512sums = 2141359af03193ef8afe7e5cd38b03e8888dadabe58be8c9625e24572062167a10a3bf990728f16ab765cae776e834eaab88ff9c7e6a96f909a7c6ae807a1e82 pkgname = superslicer-prerelease diff --git a/0001-boost1.79.patch b/0001-boost1.79.patch deleted file mode 100644 index f3ad855..0000000 --- a/0001-boost1.79.patch +++ /dev/null @@ -1,81 +0,0 @@ -From 408e56f0390f20aaf793e0aa0c70c4d9544401d4 Mon Sep 17 00:00:00 2001 -From: Vojtech Bubnik -Date: Mon, 25 Apr 2022 08:33:48 +0200 -Subject: [PATCH] Fix of Boost 1.79 deprecated boost::filesystem::ofstream - #8238 Replacing boost::filesystem::fstream with boost::nowide::fstream - variants with the unfortunate cost of string path conversion on Windows from - 16 bits to UTF8 and back to 16 bits. - -Unfortunately we cannot use std::filesystem yet as it is missing -on older MACs and because the interface is crooked minefield on Windows -see https://github.com/microsoft/STL/issues/909 ---- - src/hints/HintsToPot.cpp | 2 +- - src/libslic3r/Preset.cpp | 2 +- - src/slic3r/GUI/HintNotification.cpp | 8 +++++--- - 3 files changed, 7 insertions(+), 5 deletions(-) - -diff --git a/src/hints/HintsToPot.cpp b/src/hints/HintsToPot.cpp -index 7c8029cdeb..4791f0612f 100644 ---- a/src/hints/HintsToPot.cpp -+++ b/src/hints/HintsToPot.cpp -@@ -9,7 +9,7 @@ - - bool write_to_pot(boost::filesystem::path path, const std::vector>& data) - { -- boost::filesystem::ofstream file(std::move(path), std::ios_base::app); -+ boost::nowide::ofstream file(path.string(), std::ios_base::app); - for (const auto& element : data) - { - //Example of .pot element -diff --git a/src/libslic3r/Preset.cpp b/src/libslic3r/Preset.cpp -index f3a1c15b3e..f171cb14dd 100644 ---- a/src/libslic3r/Preset.cpp -+++ b/src/libslic3r/Preset.cpp -@@ -84,7 +84,7 @@ ConfigFileType guess_config_file_type(const ptree &tree) - VendorProfile VendorProfile::from_ini(const boost::filesystem::path &path, bool load_all) - { - ptree tree; -- boost::filesystem::ifstream ifs(path); -+ boost::nowide::ifstream ifs(path.string()); - boost::property_tree::read_ini(ifs, tree); - return VendorProfile::from_ini(tree, path, load_all); - } -diff --git a/src/slic3r/GUI/HintNotification.cpp b/src/slic3r/GUI/HintNotification.cpp -index 93e0fb3259..820b74eedb 100644 ---- a/src/slic3r/GUI/HintNotification.cpp -+++ b/src/slic3r/GUI/HintNotification.cpp -@@ -14,12 +14,14 @@ - #include "libslic3r/Config.hpp" - #include "libslic3r/PrintConfig.hpp" - -+#include -+ - #include - #include - #include - #include - #include --#include -+ - #include - #include - #include -@@ -65,7 +67,7 @@ inline void push_style_color(ImGuiCol idx, const ImVec4& col, bool fading_out, f - - void write_used_binary(const std::vector& ids) - { -- boost::filesystem::ofstream file((boost::filesystem::path(data_dir()) / "cache" / "hints.cereal"), std::ios::binary); -+ boost::nowide::ofstream file((boost::filesystem::path(data_dir()) / "cache" / "hints.cereal").string(), std::ios::binary); - cereal::BinaryOutputArchive archive(file); - HintsCerealData cd { ids }; - try -@@ -84,7 +86,7 @@ void read_used_binary(std::vector& ids) - BOOST_LOG_TRIVIAL(warning) << "Failed to load to hints.cereal. File does not exists. " << path.string(); - return; - } -- boost::filesystem::ifstream file(path); -+ boost::nowide::ifstream file(path.string()); - cereal::BinaryInputArchive archive(file); - HintsCerealData cd; - try diff --git a/0001-findwxwidgets.patch b/0001-findwxwidgets.patch new file mode 100644 index 0000000..4b30dce --- /dev/null +++ b/0001-findwxwidgets.patch @@ -0,0 +1,34 @@ +diff --git a/cmake/modules/FindwxWidgets.cmake b/cmake/modules/FindwxWidgets.cmake +index e1f93a6a26..88c5f2487d 100644 +--- a/cmake/modules/FindwxWidgets.cmake ++++ b/cmake/modules/FindwxWidgets.cmake +@@ -183,12 +183,12 @@ This module defines the following :prop_tgt:`IMPORTED` targets: + # Helper macro to control the debugging output globally. There are + # two versions for controlling how verbose your output should be. + macro(DBG_MSG _MSG) +-# message(STATUS +-# "${CMAKE_CURRENT_LIST_FILE}(${CMAKE_CURRENT_LIST_LINE}): ${_MSG}") ++ message(STATUS ++ "${CMAKE_CURRENT_LIST_FILE}(${CMAKE_CURRENT_LIST_LINE}): ${_MSG}") + endmacro() + macro(DBG_MSG_V _MSG) +-# message(STATUS +-# "${CMAKE_CURRENT_LIST_FILE}(${CMAKE_CURRENT_LIST_LINE}): ${_MSG}") ++ message(STATUS ++ "${CMAKE_CURRENT_LIST_FILE}(${CMAKE_CURRENT_LIST_LINE}): ${_MSG}") + endmacro() + + # Clear return values in case the module is loaded more than once. +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index aee1aaf100..e6db66b00d 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -57,7 +57,7 @@ if (SLIC3R_GUI) + if (CMAKE_SYSTEM_NAME STREQUAL "Linux") + set (wxWidgets_CONFIG_OPTIONS "--toolkit=gtk${SLIC3R_GTK}") + endif () +- find_package(wxWidgets 3.2 MODULE REQUIRED COMPONENTS base core adv html gl stc scintilla) ++ find_package(wxWidgets 3.2 MODULE REQUIRED COMPONENTS base core adv html gl stc) + + include(${wxWidgets_USE_FILE}) + diff --git a/0001-libbgcode-binarize-public-deps.patch b/0001-libbgcode-binarize-public-deps.patch new file mode 100644 index 0000000..97e0195 --- /dev/null +++ b/0001-libbgcode-binarize-public-deps.patch @@ -0,0 +1,13 @@ +diff --git a/src/LibBGCode/binarize/CMakeLists.txt b/src/LibBGCode/binarize/CMakeLists.txt +index 71bf85c..af0f9b5 100644 +--- a/src/LibBGCode/binarize/CMakeLists.txt ++++ b/src/LibBGCode/binarize/CMakeLists.txt +@@ -36,7 +36,7 @@ target_include_directories(${_libname}_binarize + $ + ) + +-target_link_libraries(${_libname}_binarize PRIVATE heatshrink::heatshrink_dynalloc ZLIB::ZLIB) ++target_link_libraries(${_libname}_binarize PUBLIC heatshrink::heatshrink_dynalloc ZLIB::ZLIB) + target_link_libraries(${_libname}_binarize PUBLIC ${_libname}_core) + + set(Binarize_DOWNSTREAM_DEPS ${Binarize_DOWNSTREAM_DEPS} PARENT_SCOPE) diff --git a/0002-addlib-expat.patch b/0002-addlib-expat.patch new file mode 100644 index 0000000..a2501e8 --- /dev/null +++ b/0002-addlib-expat.patch @@ -0,0 +1,13 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 34fe44a2ef..c0792f5476 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -485,8 +485,6 @@ include_directories(BEFORE SYSTEM ${EIGEN3_INCLUDE_DIR}) + # no matter what. + find_package(EXPAT REQUIRED) + +-add_library(libexpat INTERFACE) +- + if (TARGET EXPAT::EXPAT ) + target_link_libraries(libexpat INTERFACE EXPAT::EXPAT) + elseif(TARGET expat::expat) diff --git a/0002-fix-cereal.patch b/0002-fix-cereal.patch deleted file mode 100644 index f3d52a0..0000000 --- a/0002-fix-cereal.patch +++ /dev/null @@ -1,71 +0,0 @@ -diff --git a/cmake/modules/Findcereal.cmake b/cmake/modules/Findcereal.cmake -deleted file mode 100644 -index b4829757e..000000000 ---- a/cmake/modules/Findcereal.cmake -+++ /dev/null -@@ -1,26 +0,0 @@ --set(_q "") --if(${CMAKE_FIND_PACKAGE_NAME}_FIND_QUIETLY) -- set(_q QUIET) -- set(_quietly TRUE) --endif() --find_package(${CMAKE_FIND_PACKAGE_NAME} ${${CMAKE_FIND_PACKAGE_NAME}_FIND_VERSION} CONFIG ${_q}) -- --if (NOT ${CMAKE_FIND_PACKAGE_NAME}_FOUND) -- # Fall-back solution to find the Cereal serialization library header file -- include(CheckIncludeFileCXX) -- add_library(cereal INTERFACE) -- target_include_directories(cereal INTERFACE include) -- -- if (_quietly) -- set(CMAKE_REQUIRED_QUIET ON) -- endif() -- CHECK_INCLUDE_FILE_CXX("cereal/cereal.hpp" HAVE_CEREAL_H) -- -- if (NOT HAVE_CEREAL_H) -- if (${CMAKE_FIND_PACKAGE_NAME}_FIND_REQUIRED) -- message(FATAL_ERROR "Cereal library not found. Please install the dependency.") -- elseif(NOT _quietly) -- message(WARNING "Cereal library not found.") -- endif() -- endif () --endif() -diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt -index 01ef37905..98dbafa01 100644 ---- a/src/CMakeLists.txt -+++ b/src/CMakeLists.txt -@@ -139,8 +139,8 @@ if (NOT WIN32) - set_target_properties(Slic3r PROPERTIES OUTPUT_NAME "${SLIC3R_APP_CMD}") - endif () - --target_link_libraries(Slic3r libslic3r cereal) -+target_link_libraries(Slic3r libslic3r) - - if (APPLE) - # add_compile_options(-stdlib=libc++) - # add_definitions(-DBOOST_THREAD_DONT_USE_CHRONO -DBOOST_NO_CXX11_RVALUE_REFERENCES -DBOOST_THREAD_USES_MOVE) -diff --git a/src/libslic3r/CMakeLists.txt b/src/libslic3r/CMakeLists.txt -index 7048fb60c..95c5ed9e2 100644 ---- a/src/libslic3r/CMakeLists.txt -+++ b/src/libslic3r/CMakeLists.txt -@@ -356,7 +356,6 @@ target_include_directories(libslic3r PUBLIC ${EXPAT_INCLUDE_DIRS}) - target_link_libraries(libslic3r - libnest2d - admesh -- cereal - libigl - miniz - boost_libs -diff --git a/src/slic3r/CMakeLists.txt b/src/slic3r/CMakeLists.txt -index fe3d15425..24be67592 100644 ---- a/src/slic3r/CMakeLists.txt -+++ b/src/slic3r/CMakeLists.txt -@@ -291,7 +291,7 @@ target_compile_definitions(libslic3r_gui PRIVATE $<$:SLIC3 - - encoding_check(libslic3r_gui) - --target_link_libraries(libslic3r_gui libslic3r avrdude cereal imgui GLEW::GLEW OpenGL::GL hidapi exif angelscript libcurl ${wxWidgets_LIBRARIES}) -+target_link_libraries(libslic3r_gui libslic3r avrdude imgui GLEW::GLEW OpenGL::GL hidapi exif angelscript libcurl ${wxWidgets_LIBRARIES}) - - if (MSVC) - target_link_libraries(libslic3r_gui Setupapi.lib) diff --git a/0004-fix-opencascade-version-check.patch b/0004-fix-opencascade-version-check.patch index 2fa784a..c41b050 100644 --- a/0004-fix-opencascade-version-check.patch +++ b/0004-fix-opencascade-version-check.patch @@ -1,7 +1,7 @@ https://github.com/supermerill/SuperSlicer/issues/3912#issuecomment-1675135988 ---- src/occt_wrapper/CMakeLists.txt.bak 2024-11-20 13:23:45.624527309 +0100 -+++ src/occt_wrapper/CMakeLists.txt 2024-11-20 13:23:56.347478724 +0100 +--- a/src/occt_wrapper/CMakeLists.txt 2024-11-20 13:23:45.624527309 +0100 ++++ b/src/occt_wrapper/CMakeLists.txt 2024-11-20 13:23:56.347478724 +0100 @@ -19,7 +19,12 @@ generate_export_header(OCCTWrapper) diff --git a/0006-fix-non-const-lvalue.patch b/0006-fix-non-const-lvalue.patch deleted file mode 100644 index 0ccd25c..0000000 --- a/0006-fix-non-const-lvalue.patch +++ /dev/null @@ -1,19 +0,0 @@ -diff --git a/src/libslic3r/MeshBoolean.cpp b/src/libslic3r/MeshBoolean.cpp -index 31fdc35de5..6e5e48e0f7 100644 ---- a/src/libslic3r/MeshBoolean.cpp -+++ b/src/libslic3r/MeshBoolean.cpp -@@ -147,12 +147,12 @@ template TriangleMesh cgal_to_triangle_mesh(const _Mesh &cgalmesh) - const auto &vertices = cgalmesh.vertices(); - int vsize = int(vertices.size()); - -- for (auto &vi : vertices) { -+ for (const auto &vi : vertices) { - auto &v = cgalmesh.point(vi); // Don't ask... - its.vertices.emplace_back(to_vec3f(v)); - } - -- for (auto &face : faces) { -+ for (const auto &face : faces) { - auto vtc = cgalmesh.vertices_around_face(cgalmesh.halfedge(face)); - - int i = 0; diff --git a/0007-boost1.84.patch b/0007-boost1.84.patch deleted file mode 100644 index 4ac2dfc..0000000 --- a/0007-boost1.84.patch +++ /dev/null @@ -1,34 +0,0 @@ -diff --git a/src/slic3r/GUI/ScriptExecutor.cpp b/src/slic3r/GUI/ScriptExecutor.cpp -index 3e10680e46..3dcbf9643f 100644 ---- a/src/slic3r/GUI/ScriptExecutor.cpp -+++ b/src/slic3r/GUI/ScriptExecutor.cpp -@@ -827,6 +827,20 @@ void as_back_custom_initial_value(int preset_type, std::string& key) { - - /////// main script fucntions ////// - -+// stolen from https://www.boost.org/doc/libs/1_79_0/boost/filesystem/string_file.hpp -+static inline void load_string_file(boost::filesystem::path const& p, std::string& str) -+{ -+ boost::filesystem::ifstream file; -+ file.exceptions(std::ios_base::failbit | std::ios_base::badbit); -+ file.open(p, std::ios_base::binary); -+ const boost::uintmax_t sz = boost::filesystem::file_size(p); -+ if (BOOST_UNLIKELY(sz > static_cast< boost::uintmax_t >((std::numeric_limits< std::streamsize >::max)()))) -+ BOOST_FILESYSTEM_THROW(std::length_error("File size exceeds max read size")); -+ str.resize(static_cast< std::size_t >(sz), '\0'); -+ if (sz > 0u) -+ file.read(&str[0], static_cast< std::streamsize >(sz)); -+} -+ - //TODO: add "unset" function, that revert to last value (befoer a scripted set) if a set has been made since last not-scripted change. - void ScriptContainer::init(const std::string& tab_key, Tab* tab) - { -@@ -960,7 +974,7 @@ void ScriptContainer::init(const std::string& tab_key, Tab* tab) - //res = builder.AddSectionFromFile(ui_script_file.string().c_str()); //seems to be problematic on cyrillic locale - { - std::string all_file; -- boost::filesystem::load_string_file(ui_script_file, all_file); -+ load_string_file(ui_script_file, all_file); - res = builder.AddSectionFromMemory(ui_script_file.string().c_str(), all_file.c_str(), (unsigned int)(all_file.length()), 0); - } - if (res < 0) throw CompileErrorException("Error, can't build the script for tab " + tab_key); diff --git a/0011-fix-constructible-svgfile.patch b/0011-fix-constructible-svgfile.patch new file mode 100644 index 0000000..bace11e --- /dev/null +++ b/0011-fix-constructible-svgfile.patch @@ -0,0 +1,17 @@ +diff --git a/src/libslic3r/EmbossShape.hpp b/src/libslic3r/EmbossShape.hpp +index 3e4a950037..22e5d3aee1 100644 +--- a/src/libslic3r/EmbossShape.hpp ++++ b/src/libslic3r/EmbossShape.hpp +@@ -101,6 +101,12 @@ struct EmbossShape + // Loaded string data from file + std::shared_ptr file_data = nullptr; + ++ SvgFile() {} ++ ++ SvgFile(const std::string &path) : path(path) {} ++ ++ SvgFile(const std::string &path, const std::string &path_in_3mf) : path(path), path_in_3mf(path_in_3mf) {} ++ + template void save(Archive &ar) const { + // Note: image is only cache it is not neccessary to store + diff --git a/0012-boost1.87.patch b/0012-boost1.87.patch new file mode 100644 index 0000000..6ddb085 --- /dev/null +++ b/0012-boost1.87.patch @@ -0,0 +1,15 @@ +This patch is an addition to https://bugs.gentoo.org/attachment.cgi?id=914594 + +diff --git a/src/slic3r/GUI/FreeCADDialog.cpp b/src/slic3r/GUI/FreeCADDialog.cpp +index 822bc4e2d9..dfbb037ed0 100644 +--- a/src/slic3r/GUI/FreeCADDialog.cpp ++++ b/src/slic3r/GUI/FreeCADDialog.cpp +@@ -64,7 +64,7 @@ namespace GUI { + class ExecVar { + public: + boost::process::opstream pyin; +- boost::asio::io_service ios; ++ boost::asio::io_context ios; + std::future data_out; + std::future data_err; + std::unique_ptr process; diff --git a/0013-fix-missing-template-args.patch b/0013-fix-missing-template-args.patch new file mode 100644 index 0000000..4e4e179 --- /dev/null +++ b/0013-fix-missing-template-args.patch @@ -0,0 +1,13 @@ +diff --git a/src/libslic3r/Arrange/Core/DataStoreTraits.hpp b/src/libslic3r/Arrange/Core/DataStoreTraits.hpp +index ba932d57a8..624569d3f4 100644 +--- a/src/libslic3r/Arrange/Core/DataStoreTraits.hpp ++++ b/src/libslic3r/Arrange/Core/DataStoreTraits.hpp +@@ -71,7 +71,7 @@ template using WritableDataStoreOnly = std::enable_if_t + void set_data(ArrItem &itm, const std::string &key, T &&data) + { +- WritableDataStoreTraits::template set(itm, key, std::forward(data)); ++ WritableDataStoreTraits::template set(itm, key, std::forward(data)); + } + + template constexpr bool IsReadWritableDataStore = IsDataStore && IsWritableDataStore; diff --git a/PKGBUILD b/PKGBUILD index c22e8f5..f8d0c23 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -3,74 +3,140 @@ # Maintainer: Lukas1818 aur at lukas1818 dot de pkgname=superslicer-prerelease -pkgver=2.5.60.0 +pkgver=2.7.61.0 _pkgtag=$pkgver -pkgrel=2 +# https://github.com/supermerill/SuperSlicer/blob/2.7.61.0/deps/%2BLibBGCode/LibBGCode.cmake +_libbgcode=6f43cb004ef3d3bda37dde49f6235e24d2717629 +pkgrel=1 epoch=1 pkgdesc="G-code generator for 3D printers (RepRap, Makerbot, Ultimaker etc.)" arch=("$CARCH") url="https://github.com/supermerill/SuperSlicer" license=('AGPL3') options=(!emptydirs) -depends=('boost-libs>=1.73.0' 'cgal' 'glew' 'imath' 'libspnav' 'nlopt' 'openvdb' 'qhull>=2020.2-4' 'slicer-udev' 'wxwidgets-gtk3') -makedepends=('boost>=1.73.0' 'cereal>=1.3.0' 'cmake' 'eigen' 'libigl' 'openvdb' 'samurai') +depends=( + 'boost-libs' + 'cgal' + 'glew' + 'imath' + 'heatshrink' + 'libspnav' + 'nanosvg' + 'nlopt' + 'openvdb' + 'qhull>=2020.2-4' + 'slicer-udev' + 'wxwidgets-gtk3' +) +makedepends=( + 'boost' + 'cereal>=1.3.0' + 'cmake' + 'eigen' + 'libigl' + 'ninja' + 'openvdb' +) optdepends=('superslicer-profiles: Predefined printer profiles') provides=("superslicer=$epoch:$pkgver") conflicts=('superslicer' 'superslicer-git') source=("https://github.com/supermerill/SuperSlicer/archive/$_pkgtag.tar.gz" - "0001-boost1.79.patch" - "0002-fix-cereal.patch" + "https://github.com/prusa3d/libbgcode/archive/$_libbgcode.tar.gz" + "prusaslicer-2.8.1-boost-1.87.0-asio.patch::https://bugs.gentoo.org/attachment.cgi?id=914594" + "prusaslicer-2.8.1-cgal-6.0.patch" + "0001-libbgcode-binarize-public-deps.patch" + "0001-findwxwidgets.patch" + "0002-addlib-expat.patch" "0003-openexr3.patch" "0004-fix-opencascade-version-check.patch" "0005-fix-opencascade-libs.patch" - "0006-fix-non-const-lvalue.patch" - "0007-boost1.84.patch" "0008-boost1.85.patch" "0009-fix-multiple-choice.patch" - "0010-occtwrapper-install-dir.patch") -sha512sums=('a53f4cc9b5a20f3f60d38553d47bfd19ce8bd739a8a16493bbcf64f75825fa760b8c107d7f927d49d967f7d067fac8c428c8f6e67219e74b0970d9ab7aa5b9e6' - 'fc18e8edf516f9479c3b0e201d1c74b42289f15ef8a64ff3a88c2bb14613978a9dcf7be50ff8b79faf054c7721a095a70715b0fb0747be48757f9502ba0eb859' - '58467732161eb0abe58cfb1e64e080f64f9f2221032b0d6176739fc81a61fe7838fa6479e9aac7fa0ee9805898f9293081c5e35a146df103830199b46354b97e' + "0010-occtwrapper-install-dir.patch" + "0011-fix-constructible-svgfile.patch" + "0012-boost1.87.patch" + "0013-fix-missing-template-args.patch") +sha512sums=('0d72bf61adcafe8eef2ed860449dc25ca295ba0732d956bff8c0ae50b381387b803fd88241ab855a9b38daf8f5eaa4c41d17241b8c15c66d63576874179aa1c0' + '04cb7cb69d887e1fa5ced5c0219b0ee6cab81f09d1bc1226ebd26563e2ce60b85fb6e5aef11a36dffd3e00779849906fc5c19ad2cdd22d45360226912b6af31b' + '3466fbbb00a4b9295c4c6a8fc5a983b5c5a78c7f091cd4502137301e10d0087abb50d5994ceba717a435693d8e4b6f5e4b084bd950b82ec91a33b1981d13226b' + '188a5efa0128f848c6b3d882c2e472b3fbdd9db8c130735083b3410095197bc69dea855f4622d1011c8540cdfbfc25dc4a14e81fd28f2510067293ae5de15fce' + 'ecbe9bdec72a372dfdc25b32dee382a9937c544567fa2da42a30467ddff2594495bf244a773401f655930301a2debc94636a362383239fa08808d0e51bc687a4' + 'd910cf1fc07219b6c776240eae0f203813368e69b6a0215bcdcabba385531744093b6214b21d0dffbafa8992d3549c96bbdb02e939c52a4e81dbce98389397f9' + '93a943eb9be52085a811d7cc8379dc5a3942befdc3d19eecf6310f8dfcfdef72bfa15dfcb85ac1f4f9d7731c973b9815a532ae444e3fe275f8f624825fe8e98b' '840e51b8feb3568ff46d309ece063f7188018fcaa43d19ec50ede408fdf2c237a3b7eaa11ba24409d8c3f7d6f5fb270181508cc56e0b2b0fef68b766130ef1eb' - '4efb6dd48c8184f47b838228cf624a74429f35d133fb85316ddcde9d78bd462d64009ec9fe0b3f34232ddf4971f81ea03385ed661c771de9f0fd5bffcbe2a74c' + '8512ace14c71b04eb98532e71592447475cf7feccf1c85f376487615c8a95f6afa645e4581f577ee26d91532c57f389eac7534a875d5a24e871f3ef593af33c9' 'a01abf748f82bc423f2c012ac430f78cfd5e56dede1d5999376e780267d0302d9a2a80c3eb15226c2f82102dda4c567c721ff99ab1fdeef504cbf9d9cb63ca53' - 'aca3a028eaab63baf83dd80d82615394435c97b9b45c99764ca84995d246096e3e5c2b564ed29e194652c8e221a80cf6abdc165cb3009fd20af586b0432b2bc9' - 'a92af974cb62901aab5a5c8c34672e9a7c90ea7246bbd7423421a9b7ee12a7b17073d90a6f36f994328c7dc9c2d0a6e4fd18c980a71863bc530d873ebaa80433' 'ca9f407d87d8dd0181077bc2da5a8e2f8995eed88a4787b73ee6c62ef6d2380fd1394fe5412cdc34276d4182bce6f272173e9ccb653d1e28978e16f379114002' '6d7ab93042a75f04e1c3c8f294d19dd39abaf22aa75caf996c6a0cf753f6472134a3d4fa443b73924800b2d3a710416a931745c168911c0df3709fb71ec00570' - '92929ba1cb6ee104a10f34a649eba3789ca02f1725104a57412279ff68c46614b1812b13e7dcdf0d235618b9f2a868b4798b1404d9e712d9f1efd46e6c71fcb5') + '92929ba1cb6ee104a10f34a649eba3789ca02f1725104a57412279ff68c46614b1812b13e7dcdf0d235618b9f2a868b4798b1404d9e712d9f1efd46e6c71fcb5' + '6b677b68ebc7eda67d2f378c4d1cb5aca0a92fcecb04f685ae04aa4975655c36a606887526c4ff34b7e0b0ae2627eaf759fdeda896dffa0e0925132be36881ca' + '559b52ed83f4032b00e2daaf22e2f86c66ce016bd4f1368f216cffed38fd5436ae12ddea427655d39c969e7de35cdcec06a0be317e58cf3d8ba1388a29664164' + '2141359af03193ef8afe7e5cd38b03e8888dadabe58be8c9625e24572062167a10a3bf990728f16ab765cae776e834eaab88ff9c7e6a96f909a7c6ae807a1e82') + +_apply_patches() { + for patch in "${@}" + do + msg2 "Applying patch $patch" + patch -Np1 -i "$patch" + done +} + +prepare() { + cd "$srcdir/libbgcode-$_libbgcode" + rm -rf build + mkdir -p build + + _apply_patches \ + "$srcdir/0001-libbgcode-binarize-public-deps.patch" -prepare() -{ cd "$srcdir/SuperSlicer-$_pkgtag" - [ ! -f build/Makefile ] || rm -rf build - rm -rf build # build does fail everytime if it is not clean build ? + rm -rf build # build fails everytime if it isn't a clean build?!? mkdir -p build # disabling tests is not enough, we need to remove them explicitly sed -i 's,add_subdirectory(test),,g' src/CMakeLists.txt - # apply patches - patch -Np1 -i "$srcdir/0001-boost1.79.patch" - patch -Np1 -i "$srcdir/0002-fix-cereal.patch" - patch -Np1 -i "$srcdir/0003-openexr3.patch" - patch -Np0 -i "$srcdir/0004-fix-opencascade-version-check.patch" - patch -Np1 -i "$srcdir/0005-fix-opencascade-libs.patch" - patch -Np1 -i "$srcdir/0006-fix-non-const-lvalue.patch" - patch -Np1 -i "$srcdir/0007-boost1.84.patch" - patch -Np1 -i "$srcdir/0008-boost1.85.patch" - patch -Np1 -i "$srcdir/0009-fix-multiple-choice.patch" - patch -Np1 -i "$srcdir/0010-occtwrapper-install-dir.patch" + # apply patches for superslicer + _apply_patches \ + "$srcdir/prusaslicer-2.8.1-boost-1.87.0-asio.patch" \ + "$srcdir/prusaslicer-2.8.1-cgal-6.0.patch" \ + "$srcdir/0001-findwxwidgets.patch" \ + "$srcdir/0002-addlib-expat.patch" \ + "$srcdir/0003-openexr3.patch" \ + "$srcdir/0004-fix-opencascade-version-check.patch" \ + "$srcdir/0005-fix-opencascade-libs.patch" \ + "$srcdir/0008-boost1.85.patch" \ + "$srcdir/0009-fix-multiple-choice.patch" \ + "$srcdir/0010-occtwrapper-install-dir.patch" \ + "$srcdir/0011-fix-constructible-svgfile.patch" \ + "$srcdir/0012-boost1.87.patch" \ + "$srcdir/0013-fix-missing-template-args.patch" } -build() -{ - cd "$srcdir/SuperSlicer-$_pkgtag" +build() { + msg2 "Building libbgcode" + cd "$srcdir/libbgcode-$_libbgcode" cd build cmake .. \ -G Ninja \ - -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_BUILD_TYPE=None \ + -DCMAKE_INSTALL_PREFIX= \ + -DLibBGCode_BUILD_CMD_TOOL=OFF \ + -DLibBGCode_BUILD_TESTS=OFF \ + -Wno-dev + ninja + mkdir destdir + DESTDIR=destdir ninja install + export "CMAKE_PREFIX_PATH=$PWD/destdir:$CMAKE_PREFIX_PATH" + + msg2 "Building SuperSlicer" + cd "$srcdir/SuperSlicer-$_pkgtag" + cd build + + cmake .. -DCMAKE_MESSAGE_LOG_LEVEL=DEBUG \ + -G Ninja \ + -DCMAKE_BUILD_TYPE=None \ -DCMAKE_INSTALL_PREFIX=/usr \ -DOpenGL_GL_PREFERENCE=GLVND \ -DSLIC3R_FHS=ON \ @@ -80,12 +146,10 @@ build() -DSLIC3R_BUILD_TESTS=OFF \ -DSLIC3R_ALPHA=ON \ -Wno-dev - - samu + ninja } -package() -{ +package() { cd "$srcdir/SuperSlicer-$_pkgtag/build" DESTDIR="$pkgdir" samu install diff --git a/prusaslicer-2.8.1-cgal-6.0.patch b/prusaslicer-2.8.1-cgal-6.0.patch new file mode 100644 index 0000000..87de410 --- /dev/null +++ b/prusaslicer-2.8.1-cgal-6.0.patch @@ -0,0 +1,190 @@ +From a9283c62cec2b802aa2133c92b7ff5bf320c0bb6 Mon Sep 17 00:00:00 2001 +From: Laurent Rineau +Date: Sat, 13 Jul 2024 01:19:21 +0200 +Subject: [PATCH] compatibility with CGAL-6.0 (and 5.6.x) + +updated for 2.8.1 +updated for SuperSlicer + +--- a/src/libslic3r/CutSurface.cpp ++++ b/src/libslic3r/CutSurface.cpp +@@ -4,6 +4,14 @@ + ///|/ + #include "CutSurface.hpp" + ++template ++auto access_pmap(std::optional opt) -> T { ++ return opt.value(); ++} ++ ++template ++auto access_pmap(Pair pair) { return pair.first; } ++ + /// models_input.obj - Check transormation of model to each others + /// projection_center.obj - circle representing center of projection with correct distance + /// {M} .. model index +@@ -31,4 +39,5 @@ using namespace Slic3r; + #include + #include + #include ++#include + #include +@@ -1021,8 +1030,8 @@ priv::CutMesh priv::to_cgal(const ExPolygons &shapes, + if (shapes.empty()) return {}; + + CutMesh result; +- EdgeShapeMap edge_shape_map = result.add_property_map(edge_shape_map_name).first; +- FaceShapeMap face_shape_map = result.add_property_map(face_shape_map_name).first; ++ EdgeShapeMap edge_shape_map = access_pmap((result.add_property_map(edge_shape_map_name))); ++ FaceShapeMap face_shape_map = access_pmap((result.add_property_map(face_shape_map_name))); + + std::vector indices; + auto insert_contour = [&projection, &indices, &result, +@@ -1432,17 +1441,17 @@ priv::CutAOIs priv::cut_from_model(CutMesh &cgal_model, + const ExPolygonsIndices &s2i) + { + // pointer to edge or face shape_map +- VertexShapeMap vert_shape_map = cgal_model.add_property_map(vert_shape_map_name, nullptr).first; ++ VertexShapeMap vert_shape_map = access_pmap((cgal_model.add_property_map(vert_shape_map_name, nullptr))); + + // detect anomalities in visitor. + bool is_valid = true; + // NOTE: map are created when convert shapes to cgal model +- const EdgeShapeMap& edge_shape_map = cgal_shape.property_map(edge_shape_map_name).first; +- const FaceShapeMap& face_shape_map = cgal_shape.property_map(face_shape_map_name).first; ++ const EdgeShapeMap& edge_shape_map = access_pmap((cgal_shape.property_map(edge_shape_map_name))); ++ const FaceShapeMap& face_shape_map = access_pmap((cgal_shape.property_map(face_shape_map_name))); + Visitor visitor{cgal_model, cgal_shape, edge_shape_map, face_shape_map, vert_shape_map, &is_valid}; + + // a property map containing the constrained-or-not status of each edge +- EdgeBoolMap ecm = cgal_model.add_property_map(is_constrained_edge_name, false).first; ++ EdgeBoolMap ecm = access_pmap((cgal_model.add_property_map(is_constrained_edge_name, false))); + const auto &p = CGAL::parameters::visitor(visitor) + .edge_is_constrained_map(ecm) + .throw_on_self_intersection(false); +@@ -1451,7 +1460,7 @@ priv::CutAOIs priv::cut_from_model(CutMesh &cgal_model, + + if (!is_valid) return {}; + +- FaceTypeMap face_type_map = cgal_model.add_property_map(face_type_map_name, FaceType::not_constrained).first; ++ FaceTypeMap face_type_map = access_pmap((cgal_model.add_property_map(face_type_map_name, FaceType::not_constrained))); + + // Select inside and outside face in model + set_face_type(face_type_map, cgal_model, vert_shape_map, ecm, cgal_shape, s2i); +@@ -1587,8 +1596,8 @@ void priv::collect_surface_data(std::queue &process, + + void priv::create_reduce_map(ReductionMap &reduction_map, const CutMesh &mesh) + { +- const VertexShapeMap &vert_shape_map = mesh.property_map(vert_shape_map_name).first; +- const EdgeBoolMap &ecm = mesh.property_map(is_constrained_edge_name).first; ++ const VertexShapeMap &vert_shape_map = access_pmap((mesh.property_map(vert_shape_map_name))); ++ const EdgeBoolMap &ecm = access_pmap((mesh.property_map(is_constrained_edge_name))); + + // check if vertex was made by edge_2 which is diagonal of quad + auto is_reducible_vertex = [&vert_shape_map](VI reduction_from) -> bool { +@@ -1773,10 +1782,10 @@ priv::VDistances priv::calc_distances(const SurfacePatches &patches, + for (const SurfacePatch &patch : patches) { + // map is created during intersection by corefine visitor + const VertexShapeMap &vert_shape_map = +- models[patch.model_id].property_map(vert_shape_map_name).first; ++ access_pmap((models[patch.model_id].property_map(vert_shape_map_name))); + uint32_t patch_index = &patch - &patches.front(); + // map is created during patch creation / dividing +- const CvtVI2VI& cvt = patch.mesh.property_map(patch_source_name).first; ++ const CvtVI2VI& cvt = access_pmap((patch.mesh.property_map(patch_source_name))); + // for each point on outline + for (const Loop &loop : patch.loops) + for (const VI &vi_patch : loop) { +@@ -2666,7 +2675,7 @@ priv::SurfacePatch priv::create_surface_patch(const std::vector &fis, + /* const */ CutMesh &mesh, + const ReductionMap *rmap) + { +- auto is_counted = mesh.add_property_map("v:is_counted").first; ++ auto is_counted = access_pmap((mesh.add_property_map("v:is_counted"))); + uint32_t count_vertices = 0; + if (rmap == nullptr) { + for (FI fi : fis) +@@ -2696,7 +2705,7 @@ priv::SurfacePatch priv::create_surface_patch(const std::vector &fis, + cm.reserve(count_vertices, count_edges, count_faces); + + // vertex conversion function from mesh VI to result VI +- CvtVI2VI mesh2result = mesh.add_property_map("v:mesh2result").first; ++ CvtVI2VI mesh2result = access_pmap((mesh.add_property_map("v:mesh2result"))); + + if (rmap == nullptr) { + for (FI fi : fis) { +@@ -2748,7 +2757,7 @@ priv::SurfacePatch priv::create_surface_patch(const std::vector &fis, + assert(count_edges >= cm.edges().size()); + + // convert VI from this patch to source VI, when exist +- CvtVI2VI cvt = cm.add_property_map(patch_source_name).first; ++ CvtVI2VI cvt = access_pmap((cm.add_property_map(patch_source_name))); + // vi_s .. VertexIndex into mesh (source) + // vi_d .. new VertexIndex in cm (destination) + for (VI vi_s : mesh.vertices()) { +@@ -2939,7 +2948,7 @@ bool priv::is_patch_inside_of_model(const SurfacePatch &patch, + uint32_t priv::get_shape_point_index(const CutAOI &cut, const CutMesh &model) + { + // map is created during intersection by corefine visitor +- const VertexShapeMap &vert_shape_map = model.property_map(vert_shape_map_name).first; ++ const VertexShapeMap &vert_shape_map = access_pmap((model.property_map(vert_shape_map_name))); + // for each half edge of outline + for (HI hi : cut.second) { + VI vi = model.source(hi); +@@ -2964,7 +2973,7 @@ priv::SurfacePatch priv::separate_patch(const std::vector& fis, + patch_new.model_id = patch.model_id; + patch_new.shape_id = patch.shape_id; + // fix cvt +- CvtVI2VI cvt = patch_new.mesh.property_map(patch_source_name).first; ++ CvtVI2VI cvt = access_pmap((patch_new.mesh.property_map(patch_source_name))); + for (VI &vi : cvt) { + if (!vi.is_valid()) continue; + vi = cvt_from[vi]; +@@ -2982,9 +2991,9 @@ void priv::divide_patch(size_t i, SurfacePatchesEx &patches) + CutMesh& cm = patch.mesh; + assert(!cm.faces().empty()); + std::string patch_number_name = "f:patch_number"; +- CutMesh::Property_map is_processed = cm.add_property_map(patch_number_name, false).first; ++ CutMesh::Property_map is_processed = access_pmap((cm.add_property_map(patch_number_name, false))); + +- const CvtVI2VI& cvt_from = patch.mesh.property_map(patch_source_name).first; ++ const CvtVI2VI& cvt_from = access_pmap((patch.mesh.property_map(patch_source_name))); + + std::vector fis; + fis.reserve(cm.faces().size()); +@@ -3085,7 +3094,7 @@ priv::SurfacePatches priv::diff_models(VCutAOIs &cuts, + CutAOIs &model_cuts = cuts[model_index]; + CutMesh &cut_model_ = cut_models[model_index]; + const CutMesh &cut_model = cut_model_; +- ReductionMap vertex_reduction_map = cut_model_.add_property_map(vertex_reduction_map_name).first; ++ ReductionMap vertex_reduction_map = access_pmap((cut_model_.add_property_map(vertex_reduction_map_name))); + create_reduce_map(vertex_reduction_map, cut_model); + + for (size_t cut_index = 0; cut_index < model_cuts.size(); ++cut_index, ++index) { +@@ -3171,7 +3180,7 @@ bool priv::is_over_whole_expoly(const CutAOI &cutAOI, + const CutMesh &mesh) + { + // NonInterupted contour is without other point and contain all from shape +- const VertexShapeMap &vert_shape_map = mesh.property_map(vert_shape_map_name).first; ++ const VertexShapeMap &vert_shape_map = access_pmap((mesh.property_map(vert_shape_map_name))); + for (HI hi : cutAOI.second) { + const IntersectingElement *ie_s = vert_shape_map[mesh.source(hi)]; + const IntersectingElement *ie_t = vert_shape_map[mesh.target(hi)]; +@@ -3708,7 +3717,7 @@ void priv::store(const CutMesh &mesh, const FaceTypeMap &face_type_map, const st + } + + CutMesh &mesh_ = const_cast(mesh); +- auto face_colors = mesh_.add_property_map("f:color").first; ++ auto face_colors = access_pmap((mesh_.add_property_map("f:color"))); + for (FI fi : mesh.faces()) { + auto &color = face_colors[fi]; + switch (face_type_map[fi]) { +@@ -3734,7 +3743,7 @@ void priv::store(const CutMesh &mesh, const ReductionMap &reduction_map, const s + std::string off_file = dir + "model" + std::to_string(reduction_order++) + ".off"; + + CutMesh &mesh_ = const_cast(mesh); +- auto vertex_colors = mesh_.add_property_map("v:color").first; ++ auto vertex_colors = access_pmap((mesh_.add_property_map("v:color"))); + // initialize to gray color + for (VI vi: mesh.vertices()) + vertex_colors[vi] = CGAL::Color{127, 127, 127}; From 0089d960777cef92809f34e09c546a6d4802cb9e Mon Sep 17 00:00:00 2001 From: Dominic Date: Mon, 31 Mar 2025 11:09:18 +0200 Subject: [PATCH 8/8] superslicer-prerelease 2.7.61.0-2 --- .SRCINFO | 5 +- 0006-cmake3.5.patch | 148 ++++++++++++++++++++++++++++++++++++++++++++ PKGBUILD | 8 ++- 3 files changed, 158 insertions(+), 3 deletions(-) create mode 100644 0006-cmake3.5.patch diff --git a/.SRCINFO b/.SRCINFO index cde3c85..596c8ab 100644 --- a/.SRCINFO +++ b/.SRCINFO @@ -1,7 +1,7 @@ pkgbase = superslicer-prerelease pkgdesc = G-code generator for 3D printers (RepRap, Makerbot, Ultimaker etc.) pkgver = 2.7.61.0 - pkgrel = 1 + pkgrel = 2 epoch = 1 url = https://github.com/supermerill/SuperSlicer arch = x86_64 @@ -21,6 +21,7 @@ pkgbase = superslicer-prerelease depends = libspnav depends = nanosvg depends = nlopt + depends = opencascade depends = openvdb depends = qhull>=2020.2-4 depends = slicer-udev @@ -40,6 +41,7 @@ pkgbase = superslicer-prerelease source = 0003-openexr3.patch source = 0004-fix-opencascade-version-check.patch source = 0005-fix-opencascade-libs.patch + source = 0006-cmake3.5.patch source = 0008-boost1.85.patch source = 0009-fix-multiple-choice.patch source = 0010-occtwrapper-install-dir.patch @@ -56,6 +58,7 @@ pkgbase = superslicer-prerelease sha512sums = 840e51b8feb3568ff46d309ece063f7188018fcaa43d19ec50ede408fdf2c237a3b7eaa11ba24409d8c3f7d6f5fb270181508cc56e0b2b0fef68b766130ef1eb sha512sums = 8512ace14c71b04eb98532e71592447475cf7feccf1c85f376487615c8a95f6afa645e4581f577ee26d91532c57f389eac7534a875d5a24e871f3ef593af33c9 sha512sums = a01abf748f82bc423f2c012ac430f78cfd5e56dede1d5999376e780267d0302d9a2a80c3eb15226c2f82102dda4c567c721ff99ab1fdeef504cbf9d9cb63ca53 + sha512sums = 7ff2c1b39d18bd0e2cdf56582281f04509ae92e9c8837c67b99afcebffe293688fc9d93c4a790b231413bf8bafda803db9fc90b312db03c989122e4319bab66b sha512sums = ca9f407d87d8dd0181077bc2da5a8e2f8995eed88a4787b73ee6c62ef6d2380fd1394fe5412cdc34276d4182bce6f272173e9ccb653d1e28978e16f379114002 sha512sums = 6d7ab93042a75f04e1c3c8f294d19dd39abaf22aa75caf996c6a0cf753f6472134a3d4fa443b73924800b2d3a710416a931745c168911c0df3709fb71ec00570 sha512sums = 92929ba1cb6ee104a10f34a649eba3789ca02f1725104a57412279ff68c46614b1812b13e7dcdf0d235618b9f2a868b4798b1404d9e712d9f1efd46e6c71fcb5 diff --git a/0006-cmake3.5.patch b/0006-cmake3.5.patch new file mode 100644 index 0000000..401e379 --- /dev/null +++ b/0006-cmake3.5.patch @@ -0,0 +1,148 @@ +diff --git a/cmake/modules/FindOpenVDB.cmake b/cmake/modules/FindOpenVDB.cmake +index 4fde5fa4a7..5379a1a9e3 100644 +--- a/cmake/modules/FindOpenVDB.cmake ++++ b/cmake/modules/FindOpenVDB.cmake +@@ -123,7 +123,7 @@ if (OPENVDB_FIND_MODULE_PATH) + endif () + # ########################################################################### + +-cmake_minimum_required(VERSION 3.3) ++cmake_minimum_required(VERSION 3.5) + # Monitoring _ROOT variables + if(POLICY CMP0074) + cmake_policy(SET CMP0074 NEW) +diff --git a/sandboxes/opencsg/CMakeLists.txt b/sandboxes/opencsg/CMakeLists.txt +index ace8f4d539..fd1e5601e2 100644 +--- a/sandboxes/opencsg/CMakeLists.txt ++++ b/sandboxes/opencsg/CMakeLists.txt +@@ -1,4 +1,4 @@ +-cmake_minimum_required(VERSION 3.0) ++cmake_minimum_required(VERSION 3.5) + + project(OpenCSG-example) + +diff --git a/src/admesh/CMakeLists.txt b/src/admesh/CMakeLists.txt +index 217976318a..645495d9bb 100644 +--- a/src/admesh/CMakeLists.txt ++++ b/src/admesh/CMakeLists.txt +@@ -1,4 +1,4 @@ +-cmake_minimum_required(VERSION 2.8.12) ++cmake_minimum_required(VERSION 3.5) + project(admesh) + + add_library(admesh STATIC +diff --git a/src/avrdude/CMakeLists.txt b/src/avrdude/CMakeLists.txt +index 091afc6f98..64ce87f56f 100644 +--- a/src/avrdude/CMakeLists.txt ++++ b/src/avrdude/CMakeLists.txt +@@ -1,4 +1,4 @@ +-cmake_minimum_required(VERSION 3.0) ++cmake_minimum_required(VERSION 3.5) + + add_definitions(-D_BSD_SOURCE -D_DEFAULT_SOURCE) # To enable various useful macros and functions on Unices + remove_definitions(-D_UNICODE -DUNICODE) +diff --git a/src/boost/CMakeLists.txt b/src/boost/CMakeLists.txt +index e8c9e11ce6..c8950e1501 100644 +--- a/src/boost/CMakeLists.txt ++++ b/src/boost/CMakeLists.txt +@@ -1,4 +1,4 @@ +-cmake_minimum_required(VERSION 2.8.12) ++cmake_minimum_required(VERSION 3.5) + project(nowide) + + add_library(nowide STATIC +diff --git a/src/clipper/CMakeLists.txt b/src/clipper/CMakeLists.txt +index 1c1cfd5a7c..e57218413a 100644 +--- a/src/clipper/CMakeLists.txt ++++ b/src/clipper/CMakeLists.txt +@@ -1,4 +1,4 @@ +-cmake_minimum_required(VERSION 2.8.12) ++cmake_minimum_required(VERSION 3.5) + project(clipper) + + add_library(clipper STATIC +diff --git a/src/exif/CMakeLists.txt b/src/exif/CMakeLists.txt +index bdab4df6c4..48a5ecf883 100644 +--- a/src/exif/CMakeLists.txt ++++ b/src/exif/CMakeLists.txt +@@ -1,5 +1,4 @@ +- +-cmake_minimum_required(VERSION 2.5) ++cmake_minimum_required(VERSION 3.5) + + include_directories(include) + +diff --git a/src/glu-libtess/CMakeLists.txt b/src/glu-libtess/CMakeLists.txt +index 8fca992a3e..bfa43d3693 100644 +--- a/src/glu-libtess/CMakeLists.txt ++++ b/src/glu-libtess/CMakeLists.txt +@@ -1,4 +1,4 @@ +-cmake_minimum_required(VERSION 2.8.12) ++cmake_minimum_required(VERSION 3.5) + project(glu-libtess) + + add_library(glu-libtess STATIC +diff --git a/src/imgui/CMakeLists.txt b/src/imgui/CMakeLists.txt +index 5239eb3d5c..d71bf3716e 100644 +--- a/src/imgui/CMakeLists.txt ++++ b/src/imgui/CMakeLists.txt +@@ -1,4 +1,4 @@ +-cmake_minimum_required(VERSION 2.8.12) ++cmake_minimum_required(VERSION 3.5) + project(imgui) + + add_library(imgui STATIC +diff --git a/src/jpeg-compressor/CMakeLists.txt b/src/jpeg-compressor/CMakeLists.txt +index 7d404dc995..9f717165f2 100644 +--- a/src/jpeg-compressor/CMakeLists.txt ++++ b/src/jpeg-compressor/CMakeLists.txt +@@ -1,6 +1,6 @@ + # PrusaSlicer specific CMake + +-cmake_minimum_required(VERSION 2.8.12) ++cmake_minimum_required(VERSION 3.5) + project(jpeg-compressor) + + add_library(jpeg-compressor STATIC +diff --git a/src/libigl/CMakeLists.txt b/src/libigl/CMakeLists.txt +index f023826a52..f180ea4168 100644 +--- a/src/libigl/CMakeLists.txt ++++ b/src/libigl/CMakeLists.txt +@@ -1,4 +1,4 @@ +-cmake_minimum_required(VERSION 3.0) ++cmake_minimum_required(VERSION 3.5) + project(libigl) + + add_library(libigl INTERFACE) +diff --git a/src/miniz/CMakeLists.txt b/src/miniz/CMakeLists.txt +index 04d562b764..3beefa3921 100644 +--- a/src/miniz/CMakeLists.txt ++++ b/src/miniz/CMakeLists.txt +@@ -1,4 +1,4 @@ +-cmake_minimum_required(VERSION 2.8.12) ++cmake_minimum_required(VERSION 3.5) + project(miniz) + + add_library(miniz INTERFACE) +diff --git a/src/qoi/CMakeLists.txt b/src/qoi/CMakeLists.txt +index af8bf2e051..acd97ee230 100644 +--- a/src/qoi/CMakeLists.txt ++++ b/src/qoi/CMakeLists.txt +@@ -1,6 +1,6 @@ + # PrusaSlicer specific CMake + +-cmake_minimum_required(VERSION 2.8.12) ++cmake_minimum_required(VERSION 3.5) + project(qoi) + + add_library(qoi STATIC +diff --git a/src/semver/CMakeLists.txt b/src/semver/CMakeLists.txt +index 4b61a7456e..59f12a4ca5 100644 +--- a/src/semver/CMakeLists.txt ++++ b/src/semver/CMakeLists.txt +@@ -1,4 +1,4 @@ +-cmake_minimum_required(VERSION 2.8.12) ++cmake_minimum_required(VERSION 3.5) + project(semver) + + add_library(semver STATIC diff --git a/PKGBUILD b/PKGBUILD index f8d0c23..5e4b9bc 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -7,7 +7,7 @@ pkgver=2.7.61.0 _pkgtag=$pkgver # https://github.com/supermerill/SuperSlicer/blob/2.7.61.0/deps/%2BLibBGCode/LibBGCode.cmake _libbgcode=6f43cb004ef3d3bda37dde49f6235e24d2717629 -pkgrel=1 +pkgrel=2 epoch=1 pkgdesc="G-code generator for 3D printers (RepRap, Makerbot, Ultimaker etc.)" arch=("$CARCH") @@ -23,6 +23,7 @@ depends=( 'libspnav' 'nanosvg' 'nlopt' + 'opencascade' 'openvdb' 'qhull>=2020.2-4' 'slicer-udev' @@ -50,6 +51,7 @@ source=("https://github.com/supermerill/SuperSlicer/archive/$_pkgtag.tar.gz" "0003-openexr3.patch" "0004-fix-opencascade-version-check.patch" "0005-fix-opencascade-libs.patch" + "0006-cmake3.5.patch" "0008-boost1.85.patch" "0009-fix-multiple-choice.patch" "0010-occtwrapper-install-dir.patch" @@ -66,6 +68,7 @@ sha512sums=('0d72bf61adcafe8eef2ed860449dc25ca295ba0732d956bff8c0ae50b381387b803 '840e51b8feb3568ff46d309ece063f7188018fcaa43d19ec50ede408fdf2c237a3b7eaa11ba24409d8c3f7d6f5fb270181508cc56e0b2b0fef68b766130ef1eb' '8512ace14c71b04eb98532e71592447475cf7feccf1c85f376487615c8a95f6afa645e4581f577ee26d91532c57f389eac7534a875d5a24e871f3ef593af33c9' 'a01abf748f82bc423f2c012ac430f78cfd5e56dede1d5999376e780267d0302d9a2a80c3eb15226c2f82102dda4c567c721ff99ab1fdeef504cbf9d9cb63ca53' + '7ff2c1b39d18bd0e2cdf56582281f04509ae92e9c8837c67b99afcebffe293688fc9d93c4a790b231413bf8bafda803db9fc90b312db03c989122e4319bab66b' 'ca9f407d87d8dd0181077bc2da5a8e2f8995eed88a4787b73ee6c62ef6d2380fd1394fe5412cdc34276d4182bce6f272173e9ccb653d1e28978e16f379114002' '6d7ab93042a75f04e1c3c8f294d19dd39abaf22aa75caf996c6a0cf753f6472134a3d4fa443b73924800b2d3a710416a931745c168911c0df3709fb71ec00570' '92929ba1cb6ee104a10f34a649eba3789ca02f1725104a57412279ff68c46614b1812b13e7dcdf0d235618b9f2a868b4798b1404d9e712d9f1efd46e6c71fcb5' @@ -105,6 +108,7 @@ prepare() { "$srcdir/0003-openexr3.patch" \ "$srcdir/0004-fix-opencascade-version-check.patch" \ "$srcdir/0005-fix-opencascade-libs.patch" \ + "$srcdir/0006-cmake3.5.patch" \ "$srcdir/0008-boost1.85.patch" \ "$srcdir/0009-fix-multiple-choice.patch" \ "$srcdir/0010-occtwrapper-install-dir.patch" \ @@ -152,7 +156,7 @@ build() { package() { cd "$srcdir/SuperSlicer-$_pkgtag/build" - DESTDIR="$pkgdir" samu install + DESTDIR="$pkgdir" ninja install test ! -h "$pkgdir/usr/share/SuperSlicer/resources" || rm "$pkgdir/usr/share/SuperSlicer/resources" rm -r "$pkgdir/usr/lib/udev" # provided by slicer-udev }