From 68ed0b93537fc9719bc6e704c7f4ca31c5f16968 Mon Sep 17 00:00:00 2001 From: Tom van Dijk <18gatenmaker6@gmail.com> Date: Mon, 12 May 2025 20:45:38 +0200 Subject: [PATCH] build: split into build and install phase --- .gitignore | 1 + CMakeLists.txt | 4 ++++ README.md | 1 + docker/entrypoint.sh | 5 ++++- 4 files changed, 10 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index a40c129e..7a38379f 100644 --- a/.gitignore +++ b/.gitignore @@ -27,5 +27,6 @@ tools/ghidra_scripts/import.log # These entries are kept for now since that convention has not always been around. ISLE.EXE LEGO1.DLL +/result* .DS_Store diff --git a/CMakeLists.txt b/CMakeLists.txt index c4681228..8538ca01 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -472,6 +472,7 @@ if(ISLE_BUILD_LEGO1) OUT_TARGETS lego1_targets ) reccmp_add_target(lego1 ID LEGO1) + install(TARGETS lego1 DESTINATION ".") endif() if(ISLE_BUILD_BETA10) @@ -484,6 +485,7 @@ if(ISLE_BUILD_BETA10) ) reccmp_add_target(beta10 ID BETA10) target_compile_definitions(beta10 PRIVATE BETA10) + install(TARGETS beta10 DESTINATION ".") endif() if (ISLE_BUILD_APP) @@ -513,6 +515,8 @@ if (ISLE_BUILD_APP) # Make sure filenames are ALL CAPS set_property(TARGET isle PROPERTY OUTPUT_NAME ISLE) set_property(TARGET isle PROPERTY SUFFIX ".EXE") + + install(TARGETS isle DESTINATION ".") endif() if (ISLE_BUILD_CONFIG) diff --git a/README.md b/README.md index c246e850..2079bad8 100644 --- a/README.md +++ b/README.md @@ -58,6 +58,7 @@ docker run -d \ -e CMAKE_FLAGS="-DCMAKE_BUILD_TYPE=RelWithDebInfo" \ -v :/isle:rw \ -v :/build:rw \ + -v ./legobin:/install:rw \ ghcr.io/isledecomp/isle:latest ``` diff --git a/docker/entrypoint.sh b/docker/entrypoint.sh index 11d3e3ec..d9f19e3f 100644 --- a/docker/entrypoint.sh +++ b/docker/entrypoint.sh @@ -18,5 +18,8 @@ if [ "x$JOBS" = "x" ]; then fi wine cmake --build build --parallel $JOBS +# Install to /install +wine cmake --install build --prefix install + # Unlock directories -chmod -R 777 isle build +chmod -R 777 isle install