what are the “optimized;” and “;debug;” strings embedded in the $LD_LIBRARY_PATH value? Those are not normal parts of a path statement? I suspect that you added incorrect values to some of the CMake options.
These are CMake’s way of supporting more than one variant of a library so that e.g., only Debug targets in a project are linked to a Debug dependency. The creation of geant4.sh assumes a Linux/Unix system where generally this distinction doesn’t exist, or is less important.
I’m not sure why these get set in a WSL system though especially as the debug path is a directory not a library. Did you set XercesC_LIBRARY_DEBUG explicitly? That’s the only way I can think that it would have got set to this.
That’s it! I failed to configure the projest the first time and it said I should provide XercesC_INCLUDE_DIR and XercesC_LIBRARY (or something like that). So I use ccmake .
and set them in the advanced mode.
Thank you all for your help!