Closed hoangt closed 6 years ago
You can install the missing packages. The names depend on which OS/distro you are using, but is probably something like libgmp-dev, libmpfr-dev, and libmpc-dev. The "dev" might be "devel".
Or you can download sources for the packages and add them to your gcc tree, and they will be built as part of the gcc build.
If you are building really old versions of gcc, it is possible that current gmp/mpfr/mpc versions might not be compatible with it, and you might need to use old versions of them, which means you will need to use the approach of downloading old versions of their sources and adding them to your gcc tree.
The "fix" in the riscv-gnu-toolchain tree is to add source packages to the repo and makefile rules to download and unpack them. But this "fix" causes other problems, so it is best not to rely on it. I see no reason to backport this "fix" to other branches.
@palmer-dabbelt
I checked out the old versions via their tags (priv-1.7, priv-1.9 etc.). Following installation steps,
Error message occurred when riscv-gnu-toolchain was built. It has been fixed in commit "efa614e51" but it was not fixed for versions before that commit.