1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
Commit Graph

60 Commits

Author SHA1 Message Date
benpicco
ee189fa428
Merge pull request #15187 from bergzand/pr/info/add_json
info.inc.mk: Add info-build-json as JSON-formatted build info
2020-10-15 21:27:26 +02:00
2dac4db343
make: Use common comma variable definition 2020-10-09 12:02:28 +02:00
Bas Stottelaar
0f8cecb50b cpu/cortexm_common: add support for Cortex-M33 2020-10-06 17:11:26 +02:00
chrysn
2eeda9a1ca makefiles: Pass explicit float mode to clang
The assumption that clang defaults to hard-float on ARM architectures
does not hold on Debian systems where [set-correct-float-abi].
As setting the flags that are implied on most systems does no harm, the
flags for the selected hard- or soft float behavior are now set
independently of the toolchain.

[set-correct-float-abi]: https://salsa.debian.org/pkg-llvm-team/llvm-toolchain/-/blob/10/debian/patches/26-set-correct-float-abi.diff

Closes: https://github.com/RIOT-OS/RIOT/issues/15026
2020-09-25 11:02:29 +02:00
Marian Buschsieweke
d9e495fe83
build system: use riscv-none-elf as triplet
Use riscv-none-elf instead of legacy riscv-none-embed as target triplet for
RISC-V development. However, if ricsv-none-elf is not present, try
riscv64-unknown-elf and riscv-none-embed instead. If the legacy riscv-none-embed
is used, a warning is printed.
2020-09-15 11:18:33 +02:00
Cenk Gündoğan
0d0bc91553
Merge pull request #14754 from leandrolanzieri/pr/no_archives
build system: link object files
2020-09-10 09:36:29 +02:00
Marian Buschsieweke
7c1949341e
build system: Overwrite TARGET_ARCH per arch
Add `TARGET_ARCH_<ARCH>` for each architecture (e.g. `TARGET_ARCH_CORTEX` for
Cortex M) to allow users to overwrite the target triple for a specific arch
from ~/.profile or ~/.bashrc (or the like) without overwriting it for all others
as well.
2020-09-08 22:28:41 +02:00
Leandro Lanzieri
81cb769cad
makefiles: avoid building archives when compiling 2020-09-04 15:01:10 +02:00
08c50947cc cpu/msp430_common: move newlib default module decl to Makefile.dep 2020-08-05 14:32:58 +02:00
a0aeeb5ff4 cpu/msp430: update to modern gcc & newlib 2020-08-05 14:29:00 +02:00
Francisco Molina
e98341da93
Makefile: use normal conditionals 2020-06-29 22:40:29 +02:00
Leandro Lanzieri
4d65bc8e0a
cpu: Rename CPU_ARCH to CPU_CORE 2020-06-16 12:05:40 +02:00
Leandro Lanzieri
ea2f963302
cpu/cortexm: Add 'cortexm_fpu' as a DEFAULT_MODULE if possible
This adds cortexm_fpu to the DEFAULT_MODULE list when the feature
cortexm_fpu is provided by the architecture. It also moves the
dependency resolution of this module to the architecture-specific
Makefile.dep file.
2020-04-01 09:46:29 +02:00
Leandro Lanzieri
64552a3b9a
cpu/cortexm_common: Move common modules to Makefile.dep
This moves the following modules to a architecture-specific Makefile.dep
file:
- cortexm_common
- cortexm_common_periph
- newlib
- newlib_nano
- periph
2020-04-01 09:46:21 +02:00
c7a3219ddb
make: remove useless export of TARGET_ARCH 2020-02-25 09:42:12 +01:00
benpicco
bc6fb241a0
Merge pull request #13139 from francois-berder/mips-cflags
makefiles: arch: mips: Allow CFLAGS_DBG and CFLAGS_OPT to be overridden
2020-02-12 00:02:20 +01:00
e969b2fcd5
cpu/atmega_common: move common dependencies 2020-01-28 13:20:53 +01:00
Francois Berder
10939f2a57 makefiles: arch: mips: Allow CFLAGS_DBG and CFLAGS_OPT to be overridden
Signed-off-by: Francois Berder <18538310+francois-berder@users.noreply.github.com>
2020-01-15 22:00:58 +00:00
b56827323c
make/mips: cleanup include makefile
Remove a useless export of the ABI variable, fix indentation
2020-01-10 15:08:12 +01:00
ff00097992
cpu/cortexm: cleanup cortexm.inc.mk
- fix indent
- remove unnecessary exports
2020-01-03 14:19:48 +01:00
Francisco
45b2cca14f
Merge pull request #13018 from aabadie/pr/make/linkflags_remove_exports
make: remove use of export with LINKFLAGS variable
2020-01-02 16:37:04 +01:00
df376aeef7
make/cortexm: fix mfpu flag for CortexM7
Use single precision, like with M4 instead of double precision
2020-01-02 14:40:50 +01:00
7c121000ce
make/riscv: remove use of export for LINKFLAGS 2020-01-02 09:51:20 +01:00
b664de5593
make/msp430: remove use of export for LINKFLAGS 2020-01-02 09:50:55 +01:00
1e8528d6e8
cpu/mips: remove use of export for LINKFLAGS 2020-01-02 09:48:46 +01:00
27e8caf3f3
Merge pull request #12526 from kaspar030/fix_fe310_default_optimization
cpu/fe310: change default optimization to "-Os"
2019-11-15 13:10:13 +01:00
benpicco
80c00339a4
Merge pull request #12477 from francois-berder/mips-refactor
cpu: mips*: Reorganize headers
2019-10-21 15:26:45 +02:00
1193b0b1f8 cpu/fe310: change default optimization to "-Os"
Also moves the option to CFLAGS_OPT.
2019-10-21 11:27:21 +02:00
Benjamin Valentin
b1ef68abf7 cpu/atmega_common: move periph/cpuid.c to common code
Both atmega128rfa1 and atmega256rfr2 implement it.
2019-10-17 19:20:31 +02:00
Francois Berder
9af14d7eb2 makefiles: arch: mips: Define CPU_MODEL in CFLAGS
Signed-off-by: Francois Berder <18538310+francois-berder@users.noreply.github.com>
2019-10-16 20:00:32 +01:00
Gaëtan Harter
7416337d4d
makefiles/arch/cortexm.inc.mk: remove clang 3.6.2 workaround
Remove the workaround for clang 3.6.2 that did not support
'cortex-m0plus'.

