serac
serac copied to clipboard
deprecate/fix config-build.py
it seems there are a number of serious issues with config-build.py script:
-
our documentation is misleading or out of date, instructing users to specify the build type through
CMAKE_BUILD_TYPE
, but this variable is ignored when naming the build directory. This means that users that ask for a Release build and get a build directory that says "debug" (but is actually compiling with optimization flags)! -
config-build.py seems to delete the entire build directory if it already exists. This is incredibly dangerous, not at all documented, and completely inconsistent with the what "configuring" actually means to CMake (configuration is a nondestructive operation). One of our users recently lost a considerable amount of work because of this, and we should not let that happen again.
-
most of the options in config-build are undocumented and unnecessary (e.g. why is the build type communicated by "-bt" instead of the idiomatic CMAKE_BUILD_TYPE?). This is less clear than just configuring CMake directly.
Serac is a CMake project, do we really need a (currently dangerous) python script to pass common CMake configure flags?
We don't "need" config-build.py
, it is not required in anyway and if you don't want to use it, you don't have to. It just reduces the amount of commands needed to get you to a configured build.
I would be interested in hearing how a user lost work due to this.
I agree on the first note that our documentation is wrong if using config-build.py
.