30 lines
671 B
CMake
Raw Normal View History

2021-06-17 17:32:24 -04:00
project(minecraft-pi)
include(FetchContent)
## Minecraft: Pi Edition
# Download
FetchContent_Declare(
minecraft-pi
2021-07-04 19:02:45 -04:00
URL "${CMAKE_CURRENT_SOURCE_DIR}/minecraft-pi-0.1.1.tar.gz"
2021-06-17 17:32:24 -04:00
)
FetchContent_Populate(minecraft-pi)
# Install
install(
DIRECTORY "${minecraft-pi_SOURCE_DIR}/"
2022-06-09 21:31:40 -04:00
DESTINATION "${MCPI_INSTALL_DIR}/game"
USE_SOURCE_PERMISSIONS
REGEX "api" EXCLUDE
2023-11-11 00:44:26 -05:00
REGEX "data" EXCLUDE
)
2023-11-11 00:44:26 -05:00
if(NOT MCPI_HEADLESS_MODE)
install(
DIRECTORY "${minecraft-pi_SOURCE_DIR}/data/"
DESTINATION "${MCPI_INSTALL_DIR}/game/data"
USE_SOURCE_PERMISSIONS
)
endif()
2022-06-09 21:31:40 -04:00
install_symlink("game/minecraft-pi" "${MCPI_INSTALL_DIR}/minecraft-pi")