buildroot eclipse bundle : a powerful ide for embedded ...€¦ · building an embedded linux...

19
Buildroot Eclipse Bundle : A powerful IDE for Embedded Linux developers Mélanie Bats, Obeo

Upload: others

Post on 24-May-2020

21 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Buildroot Eclipse Bundle : A powerful IDE for Embedded Linux

developers

Mélanie Bats, Obeo

Page 2: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Who Am I ?

Page 3: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

What is embedded Linux ?

Linux kernel

Open source components

Specific applications

Page 4: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Demo hardware platform

● Fairly typical ARM evaluation platform

● Many devices: Screen, Network, SD card, USB ...

● Used to develop prototypes

● Reference to design specific board Atmel AT91SAM9G45 (ARMv5) processor

Page 5: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Building an embedded Linux system

Binary distributions Building tools

PTXdistOpenWRT● Automate system

reconstruction from source code

● Support many more CPU architectures

● High flexibility on components configuration

● Most used solution

● Heavyweight systems

● Not all CPU architectures supported

● Not flexible to choose the configuration for each components

Page 6: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

What is Buildroot ?

● Simple build system - http://buildroot.org :– automate the cross compilation process – generate kernel images, file system and bootloader

● Developped by :– an open source community– vendor neutral– under GPLv2

● Actively developped and used for many products● Written in make language ● Choice of options in configuration interface

Page 7: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Buildroot Demo

Page 8: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Host (PC)

Buildroot

Buildroot generates

Target (ARM)Toolchain

DirectFB headers & lib

Openssh headers & lib

BusyBoxsource

DirectFB source

Opensshsource

Specific Library source

Target File System

Kernel Image

Applications

BusyBox

DirectFB

Openssh

Specific Library

Libc

Pre compiled Toolchain

gcc

gdb

binutils

Libc

gcc

gdb

binutils

Libc

Specific lib headers & lib

Various host utilities : Pkg-

config...

Kernelsource

Inpu

tsOutpu

ts

Page 9: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Why Integrating Buildroot in Eclipse ?

System developers Application developers

Page 10: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Why Integrating Buildroot in Eclipse ?

● Open source IDE for Application developers– Preconfigured with the cross compilation toolchain– Transfer / Execute remote application– Remote Debug

Page 11: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Buildroot toolchain Eclipse plugin

● Integrate the toolchains to Eclipse CDT– Read the toolchain description file (/home/.buildroot-

eclipse.toolchains)– Register dynamically the toolchains in CDT– Project toolchain selection:

● Set the C/C++ compiler path● Integration with scanner information● Remote Launch configuration● Remote Debug configuration

Page 12: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Integration with CDT

● Inspired by the Eclipse Blackfin plugin and the GNU ARM Eclipse plugin

● Use CDT extension point : org.eclipse.cdt.managedbuilder.core.buildDefinitions

– with a dynamicElementProvider and according to the Buildroot configuration file:

● declare toolchain ● projectType

Page 13: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Integration with CDT

● Missing dynamic extension points in CDT ?● scanner configuration discovery profile● launch configuration

Page 14: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Integration with CDT

Page 15: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Buildroot Eclipse Update-site

● Update-site integrating embedded Linux tools :– Buildroot Toolchain Eclipse Plugin– CDT – Linux tools– Autotools …

● Make a Ready-to-Use development platform for embedded Linux

Page 16: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Buildroot Eclipse plugin demonstration

Page 17: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Availability

● Buildroot : http://buildroot.org● Buildroot Eclipse plugin sources (EPL licence):

– https://github.com/mbats/eclipse-buildroot-toolchain-plugin– Also contains the Buildroot patch to add Eclipse toolchain

generation menu● Buildroot Eclipse bundle sources :

https://github.com/mbats/eclipse-buildroot-bundle● Buildroot Eclipse bundle update-site (based on Eclipse

3.8) : available soon

Page 18: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Future work

● Create an Eclipse bundle with Tycho which will be available on Buildroot website

● Integrate :– pkg-config– RX-TX– LTTNG– Other relevant Eclipse plugins for embedded Linux

development● Write documentation and make a video tutorial

Page 19: Buildroot Eclipse Bundle : A powerful IDE for Embedded ...€¦ · Building an embedded Linux system Binary distributions Building tools OpenWRT PTXdist ... Toolchain DirectFB headers

Questions ?

Contact :

[email protected]