diff --git a/CMakeLists.txt b/CMakeLists.txt index e2c6c17e..b9fc8d2d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -85,12 +85,12 @@ endif() # OVS build mode # ################## -set_property(CACHE P4OVS_MODE PROPERTY STRINGS - "NONE;P4OVS;OVSP4RT;STUBS") - set(P4OVS_MODE "p4ovs" CACHE STRING "P4OVS build mode") string(TOLOWER "${P4OVS_MODE}" P4OVS_MODE) +set_property(CACHE P4OVS_MODE PROPERTY STRINGS + "NONE;P4OVS;OVSP4RT;STUBS") + if(NOT WITH_OVSP4RT OR P4OVS_MODE STREQUAL "none") unset(WITH_OVSP4RT) set(WITH_OVSP4RT OFF CACHE STRING "" FORCE)