|
FhSim
3.1.0
Marine systems simulation
|
| ID | 0070 |
| Class | BUG |
| Severity | 1 |
| Status | ready |
| Models | — |
| Found | 2026-09-26, resolving FISH-0068 |
| Decision needed |
conanfile.py:32-35: cmake_layout(self) then, for fhsim:with_visualization=False, self.folders.build = str(self.folders.build).replace("build", "build/no_vis"). Only the build folder is moved; cmake_layout has already set folders.generators to build/Release/generators, and that is not moved.build/no_vis/Release/CMakeCache.txt: CMAKE_TOOLCHAIN_FILE is ../../Release/generators/conan_toolchain.cmake, and every <pkg>_DIR is build/Release/generators, the same folder the visualisation tree uses.conan install with with_visualization=False at 12:04, build/Release/generators/FhSim-release-x86_64-data.cmake pointed at the no-vis fhsim package (conaninfo.txt: with_visualization=False). A plain cmake --build build/Release then reconfigured the visualisation tree against it: FH_VISUALIZATION was off (no render symbols in libfhsim_fisheryVis.so), every _NEEDS_GUI case failed, FhVis segfaulted in ModelStructure::RenderUpdate, and ctest failed with Simobject library file not found ... libfishery.so. A conan build with with_visualization=True restored it.The two build trees cannot be used side by side: whichever variant was installed last decides the dependencies of both, and cmake --build of the other tree silently builds the wrong variant or crashes at run time. Packaging (conan create) is not affected, as it uses its own build folder in the cache.
Move the generators folder with the build folder in layout(), e.g. self.folders.generators = os.path.join(self.folders.build, "generators") after the replace (or apply the same replace to folders.generators). Existing build/no_vis trees then need one conan install/conan build to get their own generators; the CMakePresets.json/CMakeUserPresets.json that cmake_layout writes should be checked for both variants. The same pattern may exist in the sibling repositories' recipes or in fhsim_conan.
conan install both variants in turn, then cmake --build and ctest both trees without reinstalling: both pass, and build/no_vis/Release/CMakeCache.txt names build/no_vis/Release/generators.
Low: build layout only; no source, result or package content changes.