[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v4] Add optionrom compatible with fw_cfg DMA ver
From: |
Stefan Hajnoczi |
Subject: |
Re: [Qemu-devel] [PATCH v4] Add optionrom compatible with fw_cfg DMA version |
Date: |
Wed, 3 Feb 2016 09:47:10 +0000 |
User-agent: |
Mutt/1.5.24 (2015-08-30) |
On Tue, Feb 02, 2016 at 01:58:14PM +0100, Marc Marí wrote:
> El Tue, 02 Feb 2016 12:06:27 +0100
> Gerd Hoffmann <address@hidden> escribió:
> > Hi,
> >
> > > %.img: %.o
> > > - $(call quiet-command,$(LD) $(LDFLAGS_NOPIE) -Ttext 0 -e
> > > _start -s -o $@ $<," Building $(TARGET_DIR)$@")
> > > + $(call quiet-command,$(LD) $(LDFLAGS_NOPIE) -m elf_i386
> > > -Ttext 0 -e _start -s -o $@ $<," Building $(TARGET_DIR)$@")
> >
> > Hmm, that breaks the windows cross build:
> >
> > make: Entering directory `/home/kraxel/projects/qemu/build-win32'
> > Building optionrom/linuxboot_dma.img
> > i686-w64-mingw32-ld: unrecognised emulation mode: elf_i386
> > Supported emulations: i386pe
> > make[1]: *** [linuxboot_dma.img] Error 1
>
> Thanks for reporting.
>
> I don't know much about Windows cross-builds. Any idea on how to solve
> the issue?
The Windows toolchain doesn't use ELF binaries so -m elf_i386 doesn't
work there (the emulation is called "i386pe" in i686-w64-mingw32-ld).
I wonder whether it's possible to use gcc -m32 ... -o $@ %< as a wrapper
that automatically does the right thing. But I guess it won't work
since gcc wants a C source file and not an object file as input.
You could make the emulation ("elf_i386" vs "i386pe") conditional on the
host platform (CONFIG_WIN32=y).
I'm not sure what the most elegant solution is.
Stefan
signature.asc
Description: PGP signature
- Re: [Qemu-devel] [PATCH v4] Add optionrom compatible with fw_cfg DMA version, Gerd Hoffmann, 2016/02/02
- Re: [Qemu-devel] [PATCH v4] Add optionrom compatible with fw_cfg DMA version, Gerd Hoffmann, 2016/02/02
- Re: [Qemu-devel] [PATCH v4] Add optionrom compatible with fw_cfg DMA version, Marc Marí, 2016/02/02
- Re: [Qemu-devel] [PATCH v4] Add optionrom compatible with fw_cfg DMA version, Gerd Hoffmann, 2016/02/02
- Re: [Qemu-devel] [PATCH v4] Add optionrom compatible with fw_cfg DMA version, Laszlo Ersek, 2016/02/02
- Re: [Qemu-devel] [PATCH v4] Add optionrom compatible with fw_cfg DMA version, Gerd Hoffmann, 2016/02/03
- Re: [Qemu-devel] [PATCH v4] Add optionrom compatible with fw_cfg DMA version, Laszlo Ersek, 2016/02/03
- Re: [Qemu-devel] [PATCH v4] Add optionrom compatible with fw_cfg DMA version, Gerd Hoffmann, 2016/02/03
Re: [Qemu-devel] [PATCH v4] Add optionrom compatible with fw_cfg DMA version, Marc Marí, 2016/02/02
- Re: [Qemu-devel] [PATCH v4] Add optionrom compatible with fw_cfg DMA version,
Stefan Hajnoczi <=