From patchwork Fri Jan 29 19:28:58 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Scott Tsai X-Patchwork-Id: 44020 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 29928B7CC1 for ; Sat, 30 Jan 2010 06:39:12 +1100 (EST) Received: from localhost ([127.0.0.1]:44437 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NawfP-0005Vw-Eg for incoming@patchwork.ozlabs.org; Fri, 29 Jan 2010 14:38:07 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Nawe5-0005US-A8 for qemu-devel@nongnu.org; Fri, 29 Jan 2010 14:36:45 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Nawe0-0005PA-IO for qemu-devel@nongnu.org; Fri, 29 Jan 2010 14:36:44 -0500 Received: from [199.232.76.173] (port=43236 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Nawe0-0005Ot-A2 for qemu-devel@nongnu.org; Fri, 29 Jan 2010 14:36:40 -0500 Received: from mail-fx0-f222.google.com ([209.85.220.222]:37895) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1Nawdy-0003c8-TP for qemu-devel@nongnu.org; Fri, 29 Jan 2010 14:36:39 -0500 Received: by fxm22 with SMTP id 22so750469fxm.2 for ; Fri, 29 Jan 2010 11:36:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:subject:date :message-id:x-mailer; bh=Af1i/CZKaxvH205+ZgDjzaSN+aBQIFEKw0NwcG1nVzc=; b=Q12+EfoChL+RoP0NTc3qhUu+IPf3uBZ3AywE3+zwld2mAlR1P7QV7Y6Oy86oEOOCoo ENE2fIe00I9ULRv5HjfNTi9wGHUVJLe4Be6xKtu9DddpuTukF06q1/emNnfYQ5kBVxtt qIA1B5OD07238vV2+y45QHuCvuyFSzYD6bLpw= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer; b=CDf5xdW2k7UAUl1HuaqmjqJlqn0oQWMN2lBahRFf8qPq6CYKA5/MMs03ZltXwTjOgh FZNCIbz/U8yfEiG1B5AP59ggOkP6XW9CNa4yHMP4qZhEpBVKn/1a1VCs+L5ZLBDcMCrT c3fQUanqXEyVWRD0twSDCndRpT05oJLAxGZVM= Received: by 10.87.16.39 with SMTP id t39mr2514945fgi.46.1264793381925; Fri, 29 Jan 2010 11:29:41 -0800 (PST) Received: from localhost (220-136-181-22.dynamic.hinet.net [220.136.181.22]) by mx.google.com with ESMTPS id e3sm2938921fga.11.2010.01.29.11.29.39 (version=TLSv1/SSLv3 cipher=RC4-MD5); Fri, 29 Jan 2010 11:29:40 -0800 (PST) From: Scott Tsai To: qemu-devel@nongnu.org Date: Sat, 30 Jan 2010 03:28:58 +0800 Message-Id: <1264793338-30981-1-git-send-email-scottt.tw@gmail.com> X-Mailer: git-send-email 1.6.6 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Cc: Scott Tsai Subject: [Qemu-devel] [PATCH] doc: Update mingw cross compile instructions X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org The "Cross compilation for Windows with Linux" section of qemu-doc.texi still instructs the user to use 'configure --enable-mingw32' even after the option was removed in Aug 2008: http://git.savannah.gnu.org/cgit/qemu.git/commit/?id=cd01b4a312248dd4e12c3d389d1a349cea4015d8 This documentation only change updates the instructions to: * Remove use of '--enable-mingw32' in the configure example * Correct the 'sdl-config' script name * Remove references to i386-mingw32msvc.tar.gz which no longer exists in recent SDL releases * Document the zlib dependency Signed-off-by: Scott Tsai --- qemu-doc.texi | 45 +++++++++++++++++++++++++++++++-------------- 1 files changed, 31 insertions(+), 14 deletions(-) diff --git a/qemu-doc.texi b/qemu-doc.texi index 2fb5c0b..4e220d0 100644 --- a/qemu-doc.texi +++ b/qemu-doc.texi @@ -2313,11 +2313,14 @@ instructions in the download section and the FAQ. @item Download the MinGW development library of SDL 1.2.x (@file{SDL-devel-1.2.x-@/mingw32.tar.gz}) from -@url{http://www.libsdl.org}. Unpack it in a temporary place, and -unpack the archive @file{i386-mingw32msvc.tar.gz} in the MinGW tool -directory. Edit the @file{sdl-config} script so that it gives the +@url{http://www.libsdl.org}. Unpack it in a temporary place and +edit the @file{sdl-config} script so that it gives the correct SDL directory when invoked. +@item Install the MinGW version of zlib and make sure +@file{zlib.h} and @file{libz.dll.a} are in +MingGW's default header and linker search paths. + @item Extract the current version of QEMU. @item Start the MSYS shell (file @file{msys.bat}). @@ -2340,29 +2343,43 @@ correct SDL directory when invoked. Install the MinGW cross compilation tools available at @url{http://www.mingw.org/}. -@item -Install the Win32 version of SDL (@url{http://www.libsdl.org}) by -unpacking @file{i386-mingw32msvc.tar.gz}. Set up the PATH environment -variable so that @file{i386-mingw32msvc-sdl-config} can be launched by +@item Download +the MinGW development library of SDL 1.2.x +(@file{SDL-devel-1.2.x-@/mingw32.tar.gz}) from +@url{http://www.libsdl.org}. Unpack it in a temporary place and +edit the @file{sdl-config} script so that it gives the +correct SDL directory when invoked. Set up the @code{PATH} environment +variable so that @file{sdl-config} can be launched by the QEMU configuration script. +@item Install the MinGW version of zlib and make sure +@file{zlib.h} and @file{libz.dll.a} are in +MingGW's default header and linker search paths. + @item Configure QEMU for Windows cross compilation: @example -./configure --enable-mingw32 +PATH=/usr/i686-pc-mingw32/sys-root/mingw/bin:$PATH ./configure --cross-prefix='i686-pc-mingw32-' +@end example +The example assumes @file{sdl-config} is installed under @file{/usr/i686-pc-mingw32/sys-root/mingw/bin} and +MinGW cross compilation tools have names like @file{i686-pc-mingw32-gcc} and @file{i686-pc-mingw32-strip}. +We set the @code{PATH} environment variable to ensure the MingW version of @file{sdl-config} is used and +use --cross-prefix to specify the name of the cross compiler. +You can also use --prefix to set the Win32 install path which defaults to @file{c:/Program Files/Qemu}. + +Under Fedora Linux, you can run: +@example +yum -y install mingw32-gcc mingw32-SDL mingw32-zlib @end example -If necessary, you can change the cross-prefix according to the prefix -chosen for the MinGW tools with --cross-prefix. You can also use ---prefix to set the Win32 install path. +to get a suitable cross compilation environment. @item You can install QEMU in the installation directory by typing -@file{make install}. Don't forget to copy @file{SDL.dll} in the +@code{make install}. Don't forget to copy @file{SDL.dll} and @file{zlib1.dll} into the installation directory. @end itemize -Note: Currently, Wine does not seem able to launch -QEMU for Win32. +Wine can be used to launch the resulting qemu.exe compiled for Win32. @node Mac OS X @section Mac OS X