Home

Awesome

asdf-nerves-toolchain Build Lint

nerves-toolchain plugin for the asdf version manager.

This lets you use the official Nerves cross toolchains outside of Elixir. These provide recent versions of GCC with either musl libc or GNU libc for Intel, 32-bit and 64-bit ARM, RISC-V and MIPS.

$ asdf install nerves-toolchain v13.2.0-riscv64-nerves-linux-gnu
$ asdf local nerves-toolchain v13.2.0-riscv64-nerves-linux-gnu
$ riscv64-nerves-linux-gnu-gcc --version
riscv64-nerves-linux-gnu-gcc (crosstool-NG UNKNOWN) 13.2.0
Copyright (C) 2023 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Contents

Dependencies

Nerves toolchain releases are large and hosted on GitHub. It is recommended to create a GitHub API token and export it as GITHUB_API_TOKEN to avoid throttling.

Install

Plugin:

asdf plugin add nerves-toolchain https://github.com/nerves-project/asdf-plugin-nerves-toolchain.git
# Once https://github.com/asdf-vm/asdf-plugins/pull/994 is merged, run this instead:
asdf plugin add nerves-toolchain

nerves-toolchain:

# Show all installable versions. Only toolchains compatible with the current OS/arch
# will be displayed.
asdf list-all nerves-toolchain

# Install specific version
asdf install nerves-toolchain v13.2.0-aarch64-nerves-linux-gnu

# Set a version globally (on your ~/.tool-versions file)
asdf global nerves-toolchain v13.2.0-aarch64-nerves-linux-gnu

Check asdf readme for more instructions on how to install & manage versions.

Contributing

Contributions of any kind welcome! See the contributing guide.

Thanks goes to these contributors!

License

See LICENSE.