Closed sbrkopac closed 3 years ago
@rhabacker Could you please take a look as well.
Before merging pr https://github.com/vsg-dev/VulkanSceneGraph/pull/313 builds were performed on Windows with MSVC, see e.g. https://github.com/vsg-dev/VulkanSceneGraph/runs/3524834865, which should have raised such issues. Unfortunately, they do not perform a "make install" step that should be added to the corresponding CI configuration.
Looks like when VSG_MACROS_INSTALLED is enabled then the uninstall.cmake file is skipped from the installation.
When vsgMacros.cmake is included from the top level CMakeLists.txt of the VulkanSceneGraph git repo, VSG_MACROS_INSTALLED is not set and the file uninstall.cmake is installed along with vsgMacros.cmake.
When vsgMacros.cmake
is included from vsgConfig.cmake
as a result of a call to find_package(vsg)
in a package depending on vsg, VSG_MACROS_INSTALLED is set and uninstall.cmake must not be installed, only used.
This is known to work on linux builds, see https://build.opensuse.org/package/show/home:rhabacker:branches:games/libvsg
[ 112s] /usr/bin/cmake -P cmake_install.cmake
[ 112s] -- Install configuration: "RelWithDebInfo"
[ 113s] -- Installing: /home/abuild/rpmbuild/BUILDROOT/libvsg-0.1.4.20210907.git+ca40fbdd-lp152.13.1.x86_64/usr/lib64/cmake/vsg/uninstall.cmake.
Installing that file also works with mingw builds
The only possibility I see is that -DVSG_MACROS_INSTALLED=1
has been added to the cmake command line for VulkanSceneGraph.
Adding the -DVSG_MACROS_INSTALLED=1
to my build produces the same error. It doesn't look my uninstall.cmake is being produced at all.
So it looks like what happened was I manually cleaned my build directory which is where some of the templates are sitting. When I do that - they obviously can't be found. I've created a draft pull request to put them in a more appropriate location which should prevent this from happening in the future.
Snuck in a quick change to also address #319
Describe the bug Looks like 7a4a0a06ad17027294ba4f2e1b0671c3197f9935 broke installation of VSG on windows. Looks like when VSG_MACROS_INSTALLED is enabled then the uninstall.cmake file is skipped from the installation.
Expected behavior VSG should install correctly to the target folders.
Screenshots
Additional context Add any other context about the problem here.