File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ option(V8_SNAPSHOT "turn on snapshot when building stock v8")
1212
1313
1414# cmake policies to get rid of some warnings
15- cmake_policy (SET CMP0009 NEW )
15+ cmake_policy (SET CMP0009 NEW ) # GLOB_RECURSE should no follow symlinks
1616
1717# generic cmake configuration
1818include ("cmake/configure.cmake" )
@@ -27,10 +27,12 @@ include("cmake/node_build.cmake")
2727include ("cmake/v8_build.cmake" )
2828
2929# docs
30+ ## might want to move this to doc/CMakeLists.txt
3031include ("cmake/docs.cmake" )
3132
3233# tests
33- include ("cmake/tests.cmake" )
34+ enable_testing ()
35+ add_subdirectory ("test/" )
3436
3537# package
3638include ("cmake/package.cmake" )
@@ -64,7 +66,7 @@ message(" RT library: ${RT}")
6466message (" DL library: ${DL} " )
6567
6668if (${OPENSSL_FOUND} MATCHES TRUE )
67- message (" OpenSSL: Found! " )
69+ message (" OpenSSL: ${OPENSSL_LIBRARIES} " )
6870endif ()
6971
7072# message(" CCFLAGS: ${CCFLAGS}")
Original file line number Diff line number Diff line change @@ -35,8 +35,7 @@ if(NOT SHARED_V8)
3535 PROPERTY IMPORTED_LOCATION ${PROJECT_BINARY_DIR } /deps/v8/${v8_fn} )
3636
3737
38-
39- if (CMAKE_VERSION VERSION_GREATER 2.8)
38+ if (CMAKE_VERSION VERSION_GREATER 2.8 OR CMAKE_VERSION VERSION_EQUAL 2.8)
4039 # use ExternalProject for CMake >2.8
4140 include (ExternalProject )
4241
@@ -55,7 +54,7 @@ if(NOT SHARED_V8)
5554 )
5655
5756 add_dependencies (node v8_extprj )
58- else (CAMKE_VERSION VERSION_GREATER 2.8 )
57+ else ()
5958 # copy v8 sources inefficiently with CMake versions <2.8
6059 file (GLOB_RECURSE v8_sources RELATIVE ${PROJECT_SOURCE_DIR } deps/v8/* )
6160
Original file line number Diff line number Diff line change @@ -5,7 +5,6 @@ if(!${CMAKE_USE_PTHREADS_INIT})
55 message (FATAL_ERROR "Unable to find pthreads" )
66endif ()
77
8- include_directories (${platform} )
98add_definitions (-DHAVE_CONFIG_H=1 -D_GNU_SOURCE )
109
1110check_function_exists (futimes HAVE_FUTIMES )
Original file line number Diff line number Diff line change @@ -10,12 +10,12 @@ else()
1010 get_target_property (node_bin node LOCATION)
1111endif ()
1212
13- enable_testing ()
1413file (GLOB_RECURSE node_tests ${CMAKE_SOURCE_DIR } /test/* )
1514
15+ # add all tests with add_test
1616foreach (test ${node_tests} )
17- if (test MATCHES ".*/test-[^./\ ]*.\\ .js" AND NOT test MATCHES ".*disabled.*"
18- AND NOT test MATCHES ".*pummel .*" )
17+ if (test MATCHES ".*/test-[^./\ ]*.\\ .js"
18+ AND NOT test MATCHES ".*disabled .*" )
1919
2020 # build a fancy name for each test
2121 string (REPLACE ${CMAKE_SOURCE_DIR } /test/ "" test_name ${test} )
@@ -27,6 +27,8 @@ foreach(test ${node_tests})
2727 endif ()
2828endforeach ()
2929
30+ # the CTest custom config makes ctest recreate the tmp directory before and after
31+ # each run
3032configure_file (${CMAKE_SOURCE_DIR } /cmake/CTestCustom.cmake ${CMAKE_BINARY_DIR } /CTestCustom.cmake COPYONLY )
3133
3234add_custom_command (
You can’t perform that action at this time.
0 commit comments