[build]: add uninstall cmake target (#3511)
This commit is contained in:
parent
a470cdce4c
commit
b9f98dd8cd
3 changed files with 33 additions and 0 deletions
|
@ -37,6 +37,17 @@ include(BuildOptions)
|
|||
# Main sources directory (the second parameter sets the output directory name to raylib)
|
||||
add_subdirectory(src raylib)
|
||||
|
||||
# Uninstall target
|
||||
if(NOT TARGET uninstall)
|
||||
configure_file(
|
||||
"${CMAKE_MODULE_PATH}/Uninstall.cmake"
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake"
|
||||
IMMEDIATE @ONLY)
|
||||
|
||||
add_custom_target(uninstall
|
||||
COMMAND ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake)
|
||||
endif()
|
||||
|
||||
if (${BUILD_EXAMPLES})
|
||||
MESSAGE(STATUS "Building examples is enabled")
|
||||
add_subdirectory(examples)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue