Skip to content

Commit

Permalink
Merge pull request #24 from ffontaine/master
Browse files Browse the repository at this point in the history
CMakeLists.txt: add BUILD_WERROR option
  • Loading branch information
zhaojh329 authored Mar 10, 2024
2 parents c1981c9 + c0f2260 commit 683aeac
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,13 @@ include(CheckLibraryExists)
list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/Modules/")

add_definitions(-D_GNU_SOURCE -D_FILE_OFFSET_BITS=64)
add_compile_options(-O -Wall -Werror --std=gnu99)
add_compile_options(-O -Wall --std=gnu99)

option(BUILD_WERROR "Build with -Werror" ON)

if(BUILD_WERROR)
add_compile_options(-Werror)
endif()

option(BUILD_STATIC "Build static library" OFF)

Expand Down

0 comments on commit 683aeac

Please sign in to comment.