Skip to contentSkip to conversation

error: PIC register 'ebx' clobbered in 'asm'

DISCUSSION Serge Leschinsky 2 participants 2 messages Dec 18, 2008 – Dec 24, 2008 KVM

lore
Share & tools
lore
#0 lore raw

Hello,

I tried to compile kvm and got the following error:
"PIC register 'ebx' clobbered in 'asm'"

Could you please explain me how to fix it?

kvm-81,
linux-2.6.27.9,
gcc -v:

	i686-pc-linux-gnu
	Thread model: posix
	gcc version 4.1.2

make[1]: Entering directory `/data/build/tmp/kvm-81/user'
gcc -D__i386__ -I /data/build/tmp/kvm-81/kernel/include -m32 -O1 -MMD -MF
test/x86/.vmexit.d -g -fomit-frame-pointer -Wall -fno-stack-protector -I
../libkvm -std=gnu99 -ffreestanding -I test/lib -I test/lib/x86 -c -o
test/x86/vmexit.o test/x86/vmexit.c
test/x86/vmexit.c: In function 'main':
test/x86/vmexit.c:30: warning: implicit declaration of function 'printf' test/x86/vmexit.c:28: error: PIC register 'ebx' clobbered in 'asm' make[1]: *** [test/x86/vmexit.o] Error 1
make[1]: Leaving directory `/data/build/tmp/kvm-81/user'
make: *** [user] Error 2

Thanks

--
Serge

#1 lore raw
Quoted 8 lines · Serge Leschinsky

Hello,

I tried to compile kvm and got the following error:
"PIC register 'ebx' clobbered in 'asm'"

Could you please explain me how to fix it?

Just comment out the entire for loop; it's a unit test not used during runtime. I've committed a real fix.

Signature · 1 line
error compiling committee.c: too many arguments to function