Skip to content

Conversation

AnnsAnns
Copy link
Contributor

Contribution description

Currently the print-version script used for debugging does not include information about the Rust and Frontend environment. While at it I thought it might also make sense to include information about the exact state the RIOT repository is in, esp. to debug cases where the RIOT repository might simply be outdated.

Before:

[ann@computer RIOT]$ make print-versions 

Operating System Environment
----------------------------
         Operating System: "EndeavourOS" 
                   Kernel: Linux 6.16.5-arch1-1 x86_64 unknown
             System shell: GNU bash, version 5.3.3(1)-release (x86_64-pc-linux-gnu)
             make's shell: GNU bash, version 5.3.3(1)-release (x86_64-pc-linux-gnu)

Installed compiler toolchains
-----------------------------
               native gcc: gcc (GCC) 15.2.1 20250813
        arm-none-eabi-gcc: missing
                  avr-gcc: missing
           msp430-elf-gcc: missing
       riscv-none-elf-gcc: missing
  riscv64-unknown-elf-gcc: missing
      riscv32-esp-elf-gcc: missing
     xtensa-esp32-elf-gcc: missing
   xtensa-esp32s2-elf-gcc: missing
   xtensa-esp32s3-elf-gcc: missing
   xtensa-esp8266-elf-gcc: missing
                    clang: clang version 20.1.8

Installed compiler libs
-----------------------
     arm-none-eabi-newlib: missing
        msp430-elf-newlib: missing
    riscv-none-elf-newlib: missing
riscv64-unknown-elf-newlib: missing
   riscv32-esp-elf-newlib: missing
  xtensa-esp32-elf-newlib: missing
xtensa-esp32s2-elf-newlib: missing
xtensa-esp32s3-elf-newlib: missing
xtensa-esp8266-elf-newlib: missing
                 avr-libc: missing (missing)

Installed development tools
---------------------------
                   ccache: missing
                    cmake: cmake version 4.1.1
                 cppcheck: missing
                  doxygen: missing
                      git: git version 2.51.0
                     make: GNU Make 4.4.1
                  openocd: missing
                   python: Python 3.13.7
                  python2: missing
                  python3: Python 3.13.7
                   flake8: error: /usr/bin/python3: No module named flake8
               coccinelle: missing

After:

[ann@computer RIOT]$ make print-versions 

RIOT version information
----------------------------
              RIOT branch: extend_print_version
         RIOT commit hash: 5d52edeb57ef88c5435dbccd55c14cb93a31e236
         RIOT commit date: 2025-09-21

Operating System Environment
----------------------------
         Operating System: "EndeavourOS" 
                   Kernel: Linux 6.16.5-arch1-1 x86_64 unknown
             System shell: GNU bash, version 5.3.3(1)-release (x86_64-pc-linux-gnu)
             make's shell: GNU bash, version 5.3.3(1)-release (x86_64-pc-linux-gnu)

Installed compiler toolchains
-----------------------------
               native gcc: gcc (GCC) 15.2.1 20250813
        arm-none-eabi-gcc: missing
                  avr-gcc: missing
           msp430-elf-gcc: missing
       riscv-none-elf-gcc: missing
  riscv64-unknown-elf-gcc: missing
      riscv32-esp-elf-gcc: missing
     xtensa-esp32-elf-gcc: missing
   xtensa-esp32s2-elf-gcc: missing
   xtensa-esp32s3-elf-gcc: missing
   xtensa-esp8266-elf-gcc: missing
                    clang: clang version 20.1.8

Installed compiler libs
-----------------------
     arm-none-eabi-newlib: missing
        msp430-elf-newlib: missing
    riscv-none-elf-newlib: missing
riscv64-unknown-elf-newlib: missing
   riscv32-esp-elf-newlib: missing
  xtensa-esp32-elf-newlib: missing
xtensa-esp32s2-elf-newlib: missing
xtensa-esp32s3-elf-newlib: missing
xtensa-esp8266-elf-newlib: missing
                 avr-libc: missing (missing)

Installed development tools
---------------------------
                   ccache: missing
                    cmake: cmake version 4.1.1
                 cppcheck: missing
                  doxygen: missing
                      git: git version 2.51.0
                     make: GNU Make 4.4.1
                  openocd: missing
                   python: Python 3.13.7
                  python2: missing
                  python3: Python 3.13.7
                    cargo: cargo 1.84.0 (66221abde 2024-11-19)
                    rustc: rustc 1.84.0 (9fc6b4312 2025-01-07)
                     node: v22.13.0
                      npm: 10.9.2
                   flake8: error: /usr/bin/python3: No module named flake8
               coccinelle: missing

Testing procedure

make print-version

Issues/PRs references

