http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42947
Kyle Farnsworth <kyle at farnsworthtech dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |kyle at farnsworthtech dot com
--- Comment #1 from Kyle Farnsworth <kyle at farnsworthtech dot com> ---
I encountered this same issue. When I added the -print-sysroot option to see
what gcc was thinking was the sysroot setting it revealed this:
WITH -m4 option:
$ sh4-oe-linux-gcc -ml -m4 --sysroot=sysroots/sh775x-oe-linux -print-sysroot
sysroots/sh775x-oe-linux/m4
WITHOUT -m4 option:
$ sh4-oe-linux-gcc -ml --sysroot=sysroots/sh775x-oe-linux -print-sysroot
sysroots/sh775x-oe-linux
It appears some arguments are getting mangled and somehow the m4 option is
concatinated to the end of the sysroot.
My workaround was to add symlink sysroots/sh775x-oe-linux/m4 to point to "./".
$ sh4-oe-linux-gcc --version
sh4-oe-linux-gcc (GCC) 4.7.2