|
From: kosmirror <kos...@us...> - 2025-08-06 13:46:55
|
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "A pseudo Operating System for the Dreamcast.".
The branch, master has been updated
via f68aa6ceeb9a229bb964091fb8786c88d3cd8d68 (commit)
from 0d611105f71621c9688172ca2988c77065c089c8 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit f68aa6ceeb9a229bb964091fb8786c88d3cd8d68
Author: Paul Cercueil <pa...@cr...>
Date: Tue Aug 5 01:07:16 2025 +0200
cmake: Make CMake toolchain script arch-agnostic
Rename the toolchain script kallistios.toolchain.cmake, and move all
Dreamcast-specific stuff to the Platform/dreamcast.cmake file (renamed
to match $KOS_ARCH).
Rename the utility script dreamcast.cmake to kallistios.cmake, as it did
not contain anything Dreamcast specific. Also, it is no more included
from the toolchain script, which should do the bare minimum. Projects
that wish to use the KOS specific macros should include(kallistios) now.
Signed-off-by: Paul Cercueil <pa...@cr...>
-----------------------------------------------------------------------
Summary of changes:
doc/environ.sh.sample | 2 +-
utils/build_wrappers/kos-ccmake | 2 +-
utils/build_wrappers/kos-cmake | 2 +-
utils/cmake/Platform/{Dreamcast.cmake => dreamcast.cmake} | 5 +++++
utils/cmake/{dreamcast.cmake => kallistios.cmake} | 0
.../{dreamcast.toolchain.cmake => kallistios.toolchain.cmake} | 9 ++-------
6 files changed, 10 insertions(+), 10 deletions(-)
rename utils/cmake/Platform/{Dreamcast.cmake => dreamcast.cmake} (69%)
rename utils/cmake/{dreamcast.cmake => kallistios.cmake} (100%)
rename utils/cmake/{dreamcast.toolchain.cmake => kallistios.toolchain.cmake} (92%)
diff --git a/doc/environ.sh.sample b/doc/environ.sh.sample
index e9cf952d..abfb4733 100644
--- a/doc/environ.sh.sample
+++ b/doc/environ.sh.sample
@@ -75,7 +75,7 @@ export DC_TOOLS_BASE="/opt/toolchains/dc/bin"
# Specifies the path to the toolchain file used to target
# KOS with the "cmake" build utility.
#
-export KOS_CMAKE_TOOLCHAIN="${KOS_BASE}/utils/cmake/dreamcast.toolchain.cmake"
+export KOS_CMAKE_TOOLCHAIN="${KOS_BASE}/utils/cmake/kallistios.toolchain.cmake"
# Genromfs Utility Path
#
diff --git a/utils/build_wrappers/kos-ccmake b/utils/build_wrappers/kos-ccmake
index c63d2be4..e79d1208 100755
--- a/utils/build_wrappers/kos-ccmake
+++ b/utils/build_wrappers/kos-ccmake
@@ -13,6 +13,6 @@ if [ -z "$(which ccmake)" ]; then
fi
ccmake \
- -DCMAKE_TOOLCHAIN_FILE="${KOS_BASE}/utils/cmake/${KOS_ARCH}.toolchain.cmake" \
+ -DCMAKE_TOOLCHAIN_FILE="${KOS_BASE}/utils/cmake/kallistios.toolchain.cmake" \
"$@"
diff --git a/utils/build_wrappers/kos-cmake b/utils/build_wrappers/kos-cmake
index 8db8c946..1603e15c 100755
--- a/utils/build_wrappers/kos-cmake
+++ b/utils/build_wrappers/kos-cmake
@@ -8,6 +8,6 @@ if [ -z "${KOS_BASE}" ]; then
fi
cmake \
- -DCMAKE_TOOLCHAIN_FILE="${KOS_BASE}/utils/cmake/${KOS_ARCH}.toolchain.cmake" \
+ -DCMAKE_TOOLCHAIN_FILE="${KOS_BASE}/utils/cmake/kallistios.toolchain.cmake" \
"$@"
diff --git a/utils/cmake/Platform/Dreamcast.cmake b/utils/cmake/Platform/dreamcast.cmake
similarity index 69%
rename from utils/cmake/Platform/Dreamcast.cmake
rename to utils/cmake/Platform/dreamcast.cmake
index 87e31a20..530369a7 100644
--- a/utils/cmake/Platform/Dreamcast.cmake
+++ b/utils/cmake/Platform/dreamcast.cmake
@@ -7,3 +7,8 @@ set(CMAKE_EXECUTABLE_SUFFIX .elf)
if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
set(CMAKE_INSTALL_PREFIX "" CACHE PATH "Install prefix" FORCE)
endif()
+
+set(CMAKE_SYSTEM_VERSION 1)
+set(CMAKE_SYSTEM_PROCESSOR SH4)
+set(CMAKE_SIZEOF_VOID_P 4)
+set(PLATFORM_DREAMCAST TRUE)
diff --git a/utils/cmake/dreamcast.cmake b/utils/cmake/kallistios.cmake
similarity index 100%
rename from utils/cmake/dreamcast.cmake
rename to utils/cmake/kallistios.cmake
diff --git a/utils/cmake/dreamcast.toolchain.cmake b/utils/cmake/kallistios.toolchain.cmake
similarity index 92%
rename from utils/cmake/dreamcast.toolchain.cmake
rename to utils/cmake/kallistios.toolchain.cmake
index 4ff699b6..b7e008c0 100644
--- a/utils/cmake/dreamcast.toolchain.cmake
+++ b/utils/cmake/kallistios.toolchain.cmake
@@ -7,7 +7,7 @@
# This file is to be passed to CMake when compiling a regular CMake project
# to cross-compile for the Dreamcast, using the KOS environment and settings.
#
-# cmake /path/to/src -DCMAKE_TOOLCHAIN_FILE=${KOS_BASE}/kos/utils/cmake/dreamcast.toolchain.cmake
+# cmake /path/to/src -DCMAKE_TOOLCHAIN_FILE=${KOS_BASE}/kos/utils/cmake/kallistios.toolchain.cmake
#
# or alternatively:
#
@@ -47,11 +47,7 @@ set(KOS_ADDONS ${KOS_BASE}/addons)
list(APPEND CMAKE_MODULE_PATH $ENV{KOS_BASE}/utils/cmake)
##### Configure CMake System #####
-set(CMAKE_SYSTEM_NAME Dreamcast)
-set(CMAKE_SYSTEM_VERSION 1)
-set(CMAKE_SYSTEM_PROCESSOR SH4)
-set(CMAKE_SIZEOF_VOID_P 4)
-set(PLATFORM_DREAMCAST TRUE)
+set(CMAKE_SYSTEM_NAME ${KOS_ARCH})
##### Configure Cross-Compiler #####
set(CMAKE_CROSSCOMPILING TRUE)
@@ -90,4 +86,3 @@ endif()
if(NOT DEFINED CMAKE_INSTALL_LIBDIR)
set(CMAKE_INSTALL_LIBDIR ${KOS_ADDONS}/lib/${KOS_ARCH})
endif()
-include("${KOS_BASE}/utils/cmake/dreamcast.cmake")
hooks/post-receive
--
A pseudo Operating System for the Dreamcast.
|