From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47998) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a1uar-0000Vy-2V for qemu-devel@nongnu.org; Thu, 26 Nov 2015 06:20:05 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a1uan-0005jU-5l for qemu-devel@nongnu.org; Thu, 26 Nov 2015 06:20:05 -0500 Received: from qemu.weilnetz.de ([37.221.198.45]:44838) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a1uam-0005iw-Vx for qemu-devel@nongnu.org; Thu, 26 Nov 2015 06:20:01 -0500 From: Stefan Weil Date: Thu, 26 Nov 2015 12:19:56 +0100 Message-Id: <1448536796-9299-1-git-send-email-sw@weilnetz.de> Subject: [Qemu-devel] [PATCH for-2.5] w32: Use gcc option -mthreads List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: QEMU Developer , Peter Maydell Cc: Paolo Bonzini , David Engraf , Stefan Weil QEMU uses threads / coroutines, therefore support for thread local storage and thread safe libraries (-D_MT) must be enabled by using -mthreads. Reported-by: David Engraf Signed-off-by: Stefan Weil --- configure | 2 ++ 1 file changed, 2 insertions(+) diff --git a/configure b/configure index 979bc55..67801b0 100755 --- a/configure +++ b/configure @@ -727,6 +727,8 @@ if test "$mingw32" = "yes" ; then QEMU_CFLAGS="-DWIN32_LEAN_AND_MEAN -DWINVER=0x501 $QEMU_CFLAGS" # enable C99/POSIX format strings (needs mingw32-runtime 3.15 or later) QEMU_CFLAGS="-D__USE_MINGW_ANSI_STDIO=1 $QEMU_CFLAGS" + # MinGW needs -mthreads for TLS and macro _MT. + QEMU_CFLAGS="-mthreads $QEMU_CFLAGS" LIBS="-lwinmm -lws2_32 -liphlpapi $LIBS" write_c_skeleton; if compile_prog "" "-liberty" ; then -- 2.1.4