FreddieChopin / bleeding-edge-toolchain

All-in-one script to build bleeding-edge-toolchain for ARM microcontrollers
71 stars 24 forks source link

build errors on openSUSE Leap 42.2 #7

Open cszawisza opened 7 years ago

cszawisza commented 7 years ago

Hi! build-bleeding-edge-toolchain.sh faild to build on my system, It seams that on opensuse libraries needs to be located in ${top}/${buildFolder}/${prerequisites}/${<NAME>}/lib insted of${top}/${buildFolder}/${prerequisites}/${<NAME>}/lib64

the workaround is to add ln -s ${top}/${buildFolder}/${prerequisites}/${<NAME>}/lib64 ${top}/${buildFolder}/${prerequisites}/${<NAME>}/lib for GMP, MPFR, MPC, ISL and EXPAT libraries

I don't provide an diff for this workaround, because I don't know haw would it impact other systems.

FreddieChopin commented 7 years ago

Seems this might be the reason - http://stackoverflow.com/a/9280009/157344 The solution would then be to either force --libdir=... for each of the prerequisites or to discover this lib directory and just pass it to all scripts which need it - for example by adding --with-gmp-lib=... option. The second option seems a bit more "generic", but I have no strong opinion here. Any thoughts?

Could you show the output of these two commands?

echo ${CONFIG_SITE}
cat ${CONFIG_SITE}
cszawisza commented 7 years ago
echo ${CONFIG_SITE}
/usr/share/site/x86_64-unknown-linux-gnu

https://gist.github.com/cszawisza/e3f27b5c84df78cab03c798115a3042f

kemonats commented 3 years ago

The issue is old, but the solution may be useful. You need to delete the CONFIG_SITE variable, that is

set -eu

# add this line
unset CONFIG_SITE

binutilsVersion="2.34"

Another solution is to run script as:

CONFIG_SITE= ./build-bleeding-edge-toolchain.sh

Tested on OpenSUSE Leap 15.2

FreddieChopin commented 3 years ago

@kemonats - could you provide a pull request? (;

kemonats commented 3 years ago

Maybe it is enough to add to README.md that for OpenSUSE the script should be run like this:

CONFIG_SITE= ./build-bleeding-edge-toolchain.sh