Bare_runtime

Website:

https://github.com/Fabien-Chouteau/bare_runtime

Author:
  • AdaCore
Maintainer:
  • Fabien Chouteau <fabien.chouteau@gmail.com>
License:

GPL-3.0-or-later WITH GCC-exception-3.1

Version:

14.0.0

Alire CI:

Dependencies:
  • image/svg+xml gnat ^14
Dependents:

No dependents.

Badge:

Minimal Ada/SPARK run-time for embedded or other restricted targets

#embedded #runtime

Usage

First edit you alire.toml file and add the following elements:

  • Add bare_runtime in the dependency list:
    [[depends-on]]
    bare_runtime = "*"
    
  • Add cross GNAT in the dependency list (e.g. gnat_arm_elf):
    [[depends-on]]
    gnat_arm_elf = "*"
    
  • Set the architecture build switches, we use ARM Cortex-M4F as an example here:
    [gpr-set-externals]
    BARE_RUNTIME_SWITCHES = "-mlittle-endian -mthumb -mfloat-abi=hard -mcpu=cortex-m4 -mfpu=fpv4-sp-d16"
    

Then edit your project file to add the following elements:

  • “with” the run-time project file. With this, gprbuild will compile the run-time before your application
    with "bare_runtime.gpr";
    
  • Specify the Target and Runtime attributes: ```ada for Target use “arm-eabi”; for Runtime (“Ada”) use Bare_Runtime’Runtime (“Ada”);