Skip to content

Commit

Permalink
Tweaks to boost program_options
Browse files Browse the repository at this point in the history
value<bool> required an argument (true/false), whereas bool_switch is
new (since 1.59) and is an actual switch.
  • Loading branch information
WPettersson committed Jun 25, 2021
1 parent bdbf561 commit 6f47f3d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ FIND_PACKAGE(CPLEX REQUIRED)
INCLUDE_DIRECTORIES(${CPLEX_INCLUDE_DIR})
LINK_DIRECTORIES(${CPLEX_LIBRARY_PATH})

FIND_PACKAGE(Boost 1.57.0 COMPONENTS program_options)
FIND_PACKAGE(Boost 1.59.0 COMPONENTS program_options)
INCLUDE_DIRECTORIES(${Boost_INCLUDE_DIR})

SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DDEBUG")
Expand Down
2 changes: 1 addition & 1 deletion src/aira.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ int main (int argc, char *argv[])
"If splitting, assume a normal distribution for objective values\n"
"Optional, defaults to False.")
("spread,s",
po::value<bool>(&spread)->default_value(true),
po::bool_switch(&spread)->default_value(true),
"Spread threads out over various subgroups of the symmetries (as opposed to clustering inside subgroups).\n"
"Optional, defaults to True")
("threads,t",
Expand Down

0 comments on commit 6f47f3d

Please sign in to comment.