-
Notifications
You must be signed in to change notification settings - Fork 47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue on cmake_install.cmake with uninstall.cmake #617
Comments
Your suggested patch would disable the auto-uninstall feature in this scenario. I suggest (not tried): if(DEFINED CMAKE_CONFIGURATION_TYPES)
set(UNINSTALL_CONFIG_ARG "--config \${CMAKE_INSTALL_CONFIG_NAME}")
endif()
install(
CODE "execute_process(COMMAND \"${CMAKE_COMMAND}\" --build \"${PROJECT_BINARY_DIR}\" ${UNINSTALL_CONFIG_ARG} --target uninstall)"
) Since the |
I will try and keep you posted. |
Thanks this is working. |
I'm closing since this is fixed in #618 |
Yes. Thx. sorry I should have close it. |
Steps to reproduce the problem
Let us use a package using jrl-cmake modules as a cmake git submodule, for instance master_board_sdk, and a ros humble distro.
Compiling is ok, and the installation is going fine, but the output displays this :
Analysis
The error :
disappear if one comments the line
in
./build/master_board_sdk/cmake_install.cmake
It seems to be generated by the file
uninstall.cmake
and more specificallyjrl-cmakemodules/uninstall.cmake
Line 55 in 47b924b
When not specifying a CMAKE_BUILD_TYPE this line fails.
I have a fix here:
https://github.com/olivier-stasse/jrl-cmakemodules/blob/cf58b6616b8c28e337d1b55fd3a1e4708b6711d0/uninstall.cmake#L55
Basically if the configuration is empty, the line is not called.
Maybe it would be better to not specify the
--config
option if the variable is empty.WDYT ?
The text was updated successfully, but these errors were encountered: