qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] compiling qemu-0.7.2 on Solaris express (gcc-3.4.4)
@ 2005-09-05 13:21 Ben Taylor
  2005-09-05 15:55 ` Martin Bochnig
  0 siblings, 1 reply; 3+ messages in thread
From: Ben Taylor @ 2005-09-05 13:21 UTC (permalink / raw)
  To: qemu-devel

Testing the new qemu-0.7.2 on Solaris Express (11) using
gcc-3.4.4.  I'm getting a couple of weird errors
I can't seem to get my hands around.

in qemu-0.7.2/hw/apic.c

gcc -Wall -O2 -g -fno-strict-aliasing -fomit-frame-pointer -I. -I/export/src/qemu-05-18-05/test/qemu-0.7.2/target-i386 -I/export/src/qemu-05-18-05/test/qemu-0.7.2 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -I/export/src/qemu-05-18-05/test/qemu-0.7.2/fpu -I/export/src/qemu-05-18-05/test/qemu-0.7.2/slirp -c -o apic.o /export/src/qemu-05-18-05/test/qemu-0.7.2/hw/apic.c
Assembler: apic.c
        "/var/tmp//ccO3Ifuk.s", line 165 : Illegal mnemonic
        "/var/tmp//ccO3Ifuk.s", line 165 : Syntax error
gmake: *** [apic.o] Error 1


in i386-softmmu/op.h, I see:

gcc -Wall -O2 -g -fno-strict-aliasing -fomit-frame-pointer -I. -I/export/src/qemu-05-18-05/test/qemu-0.7.2/target-i386 -I/export/src/qemu-05-18-05/test/qemu-0.7.2 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -I/export/src/qemu-05-18-05/test/qemu-0.7.2/fpu -I/export/src/qemu-05-18-05/test/qemu-0.7.2/slirp -c -o translate-op.o /export/src/qemu-05-18-05/test/qemu-0.7.2/translate-op.c
In file included from /export/src/qemu-05-18-05/test/qemu-0.7.2/translate-op.c:36:
./op.h: In function `dyngen_code':
./op.h:1427: error: `par' undeclared (first use in this function)
./op.h:1427: error: (Each undeclared identifier is reported only once
./op.h:1427: error: for each function it appears in.)
./op.h:2247: error: `gen' undeclared (first use in this function)
gmake: *** [translate-op.o] Error 1

Ideas?  

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Qemu-devel] compiling qemu-0.7.2 on Solaris express (gcc-3.4.4)
  2005-09-05 13:21 [Qemu-devel] compiling qemu-0.7.2 on Solaris express (gcc-3.4.4) Ben Taylor
@ 2005-09-05 15:55 ` Martin Bochnig
  2005-09-05 16:09   ` Martin Bochnig
  0 siblings, 1 reply; 3+ messages in thread
From: Martin Bochnig @ 2005-09-05 15:55 UTC (permalink / raw)
  To: sol10x86, qemu-devel

Ben Taylor wrote:

>in qemu-0.7.2/hw/apic.c
>
>gcc -Wall -O2 -g -fno-strict-aliasing -fomit-frame-pointer -I. -I/export/src/qemu-05-18-05/test/qemu-0.7.2/target-i386 -I/export/src/qemu-05-18-05/test/qemu-0.7.2 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -I/export/src/qemu-05-18-05/test/qemu-0.7.2/fpu -I/export/src/qemu-05-18-05/test/qemu-0.7.2/slirp -c -o apic.o /export/src/qemu-05-18-05/test/qemu-0.7.2/hw/apic.c
>Assembler: apic.c
>        "/var/tmp//ccO3Ifuk.s", line 165 : Illegal mnemonic
>        "/var/tmp//ccO3Ifuk.s", line 165 : Syntax error
>gmake: *** [apic.o] Error 1
>
>
>Ideas?  
>
>
>  
>

Just use "gnu-as" (often called "gas") instead of SUNW's 
"/usr/ccs/bin/as" and (a patched) 0.7.2 will also compile on x86, not 
only on SPARC Solaris.
On Solaris10 or 11_nevada it is not required to custom-build gcc for 
doing so anymore, just use "/usr/sfw/bin/gcc". It will then use gas, but 
still not gnu-ld.
However, it works.


