You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, the version build metadata (i.e. commit hash) is stored in include/flamegpu/version.h, which is modified at every cmake configuration event.
This breaks out of tree builds, but is a current neccesary evil to minimise the use of the incorrect include directory for RTC compilation (potentially only for non-python RTC?)
Instead, it would be preferable if flamegpu::VERSION_BUILDMETADATA was declared in version.h and defined in a dynamic file in the build directory (i.e. build/flamegpu/version.cpp), so that the include directory is not modified by cmake.
This will prevent the use of it while checking the include directory version, instead the major, minor and prerelease version would need to be sufficient. This would be OK for users of stable releases, but may be insufficient during development.
One possible workaround for this would be to add a new CMake option, or CLI/environment varible option to ignore the jitify cache, to avoid incorrect cache hits, however it might still cause some issues during development.
Another solution would be to dynamically create version.h in the build directory, pulling in a copy of the headers and using that as the FLAMEGPU_INC_DIR?
It's unclear what is the best option.
Stop include/flamegpu/version.h from being generated by CMake
Encode the version information in the header manually, and extract into CMake. Inverting the relationship. Include the pre-release version number in the header. I.e. alpha.1 as a constexpr string literal.
Declare but do not define extern const char VERSION_BUILDMETADATA[];, implemented as static.
Adjust RTC include directory checking to not consider build metadata (subject to any alternatives found). Only major/minor/patch/prerelease should be sufficient?
We may want to add some form of development mode cmake version that changes RTC include directory behaviour? This could include embeding the include/ directory in binaries (1.5MB currently)? Continuing without for now.
Generate build/flamegpu/version.cpp via CMake at configure time, including the git commit hash as build meta data, embedding the build metadata in the static library.
The text was updated successfully, but these errors were encountered:
After a discussion it was agreed to proceed without the opt-in metadata include directory check, as the RTC API should be stable enough that this isn't a problem. If it does turn out to be an issue, we could potentially do one or more of:
Add an cmake configuraiton option for a developer mode, which will embed the version in the include directory
Copy the include directory into the build directory, which would be found before the parent include dir (if the appropriate env var is not set). Might lead to other issues, such as editing the wrong files, or running without reconfiguring and being thrown off.
Currently, the version build metadata (i.e. commit hash) is stored in
include/flamegpu/version.h
, which is modified at every cmake configuration event.This breaks out of tree builds, but is a current neccesary evil to minimise the use of the incorrect include directory for RTC compilation (potentially only for non-python RTC?)
Instead, it would be preferable if
flamegpu::VERSION_BUILDMETADATA
was declared inversion.h
and defined in a dynamic file in the build directory (i.e.build/flamegpu/version.cpp
), so that the include directory is not modified by cmake.This will prevent the use of it while checking the include directory version, instead the major, minor and prerelease version would need to be sufficient. This would be OK for users of stable releases, but may be insufficient during development.
One possible workaround for this would be to add a new CMake option, or CLI/environment varible option to ignore the jitify cache, to avoid incorrect cache hits, however it might still cause some issues during development.
Another solution would be to dynamically create
version.h
in the build directory, pulling in a copy of the headers and using that as theFLAMEGPU_INC_DIR
?It's unclear what is the best option.
include/flamegpu/version.h
from being generated by CMakealpha.1
as a constexpr string literal.extern const char VERSION_BUILDMETADATA[];
, implemented as static.We may want to add some form of development mode cmake version that changes RTC include directory behaviour? This could include embeding theContinuing without for now.include/
directory in binaries (1.5MB currently)?build/flamegpu/version.cpp
via CMake at configure time, including the git commit hash as build meta data, embedding the build metadata in the static library.The text was updated successfully, but these errors were encountered: