Subject: Re: -mcpu=ultrasparc problems
To: None <segv@netctl.net>
From: Takeshi Nakayama <tn@catvmics.ne.jp>
List: port-sparc64
Date: 02/27/2006 03:51:27
>>> segv@netctl.net wrote

> Hi, I'm trying to build 32-bit sparc port of NetBSD-current to run on sun4u
> platform. Setting  COPTS+=-mcpu=ultrasparc results in the following error:
> 
> --- sparc.o ---
> /opt/xsrc/xfree/xc/extras/Mesa/src/mesa/sparc/sparc.c: In function
> `_mesa_init_sparc_glapi_relocs':
> /opt/xsrc/xfree/xc/extras/Mesa/src/mesa/sparc/sparc.c:167: warning: right shift
> count >= width of type
> /opt/xsrc/xfree/xc/extras/Mesa/src/mesa/sparc/sparc.c:170: warning: right shift
> count >= width of type
> *** [sparc.o] Error code 1
> 
> Shall I file a PR, or can anyone think of a quick patch to fix this?

If there is __sparc_v9__ macro in this file, change it to
__sparc64__ or something else.
__sparc_v9__ means that use SPARC V9 instructions, not 64-bit
environment.

-- Takeshi Nakayama