Giter Club home page Giter Club logo

Comments (2)

cfrantz avatar cfrantz commented on June 19, 2024

After digging in a bit more, it seems that the device struct defined in devices/device_config.bzl might be the best way to specify architecture specific flags that would get passed to the toolchain feature functions in toolchains/features/{common,embedded}.

I'm not quite sure if/how one might tie a toolchain with device config to a platform definition in platforms/BUILD. The toolchains seem to be bound to the architecture by the cpu constraint (via target_compatible_with of native.toolchain when the toolchains are registered). I'm curious if it makes sense to constrain on the platform as well? One could then link a device_config together with a platform definition and specify compiler/linker flags that you might want for your particular platform.

from bazel-embedded.

silvergasp avatar silvergasp commented on June 19, 2024

Sorry for the late reply. I've also been looking into this. I have been working on a complete rewrite of the toolchain suite using clang tools. Checkout bazel_rules_cc_toolchain which should support this better. The new approach allows you to swap out system libraries and sysroots fairly easily. I haven't added arm-none-eabi yet but that is eventually the goal.

The biggest challenge I am running into so far with risc-v is the lack of precompiled binaries for system libs e.g. libc, libc++ etc. ARM ships a distribution of GCC alongside pre-compiled and configured libc and libc++ implementations. This makes creating a toolchain suite a lot simpler.

If you have experience with risc-v toolchains more generally I'd be keen to collaborate on this.

from bazel-embedded.

Related Issues (13)

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.