File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -9,6 +9,14 @@ include_directories(${CMAKE_CURRENT_BINARY_DIR}/include) # Tablegen'd files
99include_directories (${Python3_INCLUDE_DIR} )
1010include_directories (${pybind11_INCLUDE_DIR} )
1111
12+ function (add_symlink source_file link_name )
13+ if (EXISTS ${source_file} )
14+ file (CREATE_LINK ${source_file} ${link_name} SYMBOLIC )
15+ else ()
16+ message (WARNING "${source_file} not found. Skipping symlink creation for ${link_name} ." )
17+ endif ()
18+ endfunction ()
19+
1220add_subdirectory (include )
1321add_subdirectory (lib )
1422add_subdirectory (test )
@@ -28,6 +36,6 @@ cmake_path(APPEND CMAKE_SOURCE_DIR "python" "test" "unit" "language" "test_core.
2836cmake_path (APPEND CMAKE_SOURCE_DIR "python" "test" "unit" "language" "test_annotations.py" OUTPUT_VARIABLE TRITON_TEST_ANNOTATIONS )
2937cmake_path (APPEND CMAKE_SOURCE_DIR ".clang-format" OUTPUT_VARIABLE TRITON_CLANG_FORMAT_SETTING )
3038
31- file ( CREATE_LINK ${TRITON_TEST_CORE} ${TRITON_SHARED_TEST_CORE} SYMBOLIC )
32- file ( CREATE_LINK ${TRITON_TEST_ANNOTATIONS} ${TRITON_SHARED_TEST_ANNOTATIONS} SYMBOLIC )
33- file ( CREATE_LINK ${TRITON_CLANG_FORMAT_SETTING} ${TRITON_SHARED_CLANG_FORMAT_SETTING} SYMBOLIC )
39+ add_symlink ( ${TRITON_TEST_CORE} ${TRITON_SHARED_TEST_CORE} )
40+ add_symlink ( ${TRITON_TEST_ANNOTATIONS} ${TRITON_SHARED_TEST_ANNOTATIONS} )
41+ add_symlink ( ${TRITON_CLANG_FORMAT_SETTING} ${TRITON_SHARED_CLANG_FORMAT_SETTING} )
You can’t perform that action at this time.
0 commit comments