File tree Expand file tree Collapse file tree 6 files changed +1544
-5
lines changed Expand file tree Collapse file tree 6 files changed +1544
-5
lines changed Original file line number Diff line number Diff line change @@ -391,7 +391,8 @@ function(add_umf_library)
391391 ${ARG_NAME}
392392 PRIVATE ${UMF_CMAKE_SOURCE_DIR} /include
393393 ${UMF_CMAKE_SOURCE_DIR} /src/utils
394- ${UMF_CMAKE_SOURCE_DIR} /src/base_alloc)
394+ ${UMF_CMAKE_SOURCE_DIR} /src/base_alloc
395+ ${UMF_CMAKE_SOURCE_DIR} /src/coarse)
395396 add_umf_target_compile_options(${ARG_NAME} )
396397 add_umf_target_link_options(${ARG_NAME} )
397398endfunction ()
Original file line number Diff line number Diff line change @@ -16,15 +16,16 @@ set(UMF_CUDA_INCLUDE_DIR
1616# TODO: Cleanup the compile definitions across all the CMake files
1717set (UMF_COMMON_COMPILE_DEFINITIONS UMF_VERSION=${UMF_VERSION} )
1818
19- add_subdirectory (utils)
20-
21- set (UMF_LIBS $<BUILD_INTERFACE:umf_utils>)
22-
2319set (BA_SOURCES
2420 ${CMAKE_CURRENT_SOURCE_DIR} /base_alloc/base_alloc.c
2521 ${CMAKE_CURRENT_SOURCE_DIR} /base_alloc/base_alloc_linear.c
2622 ${CMAKE_CURRENT_SOURCE_DIR} /base_alloc/base_alloc_global.c)
2723
24+ add_subdirectory (utils)
25+ add_subdirectory (coarse)
26+
27+ set (UMF_LIBS $<BUILD_INTERFACE:umf_utils> $<BUILD_INTERFACE:coarse>)
28+
2829if (LINUX)
2930 set (BA_SOURCES ${BA_SOURCES}
3031 ${CMAKE_CURRENT_SOURCE_DIR} /base_alloc/base_alloc_linux.c)
@@ -145,6 +146,8 @@ else()
145146 LIBS ${UMF_LIBS} )
146147endif ()
147148
149+ add_dependencies (umf coarse)
150+
148151if (UMF_LINK_HWLOC_STATICALLY)
149152 add_dependencies (umf ${UMF_HWLOC_NAME} )
150153endif ()
Original file line number Diff line number Diff line change 1+ # Copyright (C) 2024 Intel Corporation
2+ # Under the Apache License v2.0 with LLVM Exceptions. See LICENSE.TXT.
3+ # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
4+
5+ include (${UMF_CMAKE_SOURCE_DIR} /cmake/helpers.cmake)
6+
7+ set (COARSE_SOURCES coarse.c ../ravl/ravl.c ${BA_SOURCES} )
8+
9+ add_umf_library(
10+ NAME coarse
11+ TYPE STATIC
12+ SRCS ${COARSE_SOURCES}
13+ LIBS ${UMF_LIBS} )
14+
15+ target_include_directories (
16+ coarse
17+ PRIVATE $<BUILD_INTERFACE:${PROJECT_SOURCE_DIR} /include >
18+ $<BUILD_INTERFACE:${PROJECT_SOURCE_DIR} /src>
19+ $<BUILD_INTERFACE:${PROJECT_SOURCE_DIR} /src/ravl>)
20+
21+ add_library (${PROJECT_NAME} ::coarse ALIAS coarse)
22+
23+ install (TARGETS coarse EXPORT ${PROJECT_NAME} -targets)
You can’t perform that action at this time.
0 commit comments