Skip to content

Commit

Permalink
fix linux compilation
Browse files Browse the repository at this point in the history
  • Loading branch information
wwiv committed Oct 21, 2022
1 parent 4279687 commit 0d4d91e
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 6 deletions.
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ include_directories(${CMAKE_SOURCE_DIR})
include(Common)
include(FindASan)
find_package(fmt CONFIG REQUIRED)
find_package(cereal CONFIG REQUIRED)

MACRO_ENSURE_OUT_OF_SOURCE_BUILD()
ENSURE_MINIMUM_COMPILER_VERSIONS()
Expand Down
2 changes: 1 addition & 1 deletion cmake-config.sh
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,4 @@ fi
echo "Using Ninja Build Tool: ${NINJA}"
echo "Using Source Root: ${HERE}"

cmake -G "Ninja" ${HERE} "${@}"
cmake -G "Ninja" ${HERE} -DCMAKE_TOOLCHAIN_FILE=${HERE}/vcpkg/scripts/buildsystems/vcpkg.cmake "${@}"
8 changes: 4 additions & 4 deletions core/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -71,15 +71,15 @@ configure_file(version_internal.h.in version_internal.h @ONLY)

#target_compile_options(core PRIVATE /fsanitize=address)
target_link_libraries(core fmt::fmt-header-only)
target_link_libraries(core cereal::cereal)
target_link_libraries(core cereal)
target_include_directories(core PRIVATE ${CMAKE_CURRENT_BINARY_DIR})

if (UNIX)
if (CMAKE_CXX_COMPILER_ID MATCHES "Clang")
# using regular Clang or AppleClang
target_link_libraries(core INTERFACE c++fs)
target_link_libraries(core c++fs)
else()
target_link_libraries(core INTERFACE stdc++fs)
target_link_libraries(core stdc++fs)
endif()
endif()

Expand Down Expand Up @@ -139,4 +139,4 @@ if (WWIV_BUILD_TESTS)
target_link_libraries(core_tests libcx)
endif()

endif()
endif()
2 changes: 1 addition & 1 deletion vcpkg
Submodule vcpkg updated 6099 files

0 comments on commit 0d4d91e

Please sign in to comment.