Accepting request 1111613 from home:bnavigator:prusaslicer

- Update to 2.6.1
  * When renaming a preset to a name containing non-ASCII
    characters, the encoding was mangled. This is now fixed
    (#11232).
  * Supports are no longer shown when using the clipping plane in
    SLA supports tool.
  * Fixed a crash when displaying command line help (#11060).
  * Two tooltips in the Cut tool dialog were shown with mangled
    encoding in some languages (#11236).
  * The Help menu in PrusaSlicer was extended with "Sample G-codes
    and Models" item, which navigates the user to the respective
    page on our website where these assets can be downloaded.
  * The Help menu was extended with "Quick Start" item, which
    navigates the user to the beginner's guide on our website.
- Drop PrusaSlicer-pr11154-fix-cgal-c++-error.patch
- Drop PrusaSlicer-drop-wx3.0.patch

OBS-URL: https://build.opensuse.org/request/show/1111613
OBS-URL: https://build.opensuse.org/package/show/science/PrusaSlicer?expand=0&rev=66
This commit is contained in:
Benjamin Greiner 2023-09-15 20:34:57 +00:00 committed by Git OBS Bridge
parent a42f41e3c7
commit 14b1fc6404
9 changed files with 55 additions and 167 deletions

View File

@ -1,8 +1,8 @@
Index: b/src/slic3r/Utils/OctoPrint.cpp
Index: PrusaSlicer-version_2.6.1/src/slic3r/Utils/OctoPrint.cpp
===================================================================
--- a/src/slic3r/Utils/OctoPrint.cpp
+++ b/src/slic3r/Utils/OctoPrint.cpp
@@ -746,7 +746,7 @@ bool PrusaLink::get_storage(wxArrayStrin
--- PrusaSlicer-version_2.6.1.orig/src/slic3r/Utils/OctoPrint.cpp
+++ PrusaSlicer-version_2.6.1/src/slic3r/Utils/OctoPrint.cpp
@@ -751,7 +751,7 @@ bool PrusaLink::get_storage(wxArrayStrin
if (path && (!available || *available)) {
StorageInfo si;
si.path = boost::nowide::widen(*path);

View File

@ -13,11 +13,11 @@ wxEXPAND overrides alignment flags in box sizers
src/slic3r/GUI/WipeTowerDialog.cpp | 2 +-
4 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/slic3r/GUI/Field.cpp b/src/slic3r/GUI/Field.cpp
index 74ad028d363..6789ce24cb5 100644
--- a/src/slic3r/GUI/Field.cpp
+++ b/src/slic3r/GUI/Field.cpp
@@ -1660,7 +1660,7 @@ void SliderCtrl::BUILD()
Index: PrusaSlicer-version_2.6.1/src/slic3r/GUI/Field.cpp
===================================================================
--- PrusaSlicer-version_2.6.1.orig/src/slic3r/GUI/Field.cpp
+++ PrusaSlicer-version_2.6.1/src/slic3r/GUI/Field.cpp
@@ -1668,7 +1668,7 @@ void SliderCtrl::BUILD()
m_textctrl->SetFont(Slic3r::GUI::wxGetApp().normal_font());
m_textctrl->SetBackgroundStyle(wxBG_STYLE_PAINT);
@ -26,11 +26,11 @@ index 74ad028d363..6789ce24cb5 100644
temp->Add(m_textctrl, 0, wxALIGN_CENTER_VERTICAL, 0);
m_slider->Bind(wxEVT_SLIDER, ([this](wxCommandEvent e) {
diff --git a/src/slic3r/GUI/FirmwareDialog.cpp b/src/slic3r/GUI/FirmwareDialog.cpp
index 47402644f4b..46d2fdb60d1 100644
--- a/src/slic3r/GUI/FirmwareDialog.cpp
+++ b/src/slic3r/GUI/FirmwareDialog.cpp
@@ -841,7 +841,7 @@ FirmwareDialog::FirmwareDialog(wxWindow *parent) :
Index: PrusaSlicer-version_2.6.1/src/slic3r/GUI/FirmwareDialog.cpp
===================================================================
--- PrusaSlicer-version_2.6.1.orig/src/slic3r/GUI/FirmwareDialog.cpp
+++ PrusaSlicer-version_2.6.1/src/slic3r/GUI/FirmwareDialog.cpp
@@ -845,7 +845,7 @@ FirmwareDialog::FirmwareDialog(wxWindow
grid->Add(port_sizer, 0, wxEXPAND);
grid->Add(label_progress, 0, wxALIGN_CENTER_VERTICAL);
@ -39,11 +39,11 @@ index 47402644f4b..46d2fdb60d1 100644
grid->Add(label_status, 0, wxALIGN_CENTER_VERTICAL);
grid->Add(p->txt_status, 0, wxEXPAND);
diff --git a/src/slic3r/GUI/Tab.cpp b/src/slic3r/GUI/Tab.cpp
index 184b8af707f..c95fcd44219 100644
--- a/src/slic3r/GUI/Tab.cpp
+++ b/src/slic3r/GUI/Tab.cpp
@@ -217,7 +217,7 @@ void Tab::create_preset_tab()
Index: PrusaSlicer-version_2.6.1/src/slic3r/GUI/Tab.cpp
===================================================================
--- PrusaSlicer-version_2.6.1.orig/src/slic3r/GUI/Tab.cpp
+++ PrusaSlicer-version_2.6.1/src/slic3r/GUI/Tab.cpp
@@ -236,7 +236,7 @@ void Tab::create_preset_tab()
const float scale_factor = em_unit(this)*0.1;// GetContentScaleFactor();
m_top_hsizer = new wxBoxSizer(wxHORIZONTAL);
@ -52,7 +52,7 @@ index 184b8af707f..c95fcd44219 100644
m_top_hsizer->Add(m_presets_choice, 0, wxLEFT | wxRIGHT | wxTOP | wxALIGN_CENTER_VERTICAL, 3);
m_top_hsizer->AddSpacer(int(4*scale_factor));
@@ -243,7 +243,7 @@ void Tab::create_preset_tab()
@@ -262,7 +262,7 @@ void Tab::create_preset_tab()
m_h_buttons_sizer->AddSpacer(int(8*scale_factor));
m_h_buttons_sizer->Add(m_btn_compare_preset, 0, wxALIGN_CENTER_VERTICAL);
@ -61,11 +61,11 @@ index 184b8af707f..c95fcd44219 100644
m_top_hsizer->AddSpacer(int(16*scale_factor));
// StretchSpacer has a strange behavior under OSX, so
// There is used just additional sizer for m_mode_sizer with right alignment
diff --git a/src/slic3r/GUI/WipeTowerDialog.cpp b/src/slic3r/GUI/WipeTowerDialog.cpp
index 4d117ff8d62..6d48daa6292 100644
--- a/src/slic3r/GUI/WipeTowerDialog.cpp
+++ b/src/slic3r/GUI/WipeTowerDialog.cpp
@@ -353,7 +353,7 @@ WipingPanel::WipingPanel(wxWindow* parent, const std::vector<float>& matrix, con
Index: PrusaSlicer-version_2.6.1/src/slic3r/GUI/WipeTowerDialog.cpp
===================================================================
--- PrusaSlicer-version_2.6.1.orig/src/slic3r/GUI/WipeTowerDialog.cpp
+++ PrusaSlicer-version_2.6.1/src/slic3r/GUI/WipeTowerDialog.cpp
@@ -357,7 +357,7 @@ WipingPanel::WipingPanel(wxWindow* paren
hsizer->AddSpacer(10);
hsizer->Add(new wxStaticText(m_page_simple, wxID_ANY, wxString(_(L("Tool #"))) << i + 1 << ": "), 0, wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL);

View File

@ -1,85 +0,0 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 49fe3437f..aa297b03b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -26,7 +26,6 @@ endif()
option(SLIC3R_STATIC "Compile PrusaSlicer with static libraries (Boost, TBB, glew)" ${SLIC3R_STATIC_INITIAL})
option(SLIC3R_GUI "Compile PrusaSlicer with GUI components (OpenGL, wxWidgets)" 1)
option(SLIC3R_FHS "Assume PrusaSlicer is to be installed in a FHS directory structure" 0)
-option(SLIC3R_WX_STABLE "Build against wxWidgets stable (3.0) as oppsed to dev (3.1) on Linux" 0)
option(SLIC3R_PCH "Use precompiled headers" 1)
option(SLIC3R_MSVC_COMPILE_PARALLEL "Compile on Visual Studio in parallel" 1)
option(SLIC3R_MSVC_PDB "Generate PDB files on MSVC in Release mode" 1)
diff --git a/doc/Dependencies.md b/doc/Dependencies.md
index d8ced6318..5645e7169 100644
--- a/doc/Dependencies.md
+++ b/doc/Dependencies.md
@@ -1,7 +1,7 @@
# Dependency report for PrusaSlicer
## Possible dynamic linking on Linux
* zlib: Strict dependency required from the system, linked dynamically. Many other libs depend on zlib.
-* wxWidgets: searches for wx-3.1 by default, but with cmake option `SLIC3R_WX_STABLE=ON` it will use wx-3.0 bundled with most distros.
+* wxWidgets >= 3.1.6
* libcurl
* tbb
* boost
diff --git a/doc/How to build - Linux et al.md b/doc/How to build - Linux et al.md
index 81e6310c4..de6e365fb 100644
--- a/doc/How to build - Linux et al.md
+++ b/doc/How to build - Linux et al.md
@@ -87,7 +87,6 @@ And that's it. It is now possible to run the freshly built PrusaSlicer binary:
- `-DSLIC3R_ASAN=ON` enables gcc/clang address sanitizer (defaults to `OFF`, requires gcc>4.8 or clang>3.1)
- `-DSLIC3R_GTK=3` to use GTK3 (defaults to `2`). Note that wxWidgets must be built against the same GTK version.
- `-DSLIC3R_STATIC=ON` for static build (defaults to `OFF`)
-- `-DSLIC3R_WX_STABLE=ON` to look for wxWidgets 3.0 (defaults to `OFF`)
- `-DCMAKE_BUILD_TYPE=Debug` to build in debug mode (defaults to `Release`)
- `-DSLIC3R_GUI=no` to build the console variant of PrusaSlicer
@@ -101,14 +100,6 @@ As already mentioned above, dynamic linking of dependencies is possible, but Pru
The list of dependencies can be easily obtained by inspecting the CMake scripts in the `deps/` directory. Some of the dependencies don't have to be as recent as the versions listed - generally versions available on conservative Linux distros such as Debian stable, Ubuntu LTS releases or Fedora are likely sufficient. If you decide to build this way, it is your responsibility to make sure that CMake finds all required dependencies. It is possible to look at your distribution PrusaSlicer package to see how the package maintainers solved the dependency issues.
-#### wxWidgets
-By default, PrusaSlicer looks for wxWidgets 3.1. Our build script in fact downloads specific patched version of wxWidgets. If you want to link against wxWidgets 3.0 (which are still provided by most distributions because wxWidgets 3.1 have not yet been declared stable), you must set `-DSLIC3R_WX_STABLE=ON` when running CMake. Note that while PrusaSlicer can be linked against wWidgets 3.0, the combination is not well tested and there might be bugs in the resulting application.
-
-When building on ubuntu 20.04 focal fossa, the package libwxgtk3.0-gtk3-dev needs to be installed instead of libwxgtk3.0-dev and you should use:
-```
--DSLIC3R_WX_STABLE=1 -DSLIC3R_GTK=3
-```
-
## Miscellaneous
### Installation
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 50eccfc84..1a335f2cd 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -49,23 +49,17 @@ if (SLIC3R_GUI)
if (CMAKE_SYSTEM_NAME STREQUAL "Linux")
set (wxWidgets_CONFIG_OPTIONS "--toolkit=gtk${SLIC3R_GTK}")
- if (SLIC3R_WX_STABLE)
- find_package(wxWidgets 3.0 REQUIRED COMPONENTS base core adv html gl)
- else ()
- find_package(wxWidgets 3.1 QUIET COMPONENTS base core adv html gl)
-
- if (NOT wxWidgets_FOUND)
- message(FATAL_ERROR "\nCould not find wxWidgets 3.1.\n"
- "Hint: On Linux you can set -DSLIC3R_WX_STABLE=1 to use wxWidgets 3.0\n")
- endif ()
+ find_package(wxWidgets 3.1.6 QUIET COMPONENTS base core adv html gl)
+ if (NOT wxWidgets_FOUND)
+ message(FATAL_ERROR "Could not find wxWidgets >= 3.1.6")
endif ()
include(${wxWidgets_USE_FILE})
else ()
- find_package(wxWidgets 3.1 COMPONENTS html adv gl core base)
+ find_package(wxWidgets 3.1.6 COMPONENTS html adv gl core base)
if (NOT wxWidgets_FOUND)
message(STATUS "Trying to find wxWidgets in CONFIG mode...")
- find_package(wxWidgets 3.2 CONFIG REQUIRED COMPONENTS html adv gl core base)
+ find_package(wxWidgets 3.1.6 CONFIG REQUIRED COMPONENTS html adv gl core base)
slic3r_remap_configs(wx::wxhtml wx::wxadv wx::wxgl wx::wxcore wx::wxbase RelWithDebInfo Release)
else ()
include(${wxWidgets_USE_FILE})

View File

@ -1,43 +0,0 @@
From dcc281f3604b8508ec01e6649c883d7fff4bd3d1 Mon Sep 17 00:00:00 2001
From: Chow Loong Jin <hyperair@debian.org>
Date: Tue, 22 Aug 2023 15:35:56 +0800
Subject: [PATCH] Fix compilation errors with -std=gnu++17
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Fixes the following error:
[ 19%] Built target imgui
/<<PKGBUILDDIR>>/src/libslic3r/MeshBoolean.cpp: In instantiation of indexed_triangle_set Slic3r::MeshBoolean::cgal::cgal_to_indexed_triangle_set(const _Mesh&) [with _Mesh = CGAL::Surface_mesh<CGAL::Point_3<CGAL::Epick> >]:
/<<PKGBUILDDIR>>/src/libslic3r/MeshBoolean.cpp:185:53: required from here
/<<PKGBUILDDIR>>/src/libslic3r/MeshBoolean.cpp:151:5: error: cannot bind non-const lvalue reference of type CGAL::SM_Vertex_index& to an rvalue of type boost::iterators::detail::iterator_facade_base<CGAL::Surface_mesh<CGAL::Point_3<CGAL::Epick> >::Index_iterator<CGAL::SM_Vertex_index>, CGAL::SM_Vertex_index, std::random_access_iterator_tag, CGAL::SM_Vertex_index, long int, false, false>::reference {aka CGAL::SM_Vertex_index}
151 | for (auto &vi : vertices) {
| ^~~
/<<PKGBUILDDIR>>/src/libslic3r/MeshBoolean.cpp:156:5: error: cannot bind non-const lvalue reference of type CGAL::SM_Face_index& to an rvalue of type boost::iterators::detail::iterator_facade_base<CGAL::Surface_mesh<CGAL::Point_3<CGAL::Epick> >::Index_iterator<CGAL::SM_Face_index>, CGAL::SM_Face_index, std::random_access_iterator_tag, CGAL::SM_Face_index, long int, false, false>::reference {aka CGAL::SM_Face_index}
156 | for (auto &face : faces) {
| ^~~
make[3]: *** [src/libslic3r/CMakeFiles/libslic3r_cgal.dir/build.make:121: src/libslic3r/CMakeFiles/libslic3r_cgal.dir/MeshBoolean.cpp.o] Error 1
---
src/libslic3r/MeshBoolean.cpp | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/libslic3r/MeshBoolean.cpp b/src/libslic3r/MeshBoolean.cpp
index c7ebcbd19e0..06fa5f35fce 100644
--- a/src/libslic3r/MeshBoolean.cpp
+++ b/src/libslic3r/MeshBoolean.cpp
@@ -148,12 +148,12 @@ indexed_triangle_set cgal_to_indexed_triangle_set(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;

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:a15f68e3b18a047c8c9a18a9d91629d2c777be1932087684cf6d2332d0888e77
size 56430180

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:516eb34835cd8f301e639fa77f9f12297300ce012ebc3b7b6a73275c6245011d
size 58479800

View File

@ -1,3 +1,23 @@
-------------------------------------------------------------------
Fri Sep 15 19:03:08 UTC 2023 - Ben Greiner <code@bnavigator.de>
- Update to 2.6.1
* When renaming a preset to a name containing non-ASCII
characters, the encoding was mangled. This is now fixed
(#11232).
* Supports are no longer shown when using the clipping plane in
SLA supports tool.
* Fixed a crash when displaying command line help (#11060).
* Two tooltips in the Cut tool dialog were shown with mangled
encoding in some languages (#11236).
* The Help menu in PrusaSlicer was extended with "Sample G-codes
and Models" item, which navigates the user to the respective
page on our website where these assets can be downloaded.
* The Help menu was extended with "Quick Start" item, which
navigates the user to the beginner's guide on our website.
- Drop PrusaSlicer-pr11154-fix-cgal-c++-error.patch
- Drop PrusaSlicer-drop-wx3.0.patch
-------------------------------------------------------------------
Tue Aug 29 07:23:22 UTC 2023 - Ben Greiner <code@bnavigator.de>

View File

@ -17,7 +17,7 @@
Name: PrusaSlicer
Version: 2.6.0
Version: 2.6.1
Release: 0
Summary: G-code generator for 3D printers (RepRap, Makerbot, Ultimaker etc.)
License: AGPL-3.0-only
@ -28,12 +28,8 @@ Source0: https://github.com/prusa3d/PrusaSlicer/archive/version_%{version
Patch0: up-occt-version.patch
# PATCH-FIX-OPENSUSE PrusaSlicer-2.6.0-octoprint-name-fix.patch -- cast lambda expression to same type
Patch1: PrusaSlicer-2.6.0-octoprint-name-fix.patch
# PATCH-FIX-UPSTREAM PrusaSlicer-2.6.0-wxWidgets-CheckResizerFlags-assert-fix.patch -- https://github.com/prusa3d/PrusaSlicer/commit/24a5ebd65c9d25a0fd69a3716d079fd1b00eb15c.patch
# PATCH-FIX-UPSTREAM PrusaSlicer-2.6.0-wxWidgets-CheckResizerFlags-assert-fix.patch -- https://github.com/prusa3d/PrusaSlicer/pull/10811
Patch2: PrusaSlicer-2.6.0-wxWidgets-CheckResizerFlags-assert-fix.patch
# PATCH-FIX-UPSTREAM PrusaSlicer-drop-wx3.0.patch gh#prusa3d/PrusaSlicer#11027 - wxWidgets >= 3.1.6 is required
Patch3: PrusaSlicer-drop-wx3.0.patch
# PATCH-FIX-UPSTREAM PrusaSlicer-pr11154-fix-cgal-c++-error.patch gh#prusa3d/PrusaSlicer#11154
Patch4: PrusaSlicer-pr11154-fix-cgal-c++-error.patch
BuildRequires: blosc-devel
BuildRequires: cereal-devel
BuildRequires: cgal-devel >= 5.6
@ -69,7 +65,7 @@ BuildRequires: openvdb-tools
BuildRequires: pkgconfig
BuildRequires: tbb-devel
BuildRequires: update-desktop-files
BuildRequires: wxWidgets-devel >= 3.1.6
BuildRequires: wxWidgets-devel >= 3.2
# need the fltk fork, see deps/NanoSVG/NanoSVG.cmake
BuildRequires: nanosvg-devel >= 2022.12.22
BuildRequires: pkgconfig(dbus-1)

View File

@ -1,7 +1,7 @@
Index: PrusaSlicer-version_2.5.0/src/occt_wrapper/CMakeLists.txt
Index: PrusaSlicer-version_2.6.1/src/occt_wrapper/CMakeLists.txt
===================================================================
--- PrusaSlicer-version_2.5.0.orig/src/occt_wrapper/CMakeLists.txt
+++ PrusaSlicer-version_2.5.0/src/occt_wrapper/CMakeLists.txt
--- PrusaSlicer-version_2.6.1.orig/src/occt_wrapper/CMakeLists.txt
+++ PrusaSlicer-version_2.6.1/src/occt_wrapper/CMakeLists.txt
@@ -19,7 +19,7 @@ include(GenerateExportHeader)
generate_export_header(OCCTWrapper)
@ -11,7 +11,7 @@ Index: PrusaSlicer-version_2.5.0/src/occt_wrapper/CMakeLists.txt
set(OCCT_LIBS
TKXDESTEP
@@ -56,5 +56,5 @@ target_link_libraries(OCCTWrapper ${OCCT
@@ -58,5 +58,5 @@ target_link_libraries(OCCTWrapper ${OCCT
include(GNUInstallDirs)