lowRISC / lowRISC/lowrisc-chip

error while building riscv-tools

Open
#123 4 comments 0 reactions 0 assignees View on GitHub
Dominant language
SystemVerilog
Stars
601
Forks
147
PR merge metrics
No merged PRs in 30d

Description

Hello
I am trying to work with lowrisc So I followed this link : https://www.lowrisc.org/docs/debug-v0.3/zedboard/
So, I have set up the **env** as following :
```
export TOP=$PWD
export RISCV=$TOP/riscv-tools/riscv-gnu-toolchain
export PATH=$PATH:$RISCV/bin
export OSD_ROOT=$TOP/opensocdebug
export PATH=$OSD_ROOT/bin:$PATH
export FPGA_BOARD=$TOP/fpga/board/zed
```
Then I moved to the **riscv-tools** and I used the build script to set up the cross compiler:
```
cd riscv-tools
./build.sh
```
But , I keep getting the following error when reaching **newlib-gcc/gcc** :
```
/lowrisc-chip/riscv-tools/riscv-gnu-toolchain/build/src/newlib-gcc/gcc/ubsan.c:1473:23: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
|| xloc.file == '\0' || xloc.file[0] == '\xff'

```
Is there a solution please?

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reproducing ./build.sh from riscv-tools with the environment variables shown in the issue. Inspect the failing newlib-gcc/gcc/ubsan.c location and the surrounding build output to identify the toolchain compatibility problem. Done means the riscv-tools build completes successfully and produces the cross-compiler.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
compilers
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.