]> git.proxmox.com Git - libgit2.git/blob - tests/headertest/CMakeLists.txt
New upstream version 1.5.0+ds
[libgit2.git] / tests / headertest / CMakeLists.txt
1 # Header file validation project: ensure that we do not publish any sloppy
2 # definitions in our headers and that a consumer can include <git2.dll>
3 # even when they have aggressive C90 warnings enabled.
4
5 add_executable(headertest headertest.c)
6 set_target_properties(headertest PROPERTIES C_STANDARD 90)
7 set_target_properties(headertest PROPERTIES C_EXTENSIONS OFF)
8 target_include_directories(headertest PRIVATE ${LIBGIT2_INCLUDES})
9
10 if (MSVC)
11 target_compile_options(headertest PUBLIC /W4 /WX)
12 else()
13 target_compile_options(headertest PUBLIC -Wall -Wextra -pedantic -Werror)
14 endif()