Skip to content

Commit

Permalink
cmake: error if imcompatible options
Browse files Browse the repository at this point in the history
  • Loading branch information
caballa committed Apr 12, 2024
1 parent 147c42e commit 6759bea
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,10 @@ option(CLAM_USE_DBM_BIGNUM "Use big numbers for DBM weights" OFF)
option(CLAM_USE_DBM_SAFEINT "Use safe integers for DBM weights" OFF)
option(CLAM_INCLUDE_ALL_DOMAINS "Include all default abstract domains" ON)

if (CLAM_USE_DBM_BIGNUM AND CLAM_USE_DBM_SAFEINT)
message(FATAL_ERROR "Crab: cannot use both big numbers and safe integers for DBM weights. Choose one")
endif()

if (CLAM_USE_DBM_BIGNUM)
message(STATUS "Crab: DBM-based domains will use big numbers for representing weights")
set(USE_DBM_BIGNUM TRUE)
Expand All @@ -122,6 +126,7 @@ else()
set(USE_DBM_SAFEINT TRUE)
else()
set(USE_DBM_SAFEINT FALSE)
message(STATUS "Crab: DBM-based domains will use unsafe (i.e., they can wraparound) integers for representing weights")
endif()
endif()

Expand Down

0 comments on commit 6759bea

Please sign in to comment.