Index: recipes.py |
diff --git a/recipes.py b/recipes.py |
index e71420e5d7307ac9d5dd5150456cccecbcdbc05e..092917380efe1d30abd991da98930ddf020def73 100755 |
--- a/recipes.py |
+++ b/recipes.py |
@@ -12,6 +12,7 @@ infra/config/recipes.cfg. |
import argparse |
import json |
import logging |
+import platform |
import os |
import subprocess |
import sys |
@@ -390,10 +391,11 @@ def main(): |
os.environ['RECIPES_RUN_BOOTSTRAP'] = '1' |
args = sys.argv |
- return subprocess.call( |
- [os.path.join( |
- os.path.dirname(os.path.realpath(__file__)), 'ENV/bin/python'), |
- os.path.join(ROOT_DIR, 'recipes.py')] + original_sys_argv[1:]) |
+ executable = ('python.exe' if sys.platform.lower() in ( |
+ 'win32', 'cygwin') else 'python') |
+ return subprocess.call([os.path.join( |
+ ROOT_DIR, 'ENV', 'bin', executable), |
+ os.path.join(ROOT_DIR, 'recipes.py')] + original_sys_argv[1:]) |
if args.verbose: |
logging.getLogger().setLevel(logging.INFO) |