mold: Unable to use mold with a (pseudo) cross compiler

~/r/mold ❯❯❯ conda create -n gccdev gxx_linux-64 -c conda-forge
~/r/mold ❯❯❯ conda activate gccdev

(gccdev) ~/r/mold ❯❯❯ $CC --version 
x86_64-conda-linux-gnu-cc (crosstool-NG 1.24.0.133_b0863d8_dirty) 9.3.0
Copyright (C) 2019 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.

(gccdev) ~/r/mold ❯❯❯ /tmp/ld --version 
mold 0.1.1 (782b7f9c55427f0ffea44543e6de44bc77f9e47e; compatible with GNU ld and GNU gold)

(gccdev) ~/r/mold ❯❯❯ echo 'int main() {return 0;}' | $CC -xc - -B/tmp
mold: library not found: gcc
collect2: error: ld returned 1 exit status

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 18 (18 by maintainers)

Most upvoted comments

0.9.3 has been released, and the fix for this bug is in that release.

Thank you! For now, mold works the --sysroot fixes 🙂