@github-actions github-actions bot added the Area: tools Area: Supplementary tools label Sep 21, 2025
@crasbe crasbe added Type: bug The issue reports a bug / The PR fixes a bug (including spelling errors) CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation and removed Type: bug The issue reports a bug / The PR fixes a bug (including spelling errors) labels Sep 21, 2025
@riot-ci
Copy link

riot-ci commented Sep 21, 2025

Murdock results

✔️ PASSED

48a7325 dist/tools/ci: include riscv32-unknown-elf in print-versions

Success Failures Total Runtime
1 0 1 01m:25s

Artifacts

@crasbe
Copy link
Contributor

crasbe commented Sep 21, 2025

Looks good, I just asked the other maintainers with more Rust experience if anything else should be evaluated too (since I don't know much about that kind of Rust 😅 )

@chrysn
Copy link
Member

chrysn commented Sep 22, 2025

c2rust --version and rustup --version would make sense as well.

While rustup is not technically required, we check through it whether the right cross toolchain is present, for it is the only widespread way to install those. (Debian ships cargo, but no cross toolchains.)

@AnnsAnns
Copy link
Contributor Author

AnnsAnns commented Sep 22, 2025

c2rust --version and rustup --version would make sense as well.

While rustup is not technically required, we check through it whether the right cross toolchain is present, for it is the only widespread way to install those. (Debian ships cargo, but no cross toolchains.)

Added 😄 I think on arch there is also a way to install Rust without rustup so its probably a common mistake people dont really notice (esp. in their first steps with Rust)

@AnnsAnns
Copy link
Contributor Author

AnnsAnns commented Sep 22, 2025

I just noticed on my work pc that riscv32-unknown-elf is not tracked, partly because the riscv toolchain ecosystem is confusing as heck and everyone has their own names. riscv32-unknown-elf is used on Arch though. (btw I use Arch)

The output looks like this now:

[ann@ann-laptop13 nondocsriot]$ make print-versions

RIOT version information
----------------------------
              RIOT branch: extend_print_version
         RIOT commit hash: 28c9ef8f17f2010074185b5705bfbcac116c55e7
         RIOT commit date: 2025-09-22

Operating System Environment
----------------------------
         Operating System: "EndeavourOS"
                   Kernel: Linux 6.16.7-arch1-1 x86_64 unknown
             System shell: GNU bash, version 5.3.3(1)-release (x86_64-pc-linux-gnu)
             make's shell: GNU bash, version 5.3.3(1)-release (x86_64-pc-linux-gnu)

Installed compiler toolchains
-----------------------------
               native gcc: gcc (GCC) 15.2.1 20250813
        arm-none-eabi-gcc: arm-none-eabi-gcc (Arch Repository) 14.2.0
                  avr-gcc: missing
           msp430-elf-gcc: missing
       riscv-none-elf-gcc: missing
  riscv64-unknown-elf-gcc: missing
      riscv32-esp-elf-gcc: missing
  riscv32-unknown-elf-gcc: riscv32-unknown-elf-gcc (g95eb81363) 14.3.1 20250819
     xtensa-esp32-elf-gcc: missing
   xtensa-esp32s2-elf-gcc: missing
   xtensa-esp32s3-elf-gcc: missing
   xtensa-esp8266-elf-gcc: missing
                    clang: clang version 20.1.8

Installed compiler libs
-----------------------
     arm-none-eabi-newlib: "4.5.0"
        msp430-elf-newlib: missing
    riscv-none-elf-newlib: missing
riscv64-unknown-elf-newlib: missing
   riscv32-esp-elf-newlib: missing
riscv32-unknown-elf-newlib: "4.4.0"
  xtensa-esp32-elf-newlib: missing
xtensa-esp32s2-elf-newlib: missing
xtensa-esp32s3-elf-newlib: missing
xtensa-esp8266-elf-newlib: missing
                 avr-libc: missing (missing)

Installed development tools
---------------------------
                   ccache: ccache version 4.12
                    cmake: cmake version 4.1.1
                 cppcheck: missing
                  doxygen: 1.14.0
                      git: git version 2.51.0
                     make: GNU Make 4.4.1
                  openocd: Open On-Chip Debugger 0.12.0+dev-gcf9c0b41c (2025-03-19-13:40)
                   python: Python 3.13.7
                  python2: missing
                  python3: Python 3.13.7
                   rustup: rustup 1.28.2 (e4f3ad6f8 2025-04-28)
                    cargo: cargo 1.87.0 (99624be96 2025-05-06)
                    rustc: rustc 1.87.0 (17067e9ac 2025-05-09)
                   c2rust: C2Rust 0.19.0
                     node: v22.8.0
                      npm: 10.8.3
                   flake8: error: /usr/bin/python3: No module named flake8
               coccinelle: missing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: tools Area: Supplementary tools CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants