File tree Expand file tree Collapse file tree 2 files changed +22
-7
lines changed
behavior_tests/src/cmake_target_link_libraries Expand file tree Collapse file tree 2 files changed +22
-7
lines changed Original file line number Diff line number Diff line change 1- cmake_minimum_required (VERSION 3.24 )
1+ cmake_minimum_required (VERSION 3.10 )
22project (foo LANGUAGES CXX )
33set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsycl" )
44find_program (dpct_bin_path NAMES dpct PATHS )
@@ -12,4 +12,4 @@ set(SOURCES
1212 ${CMAKE_SOURCE_DIR} /main.dp.cpp
1313)
1414add_executable (foo-bar ${SOURCES} )
15- target_link_libraries (foo-bar PUBLIC -qmkl ${DNN_LIB} )
15+ target_link_libraries (foo-bar PUBLIC -qmkl ${DNN_LIB} )
Original file line number Diff line number Diff line change @@ -21,11 +21,26 @@ def setup_test():
2121def migrate_test ():
2222 # clean previous migration output
2323 if (os .path .exists ("build" )):
24- shutil .rmtree ("build" )
25- call_subprocess (" mkdir build && cd build && cmake -DCMAKE_CXX_COMPILER=icpx ../ && make" )
26- return os .path .exists (os .path .join ("build" , "foo-bar" ))
24+ shutil .rmtree ("build" )
25+
26+ ret = call_subprocess ("mkdir build" )
27+ if not ret :
28+ print ("Error to create build folder:" , test_config .command_output )
29+
30+ ret = change_dir ("build" )
31+ if not ret :
32+ print ("Error to go to build folder:" , test_config .command_output )
33+
34+ ret = call_subprocess ("cmake -G \" Unix Makefiles\" -DCMAKE_CXX_COMPILER=icpx ../" )
35+ if not ret :
36+ print ("Error to run cmake configure:" , test_config .command_output )
37+
38+ ret = call_subprocess ("make" )
39+ if not ret :
40+ print ("Error to run build process:" , test_config .command_output )
41+
42+ return os .path .exists ("foo-bar" )
2743def build_test ():
2844 return True
2945def run_test ():
30- change_dir ("build" )
31- return call_subprocess (os .path .join (os .path .curdir , "foo-bar" ))
46+ return call_subprocess ("./foo-bar" )
You can’t perform that action at this time.
0 commit comments