Coder Social home page Coder Social logo

sidero-toolchain's Introduction

toolchain

Dependency Diagram

This repository produces a C toolchain with the following components:

  • binutils
  • linux headers
  • libstdc++
  • musl-libc
  • gcc

The toolchain is configured to produce binaries with a search path set to /toolchain/lib. This allows for a clean separation from the host distribution on which the toolchain will be used.

We suggest using this toolchain to create an intermediate rootfs with the tools required to build source code. For example, make can be built using this toolchain, and it will be installed to /toolchain. Once a complete set of binaries are built and installed to /toolchain, the original host is no longer required to build source code. At that point you can set you $PATH to /toolchain/bin and build source code independent of the host distribution.

Development

The development of this toolchain depends on Docker 19.03.0 or greater and bldr. The toolchain can be built for different architectures (e.g. x86_64, aarch64, etc.). To do this you will need to setup the proper docker context for the architecture you intend on building for. For example, to setup the build for aarch64 (arm64):

docker context create arm64 \
    --description "An arm64 builder" \
    --docker "host=tcp://$IP:2376,ca=${HOME}/.docker/client/ca.pem,cert=${HOME}/.docker/client/cert.pem,key=${HOME}/.docker/client/key.pem"
docker buildx create \
    --use \
    --name arm64-builder \
    arm64

Note: You can run the above steps against an x86_64 machine, substituting arm64 with amd64.

Then, to build:

make USERNAME=${DOCKER_HUB_USERNAME} PLATFORM=linux/arm64 PUSH=true

Note: You can use PLATFORM=linux/amd64,linux/arm64 if you have configured docker with and amd64 and arm64 contexts.

Resources

sidero-toolchain's People

Contributors

smira avatar frezbo avatar andrewrynhard avatar aleksi avatar rsmitty avatar timjones avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.