This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: cpp strange behavior for #line and #include
- To: egcs-bugs at cygnus dot com
- Subject: Re: cpp strange behavior for #line and #include
- From: rth at cygnus dot com (Richard Henderson)
- Date: 20 Jan 1998 20:03:31 -0800
- Newsgroups: cygnus.egcs.bugs
- Organization: Cygnus Solutions
- References: <199801202148.QAA04895.cygnus.egcs.bugs@melange.gnu.org>
In article <199801202148.QAA04895.cygnus.egcs.bugs@melange.gnu.org>,
Craig Burley <burley@gnu.org> wrote:
>The apparent cause of the problem is that this file, ldgram.c,
>contains a directive of the form:
>
>#line 20 "/net/ocean/blahblahblah..."
>
>Subsequently, this line appears:
>
>#include "bfd.h"
>
>cpp treats the latter as a possible reference to the following file:
>
> /net/ocean/blahblahblah.../bfd.h
It is a bit wierd, but I can see how it happened. Includes via ""
first check the directory the source file came from. Arguably this
should not change when you change the name of the source file.
>On my system, /net is, for some reason I don't fully understand,
>not readable -- it hangs when you do `ls /net'.
Check for a running amd or autofs. It is common for /net to be
set up to do automatic NFS mounts.
r~