File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -33,6 +33,8 @@ target_include_directories(
33
33
$<BUILD_INTERFACE:${PROJECT_SOURCE_DIR} /src/include />
34
34
$<INSTALL_INTERFACE:include >)
35
35
36
+ # If we're building this project directly (rather than as a dependency), we
37
+ # have to build tests
36
38
if (CMAKE_PROJECT_NAME STREQUAL PROJECT_NAME )
37
39
38
40
# Run configure to generate config-host.h, if configure hasn't been run
@@ -65,9 +67,9 @@ if(CMAKE_PROJECT_NAME STREQUAL PROJECT_NAME)
65
67
list (FILTER liburing_tests EXCLUDE REGEX "helpers.c" )
66
68
foreach (test_file ${liburing_tests} )
67
69
68
- # Get the name of the target
70
+ # Get the name of the target. This will be the file name, stripped of
71
+ # ".c" at the end.
69
72
get_filename_component (target ${test_file} NAME_WLE)
70
- message ("Adding test '${target} ' from test/${target} .c" )
71
73
72
74
# Create an executable target for the test; add test/helpers.c as a source
73
75
add_executable (${target} ${test_file} test /helpers.c)
You can’t perform that action at this time.
0 commit comments