Hello,
On Ubuntu Karmic `./config/scripts/switch-arch cross-ppc` did not
recognize my powerpc-elf-gcc. The GNOME Terminal appears to use bash,
where `type -p powerpc-elf-gcc && echo yah` works, but /bin/sh is
dash, where it does not:
echo "type -p powerpc-elf-gcc && echo yah" | /bin/sh
The following change made it work.
Andreas
diff --git a/config/scripts/switch-arch b/config/scripts/switch-arch
index c145e86..19dd877 100755
--- a/config/scripts/switch-arch
+++ b/config/scripts/switch-arch
@@ -88,7 +88,7 @@ select_prefix()
{
for TARGET in ${1}-linux-gnu- ${1}-elf- ${1}-eabi-
do
- if type -p ${TARGET}gcc > /dev/null
+ if which ${TARGET}gcc > /dev/null
then
return
fi