Best way to use RTEMS in existing project
Olivier C. Larocque
oclarocque at gmail.com
Fri May 19 09:42:31 UTC 2017
On Thu, May 18, 2017 at 2:07 PM, Joel Sherrill <joel at rtems.org> wrote:
>
>
> On May 18, 2017 5:20 AM, "Olivier C. Larocque" <oclarocque at gmail.com> wrote:
>
> Hi everyone,
>
> I have a project using Eclipse and System Workbench for STM32 (GNU ARM
> embedded toolchain) targeting a STM32F446 microcontroller. I am using
> a proprietary RTOS right now and would like to swap it for RTEMS so I
> can open source my work.
>
> I went through RTEMS documentation and did some tests to familiarize
> myself with RTEMS build system and how it handles BSPs.
>
> What I need to know is what is the best way to proceed.
>
> Do I need to use the complete RTEMS build system or I can add the core
> RTEMS OS files into my project and make the Eclipse build system
> manage them like I was doing with my other RTOS?
>
>
> Yes. You just need to make sure you pass the correct arguments for using
> RTEMS on that BSP. It will almost always be nothing more than this sequence
> of arguments. Look in the build and the make/custom file for your BSP for
> details.
>
> -B... --joel bsp_specs -brtems
>
> Plus the CPU_CFLAGS for your BSP.
>
> The first part adds the libraries and include path for the RTEMS install to
> the GCC invocation. The second adds specific CPU model flags.
>
> Beyond that, we don't care what you use for a build system.
When I build an example project from example-v2, that is what the
output looks like, so I guess it was the way you meant:
arm-rtems4.11-gcc --pipe
-B/home/oclarocque/development/rtems/4.11/arm-rtems4.11/stm32f4/lib/
-specs bsp_specs -qrtems -Wall -O2 -g -march=armv7-m -mthumb
-c -o o-optimize/test.o test.c
Does your --joel switch is equivalent to the -specs switch?
What about -brtems versus -qrtems?
> If using the complete RTEMS build system, what's the best way to tell
> it how to compile my application code? Should I recreate my project
> from scratch using examples-v2 like structure?
>
> What would you suggest?
>
> Thanks for your time
> _______________________________________________
> users mailing list
> users at rtems.org
> http://lists.rtems.org/mailman/listinfo/users
>
>
Thanks
Olivier
More information about the users
mailing list