[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] MinGW build
From: |
Peter Maydell |
Subject: |
Re: [Qemu-devel] MinGW build |
Date: |
Wed, 26 Nov 2014 20:13:04 +0000 |
On 26 November 2014 at 19:55, Liviu Ionescu <address@hidden> wrote:
> since I had some troubles to build QEMU on Windows, I compiled a page with
> some instructions:
>
> http://gnuarmeclipse.livius.net/wiki/How_to_build_QEMU#Windows
>
> the purpose was to generate a standalone executable, that requires no
> libraries.
>
>
> although the procedure is fully functional, I had to apply a small patch,
> basically:
>
> #ifdef __MINGW32__
> #if !defined(ffs)
> #define ffs __builtin_ffs
> #endif
> #endif
>
> in several files.
Hmm. We have a workaround already for a similar thing in
include/sysemu/os-win32.h,
but that works by declaring a prototype rather than using a #define, and it's
guarded by defined(_WIN64). I wonder if some of those workarounds in that file
need to be guarded by more specific checks than just _WIN64...
Do you have any experience with mingw-w64? When I was doing Windows
(cross-compiled) builds mingw-w64 seemed to be more actively maintained
(even for 32 bit windows targets) than the original mingw project,
and I think there was at least one issue where the fix was basically
"don't try to use mingw, it's just too old, use mingw-w64 instead".
In any case, thanks very much for writing up the instructions -- we do
get people wanting to know how to build on Windows from time to time,
so it will be useful to be able to point them at instructions.
You might consider tweaking the instructions to recommend building in
a subdirectory (ie 'mkdir -p build/windows; cd build/windows;
../../configure; make'). This is good if you're going to be building
more than one configuration, and it also makes it easy to blow away
an old build by removing the whole build tree (distclean is not always
100% reliable especially if you track head-of-git often).
-- PMM
- [Qemu-devel] MinGW build, Liviu Ionescu, 2014/11/26
- Re: [Qemu-devel] MinGW build,
Peter Maydell <=
- Re: [Qemu-devel] MinGW build, Stefan Weil, 2014/11/26
- Re: [Qemu-devel] MinGW build, Liviu Ionescu, 2014/11/26
- Re: [Qemu-devel] MinGW build, Liviu Ionescu, 2014/11/27
- Re: [Qemu-devel] MinGW build, Peter Maydell, 2014/11/27
- Re: [Qemu-devel] MinGW build, Liviu Ionescu, 2014/11/27
- Re: [Qemu-devel] MinGW build, Stefan Weil, 2014/11/27
- Re: [Qemu-devel] MinGW build, Liviu Ionescu, 2014/11/27
- Re: [Qemu-devel] MinGW build, Peter Maydell, 2014/11/27
- Re: [Qemu-devel] MinGW build, Liviu Ionescu, 2014/11/27
- Re: [Qemu-devel] MinGW build, Peter Maydell, 2014/11/27