From: nallath Date: Tue, 4 Mar 2014 09:00:55 +0000 (+0100) Subject: Fixed bug where development version did not found CuraEngine X-Git-Tag: 14.03~17^2~11 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=9abdbddc134b7f6609a0d37c4adfbd4d813929e6;p=cura.git Fixed bug where development version did not found CuraEngine --- diff --git a/Cura/util/sliceEngine.py b/Cura/util/sliceEngine.py index 432038dd..819b7795 100644 --- a/Cura/util/sliceEngine.py +++ b/Cura/util/sliceEngine.py @@ -40,7 +40,10 @@ def getEngineFilename(): 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')) + tempPath = os.path.abspath(os.path.join(os.path.dirname(__file__), '../..', 'CuraEngine')) + if os.path.isdir(tempPath): + tempPath = os.path.join(tempPath,'CuraEngine') + return tempPath class EngineResult(object): """ @@ -546,4 +549,5 @@ class Engine(object): su.wShowWindow = subprocess.SW_HIDE kwargs['startupinfo'] = su kwargs['creationflags'] = 0x00004000 #BELOW_NORMAL_PRIORITY_CLASS + print cmdList return subprocess.Popen(cmdList, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE, **kwargs)