clang 3.8 was already supporting it according to the PR introducing the check.
clang >=3.8 is avaible since ubuntu-xenial and debian-stretch.
The current ubuntu-bionic has clang 6 and debian-buster clang 7.

This removes overwriting 'CPU_ARCH'.
2019-10-08 16:19:51 +02:00
benpicco
5f6065f567
Merge pull request #12338 from cladmi/pr/make/cortexm/do_not_set_cpu_model
makefiles/arch/cortexm.inc.mk: removing setting CPU_MODEL
2019-10-01 15:25:16 +02:00
Gaëtan Harter
3a938d43e7
makefiles/arch/cortexm.inc.mk: removing setting CPU_MODEL
All cortexm boards should now define it on there own.
2019-10-01 11:38:35 +02:00
benpicco
5105a2e54d
Merge pull request #12340 from cladmi/pr/makefiles/board_cpu_macros
makefiles: CFLAGS convert to the uppercase function instead of using the shell
2019-09-30 19:53:28 +02:00
Gaëtan Harter
0303b96441
makefiles/arch/mips.inc.mk: use makefiles/utils lowercase function
Use the new common 'lowercase' function from makefiles/utils.
2019-09-30 17:35:06 +02:00
Gaëtan Harter
ba55d1d7f5
makefiles/arch/cortexm.inc.mk: use makefiles/utils uppercase
Convert the variables to uppercase using the 'makefiles/utils' function.
2019-09-30 17:25:24 +02:00
Juan Carrano
63c475cd4d toolchain/cflags: enable dwarf compression.
Use the -gz option to compress ELF sections containing DWARF information.
This saves around 50% of disk space, without any side effects.

