mirror of
https://github.com/kidfromjupiter/nearby.git
synced 2026-09-14 22:56:12 -04:00
85 lines
1.3 KiB
CMake
85 lines
1.3 KiB
CMake
add_library(platform_utils STATIC
|
|
)
|
|
|
|
target_sources(platform_utils
|
|
PRIVATE
|
|
base64_utils.cc
|
|
cancelable_alarm.cc
|
|
file_impl.cc
|
|
pipe.cc
|
|
prng.cc
|
|
reliability_utils.cc
|
|
PUBLIC
|
|
base64_utils.h
|
|
cancelable_alarm.h
|
|
file_impl.h
|
|
pipe.h
|
|
prng.h
|
|
reliability_utils.h
|
|
synchronized.h
|
|
)
|
|
|
|
target_link_libraries(platform_utils
|
|
PUBLIC
|
|
platform_api
|
|
platform_types
|
|
platform_impl_g3
|
|
platform_impl_shared_posix_lock
|
|
platform_impl_shared_posix_condition_variable
|
|
absl::strings
|
|
)
|
|
|
|
add_library(platform_types STATIC)
|
|
|
|
target_sources(platform_types
|
|
PUBLIC
|
|
byte_array.h
|
|
callable.h
|
|
cancelable.h
|
|
container_of.h
|
|
exception.h
|
|
logging.h
|
|
ptr.h
|
|
runnable.h
|
|
)
|
|
|
|
target_link_libraries(platform_types
|
|
PUBLIC
|
|
absl::base
|
|
absl::strings
|
|
)
|
|
|
|
add_executable(platform_test
|
|
byte_array_test.cc
|
|
container_of_test.cc
|
|
exception_test.cc
|
|
file_impl_test.cc
|
|
pipe_test.cc
|
|
prng_test.cc
|
|
ptr_test.cc
|
|
)
|
|
|
|
target_link_libraries(platform_test
|
|
PUBLIC
|
|
absl::base
|
|
absl::strings
|
|
absl::time
|
|
gmock
|
|
gtest
|
|
gtest_main
|
|
platform_api
|
|
platform_impl_g3
|
|
platform_types
|
|
platform_utils
|
|
)
|
|
|
|
add_test(
|
|
NAME platform_test
|
|
COMMAND platform_test
|
|
)
|
|
|
|
add_subdirectory(api)
|
|
add_subdirectory(impl/g3)
|
|
add_subdirectory(impl/shared)
|
|
add_subdirectory(port)
|