prusa-slicer: 2.9.0 -> 2.9.2 (#417043)

authored by Arne Keller and committed by GitHub 46ada98e 5bd9bdc6

+30 -70
+25 -28
pkgs/applications/misc/prusa-slicer/default.nix
··· 3 lib, 4 binutils, 5 fetchFromGitHub, 6 - fetchpatch, 7 cmake, 8 pkg-config, 9 wrapGAppsHook3, ··· 33 xorg, 34 libbgcode, 35 heatshrink, 36 - catch2, 37 webkitgtk_4_1, 38 ctestCheckHook, 39 withSystemd ? lib.meta.availableOn stdenv.hostPlatform systemd, 40 systemd, 41 wxGTK-override ? null, 42 opencascade-override ? null, 43 }: ··· 60 in 61 stdenv.mkDerivation (finalAttrs: { 62 pname = "prusa-slicer"; 63 - version = "2.9.0"; 64 65 src = fetchFromGitHub { 66 owner = "prusa3d"; 67 repo = "PrusaSlicer"; 68 - hash = "sha256-6BrmTNIiu6oI/CbKPKoFQIh1aHEVfJPIkxomQou0xKk="; 69 rev = "version_${finalAttrs.version}"; 70 }; 71 72 - # https://github.com/prusa3d/PrusaSlicer/pull/14010 73 - patches = [ 74 - (fetchpatch { 75 - url = "https://github.com/prusa3d/PrusaSlicer/commit/cdc3db58f9002778a0ca74517865527f50ade4c3.patch"; 76 - hash = "sha256-zgpGg1jtdnCBaWjR6oUcHo5sGuZx5oEzpux3dpRdMAM="; 77 - }) 78 - # https://github.com/prusa3d/PrusaSlicer/pull/11769 79 - ./fix-ambiguous-constructors.patch 80 - ]; 81 - 82 - # Patch required for GCC 14. 83 # (not applicable to super-slicer fork) 84 - # Make Gcode viewer open newer bgcode files. 85 - postPatch = lib.optionalString (finalAttrs.pname == "prusa-slicer") '' 86 - substituteInPlace src/slic3r-arrange/include/arrange/DataStoreTraits.hpp \ 87 - --replace-fail \ 88 - "WritableDataStoreTraits<ArrItem>::template set" \ 89 - "WritableDataStoreTraits<ArrItem>::set" 90 - substituteInPlace src/platform/unix/PrusaGcodeviewer.desktop \ 91 - --replace-fail 'MimeType=text/x.gcode;' 'MimeType=application/x-bgcode;text/x.gcode;' 92 - ''; 93 94 nativeBuildInputs = [ 95 cmake ··· 127 xorg.libX11 128 libbgcode 129 heatshrink 130 - catch2 131 webkitgtk_4_1 132 ] 133 ++ lib.optionals withSystemd [ 134 systemd ··· 161 # dlopen(3) for context. 162 if [ -f "src/libslic3r/Format/STEP.cpp" ]; then 163 substituteInPlace src/libslic3r/Format/STEP.cpp \ 164 - --replace 'libpath /= "OCCTWrapper.so";' 'libpath = "OCCTWrapper.so";' 165 fi 166 # https://github.com/prusa3d/PrusaSlicer/issues/9581 167 if [ -f "cmake/modules/FindEXPAT.cmake" ]; then ··· 169 fi 170 171 # Fix resources folder location on macOS 172 - substituteInPlace src/PrusaSlicer.cpp \ 173 - --replace "#ifdef __APPLE__" "#if 0" 174 ''; 175 176 cmakeFlags = [
··· 3 lib, 4 binutils, 5 fetchFromGitHub, 6 cmake, 7 pkg-config, 8 wrapGAppsHook3, ··· 32 xorg, 33 libbgcode, 34 heatshrink, 35 + catch2_3, 36 webkitgtk_4_1, 37 ctestCheckHook, 38 withSystemd ? lib.meta.availableOn stdenv.hostPlatform systemd, 39 systemd, 40 + z3, 41 wxGTK-override ? null, 42 opencascade-override ? null, 43 }: ··· 60 in 61 stdenv.mkDerivation (finalAttrs: { 62 pname = "prusa-slicer"; 63 + version = "2.9.2"; 64 65 src = fetchFromGitHub { 66 owner = "prusa3d"; 67 repo = "PrusaSlicer"; 68 + hash = "sha256-j/fdEgcFq0nWBLpyapwZIbBIXCnqEWV6Tk+6sTHk/Bc="; 69 rev = "version_${finalAttrs.version}"; 70 }; 71 72 # (not applicable to super-slicer fork) 73 + postPatch = lib.optionalString (finalAttrs.pname == "prusa-slicer") ( 74 + # Patch required for GCC 14, but breaks on clang 75 + lib.optionalString stdenv.cc.isGNU '' 76 + substituteInPlace src/slic3r-arrange/include/arrange/DataStoreTraits.hpp \ 77 + --replace-fail \ 78 + "WritableDataStoreTraits<ArrItem>::template set" \ 79 + "WritableDataStoreTraits<ArrItem>::set" 80 + '' 81 + # Make Gcode viewer open newer bgcode files. 82 + + '' 83 + substituteInPlace src/platform/unix/PrusaGcodeviewer.desktop \ 84 + --replace-fail 'MimeType=text/x.gcode;' 'MimeType=application/x-bgcode;text/x.gcode;' 85 + '' 86 + ); 87 88 nativeBuildInputs = [ 89 cmake ··· 121 xorg.libX11 122 libbgcode 123 heatshrink 124 + catch2_3 125 webkitgtk_4_1 126 + z3 127 ] 128 ++ lib.optionals withSystemd [ 129 systemd ··· 156 # dlopen(3) for context. 157 if [ -f "src/libslic3r/Format/STEP.cpp" ]; then 158 substituteInPlace src/libslic3r/Format/STEP.cpp \ 159 + --replace-fail 'libpath /= "OCCTWrapper.so";' 'libpath = "OCCTWrapper.so";' 160 fi 161 # https://github.com/prusa3d/PrusaSlicer/issues/9581 162 if [ -f "cmake/modules/FindEXPAT.cmake" ]; then ··· 164 fi 165 166 # Fix resources folder location on macOS 167 + substituteInPlace src/${ 168 + if finalAttrs.pname == "prusa-slicer" then "CLI/Setup.cpp" else "PrusaSlicer.cpp" 169 + } \ 170 + --replace-fail "#ifdef __APPLE__" "#if 0" 171 ''; 172 173 cmakeFlags = [
-37
pkgs/applications/misc/prusa-slicer/fix-ambiguous-constructors.patch
··· 1 - From 910328f3131e24e330808f5d4cb814454dbe201d Mon Sep 17 00:00:00 2001 2 - From: Gregor Riepl <onitake@gmail.com> 3 - Date: Mon, 27 Nov 2023 13:01:55 +0100 4 - Subject: [PATCH] Make initializers explicit to avoid ambiguous wxArrayString 5 - overloads 6 - 7 - --- 8 - src/slic3r/GUI/PhysicalPrinterDialog.cpp | 2 +- 9 - src/slic3r/GUI/Plater.cpp | 2 +- 10 - 2 files changed, 2 insertions(+), 2 deletions(-) 11 - 12 - diff --git a/src/slic3r/GUI/PhysicalPrinterDialog.cpp b/src/slic3r/GUI/PhysicalPrinterDialog.cpp 13 - index 849e987c731..7d0c628c23f 100644 14 - --- a/src/slic3r/GUI/PhysicalPrinterDialog.cpp 15 - +++ b/src/slic3r/GUI/PhysicalPrinterDialog.cpp 16 - @@ -607,7 +607,7 @@ void PhysicalPrinterDialog::build_printhost_settings(ConfigOptionsGroup* m_optgr 17 - // Always fill in the "printhost_port" combo box from the config and select it. 18 - { 19 - Choice* choice = dynamic_cast<Choice*>(m_optgroup->get_field("printhost_port")); 20 - - choice->set_values({ m_config->opt_string("printhost_port") }); 21 - + choice->set_values(std::vector<std::string>({ m_config->opt_string("printhost_port") })); 22 - choice->set_selection(); 23 - } 24 - 25 - diff --git a/src/slic3r/GUI/Plater.cpp b/src/slic3r/GUI/Plater.cpp 26 - index debfe625fd4..4d61e29a2dc 100644 27 - --- a/src/slic3r/GUI/Plater.cpp 28 - +++ b/src/slic3r/GUI/Plater.cpp 29 - @@ -4420,7 +4420,7 @@ void Plater::load_project(const wxString& filename) 30 - s_multiple_beds.set_loading_project_flag(true); 31 - ScopeGuard guard([](){ s_multiple_beds.set_loading_project_flag(false);}); 32 - 33 - - if (! load_files({ into_path(filename) }).empty()) { 34 - + if (! load_files(std::vector<boost::filesystem::path>({ into_path(filename) })).empty()) { 35 - // At least one file was loaded. 36 - p->set_project_filename(filename); 37 - // Save the names of active presets and project specific config into ProjectDirtyStateManager.
···
+5 -5
pkgs/by-name/li/libbgcode/package.nix
··· 7 heatshrink, 8 zlib, 9 boost, 10 - catch2, 11 }: 12 stdenv.mkDerivation { 13 pname = "libbgcode"; 14 - version = "2023-11-16"; 15 16 src = fetchFromGitHub { 17 owner = "prusa3d"; 18 repo = "libbgcode"; 19 - rev = "bc390aab4427589a6402b4c7f65cf4d0a8f987ec"; 20 - hash = "sha256-TZShYeDAh+fNdmTr1Xqctji9f0vEGpNZv1ba/IY5EoY="; 21 }; 22 23 nativeBuildInputs = [ ··· 29 heatshrink 30 zlib 31 boost 32 - catch2 33 ]; 34 35 meta = with lib; {
··· 7 heatshrink, 8 zlib, 9 boost, 10 + catch2_3, 11 }: 12 stdenv.mkDerivation { 13 pname = "libbgcode"; 14 + version = "0-unstable-2025-02-19"; 15 16 src = fetchFromGitHub { 17 owner = "prusa3d"; 18 repo = "libbgcode"; 19 + rev = "5041c093b33e2748e76d6b326f2251310823f3df"; 20 + hash = "sha256-EaxVZerH2v8b1Yqk+RW/r3BvnJvrAelkKf8Bd+EHbEc="; 21 }; 22 23 nativeBuildInputs = [ ··· 29 heatshrink 30 zlib 31 boost 32 + catch2_3 33 ]; 34 35 meta = with lib; {