[crosstool-ng] Internal compiler error with gcc 4.3.2 + patch
Yann E. MORIN
yann.morin.1998@anciens.enib.fr
Wed Aug 5 21:15:00 GMT 2009
Thomas,
All,
On Wednesday 05 August 2009 21:13:10 Thomas Petazzoni wrote:
> thomas@surf:/tmp/tst$ cat foobar.sh
> #!/bin/sh
> . "test.mk"
> thomas@surf:/tmp/tst$ cat test.mk
> export foo=bar
> thomas@surf:/tmp/tst$ echo $PATH
> /home/thomas/sys/bin/:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
> thomas@surf:/tmp/tst$ sh foobar.sh
> .: 2: test.mk: not found
OK, I identified the problem: your shell is ash (or dash), while mine is
bash. When I explictly require ash (#!/bin/ash), then I have the exact same
error as you have. It seems that ash uses PATH to resolve the "." builtin.
When one does:
. ./paths.mk
then it works with ash (and bash as well).
In this case, ash is correct. See:
http://www.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#dot
where it is stated:
... If /file/ does not contain a <slash>, the shell shall use the search
path specified by PATH to find the directory containing /file/. ...
Thank you for pointing this problem out. I will fix that.
Regards,
Yann E. MORIN.
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +0/33 662376056 | Software Designer | \ / CAMPAIGN | ___ |
| --==< ^_^ >==-- `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
`------------------------------^-------^------------------^--------------------'
--
For unsubscribe information see http://sourceware.org/lists.html#faq
More information about the crossgcc
mailing list