diff --git a/CMakeLists.txt b/CMakeLists.txt index 9270ddb..57c87d4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -13,8 +13,6 @@ set(CMAKE_EXPORT_COMPILE_COMMANDS ON) set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -O2 -DNDEBUG -Wall -Wextra -Wpedantic -Werror") set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DDEBUG -Wall -Wextra -Wpedantic") -set(CMAKE_C_COMPILER "/usr/bin/clang") -set(CMAKE_CXX_COMPILER "/usr/bin/clang++") find_package(PkgConfig REQUIRED) @@ -65,7 +63,13 @@ add_executable(bar main.cpp) target_link_libraries(bar bar_lib ${GTKMM_LIBRARIES} ${LAYERSHELL_LIBRARIES} ${WEBKIT_LIBRARIES} ${CURL_LIBRARIES} nlohmann_json::nlohmann_json) # ---- Tests (Catch2) ---- -find_package(Catch2 3 REQUIRED) +include(FetchContent) +FetchContent_Declare( + Catch2 + GIT_REPOSITORY https://github.com/catchorg/Catch2.git + GIT_TAG v3.5.2 # Check for the latest version if needed +) +FetchContent_MakeAvailable(Catch2) add_executable(bar_tests tests/string_helper_tests.cpp