martin

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Qemu-devel] compiling qemu-0.7.2 on Solaris express (gcc-3.4.4)
  2005-09-05 15:55 ` Martin Bochnig
@ 2005-09-05 16:09   ` Martin Bochnig
  0 siblings, 0 replies; 3+ messages in thread
From: Martin Bochnig @ 2005-09-05 16:09 UTC (permalink / raw)
  To: qemu-devel

Martin Bochnig wrote:

 > Ben Taylor wrote:
 >
 >> Assembler: apic.c
 >> "/var/tmp//ccO3Ifuk.s", line 165 : Illegal mnemonic
 >> "/var/tmp//ccO3Ifuk.s", line 165 : Syntax error
 >> gmake: *** [apic.o] Error 1
 >>
 >>
 >> Ideas?
 >
 >
 > Just use "gnu-as" (often called "gas") instead of SUNW's 
"/usr/ccs/bin/as" and (a patched) 0.7.2 will also compile on x86, not 
only on SPARC Solaris.
 > On Solaris10 or 11_nevada it is not required to custom-build gcc for 
doing so anymore, just use "/usr/sfw/bin/gcc". It will then use gas, but 
still not gnu-ld.
 > However, it works.
 >
 >
 > martin


Well known problem. Solaris/x86 (all versions including 2.10) has a 
broken assembler (if not "broken" at least not 100.00% compatible to GNU)

So one must use the GNU assembler in certain cases.

To make it all work, I also had to build a custom gcc in my old x86 days 
which
was configured "--with-gnu-as" (and perhaps also "--with-gnu-ld", I
don't recall). The procedure is described in the gcc sources.
Today one may just use "/usr/sfw/bin/gcc", NOT 
"/opt/csw/gcc[2|3|4]/bin/gcc" !

Here you see the difference:

$ uname -a
SunOS daedal 5.8 Generic_117351-16 i86pc i386 i86pc
$ isainfo -v
32-bit i386 applications
$ /opt/csw/gcc3/bin/gcc -v
Reading specs from /opt/csw/gcc3/lib/gcc/i386-pc-solaris2.8/3.4.4/specs
Configured with: ../sources/gcc-3.4.4/configure --prefix=/opt/csw/gcc3 
--with-local-prefix=/opt/csw --without-gnu-as --with-as=/usr/ccs/bin/as 
--without-gnu-ld --with-ld=/usr/ccs/bin/ld --enable-threads=posix 
--enable-shared --enable-multilib --enable-nls --with-included-gettext 
--with-libiconv-prefix=/opt/csw --with-x --enable-java-awt=xlib 
--enable-languages=all
Thread model: posix
gcc version 3.4.4
$ ^D
Connection to daedal closed.
$ ssh zeus
Last login: Mon Sep 5 12:08:03 2005 from login
Sun Microsystems Inc. SunOS 5.10 Generic January 2005
$ uname -a
SunOS zeus 5.10 Generic i86pc i386 i86pc
$ isainfo -v
64-bit amd64 applications
sse2 sse fxsr amd_3dnowx amd_3dnow amd_mmx mmx cmov amd_sysc cx8 tsc
fpu
32-bit i386 applications
sse2 sse fxsr amd_3dnowx amd_3dnow amd_mmx mmx cmov amd_sysc cx8 tsc
fpu
$ /usr/sfw/bin/gcc -v
Reading specs from /usr/sfw/lib/gcc/i386-pc-solaris2.10/3.4.3/specs
Configured with: /builds/sfw10-gate/usr/src/cmd/gcc/gcc-3.4.3/configure 
--prefix=/usr/sfw --with-as=/usr/sfw/bin/gas --with-gnu-as 
--with-ld=/usr/ccs/bin/ld --without-gnu-ld --enable-languages=c,c++ 
--enable-shared
Thread model: posix
gcc version 3.4.3 (csl-sol210-3_4-branch+sol_rpath)
$

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2005-09-05 16:21 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-09-05 13:21 [Qemu-devel] compiling qemu-0.7.2 on Solaris express (gcc-3.4.4) Ben Taylor
2005-09-05 15:55 ` Martin Bochnig
2005-09-05 16:09   ` Martin Bochnig

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).