Subject: Re: gcc problem
To: Stanislaw Grygiel <stach@ee.pdx.edu>
From: Krister Walfridsson <cato@df.lth.se>
List: netbsd-help
Date: 03/15/2000 20:59:09
On Sun, 12 Mar 2000, Stanislaw Grygiel wrote:
> It is netbsd-1.4.1 on DECstation 3100
> When linking a C program I got the following message several times:
> 
>  undefined reference to `_flush_cache'
> 
> The message is printed only for files where nested functions (gcc extension)
> are defined.
> 
> None of the libraries in /usr/lib contains _flush_cache symbol.
> It is contained in cc1, cc1obj, and cc1plus in /usr/libexec/ but the
> program won't link anyway.
> 
> I also tried to link with -static but it didn't help.
> 
> What am doing wrong?

You are probably not doing anything wrong, but rather have been bitten
by a bug in the gcc installation in netbsd-1.4.1. I know that nested
functions doesn't work for arm32 either (and I think it is broken for
68060 processors too.) I fixed it for arm a long time ago, but never
got around committing it...

I'll try to take a look at this before we ship NetBSD-1.5...

> And another question:
> I tried to to compile gcc-2.95.2 but got compiler complaining about
> missing mld library and ldfcn.h file. None of them exist in netbsd-1.4.1
> for DECstation 3100. Is it possible to compile it at all on netbsd-1.4.1?
> It compiles under Ultrix 4.2a for instance.

Gcc didn't build out of the box for NetBSD/pmax last time I checked. I
have promised I'll fix that before the next gcc release.

   /Krister