See https://gcc.gnu.org/onlinedocs/gcc-9.2.0/gcc/Debugging-Options.html#Debugging-Options
for more infomation on this option.

Some platforms have an outdated toolchain that does not support -gz so
the flag is blacklisted there. Even then, the results are quite impressive.

I used @cladmi's `buildtest` branch (https://github.com/cladmi/RIOT/tree/wip/du/buildtest)
with this change and compiled the `examples/default` application:

```
$ BUILD_IN_DOCKER=1 DOCKER="sudo docker" make -C examples/default buildtest-indocker
```

The size was obtained with:

```
$ find output -name "*.bin.bindirsize" -type f -exec tail  -n1 '{}' \; | cut -f 1 | awk '{s+=$1} END {printf "%.0f", s}'
```

Results:

- Vanilla: 10328112 KB (~10GB).
- with -gz: 4982788 KB (~5GB).

This was inspired by #8496.
2019-09-02 14:43:26 +02:00
Gaëtan Harter
e4331e8391
cpu/arch: blacklist incompatible CFLAGS
Blacklist incompatible CFLAGS that are currently "optionally" included
in 'cflags.inc.mk'.

This prepares for the migration to 'OPTIONAL_CFLAGS'.
2019-08-29 17:43:54 +02:00
Gaëtan Harter
34f69245c3
makefiles: do not locally export compilation variables
These are already exported by `makefiles/vars.inc.mk`.
It is a prerequisite to allow handling compilation without global exports.
2019-08-29 10:35:36 +02:00
Gunar Schorcht
d84f75b4d0 cpu/atmega_common: activate wrapper functions when linking 2019-08-12 23:22:23 +02:00
Gaëtan Harter
2d5ed4f849
cortexm.inc.mk: remove deprecated USE_NANO_SPECS
It was replaced by using directly the `newlib_nano` module.
2019-07-22 16:54:06 +02:00
smlng
2de4b3011b periph_common: add as dependency to periph drivers
Rational: the periph_common module is required by (most) other periph drivers
and also during startup of the CPU/MCU to run periph_init. The latter is only
required if other periph drivers are used, hence periph_common should be a
depency of periph_* modules and *not* of the CPU/MCU. This PR fixes that
by making periph_common a depency of periph_* and removing the explicit
include in the CPU/MCU implementation.
2019-06-03 13:44:10 +02:00
Francisco Acosta
c897773daf makefiles: add atmega arch generic makefile 2019-02-05 17:12:01 +01:00
Dylan Laduranty
6d3fda7260 cpu/cortexm: add cortex-m23 support 2019-01-21 17:04:20 +01:00
Gaëtan Harter
89d7e2ec33
cortexm.inc.mk: detect 'arm-none-eabi-gcc' from ubuntu bionic
arm-gcc version from ubuntu bionic repository is not supported in RIOT.
Both when building with `gnu` and `llvm`.

    arm-none-eabi-gcc --version
    arm-none-eabi-gcc (15:6.3.1+svn253039-1build1) 6.3.1 20170620

So detect this version and print an error if found.

The check is done on the building machine and not on the host when building in
docker.

The error can be disabled when building with WERROR=0.
2019-01-10 13:27:22 +01:00
Vincent Dupont
06f0c14460 cortexm_common: enable FPU on cortex-m4f 2019-01-03 15:24:20 +01:00
Vincent Dupont
515d3a658b cpu/mips: use gnu99 by default 2018-10-04 08:48:43 +02:00
Vincent Dupont
192e79b175 cpu/msp430: use gnu99 by default 2018-10-04 08:48:43 +02:00
kenrabold
7d1d5e77d8 cpu/fe310: add RISC-V cpu FE310
New CPU FE310 from SiFive based on RISC-V architecture

build: add makefile for RISC-V builds

Makefile for builds using RISC-V tools
2018-05-29 15:21:45 -07:00
9312a711bc cpu/cortexm: explicitly set -march=armv6s-m for crotexm0(plus)
Works around a regression in gcc 8.1.
See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85606.
2018-05-11 23:07:25 +02:00