Rockbox open source high quality audio player as a Music Player Daemon
mpris rockbox mpd libadwaita audio rust zig deno
2
fork

Configure Feed

Select the types of activity you want to include in your feed.

Revert "Toolchains: Update to GCC 10.5.0"

I pushed the wrong working tree AGAIN

This reverts commit b92033f716c7170febee75be309f674590c62cce.

+195 -253
+4 -3
apps/plugins/imageviewer/imageviewer.make
··· 26 26 IMGVSUBDIRS := $(call preprocess, $(IMGVSRCDIR)/SUBDIRS) 27 27 $(foreach dir,$(IMGVSUBDIRS),$(eval include $(dir)/$(notdir $(dir)).make)) 28 28 29 - IMGDECLDFLAGS = $(GLOBAL_LDOPTS) -T$(PLUGINLINK_LDS) -Wl,--gc-sections -Wl,-Map,$(IMGVBUILDDIR)/$*.refmap 29 + IMGDECLDFLAGS = -T$(PLUGINLINK_LDS) -Wl,--gc-sections -Wl,-Map,$(IMGVBUILDDIR)/$*.refmap 30 30 31 31 ifndef APP_TYPE 32 32 IMGDEC_OUTLDS = $(IMGVBUILDDIR)/%.link 33 - IMGDEC_OVLFLAGS = $(GLOBAL_LDOPTS) -T$(IMGVBUILDDIR)/$*.link -Wl,--gc-sections -Wl,-Map,$(IMGVBUILDDIR)/$*.map 33 + IMGDEC_OVLFLAGS = -T$(IMGVBUILDDIR)/$*.link -Wl,--gc-sections -Wl,-Map,$(IMGVBUILDDIR)/$*.map 34 34 else 35 - IMGDEC_OVLFLAGS = $(GLOBAL_LDOPTS) $(PLUGINLDFLAGS) -Wl,$(LDMAP_OPT),$(IMGVBUILDDIR)/$*.map 35 + IMGDEC_OVLFLAGS = $(PLUGINLDFLAGS) -Wl,$(LDMAP_OPT),$(IMGVBUILDDIR)/$*.map 36 36 endif 37 37 38 38 $(IMGVBUILDDIR)/%.ovl: $(IMGDEC_OUTLDS) ··· 52 52 $(IMGVBUILDDIR)/%.link: $(PLUGIN_LDS) $(IMGVBUILDDIR)/%.refmap 53 53 $(call PRINTS,PP $(@F))$(call preprocess2file,$<,$@,-DIMGVDECODER_OFFSET=$(shell \ 54 54 $(TOOLSDIR)/ovl_offset.pl $(IMGVBUILDDIR)/$*.refmap)) 55 +
+1 -1
apps/plugins/plugins.make
··· 149 149 PLUGINFLAGS += $(SHARED_CFLAGS) # <-- from Makefile 150 150 else 151 151 PLUGINLDFLAGS = -T$(PLUGINLINK_LDS) -Wl,--gc-sections -Wl,-Map,$*.map 152 - OVERLAYLDFLAGS = -T$(OVERLAYREF_LDS) -Wl,--gc-sections -Wl,-Map,$*.refmap $(GLOBAL_LDOPTS) 152 + OVERLAYLDFLAGS = -T$(OVERLAYREF_LDS) -Wl,--gc-sections -Wl,-Map,$*.refmap 153 153 endif 154 154 PLUGINLDFLAGS += $(GLOBAL_LDOPTS) 155 155
+1 -1
apps/plugins/sdl/sdl.make
··· 49 49 WOLF3D_OUTLDS = $(SDL_OBJDIR)/wolf3d.link 50 50 QUAKE_OUTLDS = $(SDL_OBJDIR)/quake.link 51 51 52 - SDL_OVLFLAGS = -Wl,--gc-sections -Wl,-Map,$(basename $@).map $(GLOBAL_LDOPTS) 52 + SDL_OVLFLAGS = -Wl,--gc-sections -Wl,-Map,$(basename $@).map 53 53 else 54 54 ### simulator 55 55 ROCKS += $(SDL_OBJDIR)/duke3d.rock
+6 -11
tools/configure
··· 138 138 139 139 findarmgcc() { 140 140 prefixtools arm-elf-eabi- 141 - gccchoice="10.5.0" 141 + gccchoice="4.9.4" 142 142 } 143 143 144 144 # scan the $PATH for the given command ··· 548 548 GCCOPTS="$CCOPTS -mcpu=5249 -malign-int -mstrict-align" 549 549 GCCOPTIMIZE="-fomit-frame-pointer" 550 550 endian="big" 551 - gccchoice="10.5.0" 551 + gccchoice="4.9.4" 552 552 } 553 553 554 554 arm7tdmicc () { ··· 628 628 GCCOPTS="$GCCOPTS -ffunction-sections -msoft-float -G 0 -Wno-parentheses" 629 629 GCCOPTIMIZE="-fomit-frame-pointer" 630 630 endian="little" 631 - gccchoice="10.5.0" 631 + gccchoice="4.9.4" 632 632 } 633 633 634 634 mipsr2elcc () { ··· 638 638 GCCOPTS="$GCCOPTS -ffunction-sections -msoft-float -G 0 -Wno-parentheses" 639 639 GCCOPTIMIZE="-fomit-frame-pointer" 640 640 endian="little" 641 - gccchoice="10.5.0" 641 + gccchoice="4.9.4" 642 642 } 643 643 644 644 maemocc () { ··· 776 776 GCCOPTIMIZE='' 777 777 LDOPTS="-lasound -lpthread -lm -ldl -lrt $LDOPTS" 778 778 GLOBAL_LDOPTS="$GLOBAL_LDOPTS -Wl,-z,defs" # warn about undefined symbols in shared libraries 779 - GLOBAL_LDOPTS="$GLOBAL_LDOPTS -Wl,-z,defs -Wl,-z,noexecstack" # Stack is not executable 780 779 SHARED_LDFLAGS="-shared" 781 780 SHARED_CFLAGS='' 782 781 endian="little" ··· 786 785 GCCOPTS="$GCCOPTS -D_GNU_SOURCE=1 -U_FORTIFY_SOURCE -D_REENTRANT" 787 786 788 787 # Set up compiler 789 - gccchoice="10.5.0" 788 + gccchoice="4.9.4" 790 789 prefixtools "arm-rockbox-linux-gnueabi-" 791 790 } 792 791 ··· 966 965 GCCOPTS="$GCCOPTS -D_GNU_SOURCE=1 -U_FORTIFY_SOURCE -D_REENTRANT" 967 966 968 967 # Set up compiler 969 - gccchoice="10.5.0" 968 + gccchoice="4.9.4" 970 969 prefixtools "mipsel-rockbox-linux-gnu-" 971 970 } 972 971 ··· 4695 4694 ldnum=0 4696 4695 else 4697 4696 ldnum=`$LD --version | sed -n '1p' | sed -e 's/.* \([0-9]*\)\.\([0-9]*\).*/\1\2/'` 4698 - fi 4699 - 4700 - if test "$ldnum" -ge "239"; then 4701 - GLOBAL_LDOPTS="$GLOBAL_LDOPTS -Wl,--no-warn-rwx-segments" 4702 4697 fi 4703 4698 4704 4699 if test "$ldnum" -ge "227"; then
+63 -51
tools/rockboxdev.sh
··· 333 333 # $5=make install options (will be replaced by "install" if left empty) 334 334 # By default, the restary step is the toolname, but it can be changed by setting 335 335 # RESTART_STEP 336 - buildtool () { 336 + buildtool() { 337 337 tool="$1" 338 338 version="$2" 339 339 toolname="$tool-$version" ··· 389 389 elif [ "$config_opt" != "NO_CONFIGURE" ]; then 390 390 echo "ROCKBOXDEV: $toolname/configure" 391 391 cflags='-U_FORTIFY_SOURCE -fgnu89-inline -O2' 392 - if [ "$tool" == "glibc" ]; then 393 - cflags="$cflags -fcommon" # glibc < 2.30 needs -fcommon for gcc10+ 394 - elif [ "$tool" == "glib" ]; then 392 + if [ "$tool" == "glib" ]; then 395 393 run_cmd "$logfile" $SED -i -e 's/m4_copy/m4_copy_force/g' "$cfg_dir/m4macros/glib-gettext.m4" 396 394 run_cmd "$logfile" autoreconf -fiv "$cfg_dir" 397 395 cflags="$cflags -Wno-format-nonliteral -Wno-format-overflow" ··· 445 443 446 444 # For Apple targets only 447 445 if [ "$system" == "Darwin" ] ; then 448 - # gcc-libcpp17: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111632 449 - patch="$patch apple_silicon.patch apple_silicon-zlib.patch gcc-libcpp17.patch" 446 + patch="$patch apple_silicon.patch apple_silicon-zlib.patch" 450 447 EXTRA_CXXFLAGS="-fbracket-depth=512" 451 448 fi 452 449 fi ··· 492 489 cd "$toolname-$version" 493 490 if (echo $needs_libs | grep -q gmp && test ! -d gmp); then 494 491 echo "ROCKBOXDEV: Getting GMP" 495 - getfile "gmp-6.2.1.tar.bz2" "$GNU_MIRROR/gmp" 496 - tar xjf $dlwhere/gmp-6.2.1.tar.bz2 497 - ln -s gmp-6.2.1 gmp 492 + getfile "gmp-6.1.2.tar.xz" "$GNU_MIRROR/gmp" 493 + tar xJf $dlwhere/gmp-6.1.2.tar.xz 494 + ln -s gmp-6.1.2 gmp 498 495 fi 499 496 500 497 if (echo $needs_libs | grep -q mpfr && test ! -d mpfr); then 501 498 echo "ROCKBOXDEV: Getting MPFR" 502 - getfile "mpfr-4.1.1.tar.xz" "$GNU_MIRROR/mpfr" 503 - tar xJf $dlwhere/mpfr-4.1.1.tar.xz 504 - ln -s mpfr-4.1.1 mpfr 499 + getfile "mpfr-3.1.6.tar.xz" "$GNU_MIRROR/mpfr" 500 + tar xJf $dlwhere/mpfr-3.1.6.tar.xz 501 + ln -s mpfr-3.1.6 mpfr 505 502 fi 506 503 507 504 if (echo $needs_libs | grep -q mpc && test ! -d mpc); then 508 505 echo "ROCKBOXDEV: Getting MPC" 509 - getfile "mpc-1.3.1.tar.gz" "http://www.multiprecision.org/downloads" 510 - tar xzf $dlwhere/mpc-1.3.1.tar.gz 511 - ln -s mpc-1.3.1 mpc 506 + getfile "mpc-1.0.1.tar.gz" "http://www.multiprecision.org/downloads" 507 + tar xzf $dlwhere/mpc-1.0.1.tar.gz 508 + ln -s mpc-1.0.1 mpc 512 509 fi 513 510 514 511 if (echo $needs_libs | grep -q isl && test ! -d isl); then 515 512 echo "ROCKBOXDEV: Getting ISL" 516 - getfile "isl-0.24.tar.bz2" "https://gcc.gnu.org/pub/gcc/infrastructure" 517 - tar xjf $dlwhere/isl-0.24.tar.bz2 518 - ln -s isl-0.24 isl 513 + getfile "isl-0.15.tar.bz2" "https://gcc.gnu.org/pub/gcc/infrastructure" 514 + tar xjf $dlwhere/isl-0.15.tar.bz2 515 + ln -s isl-0.15 isl 519 516 fi 520 517 cd $builddir 521 518 fi ··· 564 561 565 562 # check libraries: 566 563 # contrary to other toolchains that rely on a hack to avoid installing 567 - # gmp, mpc, and mpfr, we simply require that they are installed on 568 - # the system this is not a huge requirement since virtually all systems 569 - # these days provide dev packages for them 564 + # gmp, mpc and mpfr, we simply require that they are installed on the system 565 + # this is not a huge requirement since virtually all systems these days 566 + # provide dev packages for them 570 567 # FIXME: maybe add an option to download and install them automatically 571 568 checklib "mpc" "gmp" "mpfr" 572 569 ··· 805 802 echo "" 806 803 case $arch in 807 804 [Ii]) 808 - build "binutils" "mipsel-elf" "2.40" "binutils-c23.patch" "--disable-werror" "gmp isl" 809 - build "gcc" "mipsel-elf" "10.5.0" "" "" "gmp mpfr mpc isl" 805 + build "binutils" "mipsel-elf" "2.26.1" "binutils-c23.patch" "--disable-werror" "gmp isl" 806 + build "gcc" "mipsel-elf" "4.9.4" "" "" "gmp mpfr mpc isl" 810 807 ;; 811 808 812 809 [Mm]) 813 - build "binutils" "m68k-elf" "2.40" "" "--disable-werror" "gmp isl" 814 - build "gcc" "m68k-elf" "10.5.0" "" "--with-arch=cf MAKEINFO=missing" "gmp mpfr mpc isl" 810 + build "binutils" "m68k-elf" "2.26.1" "" "--disable-werror" "gmp isl" 811 + build "gcc" "m68k-elf" "4.9.4" "" "--with-arch=cf MAKEINFO=missing" "gmp mpfr mpc isl" 815 812 ;; 816 813 817 814 [Aa]) 818 815 binopts="" 819 - gccopts="--with-multilib-list=rmprofile" 816 + gccopts="" 820 817 case $system in 821 818 Darwin) 822 819 binopts="--disable-nls" 823 820 gccopts="--disable-nls" 824 821 ;; 825 822 esac 826 - build "binutils" "arm-elf-eabi" "2.40" "" "$binopts --disable-werror" "gmp isl" 827 - build "gcc" "arm-elf-eabi" "10.5.0" "rockbox-multilibs-noexceptions-arm-elf-eabi-gcc-9.5.0.diff" "$gccopts MAKEINFO=missing" "gmp mpfr mpc isl" 823 + build "binutils" "arm-elf-eabi" "2.26.1" "" "$binopts --disable-werror" "gmp isl" 824 + build "gcc" "arm-elf-eabi" "4.9.4" "rockbox-multilibs-noexceptions-arm-elf-eabi-gcc-4.9.4.diff" "$gccopts MAKEINFO=missing" "gmp mpfr mpc isl" 828 825 ;; 829 826 [Xx]) 830 827 # IMPORTANT NOTE ··· 833 830 # 834 831 # Samsung YP-R0/R1: 835 832 # ARM1176JZF-S, softfp EABI 836 - # kernel: device runs 2.6.24, but oem toolchain is built against 2.6.27.59 837 - # glibc: device runs 2.4.2 838 - # 833 + # gcc: 4.9.4 is the latest 4.9.x stable branch, also the only one that 834 + # compiles with GCC >6 835 + # kernel: 2.6.27.59 is the same 2.6.x stable kernel as used by the 836 + # original ct-ng toolchain, the device runs kernel 2.6.24 837 + # glibc: 2.19 is the latest version that supports kernel 2.6.24 which 838 + # is used on the device, but we need to support ABI 2.4 because 839 + # the device uses glibc 2.4.2 840 + # 839 841 # Sony NWZ: 840 - # kernel: Varies from device to device; 2.6.23, 2.6.35, and 3.x seen. 841 - # glibc: device runs 2.7 842 + # gcc: 4.9.4 is the latest 4.9.x stable branch, also the only one that 843 + # compiles with GCC >6 844 + # kernel: 2.6.32.71 is the latest 2.6.x stable kernel, the device 845 + # runs kernel 2.6.23 or 2.6.35 or 3.x for the most recent 846 + # glibc: 2.19 is the latest version that supports kernel 2.6.23 which 847 + # is used on many Sony players, but we need to support ABI 2.7 848 + # because the device uses glibc 2.7 842 849 # 843 - # Thus the lowest common denominator is to target 2.6.23 and glibc 2.4 844 - # Use a recent 2.6.32 LTS kernel, but glibc 2.20 targeting 2.6.23 and API 2.4 845 - # 850 + # Thus the lowest common denominator is to use the latest 2.6.x stable 851 + # kernel but compile glibc to support kernel 2.6.23 and glibc 2.4. 852 + # We use a recent 2.26.1 binutils to avoid any build problems and 853 + # avoid patches/bugs. 846 854 glibcopts="--enable-kernel=2.6.23 --enable-oldest-abi=2.4" 847 - build_linux_toolchain "arm-rockbox-linux-gnueabi" "2.40" "" "" "10.5.0" \ 848 - "$gccopts" "2.6.32.71" "" "2.20" "$glibcopts" "glibc-220-make44.patch glibc-2.20-gcc10.patch" 855 + build_linux_toolchain "arm-rockbox-linux-gnueabi" "2.26.1" "" "" "4.9.4" \ 856 + "$gccopts" "2.6.32.71" "" "2.19" "$glibcopts" "glibc-220-make44.patch" 849 857 # build alsa-lib 850 858 # we need to set the prefix to how it is on device (/usr) and then 851 859 # tweak install dir at make install step ··· 860 868 # This toolchain must support several targets and thus must support 861 869 # the oldest possible configuration. 862 870 # 863 - # AGPTek Rocker (and other HibyOS players): 871 + # AGPTek Rocker: 872 + # XBurst release 1 (something inbetween mips32r1 and mips32r2) 873 + # gcc: 4.9.4 is the latest 4.9.x stable branch, also the only one that 874 + # compiles with GCC >6 864 875 # kernel: 3.10.14 865 876 # glibc: 2.16 866 877 # alsa: 1.0.29 867 878 # 868 - # FiiO M3K Linux (Based on Ingenic SDK): 879 + # FiiO M3K Linux: 869 880 # kernel: 3.10.14 870 881 # glibc: 2.16 871 882 # alsa: 1.0.26 872 883 # 873 - # Use a recent 3.10 LTS kernel, but glibc 2.27 targeting 3.2.x and API 2.16 874 - # 875 - glibcopts="--enable-kernel=3.2 --enable-oldest-abi=2.16 --disable-werror" 876 - # FIXME: maybe add -mhard-float? 877 - build_linux_toolchain "mipsel-rockbox-linux-gnu" "2.40" "" "binutils-c23.patch" "10.5.0" \ 878 - "$gccopts" "3.10.108" "linux-c23.patch" "2.27" "$glibcopts" "glibc-227-make44.patch" 884 + # To maximize compatibility, we use kernel 3.2.89 which is the latest 885 + # longterm 3.2 kernel and is supported by the latest glibc, and we 886 + # require support for up to glibc 2.16 887 + # We use a recent 2.26.1 binutils to avoid any build problems and 888 + # avoid patches/bugs. 889 + glibcopts="--enable-kernel=3.2 --enable-oldest-abi=2.16" 890 + # FIXME: maybe add -mhard-float 891 + build_linux_toolchain "mipsel-rockbox-linux-gnu" "2.26.1" "" "binutils-c23.patch" "4.9.4" \ 892 + "$gccopts" "3.2.89" "linux-c23.patch" "2.25" "$glibcopts" "glibc-225-make44.patch" 879 893 # build alsa-lib 880 894 # we need to set the prefix to how it is on device (/usr) and then 881 895 # tweak install dir at make install step ··· 883 897 gettool "alsa-lib" "$alsalib_ver" 884 898 extract "alsa-lib-$alsalib_ver" 885 899 prefix="/usr" buildtool "alsa-lib" "$alsalib_ver" \ 886 - "--host=$target --disable-python" "" "install DESTDIR=$prefix/$target/sysroot" 887 - 888 - ### Everything below here is needed only for bluetooth support 889 - 900 + "--host=$target --disable-python" "" "install DESTDIR=$prefix/$target/sysroot" 890 901 # build libffi 891 902 libffi_ver="3.2.1" 892 903 gettool "libffi" "$libffi_ver" ··· 907 918 gettool "glib" "$glib_ver" 908 919 extract "glib-$glib_ver" 909 920 prefix="/usr" buildtool "glib" "$glib_ver" \ 910 - "--host=$target --with-sysroot=$prefix/$target/sysroot --disable-libelf glib_cv_stack_grows=no glib_cv_uscore=no ac_cv_func_posix_getpwuid_r=yes ac_cv_func_posix_getgrgid_r=yes CFLAGS=-Wno-error=format-nonliteral" "" "install DESTDIR=$prefix/$target/sysroot" 921 + "--host=$target --with-sysroot=$prefix/$target/sysroot --disable-libelf glib_cv_stack_grows=no glib_cv_uscore=no ac_cv_func_posix_getpwuid_r=yes ac_cv_func_posix_getgrgid_r=yes" "" "install DESTDIR=$prefix/$target/sysroot" 911 922 912 923 # build expat 913 924 expat_ver="2.1.0" ··· 922 933 extract "dbus-$dbus_ver" 923 934 prefix="/usr" buildtool "dbus" "$dbus_ver" \ 924 935 "--host=$target --with-sysroot=$prefix/$target/sysroot --includedir=/usr/include --enable-abstract-sockets ac_cv_lib_expat_XML_ParserCreate_MM=yes --disable-systemd --disable-launchd --enable-x11-autolaunch=no --with-x=no -disable-selinux --disable-apparmor --disable-doxygen-docs " "" "install DESTDIR=$prefix/$target/sysroot " 936 + 925 937 926 938 ;; 927 939 *)
+4 -4
tools/toolchain-patches/apple_silicon-zlib.patch
··· 1 1 diff --git a/zlib/zutil.h b/zlib/zutil.h 2 - index 4b596adf..66d54cc3 100644 2 + index ed6b127e..3186e991 100644 3 3 --- a/zlib/zutil.h 4 4 +++ b/zlib/zutil.h 5 - @@ -130,17 +130,8 @@ extern z_const char * const z_errmsg[10]; /* indexed by 2-zlib_error */ 5 + @@ -118,17 +118,8 @@ extern const char * const z_errmsg[10]; /* indexed by 2-zlib_error */ 6 6 # endif 7 7 #endif 8 8 9 9 -#if defined(MACOS) || defined(TARGET_OS_MAC) 10 10 +#if defined(MACOS) 11 - # define OS_CODE 7 11 + # define OS_CODE 0x07 12 12 -# ifndef Z_SOLO 13 13 -# if defined(__MWERKS__) && __dest_os != __be_os && __dest_os != __win32_os 14 14 -# include <unix.h> /* for fdopen */ ··· 20 20 -# endif 21 21 #endif 22 22 23 - #ifdef __acorn 23 + #ifdef TOPS20
-13
tools/toolchain-patches/apple_silicon.patch
··· 1 - diff --git a/gcc/gcc/config/aarch64/aarch64.h b/gcc/gcc/config/aarch64/aarch64.h 2 - index 976f9afae5..736b83ff0b 100644 3 - --- a/gcc/config/aarch64/aarch64.h 4 - +++ b/gcc/config/aarch64/aarch64.h 5 - @@ -1000,7 +1000,7 @@ extern const char *aarch64_rewrite_mcpu (int argc, const char **argv); 6 - #define MCPU_TO_MARCH_SPEC_FUNCTIONS \ 7 - { "rewrite_mcpu", aarch64_rewrite_mcpu }, 8 - 9 - -#if defined(__aarch64__) 10 - +#if defined(__aarch64__) && ! defined(__APPLE__) 11 - extern const char *host_detect_local_cpu (int argc, const char **argv); 12 - #define HAVE_LOCAL_CPU_DETECT 13 - # define EXTRA_SPEC_FUNCTIONS \ 14 1 diff --git a/gcc/gcc/config/host-darwin.c b/gcc/gcc/config/host-darwin.c 15 2 index 8f700eec85..b737abc006 100644 16 3 --- a/gcc/config/host-darwin.c
+3 -3
tools/toolchain-patches/binutils-c23.patch
··· 1 1 diff -ur binutils-2.26.X/opcodes/mips-formats.h binutils-2.26.1/opcodes/mips-formats.h 2 2 --- binutils-2.26.X/opcodes/mips-formats.h 2015-11-13 03:27:42.000000000 -0500 3 3 +++ binutils-2.26.1/opcodes/mips-formats.h 2025-04-28 14:04:50.949355647 -0400 4 - @@ -49,7 +49,7 @@ 4 + @@ -46,7 +46,7 @@ 5 5 #define MAPPED_INT(SIZE, LSB, MAP, PRINT_HEX) \ 6 6 { \ 7 7 typedef char ATTRIBUTE_UNUSED \ ··· 10 10 static const struct mips_mapped_int_operand op = { \ 11 11 { OP_MAPPED_INT, SIZE, LSB }, MAP, PRINT_HEX \ 12 12 }; \ 13 - @@ -83,7 +83,7 @@ 13 + @@ -80,7 +80,7 @@ 14 14 #define MAPPED_REG(SIZE, LSB, BANK, MAP) \ 15 15 { \ 16 16 typedef char ATTRIBUTE_UNUSED \ ··· 19 19 static const struct mips_reg_operand op = { \ 20 20 { OP_REG, SIZE, LSB }, OP_REG_##BANK, MAP \ 21 21 }; \ 22 - @@ -93,7 +93,7 @@ 22 + @@ -90,7 +90,7 @@ 23 23 #define OPTIONAL_MAPPED_REG(SIZE, LSB, BANK, MAP) \ 24 24 { \ 25 25 typedef char ATTRIBUTE_UNUSED \
-66
tools/toolchain-patches/gcc-libcpp17.patch
··· 1 - diff --git a/gcc/system.h b/gcc/system.h 2 - index d04f8fd33..636084682 100644 3 - --- a/gcc/system.h 4 - +++ b/gcc/system.h 5 - @@ -197,25 +197,6 @@ extern int fprintf_unlocked (FILE *, const char *, ...); 6 - /* Include <string> before "safe-ctype.h" to avoid GCC poisoning 7 - the ctype macros through safe-ctype.h */ 8 - 9 - -#ifdef __cplusplus 10 - -#ifdef INCLUDE_STRING 11 - -# include <string> 12 - -#endif 13 - -#endif 14 - - 15 - -/* There are an extraordinary number of issues with <ctype.h>. 16 - - The last straw is that it varies with the locale. Use libiberty's 17 - - replacement instead. */ 18 - -#include "safe-ctype.h" 19 - - 20 - -#include <sys/types.h> 21 - - 22 - -#include <errno.h> 23 - - 24 - -#if !defined (errno) && defined (HAVE_DECL_ERRNO) && !HAVE_DECL_ERRNO 25 - -extern int errno; 26 - -#endif 27 - - 28 - #ifdef __cplusplus 29 - #if defined (INCLUDE_ALGORITHM) || !defined (HAVE_SWAP_IN_UTILITY) 30 - # include <algorithm> 31 - @@ -229,6 +210,9 @@ extern int errno; 32 - #ifdef INCLUDE_SET 33 - # include <set> 34 - #endif 35 - +#ifdef INCLUDE_STRING 36 - +# include <string> 37 - +#endif 38 - #ifdef INCLUDE_VECTOR 39 - # include <vector> 40 - #endif 41 - @@ -237,6 +221,25 @@ extern int errno; 42 - # include <utility> 43 - #endif 44 - 45 - +#ifdef __cplusplus 46 - +#ifdef INCLUDE_STRING 47 - +# include <string> 48 - +#endif 49 - +#endif 50 - + 51 - +/* There are an extraordinary number of issues with <ctype.h>. 52 - + The last straw is that it varies with the locale. Use libiberty's 53 - + replacement instead. */ 54 - +#include "safe-ctype.h" 55 - + 56 - +#include <sys/types.h> 57 - + 58 - +#include <errno.h> 59 - + 60 - +#if !defined (errno) && defined (HAVE_DECL_ERRNO) && !HAVE_DECL_ERRNO 61 - +extern int errno; 62 - +#endif 63 - + 64 - /* Some of glibc's string inlines cause warnings. Plus we'd rather 65 - rely on (and therefore test) GCC's string builtins. */ 66 - #define __NO_STRING_INLINES
-12
tools/toolchain-patches/glibc-2.20-gcc10.patch
··· 1 - diff -Naur glibc-2.20/configure glibc-2.20-patched/configure 2 - --- glibc-2.20/configure 2014-09-07 04:09:09.000000000 -0400 3 - +++ glibc-2.20-patched/configure 2025-08-05 07:40:19.923528264 -0400 4 - @@ -4661,7 +4661,7 @@ 5 - ac_prog_version=`$CC -v 2>&1 | sed -n 's/^.*version \([egcygnustpi-]*[0-9.]*\).*$/\1/p'` 6 - case $ac_prog_version in 7 - '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;; 8 - - 4.[4-9].* | 4.[1-9][0-9].* | [5-9].* ) 9 - + 4.[4-9].* | 4.[1-9][0-9].* | [5-9].* | 1[0-9].* ) 10 - ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;; 11 - *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;; 12 -
+57 -45
tools/toolchain-patches/glibc-227-make44.patch tools/toolchain-patches/glibc-225-make44.patch
··· 1 - diff -Naur glibc-2.27/libio/stdio.h glibc-2.27-patched/libio/stdio.h 2 - --- glibc-2.27/libio/stdio.h 2018-02-01 11:17:18.000000000 -0500 3 - +++ glibc-2.27-patched/libio/stdio.h 2023-05-23 14:10:06.618633203 -0400 4 - @@ -118,18 +118,23 @@ 1 + diff -Naur glibc-2.25/libio/stdio.h glibc-2.25-patched/libio/stdio.h 2 + --- glibc-2.25/libio/stdio.h 2017-02-05 10:28:43.000000000 -0500 3 + +++ glibc-2.25-patched/libio/stdio.h 2023-05-23 15:22:27.482980335 -0400 4 + @@ -154,18 +154,23 @@ 5 5 # define P_tmpdir "/tmp" 6 6 #endif 7 7 ··· 32 32 33 33 /* Standard streams. */ 34 34 extern struct _IO_FILE *stdin; /* Standard input stream. */ 35 - diff -Naur glibc-2.27/Makerules glibc-2.27-patched/Makerules 36 - --- glibc-2.27/Makerules 2018-02-01 11:17:18.000000000 -0500 37 - +++ glibc-2.27-patched/Makerules 2023-05-23 14:10:06.617633203 -0400 38 - @@ -1522,46 +1522,6 @@ 35 + diff -Naur glibc-2.25/Makerules glibc-2.25-patched/Makerules 36 + --- glibc-2.25/Makerules 2017-02-05 10:28:43.000000000 -0500 37 + +++ glibc-2.25-patched/Makerules 2023-05-23 15:22:05.594967548 -0400 38 + @@ -1474,55 +1474,7 @@ 39 + endif 39 40 40 41 endif 41 - 42 + - 42 43 -# These will have been set by sysdeps/posix/Makefile. 43 44 -L_tmpnam ?= 1 44 45 -TMP_MAX ?= 0 45 46 -L_ctermid ?= 1 46 47 -L_cuserid ?= 1 47 - - 48 + 48 49 -stdio_lim = $(common-objpfx)bits/stdio_lim.h 49 50 - 50 51 -$(stdio_lim:lim.h=%.h) $(stdio_lim:lim.h=%.d): $(stdio_lim:lim.h=%.st); @: ··· 52 53 - $(common-objpfx)config.make 53 54 - $(make-target-directory) 54 55 - { echo '#include "$(..)posix/bits/posix1_lim.h"'; \ 55 - - } | \ 56 + - echo '#define _LIBC 1'; \ 57 + - echo '#include "$(..)misc/sys/uio.h"'; } | \ 56 58 - $(CC) -E -dM -MD -MP -MF $(@:st=dT) -MT '$(@:st=h) $(@:st=d)' \ 57 59 - $(CPPUNDEFS) $(+includes) -xc - -o $(@:st=hT) 58 60 - sed $(sed-remove-objpfx) $(sed-remove-dotdot) \ ··· 60 62 - mv -f $(@:st=dt) $(@:st=d) 61 63 - fopen_max=`sed -n 's/^#define OPEN_MAX //1p' $(@:st=hT)`; \ 62 64 - filename_max=`sed -n 's/^#define PATH_MAX //1p' $(@:st=hT)`; \ 65 + - iov_max=`sed -n 's/^#define UIO_MAXIOV //p' $(@:st=hT)`; \ 63 66 - fopen_max=$${fopen_max:-16}; \ 64 67 - filename_max=$${filename_max:-1024}; \ 68 + - if [ -z "$$iov_max" ]; then \ 69 + - define_iov_max="# undef IOV_MAX"; \ 70 + - else \ 71 + - define_iov_max="# define IOV_MAX $$iov_max"; \ 72 + - fi; \ 65 73 - sed -e "s/@FOPEN_MAX@/$$fopen_max/" \ 66 74 - -e "s/@FILENAME_MAX@/$$filename_max/" \ 67 75 - -e "s/@L_tmpnam@/$(L_tmpnam)/" \ 68 76 - -e "s/@TMP_MAX@/$(TMP_MAX)/" \ 69 77 - -e "s/@L_ctermid@/$(L_ctermid)/" \ 70 78 - -e "s/@L_cuserid@/$(L_cuserid)/" \ 79 + - -e "s/@define_IOV_MAX@/$$define_iov_max/" \ 71 80 - $< > $(@:st=h.new) 72 81 - $(move-if-change) $(@:st=h.new) $(@:st=h) 73 82 -# Remove these last so that they can be examined if something went wrong. ··· 82 91 FORCE: 83 92 84 93 .PHONY: echo-headers 85 - diff -Naur glibc-2.27/Rules glibc-2.27-patched/Rules 86 - --- glibc-2.27/Rules 2018-02-01 11:17:18.000000000 -0500 87 - +++ glibc-2.27-patched/Rules 2023-05-23 14:10:06.617633203 -0400 94 + diff -Naur glibc-2.25/Rules glibc-2.25-patched/Rules 95 + --- glibc-2.25/Rules 2017-02-05 10:28:43.000000000 -0500 96 + +++ glibc-2.25-patched/Rules 2023-05-23 15:22:27.482980335 -0400 88 97 @@ -60,9 +60,6 @@ 89 98 common-generated := 90 99 endif ··· 95 104 include $(..)Makerules 96 105 97 106 .PHONY: subdir_lib 98 - diff -Naur glibc-2.27/stdio-common/stdio_lim.h.in glibc-2.27-patched/stdio-common/stdio_lim.h.in 99 - --- glibc-2.27/stdio-common/stdio_lim.h.in 2018-02-01 11:17:18.000000000 -0500 100 - +++ glibc-2.27-patched/stdio-common/stdio_lim.h.in 1969-12-31 19:00:00.000000000 -0500 101 - @@ -1,39 +0,0 @@ 102 - -/* Copyright (C) 1994-2018 Free Software Foundation, Inc. 107 + diff -Naur glibc-2.25/stdio-common/stdio_lim.h.in glibc-2.25-patched/stdio-common/stdio_lim.h.in 108 + --- glibc-2.25/stdio-common/stdio_lim.h.in 2017-02-05 10:28:43.000000000 -0500 109 + +++ glibc-2.25-patched/stdio-common/stdio_lim.h.in 1969-12-31 19:00:00.000000000 -0500 110 + @@ -1,42 +0,0 @@ 111 + -/* Copyright (C) 1994-2017 Free Software Foundation, Inc. 103 112 - This file is part of the GNU C Library. 104 113 - 105 114 - The GNU C Library is free software; you can redistribute it and/or ··· 116 125 - License along with the GNU C Library; if not, see 117 126 - <http://www.gnu.org/licenses/>. */ 118 127 - 119 - -#ifndef _BITS_STDIO_LIM_H 120 - -#define _BITS_STDIO_LIM_H 1 121 - - 122 - -#ifndef _STDIO_H 128 + -#if !defined _STDIO_H && !defined __need_FOPEN_MAX && !defined __need_IOV_MAX 123 129 -# error "Never include <bits/stdio_lim.h> directly; use <stdio.h> instead." 124 130 -#endif 125 131 - 126 - -#define L_tmpnam @L_tmpnam@ 127 - -#define TMP_MAX @TMP_MAX@ 128 - -#define FILENAME_MAX @FILENAME_MAX@ 132 + -#ifdef _STDIO_H 133 + -# define L_tmpnam @L_tmpnam@ 134 + -# define TMP_MAX @TMP_MAX@ 135 + -# define FILENAME_MAX @FILENAME_MAX@ 129 136 - 130 - -#ifdef __USE_POSIX 131 - -# define L_ctermid @L_ctermid@ 132 - -# if !defined __USE_XOPEN2K || defined __USE_GNU 133 - -# define L_cuserid @L_cuserid@ 137 + -# ifdef __USE_POSIX 138 + -# define L_ctermid @L_ctermid@ 139 + -# if !defined __USE_XOPEN2K || defined __USE_GNU 140 + -# define L_cuserid @L_cuserid@ 141 + -# endif 134 142 -# endif 135 143 -#endif 136 144 - 137 - -#undef FOPEN_MAX 138 - -#define FOPEN_MAX @FOPEN_MAX@ 145 + -#if defined __need_FOPEN_MAX || defined _STDIO_H 146 + -# undef FOPEN_MAX 147 + -# define FOPEN_MAX @FOPEN_MAX@ 148 + -#endif 139 149 - 140 - -#endif /* bits/stdio_lim.h */ 141 - diff -Naur glibc-2.27/sysdeps/mach/hurd/bits/stdio_lim.h glibc-2.27-patched/sysdeps/mach/hurd/bits/stdio_lim.h 142 - --- glibc-2.27/sysdeps/mach/hurd/bits/stdio_lim.h 1969-12-31 19:00:00.000000000 -0500 143 - +++ glibc-2.27-patched/sysdeps/mach/hurd/bits/stdio_lim.h 2023-05-23 14:10:06.618633203 -0400 150 + -#if defined __need_IOV_MAX && !defined IOV_MAX 151 + -@define_IOV_MAX@ 152 + -#endif 153 + diff -Naur glibc-2.25/sysdeps/mach/hurd/bits/stdio_lim.h glibc-2.25-patched/sysdeps/mach/hurd/bits/stdio_lim.h 154 + --- glibc-2.25/sysdeps/mach/hurd/bits/stdio_lim.h 1969-12-31 19:00:00.000000000 -0500 155 + +++ glibc-2.25-patched/sysdeps/mach/hurd/bits/stdio_lim.h 2023-05-23 15:22:27.483980336 -0400 144 156 @@ -0,0 +1,28 @@ 145 157 +/* System specific stdio.h definitions. Hurd version. 146 158 + Copyright (C) 2023 Free Software Foundation, Inc. ··· 170 182 +#define FILENAME_MAX 1024 171 183 + 172 184 +#endif /* bits/stdio_lim.h */ 173 - diff -Naur glibc-2.27/sysdeps/posix/Makefile glibc-2.27-patched/sysdeps/posix/Makefile 174 - --- glibc-2.27/sysdeps/posix/Makefile 2018-02-01 11:17:18.000000000 -0500 175 - +++ glibc-2.27-patched/sysdeps/posix/Makefile 2023-05-23 14:10:06.618633203 -0400 185 + diff -Naur glibc-2.25/sysdeps/posix/Makefile glibc-2.25-patched/sysdeps/posix/Makefile 186 + --- glibc-2.25/sysdeps/posix/Makefile 2017-02-05 10:28:43.000000000 -0500 187 + +++ glibc-2.25-patched/sysdeps/posix/Makefile 2023-05-23 15:22:27.483980336 -0400 176 188 @@ -1,8 +1,3 @@ 177 189 -# These affect the generated bits/stdio_lim.h file. 178 190 -L_tmpnam = 20 ··· 182 194 183 195 ifeq ($(subdir)|$(have-thread-library),rt|no) 184 196 # With NPTL, this lives in libpthread so it can be used for sem_open too. 185 - diff -Naur glibc-2.27/sysdeps/unix/sysv/linux/bits/stdio_lim.h glibc-2.27-patched/sysdeps/unix/sysv/linux/bits/stdio_lim.h 186 - --- glibc-2.27/sysdeps/unix/sysv/linux/bits/stdio_lim.h 1969-12-31 19:00:00.000000000 -0500 187 - +++ glibc-2.27-patched/sysdeps/unix/sysv/linux/bits/stdio_lim.h 2023-05-23 14:10:06.618633203 -0400 197 + diff -Naur glibc-2.25/sysdeps/unix/sysv/linux/bits/stdio_lim.h glibc-2.25-patched/sysdeps/unix/sysv/linux/bits/stdio_lim.h 198 + --- glibc-2.25/sysdeps/unix/sysv/linux/bits/stdio_lim.h 1969-12-31 19:00:00.000000000 -0500 199 + +++ glibc-2.25-patched/sysdeps/unix/sysv/linux/bits/stdio_lim.h 2023-05-23 15:22:27.483980336 -0400 188 200 @@ -0,0 +1,28 @@ 189 201 +/* System specific stdio.h definitions. Linux version. 190 202 + Copyright (C) 2023 Free Software Foundation, Inc. ··· 207 219 +#ifndef _BITS_STDIO_LIM_H 208 220 +#define _BITS_STDIO_LIM_H 1 209 221 + 210 - +#ifndef _STDIO_H 211 - +# error "Never include <bits/stdio_lim.h> directly; use <stdio.h> instead." 212 - +#endif 222 + +//#ifndef _STDIO_H 223 + +//# error "Never include <bits/stdio_lim.h> directly; use <stdio.h> instead." 224 + +//#endif 213 225 + 214 226 +#define FILENAME_MAX 4096 215 227 +
+56
tools/toolchain-patches/rockbox-multilibs-noexceptions-arm-elf-eabi-gcc-4.9.4.diff
··· 1 + diff -Naur gcc-4.9.4/gcc/config/arm/t-arm-elf gcc-4.9.4-fixed/gcc/config/arm/t-arm-elf 2 + --- gcc-4.9.4/gcc/config/arm/t-arm-elf 2014-01-02 17:23:26.000000000 -0500 3 + +++ gcc-4.9.4-fixed/gcc/config/arm/t-arm-elf 2020-07-01 22:11:01.198403110 -0400 4 + @@ -44,6 +44,11 @@ 5 + #MULTILIB_EXCEPTIONS += *mcpu=fa526/*mfloat-abi=hard* 6 + #MULTILIB_EXCEPTIONS += *mcpu=fa626/*mfloat-abi=hard* 7 + 8 + +# We build a lib for each specific CPU Rockbox targets. If anyone knows a better 9 + +# way to do this, please let us know. 10 + +MULTILIB_OPTIONS += mcpu=arm7tdmi/mcpu=arm9tdmi/mcpu=arm9e/mcpu=arm926ej-s/mcpu=arm1136jf-s 11 + +MULTILIB_DIRNAMES += arm7tdmi arm9tdmi arm9e arm926ej-s arm1136jf-s 12 + + 13 + # MULTILIB_OPTIONS += mcpu=ep9312 14 + # MULTILIB_DIRNAMES += ep9312 15 + # MULTILIB_EXCEPTIONS += *mthumb/*mcpu=ep9312* 16 + @@ -56,8 +61,8 @@ 17 + # MULTILIB_DIRNAMES += fpu soft 18 + # MULTILIB_EXCEPTIONS += *mthumb/*mfloat-abi=hard* 19 + # 20 + -# MULTILIB_OPTIONS += mno-thumb-interwork/mthumb-interwork 21 + -# MULTILIB_DIRNAMES += normal interwork 22 + +MULTILIB_OPTIONS += mno-thumb-interwork/mthumb-interwork 23 + +MULTILIB_DIRNAMES += normal interwork 24 + # 25 + # MULTILIB_OPTIONS += fno-leading-underscore/fleading-underscore 26 + # MULTILIB_DIRNAMES += elf under 27 + diff -Naur gcc-4.9.4/libgcc/config/arm/t-bpabi gcc-4.9.4-fixed/libgcc/config/arm/t-bpabi 28 + --- gcc-4.9.4/libgcc/config/arm/t-bpabi 2012-08-17 11:06:06.000000000 -0400 29 + +++ gcc-4.9.4-fixed/libgcc/config/arm/t-bpabi 2020-07-01 22:13:39.103762818 -0400 30 + @@ -17,4 +17,4 @@ 31 + # On ARM, specifying -fnon-call-exceptions will needlessly pull in 32 + # the unwinder in simple programs which use 64-bit division. Omitting 33 + # the option is safe. 34 + -LIB2_DIVMOD_EXCEPTION_FLAGS := -fexceptions 35 + +LIB2_DIVMOD_EXCEPTION_FLAGS := -fno-exceptions -fno-non-call-exceptions 36 + diff -Naur gcc-4.9.4/libgcc/Makefile.in gcc-4.9.4-fixed/libgcc/Makefile.in 37 + --- gcc-4.9.4/libgcc/Makefile.in 2014-01-08 11:37:08.000000000 -0500 38 + +++ gcc-4.9.4-fixed/libgcc/Makefile.in 2020-07-01 22:11:01.199403087 -0400 39 + @@ -495,7 +495,7 @@ 40 + ifeq ($(LIB2_DIVMOD_EXCEPTION_FLAGS),) 41 + # Provide default flags for compiling divmod functions, if they haven't been 42 + # set already by a target-specific Makefile fragment. 43 + -LIB2_DIVMOD_EXCEPTION_FLAGS := -fexceptions -fnon-call-exceptions 44 + +LIB2_DIVMOD_EXCEPTION_FLAGS := -fno-exceptions -fno-non-call-exceptions 45 + endif 46 + 47 + # Build LIB2_DIVMOD_FUNCS. 48 + @@ -816,7 +816,7 @@ 49 + # libgcc_eh.a, only LIB2ADDEH matters. If we do, only LIB2ADDEHSTATIC and 50 + # LIB2ADDEHSHARED matter. (Usually all three are identical.) 51 + 52 + -c_flags := -fexceptions 53 + +c_flags := -fno-exceptions 54 + 55 + ifeq ($(enable_shared),yes) 56 +
-43
tools/toolchain-patches/rockbox-multilibs-noexceptions-arm-elf-eabi-gcc-9.5.0.diff
··· 1 - diff -aur gcc-8.5.0/gcc/config/arm/t-arm-elf gcc-8.5.0-patched/gcc/config/arm/t-arm-elf 2 - --- gcc-8.5.0/gcc/config/arm/t-arm-elf 2021-05-14 04:42:08.000000000 -0400 3 - +++ gcc-8.5.0-patched/gcc/config/arm/t-arm-elf 2022-11-26 23:16:30.714433566 -0500 4 - @@ -81,6 +81,10 @@ 5 - MULTILIB_REQUIRED += marm/mfpu=auto/march=armv5te+fp/mfloat-abi=hard 6 - MULTILIB_REQUIRED += mthumb/mfpu=auto/march=armv7+fp/mfloat-abi=hard 7 - 8 - +# And we want to be able to disable interworking 9 - +MULTILIB_OPTIONS += mno-thumb-interwork/mthumb-interwork 10 - +MULTILIB_DIRNAMES += normal interwork 11 - + 12 - # PART 3 - Match rules 13 - 14 - # Map all supported FPUs onto mfpu=auto 15 - diff -aur gcc-8.5.0/libgcc/config/arm/t-bpabi gcc-8.5.0-patched/libgcc/config/arm/t-bpabi 16 - --- gcc-8.5.0/libgcc/config/arm/t-bpabi 2021-05-14 04:42:10.000000000 -0400 17 - +++ gcc-8.5.0-patched/libgcc/config/arm/t-bpabi 2022-11-26 23:14:40.938038440 -0500 18 - @@ -17,4 +17,4 @@ 19 - # On ARM, specifying -fnon-call-exceptions will needlessly pull in 20 - # the unwinder in simple programs which use 64-bit division. Omitting 21 - # the option is safe. 22 - -LIB2_DIVMOD_EXCEPTION_FLAGS := -fexceptions 23 - +LIB2_DIVMOD_EXCEPTION_FLAGS := -fno-exceptions -fno-non-call-exceptions 24 - diff -aur gcc-8.5.0/libgcc/Makefile.in gcc-8.5.0-patched/libgcc/Makefile.in 25 - --- gcc-8.5.0/libgcc/Makefile.in 2021-05-14 04:42:10.000000000 -0400 26 - +++ gcc-8.5.0-patched/libgcc/Makefile.in 2022-11-26 23:13:56.781304250 -0500 27 - @@ -530,7 +530,7 @@ 28 - ifeq ($(LIB2_DIVMOD_EXCEPTION_FLAGS),) 29 - # Provide default flags for compiling divmod functions, if they haven't been 30 - # set already by a target-specific Makefile fragment. 31 - -LIB2_DIVMOD_EXCEPTION_FLAGS := -fexceptions -fnon-call-exceptions 32 - +LIB2_DIVMOD_EXCEPTION_FLAGS := -fno-exceptions -fno-non-call-exceptions 33 - endif 34 - 35 - # Build LIB2_DIVMOD_FUNCS. 36 - @@ -851,7 +851,7 @@ 37 - # libgcc_eh.a, only LIB2ADDEH matters. If we do, only LIB2ADDEHSTATIC and 38 - # LIB2ADDEHSHARED matter. (Usually all three are identical.) 39 - 40 - -c_flags := -fexceptions 41 - +c_flags := -fno-exceptions 42 - 43 - ifeq ($(enable_shared),yes)