From 5c2c6ed825f2c8b35cedf7c612a2516bf1d6d91c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Jastrz=C4=99bski?= Date: Sun, 4 Jan 2015 18:59:12 +0100 Subject: [PATCH] Tweaked OSX hack --- kcc.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/kcc.py b/kcc.py index edd3151..34d6102 100755 --- a/kcc.py +++ b/kcc.py @@ -30,8 +30,11 @@ if sys.version_info[0] != 3: # OS specific PATH variable workarounds import os -if sys.platform.startswith('darwin') and 'RESOURCEPATH' not in os.environ: - os.environ['PATH'] = os.path.dirname(os.path.abspath(__file__)) + '/other/:' + os.environ['PATH'] +if sys.platform.startswith('darwin'): + if 'RESOURCEPATH' not in os.environ: + os.environ['PATH'] = os.path.dirname(os.path.abspath(__file__)) + '/other/:' + os.environ['PATH'] + else: + os.environ['PATH'] = './../Resources:/usr/local/bin:/usr/bin:/bin' elif sys.platform.startswith('win'): if getattr(sys, 'frozen', False): os.chdir(os.path.dirname(os.path.abspath(sys.executable)))