From nobody Mon Feb 9 06:50:24 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1667207726; cv=none; d=zohomail.com; s=zohoarc; b=DQsZVu5I1ghXzo+WpirMNfGSqX53PtGIUIjUF7bKlU5K1wYKpOaXgc7Pj2v/tdEkSZyaNXf5GGi+uvhhME0CJ3mQZD8h6GQq0qXm9FQyTPHSIbafqJ+ApqqGhp70YAK1GqXzPp3iSF+dAwI5EGN3cMrD0kSK58h5Faqi0GGp0oQ= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1667207726; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=7/KPvJbIuSc47NEv4b40Fqyao/+WepOlUD7ykn8AW0U=; b=MXX0g2vRBoycOi7WqLnaDijb42iW5ojFHAWVxxhYiFjHsYo0v+6WaL6La9ikViW9ev9vcSK10HnXoxKYzFrW3mrXPK5d4SZ/MbCVRGa7fk4HKPjF5uPaUDbGXmLX89pITsV/1Xy1y5iZnmJmRw6nFVSk5/GO03/JeempGPG0uq0= ARC-Authentication-Results: i=1; mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1667207726481220.36341220224358; Mon, 31 Oct 2022 02:15:26 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1opQsI-0004ZR-Bc; Mon, 31 Oct 2022 05:14:30 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1opQsG-0004Yz-UU for qemu-devel@nongnu.org; Mon, 31 Oct 2022 05:14:28 -0400 Received: from mail.weilnetz.de ([37.120.169.71] helo=mail.v2201612906741603.powersrv.de) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1opQsF-0000Gu-Dv for qemu-devel@nongnu.org; Mon, 31 Oct 2022 05:14:28 -0400 Received: from qemu.weilnetz.de (qemu.weilnetz.de [188.68.58.204]) by mail.v2201612906741603.powersrv.de (Postfix) with ESMTP id A3A6FDA08F3; Mon, 31 Oct 2022 10:14:25 +0100 (CET) Received: by qemu.weilnetz.de (Postfix, from userid 1000) id 9F9AC46001C; Mon, 31 Oct 2022 10:14:25 +0100 (CET) To: qemu-devel@nongnu.org Cc: Bin Meng , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Stefan Weil Subject: [PULL 1/4] scripts/nsis.py: Drop the unnecessary path separator Date: Mon, 31 Oct 2022 10:14:03 +0100 Message-Id: <20221031091406.382872-2-sw@weilnetz.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20221031091406.382872-1-sw@weilnetz.de> References: <20221031091406.382872-1-sw@weilnetz.de> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=37.120.169.71; envelope-from=stefan@weilnetz.de; helo=mail.v2201612906741603.powersrv.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Qemu-devel" Reply-to: Stefan Weil From: Stefan Weil via Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZM-MESSAGEID: 1667207727096100001 From: Bin Meng There is no need to append a path separator to the destination directory that is passed to "make install". Signed-off-by: Bin Meng Message-Id: <20220908132817.1831008-2-bmeng.cn@gmail.com> Reviewed-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Stefan Weil Signed-off-by: Stefan Weil --- scripts/nsis.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/nsis.py b/scripts/nsis.py index 462d6cac3b..bbb41d9386 100644 --- a/scripts/nsis.py +++ b/scripts/nsis.py @@ -30,7 +30,7 @@ def main(): =20 destdir =3D tempfile.mkdtemp() try: - subprocess.run(["make", "install", "DESTDIR=3D" + destdir + os.pat= h.sep]) + subprocess.run(["make", "install", "DESTDIR=3D" + destdir]) with open( os.path.join(destdir + args.prefix, "system-emulations.nsh"), = "w" ) as nsh, open( --=20 2.30.2 From nobody Mon Feb 9 06:50:24 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1667207747; cv=none; d=zohomail.com; s=zohoarc; b=BrW4xn/5B2xI7j+K6i4iZC4aISPdFdjZvv1fa0MQfXcH8zFVQL4we2+bqcFJ6TVr7F+zL5GE4RvkhicOh6rZH2ztU7cZAd7I5sgj/k2MYtAd2E9HQNSFrZ4/S3ngWS+3kUCEaES8Kg43R+3iWnwPwLAozkoKP9nx3iq6gkiplJY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1667207747; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=KjRNc8y6eJ3od/Yqk2NPDEWlSQMbZw4QKN89G2DfOMg=; b=KdH+o6bkVq+CH+kw74vS8aiaR/Q5Eq9+2FXWzC45SJXrxqYaNtWWOX8jy1jIFs7ceZN3xy8fpAkODmotPLmOjO8G1XffRRGo1S6aufsRxamKFIfmPqwK4w0OEwxxxp2KE2+XvFb6032+Jj+JnvVBA6ROPEJ+9IKYJLwG0K5DO2w= ARC-Authentication-Results: i=1; mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1667207747101634.8514308557269; Mon, 31 Oct 2022 02:15:47 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1opQsI-0004Zh-Tf; Mon, 31 Oct 2022 05:14:30 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1opQsG-0004Z0-Vb for qemu-devel@nongnu.org; Mon, 31 Oct 2022 05:14:28 -0400 Received: from mail.weilnetz.de ([37.120.169.71] helo=mail.v2201612906741603.powersrv.de) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1opQsF-0000Gx-GJ for qemu-devel@nongnu.org; Mon, 31 Oct 2022 05:14:28 -0400 Received: from qemu.weilnetz.de (qemu.weilnetz.de [188.68.58.204]) by mail.v2201612906741603.powersrv.de (Postfix) with ESMTP id 4E40BDA10FC; Mon, 31 Oct 2022 10:14:26 +0100 (CET) Received: by qemu.weilnetz.de (Postfix, from userid 1000) id 4ABE146001C; Mon, 31 Oct 2022 10:14:26 +0100 (CET) To: qemu-devel@nongnu.org Cc: Bin Meng , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Stefan Weil Subject: [PULL 2/4] scripts/nsis.py: Fix destination directory name when invoked on Windows Date: Mon, 31 Oct 2022 10:14:04 +0100 Message-Id: <20221031091406.382872-3-sw@weilnetz.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20221031091406.382872-1-sw@weilnetz.de> References: <20221031091406.382872-1-sw@weilnetz.de> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=37.120.169.71; envelope-from=stefan@weilnetz.de; helo=mail.v2201612906741603.powersrv.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Qemu-devel" Reply-to: Stefan Weil From: Stefan Weil via Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZM-MESSAGEID: 1667207749131100003 From: Bin Meng "make installer" on Windows fails with the following message: Traceback (most recent call last): File "G:\msys64\home\foo\git\qemu\scripts\nsis.py", line 89, in main() File "G:\msys64\home\foo\git\qemu\scripts\nsis.py", line 34, in main with open( OSError: [Errno 22] Invalid argument: 'R:/Temp/tmpw83xhjquG:/msys64/qemu/system-emulations.nsh' ninja: build stopped: subcommand failed. Use os.path.splitdrive() to form a canonical path without the drive letter on Windows. This works with cross-build on Linux too. Fixes: 8adfeba953e0 ("meson: add NSIS building") Signed-off-by: Bin Meng Message-Id: <20220908132817.1831008-3-bmeng.cn@gmail.com> Reviewed-by: Marc-Andr=C3=A9 Lureau Reviewed-by: Philippe Mathieu-Daud=C3=A9 Tested-by: Stefan Weil Signed-off-by: Stefan Weil --- scripts/nsis.py | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/scripts/nsis.py b/scripts/nsis.py index bbb41d9386..baa6ef9594 100644 --- a/scripts/nsis.py +++ b/scripts/nsis.py @@ -28,16 +28,18 @@ def main(): parser.add_argument("nsisargs", nargs=3D"*") args =3D parser.parse_args() =20 + # canonicalize the Windows native prefix path + prefix =3D os.path.splitdrive(args.prefix)[1] destdir =3D tempfile.mkdtemp() try: subprocess.run(["make", "install", "DESTDIR=3D" + destdir]) with open( - os.path.join(destdir + args.prefix, "system-emulations.nsh"), = "w" + os.path.join(destdir + prefix, "system-emulations.nsh"), "w" ) as nsh, open( - os.path.join(destdir + args.prefix, "system-mui-text.nsh"), "w" + os.path.join(destdir + prefix, "system-mui-text.nsh"), "w" ) as muinsh: for exe in sorted(glob.glob( - os.path.join(destdir + args.prefix, "qemu-system-*.exe") + os.path.join(destdir + prefix, "qemu-system-*.exe") )): exe =3D os.path.basename(exe) arch =3D exe[12:-4] @@ -61,7 +63,7 @@ def main(): !insertmacro MUI_DESCRIPTION_TEXT ${{Section_{0}}} "{1}" """.format(arch, desc)) =20 - for exe in glob.glob(os.path.join(destdir + args.prefix, "*.exe")): + for exe in glob.glob(os.path.join(destdir + prefix, "*.exe")): signcode(exe) =20 makensis =3D [ @@ -69,7 +71,7 @@ def main(): "-V2", "-NOCD", "-DSRCDIR=3D" + args.srcdir, - "-DBINDIR=3D" + destdir + args.prefix, + "-DBINDIR=3D" + destdir + prefix, ] dlldir =3D "w32" if args.cpu =3D=3D "x86_64": --=20 2.30.2 From nobody Mon Feb 9 06:50:24 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1667207729; cv=none; d=zohomail.com; s=zohoarc; b=X1aq2w+Vl/Ih4C9S9ndlVN3Zj8VU/wLQ2kb3FEG2T7V3U1M31JmIBdE99b2y8OINGO9W5sUlVzz+mAi2LC5WFj3Ua70VEIoxFgj/0rhW6ZGWkVkgI42hHKFapwPJC61jShq2cgONIwYnzQeHZb6EPn5N2mrw29q9rbyic30CPSk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1667207729; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=bVoT0u16PYfYLJCNeVIk1WDl9FZShRwMzEdFM3x7tt0=; b=ZzzGSqXBCIfY/TwgOZELxQe1LgAHnmiPmO77hPVY6VGgO3KFK2JB7iD8fwjR3YHWEHwr7FaT0Je/CGNAdJzbJEtHwGDQC5RYHKxQtP3VHyA/1kP1bENnNHa71KuEkLsmAhs8bVN4UwQ8bqYdriQq+w/DMtPW5X5q49Xojxe9td4= ARC-Authentication-Results: i=1; mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1667207729325167.69097367738277; Mon, 31 Oct 2022 02:15:29 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1opQsR-0004b1-0g; Mon, 31 Oct 2022 05:14:39 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1opQsO-0004aB-Rb for qemu-devel@nongnu.org; Mon, 31 Oct 2022 05:14:36 -0400 Received: from mail.weilnetz.de ([37.120.169.71] helo=mail.v2201612906741603.powersrv.de) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1opQsH-0000HF-MD for qemu-devel@nongnu.org; Mon, 31 Oct 2022 05:14:36 -0400 Received: from qemu.weilnetz.de (qemu.weilnetz.de [188.68.58.204]) by mail.v2201612906741603.powersrv.de (Postfix) with ESMTP id 7CBDEDA11CF; Mon, 31 Oct 2022 10:14:28 +0100 (CET) Received: by qemu.weilnetz.de (Postfix, from userid 1000) id 781C146001C; Mon, 31 Oct 2022 10:14:28 +0100 (CET) To: qemu-devel@nongnu.org Cc: Bin Meng , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , Stefan Weil Subject: [PULL 3/4] scripts/nsis.py: Automatically package required DLLs of QEMU executables Date: Mon, 31 Oct 2022 10:14:05 +0100 Message-Id: <20221031091406.382872-4-sw@weilnetz.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20221031091406.382872-1-sw@weilnetz.de> References: <20221031091406.382872-1-sw@weilnetz.de> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=37.120.169.71; envelope-from=stefan@weilnetz.de; helo=mail.v2201612906741603.powersrv.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Qemu-devel" Reply-to: Stefan Weil From: Stefan Weil via Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZM-MESSAGEID: 1667207731099100007 From: Bin Meng At present packaging the required DLLs of QEMU executables is a manual process, and error prone. Actually build/config-host.mak contains a GLIB_BINDIR variable which is the directory where glib and other DLLs reside. This works for both Windows native build and cross-build on Linux. We can use it as the search directory for DLLs and automate the whole DLL packaging process. Signed-off-by: Bin Meng Message-Id: <20220908132817.1831008-4-bmeng.cn@gmail.com> Reviewed-by: Marc-Andr=C3=A9 Lureau Tested-by: Stefan Weil Signed-off-by: Stefan Weil --- meson.build | 1 + scripts/nsis.py | 46 ++++++++++++++++++++++++++++++++++++++++++---- 2 files changed, 43 insertions(+), 4 deletions(-) diff --git a/meson.build b/meson.build index 37737913df..d0a186e7f5 100644 --- a/meson.build +++ b/meson.build @@ -3616,6 +3616,7 @@ if host_machine.system() =3D=3D 'windows' '@OUTPUT@', get_option('prefix'), meson.current_source_dir(), + config_host['GLIB_BINDIR'], host_machine.cpu(), '--', '-DDISPLAYVERSION=3D' + meson.project_version(), diff --git a/scripts/nsis.py b/scripts/nsis.py index baa6ef9594..03ed7608a2 100644 --- a/scripts/nsis.py +++ b/scripts/nsis.py @@ -18,12 +18,36 @@ def signcode(path): return subprocess.run([cmd, path]) =20 +def find_deps(exe_or_dll, search_path, analyzed_deps): + deps =3D [exe_or_dll] + output =3D subprocess.check_output(["objdump", "-p", exe_or_dll], text= =3DTrue) + output =3D output.split("\n") + for line in output: + if not line.startswith("\tDLL Name: "): + continue + + dep =3D line.split("DLL Name: ")[1].strip() + if dep in analyzed_deps: + continue + + dll =3D os.path.join(search_path, dep) + if not os.path.exists(dll): + # assume it's a Windows provided dll, skip it + continue + + analyzed_deps.add(dep) + # locate the dll dependencies recursively + rdeps =3D find_deps(dll, search_path, analyzed_deps) + deps.extend(rdeps) + + return deps =20 def main(): parser =3D argparse.ArgumentParser(description=3D"QEMU NSIS build help= er.") parser.add_argument("outfile") parser.add_argument("prefix") parser.add_argument("srcdir") + parser.add_argument("dlldir") parser.add_argument("cpu") parser.add_argument("nsisargs", nargs=3D"*") args =3D parser.parse_args() @@ -63,9 +87,26 @@ def main(): !insertmacro MUI_DESCRIPTION_TEXT ${{Section_{0}}} "{1}" """.format(arch, desc)) =20 + search_path =3D args.dlldir + print("Searching '%s' for the dependent dlls ..." % search_path) + dlldir =3D os.path.join(destdir + prefix, "dll") + os.mkdir(dlldir) + for exe in glob.glob(os.path.join(destdir + prefix, "*.exe")): signcode(exe) =20 + # find all dll dependencies + deps =3D set(find_deps(exe, search_path, set())) + deps.remove(exe) + + # copy all dlls to the DLLDIR + for dep in deps: + dllfile =3D os.path.join(dlldir, os.path.basename(dep)) + if (os.path.exists(dllfile)): + continue + print("Copying '%s' to '%s'" % (dep, dllfile)) + shutil.copy(dep, dllfile) + makensis =3D [ "makensis", "-V2", @@ -73,12 +114,9 @@ def main(): "-DSRCDIR=3D" + args.srcdir, "-DBINDIR=3D" + destdir + prefix, ] - dlldir =3D "w32" if args.cpu =3D=3D "x86_64": - dlldir =3D "w64" makensis +=3D ["-DW64"] - if os.path.exists(os.path.join(args.srcdir, "dll")): - makensis +=3D ["-DDLLDIR=3D{0}/dll/{1}".format(args.srcdir, dl= ldir)] + makensis +=3D ["-DDLLDIR=3D" + dlldir] =20 makensis +=3D ["-DOUTFILE=3D" + args.outfile] + args.nsisargs subprocess.run(makensis) --=20 2.30.2 From nobody Mon Feb 9 06:50:24 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1667207738; cv=none; d=zohomail.com; s=zohoarc; b=d3UOekd2PCDhaOedoBZqrTsue4ERR5MFCfN9Q1mRz8bWnYxJf5bX5/SE4II5fuHkWRVyI2f2Y3UNLtx0odAsG0lvzOLdoRLRY1eICY58byxNY66PRYExpj35WsDcfkv+RUlPcr/nkir4JfmoBmPujZjRBJdQvoobzQvvKqPE87U= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1667207738; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=a/PMY1gX+Oapg+RoHu6D8FdaAVt89l60YmOf3W3hDbA=; b=ZUEjkQHWXgFVex7PFNrSbhaWQ44AAr+qf3ZInn6HsWQaF2zMDrm0XYCzVMh2tUUsKCgm/Fmmsw1vr5kOZlEa1AjJLMJ6eqk6bKbpwewM/i1cYPzPsmp9TD437kItJnynFQWNFaukXCiOuh1a85DRkdZd8iNUVQqFAofoUJn2sMw= ARC-Authentication-Results: i=1; mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1667207738642747.2661617970833; Mon, 31 Oct 2022 02:15:38 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1opQsL-0004Zw-F0; Mon, 31 Oct 2022 05:14:33 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1opQsK-0004Zj-6g for qemu-devel@nongnu.org; Mon, 31 Oct 2022 05:14:32 -0400 Received: from mail.weilnetz.de ([37.120.169.71] helo=mail.v2201612906741603.powersrv.de) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1opQsI-0000HU-QV for qemu-devel@nongnu.org; Mon, 31 Oct 2022 05:14:32 -0400 Received: from qemu.weilnetz.de (qemu.weilnetz.de [188.68.58.204]) by mail.v2201612906741603.powersrv.de (Postfix) with ESMTP id A79B4DA08F3; Mon, 31 Oct 2022 10:14:29 +0100 (CET) Received: by qemu.weilnetz.de (Postfix, from userid 1000) id A3B8E46001C; Mon, 31 Oct 2022 10:14:29 +0100 (CET) To: qemu-devel@nongnu.org Cc: Bin Meng , Stefan Weil Subject: [PULL 4/4] block/nfs: Fix 32-bit Windows build Date: Mon, 31 Oct 2022 10:14:06 +0100 Message-Id: <20221031091406.382872-5-sw@weilnetz.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20221031091406.382872-1-sw@weilnetz.de> References: <20221031091406.382872-1-sw@weilnetz.de> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=37.120.169.71; envelope-from=stefan@weilnetz.de; helo=mail.v2201612906741603.powersrv.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Qemu-devel" Reply-to: Stefan Weil From: Stefan Weil via Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZM-MESSAGEID: 1667207739094100003 Content-Type: text/plain; charset="utf-8" From: Bin Meng libnfs.h declares nfs_fstat() as the following for win32: int nfs_fstat(struct nfs_context *nfs, struct nfsfh *nfsfh, struct __stat64 *st); The 'st' parameter should be of type 'struct __stat64'. The codes happen to build successfully for 64-bit Windows, but it does not build for 32-bit Windows. Fixes: 6542aa9c75bc ("block: add native support for NFS") Fixes: 18a8056e0bc7 ("block/nfs: cache allocated filesize for read-only fil= es") Signed-off-by: Bin Meng Message-Id: <20220908132817.1831008-6-bmeng.cn@gmail.com> Reviewed-by: Stefan Weil Signed-off-by: Stefan Weil --- block/nfs.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/block/nfs.c b/block/nfs.c index 596ebe98cb..ece22353ac 100644 --- a/block/nfs.c +++ b/block/nfs.c @@ -418,7 +418,11 @@ static int64_t nfs_client_open(NFSClient *client, Bloc= kdevOptionsNfs *opts, int flags, int open_flags, Error **errp) { int64_t ret =3D -EINVAL; +#ifdef _WIN32 + struct __stat64 st; +#else struct stat st; +#endif char *file =3D NULL, *strp =3D NULL; =20 qemu_mutex_init(&client->mutex); @@ -781,7 +785,11 @@ static int nfs_reopen_prepare(BDRVReopenState *state, BlockReopenQueue *queue, Error **errp) { NFSClient *client =3D state->bs->opaque; +#ifdef _WIN32 + struct __stat64 st; +#else struct stat st; +#endif int ret =3D 0; =20 if (state->flags & BDRV_O_RDWR && bdrv_is_read_only(state->bs)) { --=20 2.30.2