-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
support for macOS #509
Comments
This doesn't look like a riscv-gnu-toolchain problem. |
You can find macos toolchain binaries on the SiFive web site, but I don't know if that will help you, as this isn't a riscv-gnu-toolchain problem. |
HI guys,
Here I was facing 2 issues,
Linux Tool Build binutiles & gcc But glibc is failing to build, Error is related to make version as follows. *** These critical programs are missing or too old: make Here I was using latest make of 4.2 but still getting this Error, can anyone help me to resolve this issue. Here sysroot is not build, Because of glibc faillure, so I copied ubuntu build riscv sysroot to Mac it was working, But still I need to build glibc on MACos Machine.
riscv64-unknown-linux-gnu-c++ is not building, To resolve this issue I configured tool with --enable-languages=c,c++ But still riscv64-unknown-linux-gnu-c++ is not building Can anyone help me to resolve this issue. Thanks, |
On Mon, Oct 14, 2019 at 7:56 AM cghalibkhan ***@***.***> wrote:
1.
1'st issue is :
-------------------------
Linux Tool Build binutiles & gcc But glibc is failing to build, Error is
related to make version as follows.
*** These critical programs are missing or too old: make
I don't have a mac, but know that building stuff there can be tricky. The
shell code glibc uses to check the make version number is
ac_prog_version=`$MAKE --version 2>&1 | sed -n 's/^.*GNU
Make[^0-9]*\([0-9][0-9.]*\).*$/\1/p'`
If make is GNU make, and the version number is correct (4.1 or later), then
maybe the problem is with sed.
In fact, looking at the sifive/freedom-tools which has macos support (but
not linux toolchain support), I see the makefile has for darwin (aka macos)
LIBTOOLIZE ?= glibtoolize
TAR ?= gtar
SED ?= gsed
AWK ?= gawk
2'nd issues is :
-----------------------------
riscv64-unknown-linux-gnu-c++ is not building, To resolve this issue I
configured tool with --enable-languages=c,c++
You didn't report the error here. C++ is configured and built by default
for linux toolchains, so something else is wrong, but the suggestion above
might help.
Jim
|
The GCC auto-configure scripts do not support the specifics of Darwin, which is a BSD derivative that has little to do with GNU. If you want to build GCC yourself on macOS you need to recreate a GNU environment, and probably the easiest way is via Homebrew. For details how to do it and what packages (tools and libraries) are required to build GCC, Google should be able to provide some good starting points. |
Thanks for your reply.
clang_with_riscv_release_src_build.log
riscv64-unknown-linux-gnu-addr2line please help me to overcome this issue. Thanks, |
Regarding the 1st issue, I made a few changes in the makefiles to resolve make version issue. make issue resolved but getting a linker error. /Users/macagent/khan/clang-r1.0/riscv-gnu-toolchain/install/lib/gcc/riscv64-unknown-linux-gnu/9.2.0/../../../../riscv64-unknown-linux-gnu/bin/ld: /Users/macagent/khan/clang-r1.0/riscv-gnu-toolchain/riscv-glibc/elf/dl-environ.c:68: undefined reference to |
Hi @cghalibkhan: Could you check your file system is case-sensitive or case-insensitive? glibc must build on case-sensitive system, those error message seems like I got on case-insensitive file system before. |
In case it helps anyone else reading this issue (does anyone read open issues that have been untouched for > a year?) that macro-level problem is known and is being ignored by the Sipeed team responsible for that BSP. They've pushed back to Nuclei, designer of the core, but it's been frozen for a while. sipeed/platform-gd32v#6 It's been duped dozens of times, so they've heard the request. I've found joy using the Homebrew build on GD32V. Even GDB works great on Segger Mini. You could probably teach Platform IO to call this build by shimming shell scripts to call the Homebrew version or knocking up the path or whatever so the IDE calls the "real" GNU chain provided by Homebrew. |
Issues relating to building the toolchain on macOS discussed and clarified. No RISC-V GCC toolchain issue identified. |
Try to use GD32 (Sipeed Longan Nano) with PlatformIO on macOS with no luck.

Can you add support?
The text was updated successfully, but these errors were encountered: