* scripts

* change check version

* disable inlining

* all the spots

* it's funny that this works with the wrong file extension

* bootloader

* hardware ci runs gcc 10
This commit is contained in:
Matthew Kennedy 2022-10-18 19:30:16 -07:00 committed by GitHub
parent 582cc4a10e
commit ced5db5d53
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 18 additions and 22 deletions

View File

@ -321,9 +321,9 @@ jobs:
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: 'true'
run: | # Compiler hosted on our other git repo - avoids having to download from the nice folks at ARM every time
wget 'https://github.com/rusefi/build_support/raw/master/gcc-arm-none-eabi-9-2020-q2-update-x86_64-linux.tar.xz' -O compiler.tar.xz
tar -xvf compiler.tar.xz
echo "`pwd`/gcc-arm-none-eabi-9-2020-q2-update/bin" >> $GITHUB_PATH
wget 'https://github.com/rusefi/build_support/raw/master/gcc-arm-none-eabi-10.3-2021.10-x86_64-linux.tar.bz2' -O compiler.tar.bz2
tar -xvf compiler.tar.bz2
echo "`pwd`/gcc-arm-none-eabi-10.3-2021.10/bin" >> $GITHUB_PATH
# Make sure the compiler we just downloaded works - just print out the version
- name: Test Compiler
@ -443,9 +443,9 @@ jobs:
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: 'true'
run: | # Compiler hosted on our other git repo - avoids having to download from the nice folks at ARM every time
wget 'https://github.com/rusefi/build_support/raw/master/gcc-arm-none-eabi-9-2020-q2-update-x86_64-linux.tar.xz' -O compiler.tar.xz
tar -xvf compiler.tar.xz
echo "::add-path::`pwd`/gcc-arm-none-eabi-9-2020-q2-update/bin"
wget 'https://github.com/rusefi/build_support/raw/master/gcc-arm-none-eabi-10.3-2021.10-x86_64-linux.tar.bz2' -O compiler.tar.bz2
tar -xvf compiler.tar.bz2
echo "::add-path::`pwd`/gcc-arm-none-eabi-10.3-2021.10/bin"
# Make sure the compiler we just downloaded works - just print out the version
- name: Test Compiler

View File

@ -53,7 +53,7 @@ jobs:
run: ./gen_live_documentation.sh
- name: Add compiler to PATH
run: echo "$HOME/.rusefi-tools/gcc-arm-none-eabi-9-2020-q2-update/bin" >> $GITHUB_PATH
run: echo "$HOME/.rusefi-tools/gcc-arm-none-eabi-10.3-2021.10/bin" >> $GITHUB_PATH
# Make sure the compiler works
- name: Test/Identify Compiler

View File

@ -73,8 +73,8 @@ endif
# C++ specific options here (added to USE_OPT).
ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -std=c++2a -Wno-register -fno-rtti -fno-threadsafe-statics -fno-exceptions -fno-use-cxa-atexit
# gcc-10 c++ 2a depricated uses of volatile errors
USE_CPPOPT = -std=c++20 -Wno-register -fno-rtti -fno-threadsafe-statics -fno-exceptions -fno-use-cxa-atexit
# gcc-10 c++ 20 depricated uses of volatile errors
USE_CPPOPT += -Wno-deprecated
endif

View File

@ -42,7 +42,9 @@ endif
# C++ specific options here (added to USE_OPT).
ifeq ($(USE_CPPOPT),)
# constexpr float expf_taylor_impl probably needs just c++14 but why not go with 17?
USE_CPPOPT = -std=c++2a -Wno-register -fno-rtti -fno-exceptions -fno-use-cxa-atexit -Werror=write-strings -Werror=type-limits -Winvalid-pch
USE_CPPOPT = -std=c++20 -Wno-register -fno-rtti -fno-exceptions -fno-use-cxa-atexit -Werror=write-strings -Werror=type-limits -Winvalid-pch
# gcc-10 c++ 20 depricated uses of volatile errors
USE_CPPOPT += -Wno-deprecated
endif
# Enable this if you want the linker to remove unused code and data

View File

@ -8,17 +8,11 @@
#define STR_HELPER(x) #x
#define STR(x) STR_HELPER(x)
// Firmware builds require at least GCC 9.3.1
#if (GCC_VERSION < 931)
#pragma message("GCC is " STR(__GNUC__)"."STR(__GNUC_MINOR__)"."STR(__GNUC_PATCHLEVEL__))
#error "GCC compiler >= 9.3.1 required"
#endif
#pragma message("GCC is " STR(__GNUC__)"."STR(__GNUC_MINOR__)"."STR(__GNUC_PATCHLEVEL__))
// Firmware builds but does not actually run on GCC10 :(
// todo: one day someone should fix it, do YOU want to help?
#if (GCC_VERSION > 1000)
#pragma message("GCC is " STR(__GNUC__)"."STR(__GNUC_MINOR__)"."STR(__GNUC_PATCHLEVEL__))
#error "GCC10 not supported see https://github.com/rusefi/rusefi/labels/Gcc10"
// Firmware builds require at least GCC 10.3.1
#if (GCC_VERSION < 1031)
#error "GCC compiler >= 10.3.1 required"
#endif
#endif

View File

@ -26,14 +26,14 @@ cd ~/.rusefi-tools
rm -rf arm-none-eabi-gcc.tar.bz2
# Download and extract GCC compiler
curl -L -o arm-none-eabi-gcc.tar.bz2 https://developer.arm.com/-/media/Files/downloads/gnu-rm/9-2020q2/gcc-arm-none-eabi-9-2020-q2-update-x86_64-linux.tar.bz2
curl -L -o arm-none-eabi-gcc.tar.bz2 https://developer.arm.com/-/media/Files/downloads/gnu-rm/10.3-2021.10/gcc-arm-none-eabi-10.3-2021.10-x86_64-linux.tar.bz2
tar -xjvf arm-none-eabi-gcc.tar.bz2
# Delete downloaded image
rm arm-none-eabi-gcc.tar.bz2
# Add the compiler to your path
echo 'export PATH=$PATH:$HOME/.rusefi-tools/gcc-arm-none-eabi-9-2020-q2-update/bin' >> ~/.profile
echo 'export PATH=$PATH:$HOME/.rusefi-tools/gcc-arm-none-eabi-10.3-2021.10/bin' >> ~/.profile
# Allow the current user to use serial ports
sudo usermod -a -G dialout $USER