diff options
| author | Antoni Boucher <bouanto@zoho.com> | 2023-09-13 18:56:06 -0400 |
|---|---|---|
| committer | Antoni Boucher <bouanto@zoho.com> | 2023-09-14 19:55:19 -0400 |
| commit | 45c501cdf9e711c8d7c8d06250fdc2a84caf69bd (patch) | |
| tree | 14c82536754c9e6407bdd238b10954dd566c25e2 | |
| parent | adc0b210f31324af637517aa28d81772fdf28719 (diff) | |
| download | rust-45c501cdf9e711c8d7c8d06250fdc2a84caf69bd.tar.gz rust-45c501cdf9e711c8d7c8d06250fdc2a84caf69bd.zip | |
Add note to readme
| -rw-r--r-- | Readme.md | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/Readme.md b/Readme.md index daee6e8588d..1666cbc4f75 100644 --- a/Readme.md +++ b/Readme.md @@ -205,6 +205,19 @@ error: failed to build archive: failed to open object file: No such file or dire That can be caused by the fact that you try to compile with `lto = "fat"`, but you didn't compile the sysroot with LTO. (Not sure if that's the reason since I cannot reproduce anymore. Maybe it happened when forgetting setting `FAT_LTO`.) +### ld: cannot find crtbegin.o + +When compiling an executable with libgccijt, if setting the `*LIBRARY_PATH` variables to the install directory, you will get the following errors: + +``` +ld: cannot find crtbegin.o: No such file or directory +ld: cannot find -lgcc: No such file or directory +ld: cannot find -lgcc: No such file or directory +libgccjit.so: error: error invoking gcc driver +``` + +To fix this, set the variables to `gcc-build/build/gcc`. + ### How to debug GCC LTO Run do the command with `-v -save-temps` and then extract the `lto1` line from the output and run that under the debugger. |
