Aim for this project is to make it easier to generate preprocessor macros for C++ code that needs to be build against multiple incompatible versions of third party libraries or C++ standards.
Functions of interest are:
cpreproc-insert-if
: Wrap a region in a #if
preprocessor macro.
cpreproc-semver-to-hex
: Convert a semver version to a hex value. As
some c++ libraries tend to pack their version string into an hex
value, examples for this are the houdini developer kit
(hdk
) and
openvdb
.
cpreproc-if-cplusplus
: Similar to cpreproc-insert-if
. But check
for C++ standard using the long int value defined in the preprocessor
variable __cplusplus
.