From 2cd7f7c890803a8dff2a2e9c5e5e24332979d04b Mon Sep 17 00:00:00 2001 From: _ov4 Date: Tue, 13 Oct 2026 04:09:56 +0000 Subject: build: add script-based installation and tar.xz releases Generate the manual on installation and delegate copying to install.sh. Package the compiler, manual, installer and license using the HEAD commit's UTC timestamp and short ID, plus the target system and architecture. Co-Authored-By: Claude Fable 5.1 --- cmake/Install.cmake.in | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 cmake/Install.cmake.in (limited to 'cmake/Install.cmake.in') diff --git a/cmake/Install.cmake.in b/cmake/Install.cmake.in new file mode 100644 index 0000000..68ecb46 --- /dev/null +++ b/cmake/Install.cmake.in @@ -0,0 +1,18 @@ +# The ordinary build does not require Pandoc; generate the manual on installation. +execute_process( + COMMAND "@CMAKE_COMMAND@" --build "@CMAKE_CURRENT_BINARY_DIR@" --target doc + RESULT_VARIABLE cpsc_doc_result +) +if(NOT cpsc_doc_result STREQUAL "0") + message(FATAL_ERROR "Cannot build the manual; make sure Pandoc is installed") +endif() + +execute_process( + COMMAND sh "@CMAKE_CURRENT_SOURCE_DIR@/install.sh" + --source-dir "@CMAKE_CURRENT_BINARY_DIR@" + --prefix "${CMAKE_INSTALL_PREFIX}" + RESULT_VARIABLE cpsc_install_result +) +if(NOT cpsc_install_result STREQUAL "0") + message(FATAL_ERROR "cpsc installation failed (${cpsc_install_result})") +endif() -- cgit v1.3.1-4-g156e