Skip to content

Commit

Permalink
create libdatalog, move datalog from wpiutil
Browse files Browse the repository at this point in the history
  • Loading branch information
DeltaDizzy committed Jan 8, 2025
1 parent d429635 commit 5eece58
Show file tree
Hide file tree
Showing 13 changed files with 31 additions and 0 deletions.
2 changes: 2 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -291,6 +291,8 @@ set(WPIUNITS_DEP_REPLACE_IMPL "find_dependency(wpiunits)")
set(WPIUTIL_DEP_REPLACE "find_dependency(wpiutil)")
add_subdirectory(wpiutil)

add_subdirectory(libdatalog)

if(WITH_NTCORE)
set(NTCORE_DEP_REPLACE "find_dependency(ntcore)")
set(WPINET_DEP_REPLACE "find_dependency(wpinet)")
Expand Down
29 changes: 29 additions & 0 deletions libdatalog/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
project(libdatalog)

include(CompileWarnings)

file(
GLOB libdatalog_src
src/main/native/cpp/*.cpp
)

add_library(libdatalog ${libdatalog_src})
set_target_properties(wpiutil PROPERTIES DEBUG_POSTFIX "d")

target_compile_features(libdatalog PUBLIC cxx_std_20)
if(MSVC)
target_compile_options(
libdatalog
PUBLIC /permissive- /Zc:preprocessor /Zc:__cplusplus /Zc:throwingNew /MP /bigobj /utf-8
)
target_compile_definitions(libdatalog PRIVATE -D_CRT_SECURE_NO_WARNINGS)
endif()
wpilib_target_warnings(libdatalog)

target_include_directories(
libdatalog
PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src/main/native/include>
)

target_link_libraries(libdatalog PRIVATE wpiutil)
File renamed without changes.

0 comments on commit 5eece58

Please sign in to comment.