summaryrefslogtreecommitdiff
path: root/cmake
diff options
context:
space:
mode:
authorNikhil Marathe <nsm.nikhil@gmail.com>2010-11-23 12:16:32 +0530
committerTom Hughes <tom.hughes@palm.com>2010-11-23 23:33:20 -0600
commit1b6b090cdc63301ccd1a2b1f3105c5bde7a73cf8 (patch)
treec564f05e7c1bb11142c8618615f6074bd4e49863 /cmake
parent14e6b07f6354f0dbeabd3c723a4586bafa662cc0 (diff)
downloadnode-1b6b090cdc63301ccd1a2b1f3105c5bde7a73cf8.tar.gz
Use CMake's standard way to find Python.
Rather than have the python literal string, use CMake's find_package to find actual python executable. This is more useful if you have both Python 2 and 3 installed. CMake currently only supports python 2 and so will automatically find that version
Diffstat (limited to 'cmake')
-rw-r--r--cmake/node_build.cmake2
-rw-r--r--cmake/v8_build.cmake4
2 files changed, 3 insertions, 3 deletions
diff --git a/cmake/node_build.cmake b/cmake/node_build.cmake
index f98aa103b..72e218e0d 100644
--- a/cmake/node_build.cmake
+++ b/cmake/node_build.cmake
@@ -4,7 +4,7 @@
add_custom_command(
OUTPUT ${PROJECT_BINARY_DIR}/src/node_natives.h
- COMMAND tools/js2c.py ${PROJECT_BINARY_DIR}/src/node_natives.h ${js2c_files}
+ COMMAND ${PYTHON_EXECUTABLE} tools/js2c.py ${PROJECT_BINARY_DIR}/src/node_natives.h ${js2c_files}
DEPENDS ${js2c_files})
set(node_extra_src "src/platform_${node_platform}.cc")
diff --git a/cmake/v8_build.cmake b/cmake/v8_build.cmake
index ce86e9890..d2bb76fb9 100644
--- a/cmake/v8_build.cmake
+++ b/cmake/v8_build.cmake
@@ -43,7 +43,7 @@ if(NOT SHARED_V8)
URL ${PROJECT_SOURCE_DIR}/deps/v8
BUILD_IN_SOURCE True
- BUILD_COMMAND sh -c "${PROJECT_BINARY_DIR}/tools/scons/scons.py library=static visibility=default ${v8snapshot} mode=${v8mode} verbose=on arch=${v8arch} -j ${parallel_jobs}"
+ BUILD_COMMAND ${PYTHON_EXECUTABLE} ${PROJECT_BINARY_DIR}/tools/scons/scons.py library=static visibility=default ${v8snapshot} mode=${v8mode} verbose=on arch=${v8arch} -j ${parallel_jobs}
SOURCE_DIR ${PROJECT_BINARY_DIR}/deps/v8
# ignore this stuff, it's not needed for building v8 but ExternalProject
@@ -74,7 +74,7 @@ if(NOT SHARED_V8)
add_custom_command(
OUTPUT ${PROJECT_BINARY_DIR}/deps/v8/${v8_fn}
- COMMAND ${PROJECT_BINARY_DIR}/tools/scons/scons.py library=static visibility=default ${v8snapshot} mode=${v8mode} verbose=on arch=${v8arch} -j ${parallel_jobs}
+ COMMAND ${PYTHON_EXECUTABLE} ${PROJECT_BINARY_DIR}/tools/scons/scons.py library=static visibility=default ${v8snapshot} mode=${v8mode} verbose=on arch=${v8arch} -j ${parallel_jobs}
WORKING_DIRECTORY ${PROJECT_BINARY_DIR}/deps/v8/
DEPENDS ${v8_sources_dest}
)