c-pal/win32/CMakeLists.txt

68 строки
2.1 KiB
CMake
Исходник Обычный вид История

2020-06-10 00:30:01 +03:00
#Copyright (C) Microsoft Corporation. All rights reserved.
2020-07-10 04:40:19 +03:00
set(pal_common_h_files
../common/inc/azure_c_pal/call_once.h
../common/inc/azure_c_pal/lazy_init.h
)
set(pal_common_c_files
../common/src/call_once.c
../common/src/lazy_init.c
2020-07-10 04:40:19 +03:00
)
#determining which one of the GBALLOC_LL implementations to use. By convention the file is called "gballoc_ll_" followed by "type".
string(TOLOWER "${GBALLOC_LL_TYPE}" gballoc_ll_type_lower)
set(gballoc_ll_c gballoc_ll_${gballoc_ll_type_lower}.c)
#determining which one of the GBALLOC_HL implementations to use. By convention the file is called "gballoc_hl_" followed by "type".
string(TOLOWER "${GBALLOC_HL_TYPE}" gballoc_hl_type_lower)
set(gballoc_hl_c gballoc_hl_${gballoc_hl_type_lower}.c)
2020-06-10 00:30:01 +03:00
set(pal_win32_h_files
2020-07-09 02:34:27 +03:00
${pal_common_h_files}
inc/azure_c_pal/execution_engine_win32.h
2020-06-10 00:30:01 +03:00
)
set(pal_win32_c_files
2020-07-09 02:34:27 +03:00
${pal_common_c_files}
2020-06-10 00:30:01 +03:00
src/execution_engine_win32.c
src/async_socket_win32.c
src/threadpool_win32.c
src/interlocked_win32.c
src/platform_win32.c
src/threadapi_win32.c
src/uniqueid_win32.c
src/srw_lock_win32.c
src/string_utils.c
2020-10-28 05:17:51 +03:00
src/timer_win32.c
2020-06-17 20:47:56 +03:00
src/sync_win32.c
2020-07-01 02:59:29 +03:00
src/file_win32.c
src/${gballoc_ll_c}
src/${gballoc_hl_c}
2020-06-10 00:30:01 +03:00
)
FILE(GLOB pal_win32_md_files "devdoc/*.md")
2020-07-10 04:40:19 +03:00
FILE(GLOB pal_common_md_files "../common/devdoc/*.md")
SOURCE_GROUP(devdoc FILES ${pal_win32_md_files} ${pal_common_md_files})
2020-06-10 00:30:01 +03:00
include_directories(${CMAKE_CURRENT_LIST_DIR}/inc)
2020-07-09 02:34:27 +03:00
include_directories(../common/inc)
2020-06-10 00:30:01 +03:00
add_library(pal_win32 ${pal_win32_h_files} ${pal_win32_c_files} ${pal_win32_md_files} ${pal_common_md_files})
2020-07-10 04:40:19 +03:00
target_link_libraries(pal_win32 pal_interfaces ws2_32 synchronization rpcrt4 azure_c_logging)
if(${GBALLOC_LL_TYPE} STREQUAL "MIMALLOC")
target_link_libraries(pal_win32 mimalloc-obj)
endif()
2020-08-18 05:08:48 +03:00
if(${GBALLOC_LL_TYPE} STREQUAL "JEMALLOC")
target_link_libraries(pal_win32 jemalloc)
endif()
target_include_directories(pal_win32 PUBLIC ${CMAKE_CURRENT_LIST_DIR}/inc ${CMAKE_CURRENT_LIST_DIR}/src)
2020-06-10 00:30:01 +03:00
add_subdirectory(reals)
2020-06-10 00:30:01 +03:00
add_subdirectory(tests)
add_subdirectory(../common/tests common/tests)