New version 14.06
This commit is contained in:
parent
09ea1a69a2
commit
2dfa4116ec
11 changed files with 184 additions and 118 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -2,3 +2,4 @@
|
|||
/Cura-13.04-linux-fedora.tar.gz
|
||||
/Cura-13.10-fedora.tar.gz
|
||||
/Cura-13.11.2-fedora.tar.gz
|
||||
/Cura-14.06-fedora.tar.gz
|
||||
|
|
|
|||
|
|
@ -1,23 +0,0 @@
|
|||
diff --git a/util/sliceEngine.py b/util/sliceEngine.py
|
||||
index 8944b05..461dc62 100644
|
||||
--- a/util/sliceEngine.py
|
||||
+++ b/util/sliceEngine.py
|
||||
@@ -17,17 +17,7 @@ from Cura.util import profile
|
||||
from Cura.util import version
|
||||
|
||||
def getEngineFilename():
|
||||
- if platform.system() == 'Windows':
|
||||
- if os.path.exists('C:/Software/Cura_SteamEngine/_bin/Release/Cura_SteamEngine.exe'):
|
||||
- return 'C:/Software/Cura_SteamEngine/_bin/Release/Cura_SteamEngine.exe'
|
||||
- return os.path.abspath(os.path.join(os.path.dirname(__file__), '../..', 'CuraEngine.exe'))
|
||||
- if hasattr(sys, 'frozen'):
|
||||
- return os.path.abspath(os.path.join(os.path.dirname(__file__), '../../../../..', 'CuraEngine'))
|
||||
- if os.path.isfile('/usr/bin/CuraEngine'):
|
||||
- return '/usr/bin/CuraEngine'
|
||||
- if os.path.isfile('/usr/local/bin/CuraEngine'):
|
||||
- return '/usr/local/bin/CuraEngine'
|
||||
- return os.path.abspath(os.path.join(os.path.dirname(__file__), '../..', 'CuraEngine'))
|
||||
+ return '/usr/bin/CuraEngine'
|
||||
|
||||
def getTempFilename():
|
||||
warnings.simplefilter('ignore')
|
||||
|
|
@ -1,12 +1,12 @@
|
|||
diff --git a/gui/sceneView.py b/gui/sceneView.py
|
||||
index d609cd0..8696b71 100644
|
||||
--- a/gui/sceneView.py
|
||||
+++ b/gui/sceneView.py
|
||||
@@ -1233,70 +1233,16 @@ void main(void)
|
||||
diff --git a/Cura/gui/sceneView.py b/Cura/gui/sceneView.py
|
||||
index 2913e4b..e1a2b51 100644
|
||||
--- a/Cura/gui/sceneView.py
|
||||
+++ b/Cura/gui/sceneView.py
|
||||
@@ -1237,70 +1237,16 @@ class SceneView(openglGui.glGuiPanel):
|
||||
size = [profile.getMachineSettingFloat('machine_width'), profile.getMachineSettingFloat('machine_depth'), profile.getMachineSettingFloat('machine_height')]
|
||||
|
||||
machine = profile.getMachineSetting('machine_type')
|
||||
- if profile.getMachineSetting('machine_type').startswith('ultimaker'):
|
||||
- if machine.startswith('ultimaker'):
|
||||
- if machine not in self._platformMesh:
|
||||
- meshes = meshLoader.loadMeshes(resources.getPathForMesh(machine + '_platform.stl'))
|
||||
- if len(meshes) > 0:
|
||||
|
|
@ -25,7 +25,7 @@ index d609cd0..8696b71 100644
|
|||
- #For the Ultimaker 2 render the texture on the back plate to show the Ultimaker2 text.
|
||||
- if machine == 'ultimaker2':
|
||||
- if not hasattr(self._platformMesh[machine], 'texture'):
|
||||
- self._platformMesh[machine].texture = opengl.loadGLTexture('Ultimaker2backplate.png')
|
||||
- self._platformMesh[machine].texture = openglHelpers.loadGLTexture('Ultimaker2backplate.png')
|
||||
- glBindTexture(GL_TEXTURE_2D, self._platformMesh[machine].texture)
|
||||
- glEnable(GL_TEXTURE_2D)
|
||||
- glPushMatrix()
|
||||
|
|
@ -81,5 +81,5 @@ index d609cd0..8696b71 100644
|
|||
+ glVertex3f(-size[0] / 2, -size[1] / 2+10, 0)
|
||||
+ glEnd()
|
||||
|
||||
#Cornerpoints for big blue square
|
||||
v0 = [ size[0] / 2, size[1] / 2, size[2]]
|
||||
glDepthMask(False)
|
||||
|
||||
|
|
|
|||
|
|
@ -1,23 +0,0 @@
|
|||
diff --git a/gui/tools/batchRun.py b/gui/tools/batchRun.py
|
||||
index 14c1e56..8ec19c4 100644
|
||||
--- a/gui/tools/batchRun.py
|
||||
+++ b/gui/tools/batchRun.py
|
||||
@@ -1,5 +1,5 @@
|
||||
-__copyright__ = "Copyright (C) 2013 David Braam - Released under terms of the AGPLv3 License"
|
||||
from __future__ import absolute_import
|
||||
+__copyright__ = "Copyright (C) 2013 David Braam - Released under terms of the AGPLv3 License"
|
||||
|
||||
import wx, os, multiprocessing, threading, time, shutil
|
||||
|
||||
diff --git a/gui/util/toolbarUtil.py b/gui/util/toolbarUtil.py
|
||||
index b4934a4..93e1881 100644
|
||||
--- a/gui/util/toolbarUtil.py
|
||||
+++ b/gui/util/toolbarUtil.py
|
||||
@@ -1,6 +1,6 @@
|
||||
-__copyright__ = "Copyright (C) 2013 David Braam - Released under terms of the AGPLv3 License"
|
||||
from __future__ import absolute_import
|
||||
from __future__ import division
|
||||
+__copyright__ = "Copyright (C) 2013 David Braam - Released under terms of the AGPLv3 License"
|
||||
|
||||
import wx
|
||||
from wx.lib import buttons
|
||||
13
cura-hbk-firmware-missing.patch
Normal file
13
cura-hbk-firmware-missing.patch
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
diff --git a/Cura/gui/firmwareInstall.py b/Cura/gui/firmwareInstall.py
|
||||
index 1dcac27..d1bc939 100644
|
||||
--- a/Cura/gui/firmwareInstall.py
|
||||
+++ b/Cura/gui/firmwareInstall.py
|
||||
@@ -20,7 +20,7 @@ def getDefaultFirmware(machineIndex = None):
|
||||
if profile.getMachineSettingFloat('extruder_amount', machineIndex) > 2:
|
||||
return None
|
||||
if profile.getMachineSetting('has_heated_bed', machineIndex) == 'True':
|
||||
- name += '-HBK'
|
||||
+ return None
|
||||
if sys.platform.startswith('linux'):
|
||||
name += '-115200'
|
||||
else:
|
||||
|
|
@ -4,19 +4,20 @@ VERSION="$1"
|
|||
|
||||
wget "https://github.com/daid/Cura/archive/$VERSION.tar.gz" || exit 1
|
||||
|
||||
tar -xzf "$VERSION.tar.gz" || exit 1
|
||||
tar -xzf "Cura-$VERSION.tar.gz" || exit 1
|
||||
cd "Cura-$VERSION"
|
||||
|
||||
# not needed
|
||||
rm -rf scripts
|
||||
|
||||
cd Cura
|
||||
|
||||
# Remove CC BY-NC content
|
||||
# It cannot be shipped with/in Fedora, as it has use restrictions
|
||||
rm -f resources/meshes/*
|
||||
rm -f resources/example/UltimakerRobot_support.stl
|
||||
|
||||
# Remove binary locales
|
||||
rm -f resources/locale/*/LC_MESSAGES/*.mo
|
||||
|
||||
# Drop the note about the removal
|
||||
echo -e '\n\nPlease note, that files under the terms of CC BY-NC has been removed form this Fedora package for legal reasons.' >> resources/example/Attribution.txt
|
||||
|
||||
|
|
@ -28,6 +29,6 @@ sed -i 's/UltimakerRobot_support.stl/UltimakerHandle.stl/g' $FILES
|
|||
# It is binary, so it is prohibited in Fedora
|
||||
rm -rf resources/firmware
|
||||
|
||||
cd ../..
|
||||
rm -f "$VERSION.tar.gz"
|
||||
cd ..
|
||||
# rm -f "$VERSION.tar.gz"
|
||||
tar -czf Cura-$VERSION-fedora.tar.gz "Cura-$VERSION"
|
||||
|
|
|
|||
33
cura-system-paths.patch
Normal file
33
cura-system-paths.patch
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
diff --git a/Cura/util/pluginInfo.py b/Cura/util/pluginInfo.py
|
||||
index 7290c8b..52fa14b 100644
|
||||
--- a/Cura/util/pluginInfo.py
|
||||
+++ b/Cura/util/pluginInfo.py
|
||||
@@ -80,14 +80,7 @@ def setPostProcessPluginConfig(config):
|
||||
profile.putProfileSetting('plugin_config', pickle.dumps(config))
|
||||
|
||||
def getPluginBasePaths():
|
||||
- ret = []
|
||||
- if platform.system() != "Windows":
|
||||
- ret.append(os.path.expanduser('~/.cura/plugins/'))
|
||||
- if platform.system() == "Darwin" and hasattr(sys, 'frozen'):
|
||||
- ret.append(os.path.normpath(os.path.join(resources.resourceBasePath, "plugins")))
|
||||
- else:
|
||||
- ret.append(os.path.normpath(os.path.join(os.path.dirname(os.path.abspath(__file__)), '..', '..', 'plugins')))
|
||||
- return ret
|
||||
+ return [os.path.expanduser('~/.cura/plugins/'), '/usr/share/cura/plugins']
|
||||
|
||||
def getPluginList(pluginType):
|
||||
global _pluginList
|
||||
diff --git a/Cura/util/resources.py b/Cura/util/resources.py
|
||||
index e63230b..99bb5ce 100644
|
||||
--- a/Cura/util/resources.py
|
||||
+++ b/Cura/util/resources.py
|
||||
@@ -28,7 +28,7 @@ if sys.platform.startswith('darwin'):
|
||||
else:
|
||||
resourceBasePath = os.path.join(os.path.dirname(__file__), "../../resources")
|
||||
else:
|
||||
- resourceBasePath = os.path.join(os.path.dirname(__file__), "../../resources")
|
||||
+ resourceBasePath = "/usr/share/cura"
|
||||
|
||||
def getPathForResource(dir, subdir, resource_name):
|
||||
assert os.path.isdir(dir), "{p} is not a directory".format(p=dir)
|
||||
|
|
@ -1,35 +0,0 @@
|
|||
From 7884cd29c46d270c5e101f5ddb2c122ad513fe43 Mon Sep 17 00:00:00 2001
|
||||
From: daid <daid303@gmail.com>
|
||||
Date: Thu, 21 Nov 2013 22:49:02 +0100
|
||||
Subject: [PATCH] Cura 13.11.2 fails to startup without dual-extrusion. Fuck.
|
||||
|
||||
---
|
||||
Cura/gui/mainWindow.py | 5 ++++-
|
||||
1 file changed, 4 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/Cura/gui/mainWindow.py b/Cura/gui/mainWindow.py
|
||||
index d5b27a7..d58b3a6 100644
|
||||
--- a/Cura/gui/mainWindow.py
|
||||
+++ b/Cura/gui/mainWindow.py
|
||||
@@ -153,6 +153,8 @@ def __init__(self):
|
||||
if self.extruderCount > 1:
|
||||
self.headOffsetWizardMenuItem = expertMenu.Append(-1, _("Run head offset wizard..."))
|
||||
self.Bind(wx.EVT_MENU, self.OnHeadOffsetWizard, self.headOffsetWizardMenuItem)
|
||||
+ else:
|
||||
+ self.headOffsetWizardMenuItem = None
|
||||
|
||||
self.menubar.Append(expertMenu, _("Expert"))
|
||||
|
||||
@@ -308,7 +310,8 @@ def updateSliceMode(self):
|
||||
self.defaultFirmwareInstallMenuItem.Enable(firmwareInstall.getDefaultFirmware() is not None)
|
||||
if profile.getMachineSetting('machine_type') == 'ultimaker2':
|
||||
self.bedLevelWizardMenuItem.Enable(False)
|
||||
- self.headOffsetWizardMenuItem.Enable(False)
|
||||
+ if self.headOffsetWizardMenuItem is not None:
|
||||
+ self.headOffsetWizardMenuItem.Enable(False)
|
||||
self.scene.updateProfileToControls()
|
||||
|
||||
def OnPreferences(self, e):
|
||||
--
|
||||
1.8.5.1
|
||||
|
||||
77
cura-version.patch
Normal file
77
cura-version.patch
Normal file
|
|
@ -0,0 +1,77 @@
|
|||
diff --git a/Cura/util/version.py b/Cura/util/version.py
|
||||
index 0a52fc2..add5eb0 100644
|
||||
--- a/Cura/util/version.py
|
||||
+++ b/Cura/util/version.py
|
||||
@@ -17,70 +17,12 @@ except:
|
||||
from Cura.util import resources
|
||||
|
||||
def getVersion(getGitVersion = True):
|
||||
- gitPath = os.path.abspath(os.path.join(os.path.split(os.path.abspath(__file__))[0], "../.."))
|
||||
- if hasattr(sys, 'frozen'):
|
||||
- versionFile = os.path.normpath(os.path.join(resources.resourceBasePath, "version"))
|
||||
- else:
|
||||
- versionFile = os.path.abspath(os.path.join(os.path.split(os.path.abspath(__file__))[0], "../version"))
|
||||
-
|
||||
- if getGitVersion:
|
||||
- try:
|
||||
- gitProcess = subprocess.Popen(args = "git show -s --pretty=format:%H", shell = True, cwd = gitPath, stdout = subprocess.PIPE, stderr = subprocess.PIPE)
|
||||
- (stdoutdata, stderrdata) = gitProcess.communicate()
|
||||
-
|
||||
- if gitProcess.returncode == 0:
|
||||
- return stdoutdata
|
||||
- except:
|
||||
- pass
|
||||
-
|
||||
- gitHeadFile = gitPath + "/.git/refs/heads/SteamEngine"
|
||||
- if os.path.isfile(gitHeadFile):
|
||||
- if not getGitVersion:
|
||||
- return "dev"
|
||||
- f = open(gitHeadFile, "r")
|
||||
- version = f.readline()
|
||||
- f.close()
|
||||
- return version.strip()
|
||||
- if os.path.exists(versionFile):
|
||||
- f = open(versionFile, "r")
|
||||
- version = f.readline()
|
||||
- f.close()
|
||||
- return version.strip()
|
||||
- versionFile = os.path.abspath(os.path.join(os.path.split(os.path.abspath(__file__))[0], "../../version"))
|
||||
- if os.path.exists(versionFile):
|
||||
- f = open(versionFile, "r")
|
||||
- version = f.readline()
|
||||
- f.close()
|
||||
- return version.strip()
|
||||
- return "?" #No idea what the version is. TODO:Tell the user.
|
||||
+ return "REPLACE_THIS_IN_SPEC"
|
||||
|
||||
def isDevVersion():
|
||||
- gitPath = os.path.abspath(os.path.join(os.path.split(os.path.abspath(__file__))[0], "../../.git"))
|
||||
- hgPath = os.path.abspath(os.path.join(os.path.split(os.path.abspath(__file__))[0], "../../.hg"))
|
||||
- return os.path.exists(gitPath) or os.path.exists(hgPath)
|
||||
+ return False
|
||||
|
||||
def checkForNewerVersion():
|
||||
- if isDevVersion():
|
||||
- return None
|
||||
- try:
|
||||
- updateBaseURL = 'http://software.ultimaker.com'
|
||||
- localVersion = map(int, getVersion(False).split('.'))
|
||||
- while len(localVersion) < 3:
|
||||
- localVersion += [1]
|
||||
- latestFile = urllib2.urlopen("%s/latest.xml" % (updateBaseURL))
|
||||
- latestXml = latestFile.read()
|
||||
- latestFile.close()
|
||||
- xmlTree = ElementTree.fromstring(latestXml)
|
||||
- for release in xmlTree.iter('release'):
|
||||
- os = str(release.attrib['os'])
|
||||
- version = [int(release.attrib['major']), int(release.attrib['minor']), int(release.attrib['revision'])]
|
||||
- filename = release.find("filename").text
|
||||
- if platform.system() == os:
|
||||
- if version > localVersion:
|
||||
- return "%s/current/%s" % (updateBaseURL, filename)
|
||||
- except:
|
||||
- #print sys.exc_info()
|
||||
- return None
|
||||
return None
|
||||
|
||||
if __name__ == '__main__':
|
||||
66
cura.spec
66
cura.spec
|
|
@ -1,40 +1,41 @@
|
|||
Name: cura
|
||||
Version: 13.11.2
|
||||
Release: 2%{?dist}
|
||||
Version: 14.06
|
||||
Release: 1%{?dist}
|
||||
Summary: 3D printer control software
|
||||
|
||||
# Code is AGPLv3
|
||||
# Icons AGPLv3 https://github.com/daid/Cura/issues/231#issuecomment-12209683
|
||||
# Example models are CC-BY-SA
|
||||
# TweakAtZ.py is CC-BY-SA
|
||||
License: AGPLv3 and CC-BY-SA
|
||||
|
||||
URL: http://daid.github.com/Cura/
|
||||
|
||||
# I've stripped the source with the script in Source3
|
||||
# To remove CC BY-NC content and bundled pypy binaries
|
||||
# Already asked upstream to include free package
|
||||
# To remove CC BY-NC content
|
||||
# Upstream not willing to ship free package
|
||||
Source0: Cura-%{version}-fedora.tar.gz
|
||||
Source1: %{name}
|
||||
Source2: %{name}.desktop
|
||||
Source3: %{name}-stripper.sh
|
||||
|
||||
# SyntaxError: from __future__ imports must occur at the beginning of the file
|
||||
Patch0: %{name}-future-import-first.patch
|
||||
|
||||
# Use systems CuraEngine
|
||||
Patch1: %{name}-CuraEngine.patch
|
||||
|
||||
# UltimakerPlatforms STLs were stripped from the tarball, don't crash because of that
|
||||
Patch2: %{name}-dont-show-nc-stls.patch
|
||||
Patch0: %{name}-dont-show-nc-stls.patch
|
||||
|
||||
# FIX: Cura crashes when Ultimaker2 is chosen
|
||||
# https://github.com/daid/Cura/commit/7884cd29c46d270c5e101f5ddb2c122ad513fe43
|
||||
Patch3: %{name}-ultimaker2-crash.patch
|
||||
# Use system paths
|
||||
Patch1: %{name}-system-paths.patch
|
||||
|
||||
# Rework the logic of determining the version (didn't work)
|
||||
Patch2: %{name}-version.patch
|
||||
|
||||
# Temporarily disable HKB firmware install, as it is not yet packaged for Fedora
|
||||
Patch3: %{name}-hbk-firmware-missing.patch
|
||||
|
||||
BuildArch: noarch
|
||||
BuildRequires: python2-devel
|
||||
BuildRequires: dos2unix
|
||||
BuildRequires: desktop-file-utils
|
||||
BuildRequires: gettext
|
||||
Requires: PyOpenGL
|
||||
Requires: wxPython
|
||||
Requires: pyserial
|
||||
|
|
@ -43,7 +44,7 @@ Requires: python-power
|
|||
Requires: pypy
|
||||
Requires: ultimaker-marlin-firmware >= 13
|
||||
Requires: ultimaker2-marlin-firmware >= 13.11-2
|
||||
Requires: CuraEngine >= 13.11.2
|
||||
Requires: CuraEngine >= 14.03
|
||||
|
||||
%description
|
||||
Cura is a project which aims to be an single software solution for 3D printing.
|
||||
|
|
@ -55,26 +56,37 @@ positioning, can slice the model to G-Code, with sane editable configuration
|
|||
settings and send this G-Code to the 3D printer for printing.
|
||||
|
||||
%prep
|
||||
%setup -qn Cura-%{version}/Cura
|
||||
%setup -qn Cura-%{version}
|
||||
%patch0 -p1
|
||||
%patch1 -p1
|
||||
%patch2 -p1
|
||||
%patch3 -p2
|
||||
%patch3 -p1
|
||||
|
||||
dos2unix resources/example/Attribution.txt
|
||||
|
||||
sed -i 's/REPLACE_THIS_IN_SPEC/%{version}/' Cura/util/version.py
|
||||
|
||||
%build
|
||||
# do nothing
|
||||
# rebuild locales
|
||||
cd resources/locale
|
||||
rm *.in *.pot
|
||||
for FILE in *
|
||||
do msgfmt $FILE/LC_MESSAGES/Cura.po -o $FILE/LC_MESSAGES/Cura.mo
|
||||
rm $FILE/LC_MESSAGES/Cura.po
|
||||
done
|
||||
cd -
|
||||
|
||||
%install
|
||||
mkdir -p %{buildroot}%{python_sitelib}/Cura
|
||||
mkdir -p %{buildroot}%{_datadir}/%{name}/firmware
|
||||
mkdir -p %{buildroot}%{_datadir}/pixmaps
|
||||
mkdir -p %{buildroot}%{_datadir}/locale
|
||||
mkdir -p %{buildroot}%{_bindir}
|
||||
|
||||
cp -apr * %{buildroot}%{python_sitelib}/Cura
|
||||
rm -rf %{buildroot}%{python_sitelib}/Cura/{LICENSE,version,resources}
|
||||
cp -apr Cura/* %{buildroot}%{python_sitelib}/Cura
|
||||
rm -rf %{buildroot}%{python_sitelib}/Cura/LICENSE
|
||||
cp -apr resources/* %{buildroot}%{_datadir}/%{name}
|
||||
cp -apr plugins %{buildroot}%{_datadir}/%{name}
|
||||
cp -ap %{SOURCE1} %{buildroot}%{_bindir}
|
||||
ln -s %{_datadir}/%{name} %{buildroot}%{python_sitelib}/Cura/resources
|
||||
ln -s %{_datadir}/%{name}/%{name}.ico %{buildroot}%{_datadir}/pixmaps
|
||||
|
|
@ -83,10 +95,17 @@ for FILE in 250000-dual.hex 115200-dual.hex 250000.hex 115200.hex; do
|
|||
done
|
||||
ln -s ../../ultimaker2-marlin-firmware/MarlinUltimaker2.hex %{buildroot}%{_datadir}/%{name}/firmware/
|
||||
|
||||
# locales
|
||||
cp -ar %{buildroot}%{_datadir}/%{name}/locale/* %{buildroot}%{_datadir}/locale
|
||||
rm -rf %{buildroot}%{_datadir}/%{name}/locale
|
||||
ln -s -f %{_datadir}/locale/ %{buildroot}%{_datadir}/%{name}/ # the app expects the locale folder in here
|
||||
|
||||
desktop-file-install --dir=%{buildroot}%{_datadir}/applications %{SOURCE2}
|
||||
|
||||
%files
|
||||
%doc LICENSE resources/example/Attribution.txt
|
||||
%{find_lang} Cura
|
||||
|
||||
%files -f Cura.lang
|
||||
%doc Cura/LICENSE changelog resources/example/Attribution.txt
|
||||
%{python_sitelib}/Cura
|
||||
%{_datadir}/%{name}
|
||||
%{_datadir}/pixmaps/%{name}.ico
|
||||
|
|
@ -94,6 +113,9 @@ desktop-file-install --dir=%{buildroot}%{_datadir}/applications %{SOURCE2}
|
|||
%{_bindir}/%{name}
|
||||
|
||||
%changelog
|
||||
* Mon Jun 23 2014 Miro Hrončok <mhroncok@redhat.com> - 14.06-1
|
||||
- New version 14.06
|
||||
|
||||
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 13.11.2-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
|
||||
|
||||
|
|
|
|||
2
sources
2
sources
|
|
@ -1 +1 @@
|
|||
c58cdd3834d719fbd5a905d9b2154730 Cura-13.11.2-fedora.tar.gz
|
||||
c8ef0e793659c194a3b3965e45a18dc3 Cura-14.06-fedora.tar.gz
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue