@@ -50,19 +50,6 @@ execute_process(
5050)
5151message (STATUS ${CLANG_OUTPUT} )
5252
53- execute_process (
54- COMMAND rustc --version --verbose
55- OUTPUT_VARIABLE RUSTC_OUTPUT
56- OUTPUT_STRIP_TRAILING_WHITESPACE
57- )
58- string (REGEX MATCH "LLVM version: .*" RUSTC_LLVM_VERSION_LINE "${RUSTC_OUTPUT} " )
59- string (REGEX REPLACE "LLVM version: " "" RUSTC_LLVM_VERSION "${RUSTC_LLVM_VERSION_LINE} " )
60- message (STATUS "rustc using LLVM ${RUSTC_LLVM_VERSION} " )
61-
62- if (NOT RUSTC_LLVM_VERSION STREQUAL LLVM_PACKAGE_VERSION)
63- message (WARNING "The LLVM versions used by rustc and clang are different!" )
64- endif ()
65-
6653include (${CMAKE_CURRENT_SOURCE_DIR } /cmake/rust-toolchain.cmake )
6754set (RUST_STAMP_FILE "${CMAKE_BINARY_DIR } /.rust-toolchain.stamp" )
6855
@@ -121,6 +108,13 @@ add_custom_target("check-libcc2rs"
121108 USES_TERMINAL
122109 )
123110
111+ add_custom_target ("check-libcc2rs-macros"
112+ COMMAND cargo +${RUST_STABLE_VERSION} test
113+ WORKING_DIRECTORY "${PROJECT_SOURCE_DIR } /libcc2rs-macros"
114+ DEPENDS "${RUST_STAMP_FILE} "
115+ USES_TERMINAL
116+ )
117+
124118add_custom_target ("check-unit"
125119 COMMAND ${CMAKE_COMMAND } -E env
126120 "CC=${CMAKE_C_COMPILER } "
@@ -148,7 +142,7 @@ add_custom_target("check-benchmarks"
148142 )
149143
150144add_custom_target ("check"
151- DEPENDS check-libcc2rs check-unit
145+ DEPENDS check-libcc2rs check-libcc2rs-macros check- unit
152146 )
153147
154148add_custom_target ("check-all"
0 commit comments