diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 12:47:08 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 12:47:08 +0000 |
commit | 29b5ab554790bb57337a3b6ab9dcd963cf69d22e (patch) | |
tree | be1456d2bc6c1fb078695fad7bc8f6b212062d3c /deps/xdiff/CMakeLists.txt | |
parent | Initial commit. (diff) | |
download | libgit2-29b5ab554790bb57337a3b6ab9dcd963cf69d22e.tar.xz libgit2-29b5ab554790bb57337a3b6ab9dcd963cf69d22e.zip |
Adding upstream version 1.7.2+ds.upstream/1.7.2+ds
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'deps/xdiff/CMakeLists.txt')
-rw-r--r-- | deps/xdiff/CMakeLists.txt | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/deps/xdiff/CMakeLists.txt b/deps/xdiff/CMakeLists.txt new file mode 100644 index 0000000..743ac63 --- /dev/null +++ b/deps/xdiff/CMakeLists.txt @@ -0,0 +1,28 @@ + +file(GLOB SRC_XDIFF "*.c" "*.h") +list(SORT SRC_XDIFF) + +add_library(xdiff OBJECT ${SRC_XDIFF}) +target_include_directories(xdiff SYSTEM PRIVATE + "${PROJECT_SOURCE_DIR}/include" + "${PROJECT_SOURCE_DIR}/src/util" + "${PROJECT_BINARY_DIR}/src/util" + ${LIBGIT2_SYSTEM_INCLUDES} + ${LIBGIT2_DEPENDENCY_INCLUDES}) + +# the xdiff dependency is not (yet) warning-free, disable warnings +# as errors for the xdiff sources until we've sorted them out +if(MSVC) + set_source_files_properties(xdiffi.c PROPERTIES COMPILE_FLAGS -WX-) + set_source_files_properties(xemit.c PROPERTIES COMPILE_FLAGS -WX-) + set_source_files_properties(xhistogram.c PROPERTIES COMPILE_FLAGS -WX-) + set_source_files_properties(xmerge.c PROPERTIES COMPILE_FLAGS -WX-) + set_source_files_properties(xutils.c PROPERTIES COMPILE_FLAGS -WX-) + set_source_files_properties(xpatience.c PROPERTIES COMPILE_FLAGS -WX-) +else() + set_source_files_properties(xdiffi.c PROPERTIES COMPILE_FLAGS "-Wno-sign-compare -Wno-unused-parameter") + set_source_files_properties(xemit.c PROPERTIES COMPILE_FLAGS "-Wno-sign-compare -Wno-unused-parameter") + set_source_files_properties(xhistogram.c PROPERTIES COMPILE_FLAGS "-Wno-sign-compare") + set_source_files_properties(xutils.c PROPERTIES COMPILE_FLAGS "-Wno-sign-compare") + set_source_files_properties(xpatience.c PROPERTIES COMPILE_FLAGS "-Wno-sign-compare") +endif() |