diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml index 9ad23f58..2024d36e 100644 --- a/.github/workflows/cmake.yml +++ b/.github/workflows/cmake.yml @@ -12,6 +12,7 @@ on: - 'LICENSE' - 'README.md' - '.github/workflows/xmake.yml' + - 'xmake.lua' jobs: build: @@ -71,7 +72,7 @@ jobs: if: matrix.os == 'ubuntu-24.04' run: | cmake --preset debug - cmake --build --preset debug + cmake --build --preset debug -v - name: Build clice (release) if: matrix.os == 'windows-2022' diff --git a/.github/workflows/xmake.yml b/.github/workflows/xmake.yml index 0d218d04..dd3e4565 100644 --- a/.github/workflows/xmake.yml +++ b/.github/workflows/xmake.yml @@ -2,9 +2,9 @@ name: xmake on: push: - branches: [ non-existent-branch ] + branches: [ main ] pull_request: - branches: [ non-existent-branch ] + branches: [ main ] paths-ignore: - '.clang-format' - '.clangd' @@ -12,6 +12,9 @@ on: - 'LICENSE' - 'README.md' - '.github/workflows/cmake.yml' + - 'CMakeLists.txt' + - 'CMakePresets.json' + - 'cmake' jobs: linux: diff --git a/CMakeLists.txt b/CMakeLists.txt index c3b23622..5f2a1103 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -23,6 +23,10 @@ message(STATUS "Found LLVM ${LLVM_INCLUDE_DIRS}") if(CLICE_DEV) include(FetchContent) + if(CMAKE_SYSTEM_NAME STREQUAL "Linux" AND CMAKE_BUILD_TYPE STREQUAL "Debug") + # libuv option + set(ASAN ON CACHE BOOL "" FORCE) + endif() FetchContent_Declare( tomlplusplus @@ -112,7 +116,7 @@ else() endif() target_include_directories(clice-core PUBLIC "${CMAKE_SOURCE_DIR}/include") -target_link_libraries(clice-core PUBLIC uv tomlplusplus::tomlplusplus) +target_link_libraries(clice-core PUBLIC uv_a tomlplusplus::tomlplusplus) # clice executable add_executable(clice "${CMAKE_SOURCE_DIR}/src/Driver/clice.cc") diff --git a/xmake.lua b/xmake.lua index 41d00ee4..f82f3065 100644 --- a/xmake.lua +++ b/xmake.lua @@ -25,8 +25,7 @@ if has_config("dev") then end end -add_requires("llvm", "toml++") -add_requires("libuv", {configs = {shared = is_mode("debug")}}) +add_requires("llvm", "libuv", "toml++") add_rules("mode.release", "mode.debug") set_languages("c++23")