diff --git a/setup/resources.py b/setup/resources.py index 87f4c645c4..599cdccd29 100644 --- a/setup/resources.py +++ b/setup/resources.py @@ -35,7 +35,7 @@ class Coffee(Command): # {{{ help='Display the generated javascript') def run(self, opts): - from calibre.utils.coffeescript import compile_coffeescript + from calibre.utils.serve_coffee import compile_coffeescript self.compiler = compile_coffeescript self.do_coffee_compile(opts) if opts.watch: diff --git a/src/calibre/utils/ipc/launch.py b/src/calibre/utils/ipc/launch.py index 388b353e6a..982c05b065 100644 --- a/src/calibre/utils/ipc/launch.py +++ b/src/calibre/utils/ipc/launch.py @@ -66,9 +66,10 @@ class Worker(object): if isfrozen: return os.path.join(sys.executables_location, e) - c = os.path.join(sys.executables_location, e) - if os.access(c, os.X_OK): - return c + if hasattr(sys, 'executables_location'): + c = os.path.join(sys.executables_location, e) + if os.access(c, os.X_OK): + return c return e