|
From: ljsebald <ljs...@us...> - 2024-01-11 04:41:58
|
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 1d95eff07fa77034e006d5eb4cc6c26925ce8ef8 (commit)
via 87460c89342c52c567c45304c19356407321462f (commit)
via b5370b75ec8d7cf7c90b5f9f7ee99414f064e64c (commit)
via f9e296e6071e9cf63dbb25abc682d4e8bf18b2d5 (commit)
via fc3392e7e26e987670f2309b9e815d2348dd567b (commit)
via 37072da716aefcbe89bbf26985c71cfffd0068bb (commit)
via 0018443b3dfd30ce451130bca0ad17a382797637 (commit)
via f3e3e213ca0cbecc01875340b5cd72b244c93dc2 (commit)
via 9e47264c7fe2f34f81945c58ea6e2d1ec6d9ee6d (commit)
from 95a16abc543b202cdbe3597883df441e93c06ab4 (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 1d95eff07fa77034e006d5eb4cc6c26925ce8ef8
Merge: 87460c8 f3e3e21
Author: Lawrence Sebald <ljs...@us...>
Date: Wed Jan 10 23:40:59 2024 -0500
Merge pull request #451 from KallistiOS/chain-upgrades
dc-chain: Allow fp precision adjustments; update configurations
commit 87460c89342c52c567c45304c19356407321462f
Merge: b5370b7 37072da
Author: Lawrence Sebald <ljs...@us...>
Date: Wed Jan 10 23:39:43 2024 -0500
Merge pull request #458 from KallistiOS/cmake_update
Fixed Romdisks and Added Bin2Object Support to CMake Toolchain
commit b5370b75ec8d7cf7c90b5f9f7ee99414f064e64c
Merge: f9e296e 0018443
Author: Lawrence Sebald <ljs...@us...>
Date: Wed Jan 10 23:38:35 2024 -0500
Merge pull request #455 from KallistiOS/abort_retval
Changed abort() to call arch_abort()
commit f9e296e6071e9cf63dbb25abc682d4e8bf18b2d5
Merge: fc3392e 9e47264
Author: Lawrence Sebald <ljs...@us...>
Date: Wed Jan 10 23:37:45 2024 -0500
Merge pull request #449 from KallistiOS/newnewlib
Add support for Newlib 4.4.0
commit fc3392e7e26e987670f2309b9e815d2348dd567b
Author: Andy Barajas <and...@gm...>
Date: Wed Jan 10 20:36:30 2024 -0800
Fix serpent_dma example (#448)
* Update sq usage in example
commit 37072da716aefcbe89bbf26985c71cfffd0068bb
Author: Falco Girgis <gyr...@gm...>
Date: Wed Jan 10 15:50:53 2024 -0600
CMake Toolchain Update
- Toolchain now supports the new romdisk model
- Toolchain automatically includes the CMake utility file containing
other functions
- All functions are namespace scoped by kos_
- genromfs is no longer accessed via the environment variable, so only
KOS_BASE needs to be set in the toolchain as an external env variable
- kos_add_binary() was added as a wrapper around bin2o which adds the
resulting object file to the target automatically
commit 0018443b3dfd30ce451130bca0ad17a382797637
Author: Falco Girgis <gyr...@gm...>
Date: Tue Jan 9 01:35:11 2024 -0600
Changed abort() to call arch_abort()
- abort() should 1) not return a successful result code 2) should not
invoke the atexit() finalizers upon being called, both of which were
happening
- Changed abort() to call arch_abort(), which is a hasty shutdown
without calling atexit() finalizers that will also return
EXIT_FAILURE.
commit f3e3e213ca0cbecc01875340b5cd72b244c93dc2
Author: darc <da...@pr...>
Date: Thu Jan 4 15:47:41 2024 -0600
dc-chain: Allow fp precision adjustments; update configurations
commit 9e47264c7fe2f34f81945c58ea6e2d1ec6d9ee6d
Author: darc <da...@pr...>
Date: Wed Jan 3 22:44:06 2024 -0600
Add support for Newlib 4.4.0
-----------------------------------------------------------------------
Summary of changes:
AUTHORS | 4 +-
examples/dreamcast/parallax/serpent_dma/serpent.c | 7 ++-
kernel/libc/koslib/abort.c | 10 ++--
kernel/libc/newlib/newlib_getentropy.c | 8 +++
utils/cmake/dreamcast.cmake | 58 +++++++++++++++++-----
utils/cmake/dreamcast.toolchain.cmake | 20 +++-----
utils/dc-chain/config/README.md | 14 +++---
utils/dc-chain/config/config.mk.10.5.0.sample | 23 +++++++--
utils/dc-chain/config/config.mk.11.4.0.sample | 23 +++++++--
utils/dc-chain/config/config.mk.12.3.0.sample | 23 +++++++--
...mk.devel.sample => config.mk.13.2.1-dev.sample} | 42 ++++++++++------
...mk.devel.sample => config.mk.14.0.1-dev.sample} | 31 +++++++++---
...legacy.sample => config.mk.4.7.4-legacy.sample} | 23 +++++++--
....9.3.0.sample => config.mk.9.3.0-legacy.sample} | 23 +++++++--
...-latest.sample => config.mk.9.5.0-winxp.sample} | 23 +++++++--
utils/dc-chain/config/config.mk.stable.sample | 23 +++++++--
utils/dc-chain/docker/Dockerfile | 2 +-
.../{gcc-devel-kos.diff => gcc-13.2.1-kos.diff} | 50 +++++++++----------
.../{gcc-devel-kos.diff => gcc-14.0.1-kos.diff} | 56 ++++++++++-----------
...120-kos.diff => newlib-4.4.0.20231231-kos.diff} | 42 ++++++++--------
utils/dc-chain/scripts/build.mk | 2 +-
21 files changed, 332 insertions(+), 175 deletions(-)
copy utils/dc-chain/config/{config.mk.devel.sample => config.mk.13.2.1-dev.sample} (84%)
rename utils/dc-chain/config/{config.mk.devel.sample => config.mk.14.0.1-dev.sample} (86%)
rename utils/dc-chain/config/{config.mk.legacy.sample => config.mk.4.7.4-legacy.sample} (89%)
rename utils/dc-chain/config/{config.mk.9.3.0.sample => config.mk.9.3.0-legacy.sample} (89%)
rename utils/dc-chain/config/{config.mk.winxp-latest.sample => config.mk.9.5.0-winxp.sample} (89%)
copy utils/dc-chain/patches/{gcc-devel-kos.diff => gcc-13.2.1-kos.diff} (70%)
rename utils/dc-chain/patches/{gcc-devel-kos.diff => gcc-14.0.1-kos.diff} (69%)
copy utils/dc-chain/patches/{newlib-4.3.0.20230120-kos.diff => newlib-4.4.0.20231231-kos.diff} (80%)
diff --git a/AUTHORS b/AUTHORS
index 8e8923d..0110f61 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -42,11 +42,11 @@ Josh Pearson: 2013, 2014, 2015, 2016
Joe Fenton: 2016
Stefan Galowicz: 2016, 2017
Luke Benstead: 2020, 2021, 2022, 2023
-Eric Fradella: 2023
+Eric Fradella: 2023, 2024
Falco Girgis: 2023
Ruslan Rostovtsev: 2014, 2016, 2023
Colton Pawielski: 2023
-Andy Barajas: 2023
+Andy Barajas: 2023, 2024
Paul Cercueil: 2023
Files with Specific licenses:
diff --git a/examples/dreamcast/parallax/serpent_dma/serpent.c b/examples/dreamcast/parallax/serpent_dma/serpent.c
index 0a2736d..741513f 100644
--- a/examples/dreamcast/parallax/serpent_dma/serpent.c
+++ b/examples/dreamcast/parallax/serpent_dma/serpent.c
@@ -129,10 +129,8 @@ static void draw_sphere(sphere_t *s, int list) {
/* Transform and write vertices to the TA via the store queues */
vd = (pvr_vertex_t *)pvr_vertbuf_tail(list);
- QACR0 = ((((uint32)vd) >> 26) << 2) & 0x1c;
- QACR1 = ((((uint32)vd) >> 26) << 2) & 0x1c;
- sqd = (void *)
- (0xe0000000 | (((uint32)vd) & 0x03ffffe0));
+ sq_lock(vd);
+ sqd = (void *) SQ_MASK_DEST_ADDR(vd);
/* {
int o = irq_disable();
printf("transforming to %p, len %d\n",
@@ -141,6 +139,7 @@ static void draw_sphere(sphere_t *s, int list) {
} */
mat_transform_sq(v, sqd, s->stacks * (s->slices + 2));
+ sq_unlock();
pvr_vertbuf_written(list, 32 * s->stacks * (s->slices + 2));
diff --git a/kernel/libc/koslib/abort.c b/kernel/libc/koslib/abort.c
index d7cab16..da46bfd 100644
--- a/kernel/libc/koslib/abort.c
+++ b/kernel/libc/koslib/abort.c
@@ -1,15 +1,17 @@
/* KallistiOS ##version##
abort.c
- (c)2001 Megan Potter
-
+ Copyright (C) 2001 Megan Potter
+ Copyright (C) 2024 Falco Girgis
*/
#include <stdlib.h>
#include <arch/arch.h>
-/* This is probably the closest mapping we've got for abort() */
+/* abort() causes abnormal/erroneous program termination
+ WITHOUT calling the atexit() handlers. This will eventually
+ return EXIT_FAILURE as the program's return code. */
__used void abort(void) {
- arch_exit();
+ arch_abort();
}
diff --git a/kernel/libc/newlib/newlib_getentropy.c b/kernel/libc/newlib/newlib_getentropy.c
index 5345182..add21b4 100644
--- a/kernel/libc/newlib/newlib_getentropy.c
+++ b/kernel/libc/newlib/newlib_getentropy.c
@@ -12,7 +12,15 @@
#include <arch/arch.h>
+/* We provide getentropy() if using Newlib < 4.4.0 */
+#if __NEWLIB__ < 4 || (__NEWLIB__ == 4 && __NEWLIB_MINOR__ < 4)
int getentropy(void *ptr, size_t len) {
+#else
+/* getentropy() is provided by Newlib >= 4.4.0,
+ but we must provide _getentropy_r() */
+int _getentropy_r(void *re, void *ptr, size_t len) {
+ (void)re;
+#endif
const int block_size = 128;
struct timeval tv;
uint8_t *src = ((uint8_t *)_arch_mem_top);
diff --git a/utils/cmake/dreamcast.cmake b/utils/cmake/dreamcast.cmake
index 8095511..97d8ffd 100644
--- a/utils/cmake/dreamcast.cmake
+++ b/utils/cmake/dreamcast.cmake
@@ -1,9 +1,40 @@
cmake_minimum_required(VERSION 3.23)
+### Helper Function for Bin2Object ###
+function(kos_bin2o inFile symbol)
+ # outFile is optional and defaults to the symbol name in the build directory
+ if(NOT ${ARGC} EQUAL 3)
+ set(outFile ${CMAKE_CURRENT_BINARY_DIR}/${symbol}.o)
+ else()
+ set(outFile ${ARGN})
+ endif()
+
+ # Custom Command to generate romdisk object file from image
+ add_custom_command(
+ OUTPUT ${outFile}
+ DEPENDS ${inFile}
+ COMMAND $ENV{KOS_BASE}/utils/bin2o/bin2o ${inFile} ${symbol} ${outFile}
+ )
+endfunction()
+
+function(kos_add_binary target inFile symbol)
+ set(outFile ${CMAKE_BINARY_DIR}/${symbol}.o)
+ kos_bin2o(${inFile} ${symbol} ${outFile})
+ target_sources(${target} PRIVATE ${outFile})
+endfunction()
+
### Helper Function for Generating Romdisk ###
-function(generate_romdisk target romdiskName romdiskPath)
- set(obj ${CMAKE_CURRENT_BINARY_DIR}/${romdiskName}.o)
- set(img ${CMAKE_CURRENT_BINARY_DIR}/${romdiskName}.img)
+function(kos_add_romdisk target romdiskPath)
+ # Name is optional and defaults to "romdisk"
+ if(NOT ${ARGC} EQUAL 3)
+ set(romdiskName romdisk)
+ else()
+ set(romdiskName ${ARGN})
+ endif()
+
+ set(obj ${CMAKE_CURRENT_BINARY_DIR}/${romdiskName}.o)
+ set(obj_tmp ${CMAKE_CURRENT_BINARY_DIR}/${romdiskName}_tmp.o)
+ set(img ${CMAKE_CURRENT_BINARY_DIR}/${romdiskName}.img)
# Variable holding all files in the romdiskPath folder
# CONFIGURE_DEPENDS causes the folder to always be rechecked
@@ -16,16 +47,19 @@ function(generate_romdisk target romdiskName romdiskPath)
# Only run when folder contents have changed by depending on
# the romdiskFiles variable
add_custom_command(
- OUTPUT ${img}
- COMMAND $ENV{KOS_GENROMFS} -f ${img} -d ${romdiskPath} -v
+ OUTPUT ${img}
DEPENDS ${romdiskFiles}
-)
+ COMMAND $ENV{KOS_BASE}/utils/genromfs/genromfs -f ${img} -d ${romdiskPath} -v
+ )
+
+ kos_bin2o(${img} ${romdiskName} ${obj_tmp})
- # Custom Command to generate romdisk object file from image
-add_custom_command(
- OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${romdiskName}.o
- COMMAND $ENV{KOS_BASE}/utils/bin2o/bin2o ${img} ${romdiskName} ${obj}
- DEPENDS ${img}
+ # Custom Command to generate romdisk object file from image
+ add_custom_command(
+ OUTPUT ${obj}
+ DEPENDS ${obj_tmp}
+ COMMAND ${CMAKE_C_COMPILER} -o ${obj} -r ${obj_tmp} -L${KOS_BASE}/lib/dreamcast -Wl,--whole-archive -lromdiskbase
+ COMMAND rm ${obj_tmp}
)
# Append romdisk object to target
@@ -33,7 +67,7 @@ add_custom_command(
endfunction()
### Function to Enable SH4 Math Optimizations ###
-function(enable_sh4_math)
+function(kos_enable_sh4_math)
if(NOT ${PLATFORM_DREAMCAST})
message(WARN " PLATFORM_DREAMCAST not set, skipping SH4 Math flags")
return()
diff --git a/utils/cmake/dreamcast.toolchain.cmake b/utils/cmake/dreamcast.toolchain.cmake
index 08fbb0c..ea1e27b 100644
--- a/utils/cmake/dreamcast.toolchain.cmake
+++ b/utils/cmake/dreamcast.toolchain.cmake
@@ -68,18 +68,12 @@ set(CMAKE_FIND_LIBRARY_SUFFIXES ".a")
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
##### Add Platform-Specific #defines #####
-ADD_DEFINITIONS(
- -D__DREAMCAST__
- -D_arch_dreamcast
-)
+add_compile_definitions(__DREAMCAST__ _arch_dreamcast)
if(${KOS_SUBARCH} MATCHES naomi)
- ADD_DEFINITIONS(
- -D__NAOMI__
- -D_arch_sub_naomi
- )
+ add_compile_definitions(__NAOMI__ _arch_sub_naomi)
else()
- ADD_DEFINITIONS(-D_arch_sub_pristine)
+ add_compile_definitions(_arch_sub_pristine)
endif()
##### Configure Build Flags #####
@@ -99,7 +93,7 @@ set(CMAKE_ASM_FLAGS_RELEASE "")
##### Configure Include Directories #####
set(CMAKE_SYSTEM_INCLUDE_PATH "${CMAKE_SYSTEM_INCLUDE_PATH} ${KOS_BASE}/include ${KOS_BASE}/kernel/arch/dreamcast/include ${KOS_BASE}/addons/include ${KOS_PORTS}/include")
-INCLUDE_DIRECTORIES(
+include_directories(
$ENV{KOS_BASE}/include
$ENV{KOS_BASE}/kernel/arch/dreamcast/include
$ENV{KOS_BASE}/addons/include
@@ -117,11 +111,13 @@ endif()
add_link_options(-ml -m4-single-only -Wl,--gc-sections -nodefaultlibs)
-LINK_DIRECTORIES(
+link_directories(
${KOS_BASE}/lib/dreamcast
${KOS_BASE}/addons/lib/dreamcast
${KOS_PORTS}/lib
)
add_link_options(-L${KOS_BASE}/lib/dreamcast -L${KOS_BASE}/addons/lib/dreamcast -L${KOS_PORTS}/lib)
-LINK_LIBRARIES(-Wl,--start-group -lstdc++ -lkallisti -lc -lgcc -Wl,--end-group m)
+link_libraries(-Wl,--start-group -lstdc++ -lkallisti -lc -lgcc -Wl,--end-group -lm)
+
+include("${KOS_BASE}/utils/cmake/dreamcast.cmake")
diff --git a/utils/dc-chain/config/README.md b/utils/dc-chain/config/README.md
index 8674b15..14356e7 100644
--- a/utils/dc-chain/config/README.md
+++ b/utils/dc-chain/config/README.md
@@ -2,16 +2,16 @@ The available templates include the following configurations:
| filename | sh4 gcc | newlib | sh4 binutils | arm gcc | arm binutils | notes |
|---------:|:-------:|:----------:|:------------:|:-------:|:----------------:|:------|
-| config.mk.legacy.sample | 4.7.4 | 2.0.0 | 2.34 | 4.7.4 | 2.34 | older toolchain based on GCC 4<br />former "stable" / "legacy" configuration<br /> [some issues may happen in C++](https://dcemulation.org/phpBB/viewtopic.php?f=29&t=104724) |
-| config.mk.9.3.0.sample | 9.3.0 | 3.3.0 | 2.34 | 8.4.0 | 2.34 | older toolchain based on GCC 9<br />former "stable" configuration |
-| config.mk.winxp-latest.sample | 9.5.0 | 4.3.0 | 2.34 | 8.5.0 | 2.34 | latest WinXP-compatible toolchain with GCC 9 |
+| config.mk.4.7.4-legacy.sample | 4.7.4 | 2.0.0 | 2.34 | 4.7.4 | 2.34 | older toolchain based on GCC 4<br />former "stable" / "legacy" configuration<br /> [some issues may happen in C++](https://dcemulation.org/phpBB/viewtopic.php?f=29&t=104724) |
+| config.mk.9.3.0-legacy.sample | 9.3.0 | 3.3.0 | 2.34 | 8.4.0 | 2.34 | older toolchain based on GCC 9<br />former "stable" configuration |
+| config.mk.9.5.0-winxp.sample | 9.5.0 | 4.3.0 | 2.34 | 8.5.0 | 2.34 | latest WinXP-compatible toolchain with GCC 9 |
| config.mk.10.5.0.sample | 10.5.0 | 4.3.0 | 2.41 | 8.5.0 | 2.41 | modern toolchain with GCC 10 |
| config.mk.11.4.0.sample | 11.4.0 | 4.3.0 | 2.41 | 8.5.0 | 2.41 | modern toolchain with GCC 11 |
| config.mk.12.3.0.sample | 12.3.0 | 4.3.0 | 2.41 | 8.5.0 | 2.41 | modern toolchain with GCC 12 |
-| **config.mk.stable.sample** | **13.2.0** | **4.3.0** | **2.41** | **8.5.0** | **2.41** | **modern toolchain with GCC 13**<br />**current "stable" configuration** |
-| config.mk.testing.sample | X | X | X | X | X | most recent GCC release<br />currently none in testing |
-| config.mk.devel.sample | git | 4.3.0 | 2.41 | 8.5.0 | 2.41 | latest dev version from git<br />builds as of 2023-07-30 |
+| **config.mk.stable.sample** | **13.2.0** | **4.3.0** | **2.41** | **8.5.0** | **2.41** | **modern toolchain with GCC 13.2.0 release**<br />**current "stable" configuration** |
+| config.mk.13.2.1-dev.sample | 13.2.1 (git) | 4.4.0 | 2.41 | 8.5.0 | 2.41 | latest GCC 13 development version from git<br />known to build without issues |
+| config.mk.14.0.1-dev.sample | 14.0.1 (git) | 4.4.0 | 2.41 | 8.5.0 | 2.41 | latest GCC 14 development version from git<br />builds with caveats, see sample file for more info |
-The **stable** configuration is the primary, widely tested target for KallistiOS, and is the most recent toolchain configuration known to work with all example programs. The **testing** configuration contains the most recent release of GCC that builds KallistiOS and the 2ndmix example, and is without any known major issues. The **legacy** configuration contains an older version of the toolchain that may be useful in compiling older software. The alternative configurations are maintained at a low priority and are not guaranteed to build, but feel free to open a bug report if issues are encountered building one of these configurations.
+The **stable** configuration is the primary, widely tested target for KallistiOS, and is the most recent toolchain configuration known to work with all example programs. The **legacy** configurations contain an older versions of the toolchain that may be useful in compiling older software. The non-"stable" alternative configurations are maintained at a lower priority and are not guaranteed to build, but feel free to open a bug report if issues are encountered building one of these configurations.
Please note that if you choose to install an older version of the GCC compiler, you may be required to use older versions of some of the prerequisites in certain configurations. For instance, building GCC `4.7.4` may require an older version of the `flex` tool be installed. If you receive errors about tools you have installed, check your system's package manager for an older version of that tool. Depending on availability, it may not be possible to build older versions of the toolchain on your platform.
diff --git a/utils/dc-chain/config/config.mk.10.5.0.sample b/utils/dc-chain/config/config.mk.10.5.0.sample
index c5805b8..937f35b 100644
--- a/utils/dc-chain/config/config.mk.10.5.0.sample
+++ b/utils/dc-chain/config/config.mk.10.5.0.sample
@@ -112,17 +112,30 @@ makejobs=-j2
# hard drive space.
pass2_languages=c,c++,objc,obj-c++
+# Floating point precision support (m4|m4-single|m4-single-only)
+# Build support for various SH4 floating-point operation ABIs. KallistiOS only
+# officially supports single-precision-only mode. Add m4 (double precision) or
+# m4-single (single precision) to build experimental support for those ABIs.
+precision_modes=m4-single-only
+#precision_modes=m4,m4-single,m4-single-only
+
+# Default floating point mode (m4|m4-single|m4-single-only)
+# Choose the default floating point precision ABI used when GCC is invoked. This
+# can be overridden by using passing -m4, -m4-single, or -m4-single-only to GCC.
+# KallistiOS currently only supports m4-single-only, so that is the default.
+default_precision=m4-single-only
+
# GCC threading model (single|kos|posix*)
-# With GCC 4.x versions and up, the patches provide a 'kos' thread model, so you
-# should use it. If you really don't want threading support for C++ (or
-# Objective C/Objective C++), you can set this to 'single'. With GCC 3.x, you
+# With GCC 4.x versions and up, the patches provide a 'kos' thread model, so you
+# should use it. If you really don't want threading support for C++ (or
+# Objective C/Objective C++), you can set this to 'single'. With GCC 3.x, you
# probably want 'posix' here; but this mode is deprecated as the GCC 3.x branch
# is not anymore supported.
thread_model=kos
# Automatic patching for KOS (1|0)
-# Uncomment this if you want to disable applying KOS patches to the toolchain
-# source files before building. This will disable usage of the 'kos' thread model.
+# Uncomment this if you want to disable applying KOS patches to the toolchain
+# source files before building. This will disable usage of the 'kos' thread model.
#use_kos_patches=0
# Automatic fixup SH-4 Newlib (1|0)
diff --git a/utils/dc-chain/config/config.mk.11.4.0.sample b/utils/dc-chain/config/config.mk.11.4.0.sample
index b3d2892..949e718 100644
--- a/utils/dc-chain/config/config.mk.11.4.0.sample
+++ b/utils/dc-chain/config/config.mk.11.4.0.sample
@@ -112,17 +112,30 @@ makejobs=-j2
# hard drive space.
pass2_languages=c,c++,objc,obj-c++
+# Floating point precision support (m4|m4-single|m4-single-only)
+# Build support for various SH4 floating-point operation ABIs. KallistiOS only
+# officially supports single-precision-only mode. Add m4 (double precision) or
+# m4-single (single precision) to build experimental support for those ABIs.
+precision_modes=m4-single-only
+#precision_modes=m4,m4-single,m4-single-only
+
+# Default floating point mode (m4|m4-single|m4-single-only)
+# Choose the default floating point precision ABI used when GCC is invoked. This
+# can be overridden by using passing -m4, -m4-single, or -m4-single-only to GCC.
+# KallistiOS currently only supports m4-single-only, so that is the default.
+default_precision=m4-single-only
+
# GCC threading model (single|kos|posix*)
-# With GCC 4.x versions and up, the patches provide a 'kos' thread model, so you
-# should use it. If you really don't want threading support for C++ (or
-# Objective C/Objective C++), you can set this to 'single'. With GCC 3.x, you
+# With GCC 4.x versions and up, the patches provide a 'kos' thread model, so you
+# should use it. If you really don't want threading support for C++ (or
+# Objective C/Objective C++), you can set this to 'single'. With GCC 3.x, you
# probably want 'posix' here; but this mode is deprecated as the GCC 3.x branch
# is not anymore supported.
thread_model=kos
# Automatic patching for KOS (1|0)
-# Uncomment this if you want to disable applying KOS patches to the toolchain
-# source files before building. This will disable usage of the 'kos' thread model.
+# Uncomment this if you want to disable applying KOS patches to the toolchain
+# source files before building. This will disable usage of the 'kos' thread model.
#use_kos_patches=0
# Automatic fixup SH-4 Newlib (1|0)
diff --git a/utils/dc-chain/config/config.mk.12.3.0.sample b/utils/dc-chain/config/config.mk.12.3.0.sample
index ef590d2..1e1560e 100644
--- a/utils/dc-chain/config/config.mk.12.3.0.sample
+++ b/utils/dc-chain/config/config.mk.12.3.0.sample
@@ -112,17 +112,30 @@ makejobs=-j2
# hard drive space.
pass2_languages=c,c++,objc,obj-c++
+# Floating point precision support (m4|m4-single|m4-single-only)
+# Build support for various SH4 floating-point operation ABIs. KallistiOS only
+# officially supports single-precision-only mode. Add m4 (double precision) or
+# m4-single (single precision) to build experimental support for those ABIs.
+precision_modes=m4-single-only
+#precision_modes=m4,m4-single,m4-single-only
+
+# Default floating point mode (m4|m4-single|m4-single-only)
+# Choose the default floating point precision ABI used when GCC is invoked. This
+# can be overridden by using passing -m4, -m4-single, or -m4-single-only to GCC.
+# KallistiOS currently only supports m4-single-only, so that is the default.
+default_precision=m4-single-only
+
# GCC threading model (single|kos|posix*)
-# With GCC 4.x versions and up, the patches provide a 'kos' thread model, so you
-# should use it. If you really don't want threading support for C++ (or
-# Objective C/Objective C++), you can set this to 'single'. With GCC 3.x, you
+# With GCC 4.x versions and up, the patches provide a 'kos' thread model, so you
+# should use it. If you really don't want threading support for C++ (or
+# Objective C/Objective C++), you can set this to 'single'. With GCC 3.x, you
# probably want 'posix' here; but this mode is deprecated as the GCC 3.x branch
# is not anymore supported.
thread_model=kos
# Automatic patching for KOS (1|0)
-# Uncomment this if you want to disable applying KOS patches to the toolchain
-# source files before building. This will disable usage of the 'kos' thread model.
+# Uncomment this if you want to disable applying KOS patches to the toolchain
+# source files before building. This will disable usage of the 'kos' thread model.
#use_kos_patches=0
# Automatic fixup SH-4 Newlib (1|0)
diff --git a/utils/dc-chain/config/config.mk.devel.sample b/utils/dc-chain/config/config.mk.13.2.1-dev.sample
similarity index 84%
copy from utils/dc-chain/config/config.mk.devel.sample
copy to utils/dc-chain/config/config.mk.13.2.1-dev.sample
index 6ca25e9..8bb10ba 100644
--- a/utils/dc-chain/config/config.mk.devel.sample
+++ b/utils/dc-chain/config/config.mk.13.2.1-dev.sample
@@ -8,21 +8,21 @@
###############################################################################
###############################################################################
### THIS CONFIG IS FOR AN EXPERIMENTAL VERSION OF GCC!
-## THERE ARE NO KNOWN ISSUES BUILDING THIS VERSION as of 2023-07-30.
+## THERE ARE NO KNOWN ISSUES BUILDING THIS VERSION as of 2024-01-04.
###############################################################################
###############################################################################
# Toolchain versions for SH
sh_binutils_ver=2.41
-sh_gcc_ver=devel
-newlib_ver=4.3.0.20230120
+sh_gcc_ver=13.2.1
+newlib_ver=4.4.0.20231231
gdb_ver=14.1
# Tarball extensions to download for SH
sh_binutils_download_type=xz
sh_gcc_download_type=git
sh_gcc_git_repo=git://gcc.gnu.org/git/gcc.git
-sh_gcc_git_branch=master
+sh_gcc_git_branch=releases/gcc-13
newlib_download_type=gz
gdb_download_type=xz
@@ -114,25 +114,37 @@ install_mode=install-strip
# detected on some OS.
makejobs=-j2
-# Languages (c|c++|objc|obj-c++|rust)
+# Languages (c|c++|objc|obj-c++)
# Set the languages to build for pass 2 of building gcc for sh-elf. The default
-# here is to build C, C++, Objective-C, Objective-C++, and Rust. You may want
-# to take out some languages if you're not worried about them and/or you're
-# short on hard drive space. Only C is required to build KallistiOS, but some
-# included examples use other languages.
-pass2_languages=c,c++,objc,obj-c++,rust
+# here is to build C, C++, Objective C, and Objective C++. You may want to take
+# out the latter two if you're not worried about them and/or you're short on
+# hard drive space.
+pass2_languages=c,c++,objc,obj-c++
+
+# Floating point precision support (m4|m4-single|m4-single-only)
+# Build support for various SH4 floating-point operation ABIs. KallistiOS only
+# officially supports single-precision-only mode. Add m4 (double precision) or
+# m4-single (single precision) to build experimental support for those ABIs.
+precision_modes=m4-single-only
+#precision_modes=m4,m4-single,m4-single-only
+
+# Default floating point mode (m4|m4-single|m4-single-only)
+# Choose the default floating point precision ABI used when GCC is invoked. This
+# can be overridden by using passing -m4, -m4-single, or -m4-single-only to GCC.
+# KallistiOS currently only supports m4-single-only, so that is the default.
+default_precision=m4-single-only
# GCC threading model (single|kos|posix*)
-# With GCC 4.x versions and up, the patches provide a 'kos' thread model, so you
-# should use it. If you really don't want threading support for C++ (or
-# Objective C/Objective C++), you can set this to 'single'. With GCC 3.x, you
+# With GCC 4.x versions and up, the patches provide a 'kos' thread model, so you
+# should use it. If you really don't want threading support for C++ (or
+# Objective C/Objective C++), you can set this to 'single'. With GCC 3.x, you
# probably want 'posix' here; but this mode is deprecated as the GCC 3.x branch
# is not anymore supported.
thread_model=kos
# Automatic patching for KOS (1|0)
-# Uncomment this if you want to disable applying KOS patches to the toolchain
-# source files before building. This will disable usage of the 'kos' thread model.
+# Uncomment this if you want to disable applying KOS patches to the toolchain
+# source files before building. This will disable usage of the 'kos' thread model.
#use_kos_patches=0
# Automatic fixup SH-4 Newlib (1|0)
diff --git a/utils/dc-chain/config/config.mk.devel.sample b/utils/dc-chain/config/config.mk.14.0.1-dev.sample
similarity index 86%
rename from utils/dc-chain/config/config.mk.devel.sample
rename to utils/dc-chain/config/config.mk.14.0.1-dev.sample
index 6ca25e9..1d11597 100644
--- a/utils/dc-chain/config/config.mk.devel.sample
+++ b/utils/dc-chain/config/config.mk.14.0.1-dev.sample
@@ -8,14 +8,16 @@
###############################################################################
###############################################################################
### THIS CONFIG IS FOR AN EXPERIMENTAL VERSION OF GCC!
-## THERE ARE NO KNOWN ISSUES BUILDING THIS VERSION as of 2023-07-30.
+## THERE IS ONE KNOWN ISSUE BUILDING THIS VERSION as of 2024-01-04:
+## 1. GCC 14.0.1 currently does not build with m4-single-only precision, which
+## is the only officially supported KOS mode for floating-point precision.
###############################################################################
###############################################################################
# Toolchain versions for SH
sh_binutils_ver=2.41
-sh_gcc_ver=devel
-newlib_ver=4.3.0.20230120
+sh_gcc_ver=14.0.1
+newlib_ver=4.4.0.20231231
gdb_ver=14.1
...<truncated>...
hooks/post-receive
--
A pseudo Operating System for the Dreamcast.
|