Accepting request 719629 from home:bnavigator

A slicer software based on the open-source project Slic3r. 
PrusaSlicer is a feature-rich, frequently updated tool that 
contains everything you need to export the perfect print files 
for your Original Prusa 3D printer.

Resubmitted after the comment from 71895 have been worked in

OBS-URL: https://build.opensuse.org/request/show/719629
OBS-URL: https://build.opensuse.org/package/show/science/PrusaSlicer?expand=0&rev=1
This commit is contained in:
Adrian Schröter 2019-08-12 08:58:02 +00:00 committed by Git OBS Bridge
commit e10afae535
6 changed files with 179 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

1
.gitignore vendored Normal file
View File

@ -0,0 +1 @@
.osc

19
PrusaSlicer.changes Normal file
View File

@ -0,0 +1,19 @@
-------------------------------------------------------------------
Mon Jul 29 11:30:21 UTC 2019 - Benjamin Greiner <code@bnavigator.de>
- Clean up specfile according to declined submit request 718985
- Remove non-devel BuildRequires
- Move icons to icons/hicolor
- build with -j1 as otherwise x64 build is stuck
-------------------------------------------------------------------
Fri Jul 26 15:25:15 UTC 2019 - Benjamin Greiner <code@bnavigator.de>
- use new patch from upstream
(see https://github.com/prusa3d/PrusaSlicer/pull/2676)
- use Education;Construction as long as boo#1074711 is not resolved
-------------------------------------------------------------------
Tue Jul 23 11:29:49 UTC 2019 - Benjamin Greiner <code@bnavigator.de>
- initial specfile

85
PrusaSlicer.spec Normal file
View File

@ -0,0 +1,85 @@
#
# spec file for package PrusaSlicer
#
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
Name: PrusaSlicer
Version: 2.0.0
Release: 0
Summary: A slicer software for Prusa 3D printers
License: AGPL-3.0-only
Group: Hardware/Printing
URL: https://www.prusa3d.com/prusaslicer/
Source0: https://github.com/prusa3d/PrusaSlicer/archive/version_%{version}.tar.gz
Patch0: prusaslicer-fixternary-wxstring.patch
BuildRequires: cmake
BuildRequires: eigen3-devel >= 3
BuildRequires: expat
BuildRequires: fdupes
BuildRequires: gcc-c++
BuildRequires: glew-devel
BuildRequires: gtest >= 1.7
BuildRequires: libboost_filesystem-devel
BuildRequires: libboost_locale-devel
BuildRequires: libboost_log-devel
BuildRequires: libboost_regex-devel
BuildRequires: libboost_system-devel
BuildRequires: libboost_thread-devel
BuildRequires: libcurl-devel
BuildRequires: libexpat-devel
BuildRequires: nlopt-devel
BuildRequires: tbb-devel
BuildRequires: update-desktop-files
BuildRequires: wxWidgets-devel >= 3.1
%description
A slicer software based on the open-source project Slic3r.
PrusaSlicer is a feature-rich, frequently updated tool that
contains everything you need to export the perfect print files
for your Original Prusa 3D printer.
%prep
%setup -q -n %{name}-version_%{version}
%patch0 -p1
%build
%cmake -DSLIC3R_FHS=1
%cmake_build -j1
%install
%cmake_install
for res in 32 128 192; do
install -D %{buildroot}%{_datadir}/%{name}/icons/%{name}_${res}px.png\
%{buildroot}%{_datadir}/icons/hicolor/${res}x${res}/apps/%{name}.png
done
# The category can be changed to Science;Engineering or Science; Construction as soon as boo#1074711 is resolved
%suse_update_desktop_file -c %{name} %{name} "Slicer Software for 3D Printers" prusa-slicer %{name} "Education;Construction"
%fdupes %{buildroot}%{_datadir}
%check
%ctest
%files
%{_bindir}/prusa-slicer
%{_datadir}/%{name}/
%{_datadir}/icons/hicolor/32x32/apps/%{name}.png
%{_datadir}/icons/hicolor/128x128/apps/%{name}.png
%{_datadir}/icons/hicolor/192x192/apps/%{name}.png
%{_datadir}/applications/%{name}.desktop
%license LICENSE
%doc README.md doc/
%changelog

View File

@ -0,0 +1,48 @@
From 3566afde92edf1880f9672266f0d73e7acc71546 Mon Sep 17 00:00:00 2001
From: Vojtech Kral <vojtech@kral.hk>
Date: Fri, 26 Jul 2019 13:52:51 +0200
Subject: [PATCH] Fix a ternary op type error in Tab
Fix #2668
Fix #2676
---
src/slic3r/GUI/Tab.cpp | 22 ++++++++++++++--------
1 file changed, 14 insertions(+), 8 deletions(-)
diff --git a/src/slic3r/GUI/Tab.cpp b/src/slic3r/GUI/Tab.cpp
index 5777cbc0f..5bacda80e 100644
--- a/src/slic3r/GUI/Tab.cpp
+++ b/src/slic3r/GUI/Tab.cpp
@@ -915,14 +915,20 @@ void Tab::update_preset_description_line()
{
const Preset* parent = m_presets->get_selected_preset_parent();
const Preset& preset = m_presets->get_edited_preset();
-
- wxString description_line = preset.is_default ?
- _(L("It's a default preset.")) : preset.is_system ?
- _(L("It's a system preset.")) :
- wxString::Format(_(L("Current preset is inherited from %s")), (parent == nullptr ?
- _(L("default preset"))+"." :
- ":\n\t" + parent->name));
-
+
+ wxString description_line;
+
+ if (preset.is_default) {
+ description_line = _(L("This is a default preset."));
+ } else if (preset.is_system) {
+ description_line = _(L("This is a system preset."));
+ } else if (parent == nullptr) {
+ description_line = _(L("Current preset is inherited from the default preset."));
+ } else {
+ description_line = wxString::Format(
+ _(L("Current preset is inherited from:\n\t%s")), GUI::from_u8(parent->name));
+ }
+
if (preset.is_default || preset.is_system)
description_line += "\n\t" + _(L("It can't be deleted or modified.")) +
"\n\t" + _(L("Any modifications should be saved as a new preset inherited from this one.")) +
--
2.22.0

3
version_2.0.0.tar.gz Normal file
View File

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