This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: include facility for .md files


On Mon, 19 Nov 2001, Alan Matsuoka wrote:

> On Mon, 19 Nov 2001, Aldy Hernandez wrote:
> 
> > hi alan.
> > 
> > the md include system seems to only work for absolute path names.  i
> > added (include "altivec.md") to my rs6000.md but running gen* on it
> > gives me:
> > 
> > 	altivec.md:13366: include file at  altivec.md not found
> > 
> > first, the error message is wrong, it should be:
> > 
> > 	rs6000.md:13366: blah
> > 	^^^^^^^^^
> > 
> > it can't open altivec.md because, at least for rs6000, the gen* programs
> > get fed an absolute path, ie:
> > 
> > ./genattrtab /source/net/gcc/gcc/config/rs6000/rs6000.md > tmp-attrtab.c
> > 
> > init_md_reader() does not initialize base_dir when an absolute filename
> > is given.  consequently, process_include() does not have a relative
> > path, and tries to open altivec.md in the build directory.
> > 
> > to reproduce, just add a simple (include "foobar") to rs6000.md and try
> > to make gcc on powerpc-elf.
> > 
> > could you fix this?
> > 
> Wierd.. I just tried on my laptop and it works fine. Tried on the G4 and it
> dies as advertised. I'm looking at it.
> 

Btw.. Why do you want to use absolute pathnames anyway ? Aren't hardcoded pathnames
taboo ?

Alan Matsuoka
GCC Engineering
Red Hat Canada, Ltd
mailto:alanm@redhat.com Tel: (416) 482-2661 x250 / Fax: (416) 482-6299


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]