From patchwork Thu Sep 8 13:28:11 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Bin Meng X-Patchwork-Id: 12970149 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D0881C38145 for ; Thu, 8 Sep 2022 13:36:04 +0000 (UTC) Received: from localhost ([::1]:59496 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oWHhL-0004d5-F5 for qemu-devel@archiver.kernel.org; Thu, 08 Sep 2022 09:36:03 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:41328) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oWHa1-0004SV-2Q for qemu-devel@nongnu.org; Thu, 08 Sep 2022 09:28:30 -0400 Received: from mail-pl1-x62a.google.com ([2607:f8b0:4864:20::62a]:40524) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oWHZz-0002aQ-Ki for qemu-devel@nongnu.org; Thu, 08 Sep 2022 09:28:28 -0400 Received: by mail-pl1-x62a.google.com with SMTP id b21so4948695plz.7 for ; Thu, 08 Sep 2022 06:28:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=4V2kh8bh8Emc/PHebNZxEp7jm1fTt064prqxwjUL4ng=; b=OLTES4X+L/nI7e+wPkiJVjElwgPiQKWLLJ5b7IhSG418zKqpxeV2EQ9AiDuEXzvhu1 CeRl8VMdc4EzPr9eDeYd3w23SPUzWR29vcPsyma9C8q9HuFbNaOI2krMkOmXvVC4MCtY /AZzPGwT39UFaAOWsGQDx55BxPu+aSUeDOx1LMxGJKoKpbzy/ERBDzD45P+ZJatiG7AE /0Gh1Pq0E/w7HsOkkmOLkICZI3L3Ugaz1YQMuZuDcYY8+YjS8qb+nydiJNBIpNrM1Km5 rWThqL8/2F3Kh9sHoeJrNhqFe4xI+OquwM6KAyzK6TiuVqvrhcp7qmaQczLFBqccWXTD Duxw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date; bh=4V2kh8bh8Emc/PHebNZxEp7jm1fTt064prqxwjUL4ng=; b=Ty+vwCZF0UPy+12o7hwAhVBx1Keby8Wy9LBl6ZOmOLlRohq8JYo69JRDjRJ1FZa930 sw9IkZsFPhcL4cQK5UFy89MVn18Va/QuZZvvq3zIXFra/B2DHxBKViwuN9LORjmpw/NW IzBmlP+bncRxNJN34RLbvhjgN0K2h3DbxPjv3CyX4IXh1vsejl72//ot0IyHlHHuWfaO j3UFFY83OxV+lQN/jtgiqZelT0tG4MHbF3wm7Ja8hapUThREkk4V744704rH+a/UhDVE LJOXlhOXzhPq9RD9gFgzNzIOadM/rr0phEtuK/jd1y49zyUnbSwywJdPOzIbYY4553YU oXIw== X-Gm-Message-State: ACgBeo0xpIGZ6anyG1RvnAfTsEPenAF0y6kZpVFt/fD6TyUMqXU3meR/ CHVOsiNf2kpIR+Dt90rblsPcRb3jpec= X-Google-Smtp-Source: AA6agR6uN/sImln8/cR+55cEDVU8A0qyVNKsC48oX4Fp/XJUoI19trhPq66ZJXqHWolux15l/jwffA== X-Received: by 2002:a17:90a:1b6e:b0:1f5:1902:af92 with SMTP id q101-20020a17090a1b6e00b001f51902af92mr4357269pjq.238.1662643705774; Thu, 08 Sep 2022 06:28:25 -0700 (PDT) Received: from ubuntu.. (144.168.56.201.16clouds.com. [144.168.56.201]) by smtp.gmail.com with ESMTPSA id r8-20020a170902be0800b001755ac7dd0asm1731693pls.290.2022.09.08.06.28.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Sep 2022 06:28:25 -0700 (PDT) From: Bin Meng To: qemu-devel@nongnu.org Cc: Bin Meng , Cleber Rosa , John Snow Subject: [PATCH 1/7] scripts/nsis.py: Drop the unnecessary path separator Date: Thu, 8 Sep 2022 21:28:11 +0800 Message-Id: <20220908132817.1831008-2-bmeng.cn@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220908132817.1831008-1-bmeng.cn@gmail.com> References: <20220908132817.1831008-1-bmeng.cn@gmail.com> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::62a; envelope-from=bmeng.cn@gmail.com; helo=mail-pl1-x62a.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" 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 Reviewed-by: Philippe Mathieu-Daudé Reviewed-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(): destdir = tempfile.mkdtemp() try: - subprocess.run(["make", "install", "DESTDIR=" + destdir + os.path.sep]) + subprocess.run(["make", "install", "DESTDIR=" + destdir]) with open( os.path.join(destdir + args.prefix, "system-emulations.nsh"), "w" ) as nsh, open( From patchwork Thu Sep 8 13:28:12 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Bin Meng X-Patchwork-Id: 12970112 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 286A1C38145 for ; Thu, 8 Sep 2022 13:31:21 +0000 (UTC) Received: from localhost ([::1]:33644 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oWHcm-0007Hw-2x for qemu-devel@archiver.kernel.org; Thu, 08 Sep 2022 09:31:20 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:41334) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oWHa3-0004TM-Rb for qemu-devel@nongnu.org; Thu, 08 Sep 2022 09:28:32 -0400 Received: from mail-pl1-x62c.google.com ([2607:f8b0:4864:20::62c]:40526) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oWHa2-0002aX-69 for qemu-devel@nongnu.org; Thu, 08 Sep 2022 09:28:31 -0400 Received: by mail-pl1-x62c.google.com with SMTP id b21so4948797plz.7 for ; Thu, 08 Sep 2022 06:28:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=zkVLGjem6wSZCZmhICiJtuczZUPqP8zkVJzeqrMRh7k=; b=NELC95h8i/tRnhGiNTjjRNRTfL2jkxAPvhLLxO02FO0ur3cLdAGs8f4O8UzSc9MG8z JYMDQlhuG9/NQP2hlW9UK0lUOj9BQ/Otb7a7cjqo/b6PZWCAHLSq24ipLqCm+DFt9mgt gJWC1/RQdT1Xh+R5Nsv8T5eMg5uSId6hirp3RsL+DcEz1eOCzfGvqlfftnixoCdD2HVl mOMoEF71Yl5RxBpzantMJRSFP2dkTRmAvzXSBEfQMyBi794Lhp5FoISc6Mvj4KCYRPeh oShWJBJ/w2is/K5M3Pr7MxQbB6zKfBxXVW1Cxvq83l5wL6l+P5T3LZ2yPMa9aD19qQ89 jXdA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date; bh=zkVLGjem6wSZCZmhICiJtuczZUPqP8zkVJzeqrMRh7k=; b=nwQGvZWxDTT+ChsmyCNzGAJplHa/cpYngbU57izpZ6cY5oWqzdeF8ktMwv0+ncG34j Qz5UT8EK+cBK2+9HrNebV8+Ety7fABcYnA/8ObZOWhu6wC8d+N07D85F0W18iPAjoNFS n0xeKZFrmnSdgAOzw7BVQcSbWvN73kV5JUYSzdFH9wI/sv5laaUxllP05cwdJY1Pppit uZPFew4P3K9vKxDqEQrHkKgKeen+fe2t7MJaFcKqY7AsvzXQ5KnAPepeADTYVmdN/w2o iC3FFgi4a1eCzo/QNIp3eZ/zrdMZSwADaqgm8A1wsC5xGLRTauqQWUGOqTOLO94HAC+s USHA== X-Gm-Message-State: ACgBeo0N9f689F2+d4yWfyzj1eJwwbEEil7yO5EeE+pY68buysJE6KdU EfzlMeAsCtN0ixPP1QlH1YtGVmkbXeo= X-Google-Smtp-Source: AA6agR4L1z3mTifhI0QgbLaqu2dbwkEIMPePvorNqctY/Vpenz168BSTW91tQQbTzGEMnO4Y+j2btg== X-Received: by 2002:a17:902:dac2:b0:172:5f2a:f30 with SMTP id q2-20020a170902dac200b001725f2a0f30mr8798142plx.167.1662643708027; Thu, 08 Sep 2022 06:28:28 -0700 (PDT) Received: from ubuntu.. (144.168.56.201.16clouds.com. [144.168.56.201]) by smtp.gmail.com with ESMTPSA id r8-20020a170902be0800b001755ac7dd0asm1731693pls.290.2022.09.08.06.28.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Sep 2022 06:28:27 -0700 (PDT) From: Bin Meng To: qemu-devel@nongnu.org Cc: Bin Meng , Cleber Rosa , John Snow Subject: [PATCH 2/7] scripts/nsis.py: Fix destination directory name when invoked on Windows Date: Thu, 8 Sep 2022 21:28:12 +0800 Message-Id: <20220908132817.1831008-3-bmeng.cn@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220908132817.1831008-1-bmeng.cn@gmail.com> References: <20220908132817.1831008-1-bmeng.cn@gmail.com> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::62c; envelope-from=bmeng.cn@gmail.com; helo=mail-pl1-x62c.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" 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 Reviewed-by: Marc-André Lureau Reviewed-by: Philippe Mathieu-Daudé Tested-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="*") args = parser.parse_args() + # canonicalize the Windows native prefix path + prefix = os.path.splitdrive(args.prefix)[1] destdir = tempfile.mkdtemp() try: subprocess.run(["make", "install", "DESTDIR=" + 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 = os.path.basename(exe) arch = exe[12:-4] @@ -61,7 +63,7 @@ def main(): !insertmacro MUI_DESCRIPTION_TEXT ${{Section_{0}}} "{1}" """.format(arch, desc)) - 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) makensis = [ @@ -69,7 +71,7 @@ def main(): "-V2", "-NOCD", "-DSRCDIR=" + args.srcdir, - "-DBINDIR=" + destdir + args.prefix, + "-DBINDIR=" + destdir + prefix, ] dlldir = "w32" if args.cpu == "x86_64": From patchwork Thu Sep 8 13:28:13 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Bin Meng X-Patchwork-Id: 12970148 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id B5890C38145 for ; Thu, 8 Sep 2022 13:35:07 +0000 (UTC) Received: from localhost ([::1]:52844 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oWHgQ-0003NC-MI for qemu-devel@archiver.kernel.org; Thu, 08 Sep 2022 09:35:06 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:41336) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oWHa6-0004Wz-PG for qemu-devel@nongnu.org; Thu, 08 Sep 2022 09:28:35 -0400 Received: from mail-pf1-x432.google.com ([2607:f8b0:4864:20::432]:47038) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oWHa4-0002bH-CX for qemu-devel@nongnu.org; Thu, 08 Sep 2022 09:28:33 -0400 Received: by mail-pf1-x432.google.com with SMTP id c198so8050920pfc.13 for ; Thu, 08 Sep 2022 06:28:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=f6QlqcK7maFhzyN9eWoUNYZ/AucGHK6lcA3QFGZvpf0=; b=DEpyf22yRYcdcIMrb0bl1MeQRE98wb8UNN8haZzNDY2UTQ0GEAT2NNpzdMT4QRvwDF 3etTTs3RFWF4ugmxp6JsQ8jeTGqRfgAVD9DSwNxRfedbJoFxmB2Gj31zwRG+c17PMXMx BbcBx8YZIRM5lRF948ZLQTsL9HBmc+NuB8CRGetG1gWWX7st9jwnwpACPEdLP48NlLxl UptZW0IdQWQayxoBvnPi8eXPf5g/CqIHLlb8movKKodQKqei1DwP6hURwDKg82rvzy0i pa7V/WjA8SRzP6vozXQapp8C8/0oZPy191EilAG6zbkJkjjCM9F2pYhkve9xcfWN2+e6 OO3A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date; bh=f6QlqcK7maFhzyN9eWoUNYZ/AucGHK6lcA3QFGZvpf0=; b=7qz4GrUQjwapeKbj0kp57AHtr6V8nD9aoJPCJW9Wg4uorLJfVPUhCBBBreEfcQ2Clq V9DOyaM9ZPY07yD/9AYK5/kfY6K/S5DShMlrpzHlZJn9bsYCls644YxMB6Z4HBqr+syE pMA2V8SE94bqiTG+GwrrgEl5WFGNR2gLxGZv4tbSZ1HgwiJHGw6sevhQV3i6Ol10fCb3 mNBRqQY/4D3AFvjR8nWwoeKpQ2BClfiqQND0Gg9YpESeweJLVeQeJSBUWuT6Sb7pfGAt xwZySaoyWq6ifRfYmSlZjdro1uXSPj66GDJ2QRjqWOO4RiHQF5PVfD9mnTbh+fTrqWsd 2/2g== X-Gm-Message-State: ACgBeo0zKXUIKV+udV6/Et5Sgs7Yrgf8PH6DKpNCAZndTwK1ZkS1ysJx fJdqgZx3R2WR3xe1yUlhbCzr3+CoVFI= X-Google-Smtp-Source: AA6agR4lpL6OagoODDKP+xYuwuvdZ7yApasZ1AQTHNNVrXwatXa+5Q5Tb9CfOfyO2+Xt+zI57wDOKg== X-Received: by 2002:a63:3115:0:b0:434:fe5b:adf with SMTP id x21-20020a633115000000b00434fe5b0adfmr5911838pgx.3.1662643710456; Thu, 08 Sep 2022 06:28:30 -0700 (PDT) Received: from ubuntu.. (144.168.56.201.16clouds.com. [144.168.56.201]) by smtp.gmail.com with ESMTPSA id r8-20020a170902be0800b001755ac7dd0asm1731693pls.290.2022.09.08.06.28.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Sep 2022 06:28:29 -0700 (PDT) From: Bin Meng To: qemu-devel@nongnu.org Cc: Bin Meng , Cleber Rosa , John Snow Subject: [PATCH 3/7] scripts/nsis.py: Automatically package required DLLs of QEMU executables Date: Thu, 8 Sep 2022 21:28:13 +0800 Message-Id: <20220908132817.1831008-4-bmeng.cn@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220908132817.1831008-1-bmeng.cn@gmail.com> References: <20220908132817.1831008-1-bmeng.cn@gmail.com> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::432; envelope-from=bmeng.cn@gmail.com; helo=mail-pf1-x432.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" 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 Reviewed-by: Marc-André Lureau Tested-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 c2adb7caf4..4c03850f9f 100644 --- a/meson.build +++ b/meson.build @@ -3657,6 +3657,7 @@ if host_machine.system() == 'windows' '@OUTPUT@', get_option('prefix'), meson.current_source_dir(), + config_host['GLIB_BINDIR'], host_machine.cpu(), '--', '-DDISPLAYVERSION=' + 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]) +def find_deps(exe_or_dll, search_path, analyzed_deps): + deps = [exe_or_dll] + output = subprocess.check_output(["objdump", "-p", exe_or_dll], text=True) + output = output.split("\n") + for line in output: + if not line.startswith("\tDLL Name: "): + continue + + dep = line.split("DLL Name: ")[1].strip() + if dep in analyzed_deps: + continue + + dll = 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 = find_deps(dll, search_path, analyzed_deps) + deps.extend(rdeps) + + return deps def main(): parser = argparse.ArgumentParser(description="QEMU NSIS build helper.") 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="*") args = parser.parse_args() @@ -63,9 +87,26 @@ def main(): !insertmacro MUI_DESCRIPTION_TEXT ${{Section_{0}}} "{1}" """.format(arch, desc)) + search_path = args.dlldir + print("Searching '%s' for the dependent dlls ..." % search_path) + dlldir = os.path.join(destdir + prefix, "dll") + os.mkdir(dlldir) + for exe in glob.glob(os.path.join(destdir + prefix, "*.exe")): signcode(exe) + # find all dll dependencies + deps = set(find_deps(exe, search_path, set())) + deps.remove(exe) + + # copy all dlls to the DLLDIR + for dep in deps: + dllfile = 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 = [ "makensis", "-V2", @@ -73,12 +114,9 @@ def main(): "-DSRCDIR=" + args.srcdir, "-DBINDIR=" + destdir + prefix, ] - dlldir = "w32" if args.cpu == "x86_64": - dlldir = "w64" makensis += ["-DW64"] - if os.path.exists(os.path.join(args.srcdir, "dll")): - makensis += ["-DDLLDIR={0}/dll/{1}".format(args.srcdir, dlldir)] + makensis += ["-DDLLDIR=" + dlldir] makensis += ["-DOUTFILE=" + args.outfile] + args.nsisargs subprocess.run(makensis) From patchwork Thu Sep 8 13:28:14 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Bin Meng X-Patchwork-Id: 12970150 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A9304C54EE9 for ; Thu, 8 Sep 2022 13:36:31 +0000 (UTC) Received: from localhost ([::1]:43042 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oWHhm-0005Ln-Lz for qemu-devel@archiver.kernel.org; Thu, 08 Sep 2022 09:36:30 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:55076) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oWHa8-0004Xp-62 for qemu-devel@nongnu.org; Thu, 08 Sep 2022 09:28:37 -0400 Received: from mail-pf1-x436.google.com ([2607:f8b0:4864:20::436]:34342) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oWHa6-0002bZ-Os for qemu-devel@nongnu.org; Thu, 08 Sep 2022 09:28:35 -0400 Received: by mail-pf1-x436.google.com with SMTP id e68so4880017pfe.1 for ; Thu, 08 Sep 2022 06:28:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=ufiJI7bNe+lQgV+yCFrf9iuYn0PLp3Pbem/SenhzEaI=; b=lUC4X/yvHoCbgZgzsoQIXpoLTrg/7AGNyT3G6VLnKLmEO4YJ5yUDsZwVu6OjBofMdN N126RVBBKQ2v3b2NvT1wVG/pRgnPdQPwkRRTaK6QMs1KinqUa0ymfM61xDo/ICVWcarj Udw8/dEoAomL0zMXtxf7rcUDNKJ4MnI0jagOXDmUlsqXaXRrIR+zzM4jWWsMNWkLR0GG sQyyYcPZpp7dDzJoQ32ssLV+n7/z9TqKLwbLYdjS/KIklyWMjYoaqP0o9Qr2zcuZBpWw 1PKmv6SgwAu5hAtgJ4oa2DwjPAMHhI/DAL5Hv7kQGp3ZtW6dIOCWeGiyEzLxkbGG7+lc I70Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date; bh=ufiJI7bNe+lQgV+yCFrf9iuYn0PLp3Pbem/SenhzEaI=; b=JfBIc1kVHPFJwhYorFiiFus64uDxjeetHe8zFT5HMY8/oopFZU5lIdsR2LOYZDSOJx ipReIZum7EEvQiVFUTsponrMFG2JAkvRS+G0eDCm2XXXshhH9+KYyWo5WnjMxsaaEXIZ 5OQ7O3Ynu5x0iTA6nj0uOLlxOQn/237Ir3FgZTPgNLnflJpbVMiOrkOBHKbWv2t1REmR fNfbA0jFVU/+Bgs17ragwG1sTYCVs8jz8PN0AA0HiWT5fk7aEflH+bld+LebHynQj90i lsIwGagbdiDD30s3I2e8zGLn2RFwsnJc74iiglyPVFzUDTg6HSbgmrT4E+m5HHH3nc4H iIPw== X-Gm-Message-State: ACgBeo3yDol9QpzZpHeFnS6N+WGBWkYY8GTFJoFjFJIBhIIploK6nRML uo/kzs+AaQBw/ixBKp1Q+5mNeJVeW3U= X-Google-Smtp-Source: AA6agR5D1uCKJmL08JxA5tgtAB/9dP0Dqbv9FE7s7QsHnk/d1Bortfr9POXn+vyzDD07HnLGpWkzZQ== X-Received: by 2002:aa7:87d6:0:b0:53e:79bb:feb2 with SMTP id i22-20020aa787d6000000b0053e79bbfeb2mr7722973pfo.13.1662643712928; Thu, 08 Sep 2022 06:28:32 -0700 (PDT) Received: from ubuntu.. (144.168.56.201.16clouds.com. [144.168.56.201]) by smtp.gmail.com with ESMTPSA id r8-20020a170902be0800b001755ac7dd0asm1731693pls.290.2022.09.08.06.28.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Sep 2022 06:28:32 -0700 (PDT) From: Bin Meng To: qemu-devel@nongnu.org Cc: Bin Meng , =?utf-8?q?Alex_Benn=C3=A9e?= , Beraldo Leal , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Thomas Huth , Wainer dos Santos Moschetta Subject: [PATCH 4/7] .gitlab-ci.d/windows.yml: Drop the sed processing in the 64-bit build Date: Thu, 8 Sep 2022 21:28:14 +0800 Message-Id: <20220908132817.1831008-5-bmeng.cn@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220908132817.1831008-1-bmeng.cn@gmail.com> References: <20220908132817.1831008-1-bmeng.cn@gmail.com> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::436; envelope-from=bmeng.cn@gmail.com; helo=mail-pf1-x436.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" From: Bin Meng The sed processing of build/config-host.mak seems to be no longer needed, and there is no such in the 32-bit build too. Drop it. Signed-off-by: Bin Meng Reviewed-by: Thomas Huth Reviewed-by: Philippe Mathieu-Daudé --- .gitlab-ci.d/windows.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.gitlab-ci.d/windows.yml b/.gitlab-ci.d/windows.yml index da6013904a..86a4339c48 100644 --- a/.gitlab-ci.d/windows.yml +++ b/.gitlab-ci.d/windows.yml @@ -60,7 +60,6 @@ msys2-64bit: - $env:MSYS = 'winsymlinks:native' # Enable native Windows symlink - .\msys64\usr\bin\bash -lc './configure --target-list=x86_64-softmmu --enable-capstone --without-default-devices' - - .\msys64\usr\bin\bash -lc "sed -i '/^ROMS=/d' build/config-host.mak" - .\msys64\usr\bin\bash -lc 'make' - .\msys64\usr\bin\bash -lc 'make check' From patchwork Thu Sep 8 13:28:15 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bin Meng X-Patchwork-Id: 12970157 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 42DE1C38145 for ; Thu, 8 Sep 2022 13:40:30 +0000 (UTC) Received: from localhost ([::1]:53428 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oWHld-0002lm-Aj for qemu-devel@archiver.kernel.org; Thu, 08 Sep 2022 09:40:29 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:55078) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oWHaA-0004YU-H9; Thu, 08 Sep 2022 09:28:38 -0400 Received: from mail-pj1-x1032.google.com ([2607:f8b0:4864:20::1032]:35597) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oWHa9-0002bj-1x; Thu, 08 Sep 2022 09:28:38 -0400 Received: by mail-pj1-x1032.google.com with SMTP id m10-20020a17090a730a00b001fa986fd8eeso2407305pjk.0; Thu, 08 Sep 2022 06:28:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=k0XM4f4qiZ91vGULk+sJ9slfW6MBFVrfDwbiSLgdr6k=; b=M0MKlhgwHWSu9yiJOOaxQHIigmTEwuje7AZBpdjzNrgfFEhHoBU3V5uwnuOtmpXGqf GUjrTHLLqF3oERtnfSpIMTANQvGx011cM9usYMHYRnqEuOTuGmmW52YoQYL0A0gQOW4r an0bLX7PvVjulLd97Ku6yUvo4ToSuoAL0klqQ+KzHMsZkMSZ3nN+46eb2XLlfl9YPffv nR5Z9UTeqdcLaDrhh/7oQhUxOewO9YowItl8JRF85ZMx5+40u05aGd7uK6MNWwzXP8t+ 72ghDGymq/4EAvOsIZtbCX3JfBKdLWqKCWwfvzk7z8LDlxHlEaPIGPQNz7C6Ow+gMqOf anLA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date; bh=k0XM4f4qiZ91vGULk+sJ9slfW6MBFVrfDwbiSLgdr6k=; b=UQaeJ471SX2WfIe1w4vrI1Y5hVpuKEY3v7qmlVRgUExZSYm/IMUGwXJsWFwxglIVZC PtEaXc4t5OeUyD39atYGzaavEb34OZvRwLHAkr8AB0XMlCGWgF9UOo6t7dSkwdDW3zrG Cy1g2UMv8ayIP9HLKujNjAb5jJ0Ln8bm5EUHSJchmihfSbkK+Ll1z+1qnMqd+jE3WOwV 5ms1rwe16xzxDJYT5SeEUvkhlJvoR1dlZjZ1Gs/hIlMjvqaGNSDfYKZGKoOPCQYYiyDY 9RasRikiUr8yudHS2i6wqi8BoTZU5g4S+AdJHQ4u4apY1YtfaYD9/K55urnGveRMuw0i wkDA== X-Gm-Message-State: ACgBeo17JopC/SWmV2z9K+w1/eM0kNyoD1DHDd1QN35hDuHzf3bjg0JH LEuLxWPHIq4YB0G77Z4v0uqM5J1Xz8U= X-Google-Smtp-Source: AA6agR5R/WzgW6XjOuLLgIQLZKOlHGctn/skSiCeoLWouyuXyQrTe0wRYxGRyaDvyTgE/G/Dx+VlIg== X-Received: by 2002:a17:902:9887:b0:172:7090:6485 with SMTP id s7-20020a170902988700b0017270906485mr9264432plp.63.1662643715302; Thu, 08 Sep 2022 06:28:35 -0700 (PDT) Received: from ubuntu.. (144.168.56.201.16clouds.com. [144.168.56.201]) by smtp.gmail.com with ESMTPSA id r8-20020a170902be0800b001755ac7dd0asm1731693pls.290.2022.09.08.06.28.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Sep 2022 06:28:34 -0700 (PDT) From: Bin Meng To: qemu-devel@nongnu.org Cc: Bin Meng , Hanna Reitz , Kevin Wolf , Peter Lieven , qemu-block@nongnu.org Subject: [PATCH 5/7] block/nfs: Fix 32-bit Windows build Date: Thu, 8 Sep 2022 21:28:15 +0800 Message-Id: <20220908132817.1831008-6-bmeng.cn@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220908132817.1831008-1-bmeng.cn@gmail.com> References: <20220908132817.1831008-1-bmeng.cn@gmail.com> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::1032; envelope-from=bmeng.cn@gmail.com; helo=mail-pj1-x1032.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" 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 files") Signed-off-by: Bin Meng Reviewed-by: Stefan Weil --- block/nfs.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/block/nfs.c b/block/nfs.c index 444c40b458..d5d67937dd 100644 --- a/block/nfs.c +++ b/block/nfs.c @@ -418,7 +418,11 @@ static int64_t nfs_client_open(NFSClient *client, BlockdevOptionsNfs *opts, int flags, int open_flags, Error **errp) { int64_t ret = -EINVAL; +#ifdef _WIN32 + struct __stat64 st; +#else struct stat st; +#endif char *file = NULL, *strp = NULL; qemu_mutex_init(&client->mutex); @@ -781,7 +785,11 @@ static int nfs_reopen_prepare(BDRVReopenState *state, BlockReopenQueue *queue, Error **errp) { NFSClient *client = state->bs->opaque; +#ifdef _WIN32 + struct __stat64 st; +#else struct stat st; +#endif int ret = 0; if (state->flags & BDRV_O_RDWR && bdrv_is_read_only(state->bs)) { From patchwork Thu Sep 8 13:28:16 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bin Meng X-Patchwork-Id: 12970151 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 9EF2CC38145 for ; Thu, 8 Sep 2022 13:36:32 +0000 (UTC) Received: from localhost ([::1]:43040 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oWHhn-0005LE-Ks for qemu-devel@archiver.kernel.org; Thu, 08 Sep 2022 09:36:31 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:55082) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oWHaC-0004g5-UA for qemu-devel@nongnu.org; Thu, 08 Sep 2022 09:28:40 -0400 Received: from mail-pj1-x1036.google.com ([2607:f8b0:4864:20::1036]:41663) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oWHaB-0002c5-C3 for qemu-devel@nongnu.org; Thu, 08 Sep 2022 09:28:40 -0400 Received: by mail-pj1-x1036.google.com with SMTP id q15-20020a17090a304f00b002002ac83485so2487783pjl.0 for ; Thu, 08 Sep 2022 06:28:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=5nS5bCvlfLFqWAAq8Ohfwhhh8km0jfFl9ekoab+BdY8=; b=isRo87B2KXr/v6FQl4ziq4y7JWThXM+0/PQ0yo8i01IuSW9dJp+GYSOeHL2Rx+3oJe FLKbgq3o+TiAXm4bXMQhe6ucaWpPQRXhcI6eP8C12FGqsOBhpoDUl/2q9BEWsDAG/TNZ kem+1LPlh5mQqfwYrESGYur/hOC+VX9wTwcPgEdoAEs4veDIw6UW6CqphnmI2U6U8L85 EC3GQgVUfckhaOg0wvcWX2AssOIIyj1N5C8AC6mwiDrQE28G92RSu58YdCMyMKPB+boP DzJ3fYXABs+9OlgA+UN0Vk58nqhRrEYkGmVGmO/McdIC+QwbTGOnKEEtbGX+1LWQq/8b m8cg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date; bh=5nS5bCvlfLFqWAAq8Ohfwhhh8km0jfFl9ekoab+BdY8=; b=zvLAJtLMdK72NgUZFwxADmEGV0wDkz68mR906Mll1xrKBlEPt6bnFuVFJB5tHbIAxO B4l+8hQNZzjhUG3o4xUsvA4zLgXC73iMShLlW64f5YOEwls3jIbRq+VSxSTresNHDVWw s6o/dCUBggfFxGSleKLwoMb0k97g3jhl3tUfjQRVQwyrswqrSNc5zcJWhiAdX2irUKnc Y5koiTff0WSmJdoiQ2yFIlAeuXng66e8HLP6gVJJI1x9Y+GH0hq9wiUy38bA3tbNRVSt SkkhpUZ7HPz2gsRRPKSAbkRn8Ase2nK4GaCcyYecGHqMvp4pQHl4cU10iGVUeyNA1Zpx lIwA== X-Gm-Message-State: ACgBeo1H2pkv5nE6Npq9HjBIEFFdbozV6A1YmdrhxmC+OTx3S+nHIGsZ DNX30dAxIHL41JNFuJb3Yn8OuUzub6o= X-Google-Smtp-Source: AA6agR6vppiVkr5DE6WVM5Dmr7N6vvlshns1QYtwD1Mefiu4VRzTeU9WmW976FeFALd483pku9IspA== X-Received: by 2002:a17:903:41cc:b0:176:d89d:63e3 with SMTP id u12-20020a17090341cc00b00176d89d63e3mr8859445ple.31.1662643717880; Thu, 08 Sep 2022 06:28:37 -0700 (PDT) Received: from ubuntu.. (144.168.56.201.16clouds.com. [144.168.56.201]) by smtp.gmail.com with ESMTPSA id r8-20020a170902be0800b001755ac7dd0asm1731693pls.290.2022.09.08.06.28.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Sep 2022 06:28:37 -0700 (PDT) From: Bin Meng To: qemu-devel@nongnu.org Cc: Bin Meng , =?utf-8?q?Alex_Benn=C3=A9e?= , Beraldo Leal , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Thomas Huth , Wainer dos Santos Moschetta Subject: [PATCH 6/7] .gitlab-ci.d/windows.yml: Unify the prerequisite packages Date: Thu, 8 Sep 2022 21:28:16 +0800 Message-Id: <20220908132817.1831008-7-bmeng.cn@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220908132817.1831008-1-bmeng.cn@gmail.com> References: <20220908132817.1831008-1-bmeng.cn@gmail.com> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::1036; envelope-from=bmeng.cn@gmail.com; helo=mail-pj1-x1036.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" From: Bin Meng At present the prerequisite packages for 64-bit and 32-bit builds are slightly different. Let's use the same packages for both. Signed-off-by: Bin Meng --- .gitlab-ci.d/windows.yml | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/.gitlab-ci.d/windows.yml b/.gitlab-ci.d/windows.yml index 86a4339c48..fffb202658 100644 --- a/.gitlab-ci.d/windows.yml +++ b/.gitlab-ci.d/windows.yml @@ -40,11 +40,15 @@ msys2-64bit: mingw-w64-x86_64-gcc mingw-w64-x86_64-glib2 mingw-w64-x86_64-gnutls + mingw-w64-x86_64-gtk3 + mingw-w64-x86_64-libgcrypt + mingw-w64-x86_64-libjpeg-turbo mingw-w64-x86_64-libnfs mingw-w64-x86_64-libpng mingw-w64-x86_64-libssh mingw-w64-x86_64-libtasn1 mingw-w64-x86_64-libusb + mingw-w64-x86_64-lzo2 mingw-w64-x86_64-nettle mingw-w64-x86_64-ninja mingw-w64-x86_64-pixman @@ -77,16 +81,22 @@ msys2-32bit: mingw-w64-i686-gtk3 mingw-w64-i686-libgcrypt mingw-w64-i686-libjpeg-turbo + mingw-w64-i686-libnfs + mingw-w64-i686-libpng mingw-w64-i686-libssh mingw-w64-i686-libtasn1 mingw-w64-i686-libusb mingw-w64-i686-lzo2 + mingw-w64-i686-nettle mingw-w64-i686-ninja mingw-w64-i686-pixman mingw-w64-i686-pkgconf mingw-w64-i686-python + mingw-w64-i686-SDL2 + mingw-w64-i686-SDL2_image mingw-w64-i686-snappy - mingw-w64-i686-usbredir " + mingw-w64-i686-usbredir + mingw-w64-i686-zstd " - $env:CHERE_INVOKING = 'yes' # Preserve the current working directory - $env:MSYSTEM = 'MINGW32' # Start a 32-bit MinG environment - $env:MSYS = 'winsymlinks:native' # Enable native Windows symlink From patchwork Thu Sep 8 13:28:17 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Bin Meng X-Patchwork-Id: 12970156 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 7DC03C38145 for ; Thu, 8 Sep 2022 13:40:23 +0000 (UTC) Received: from localhost ([::1]:53426 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oWHlW-0002gb-At for qemu-devel@archiver.kernel.org; Thu, 08 Sep 2022 09:40:22 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:55084) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oWHaF-0004kA-CN for qemu-devel@nongnu.org; Thu, 08 Sep 2022 09:28:43 -0400 Received: from mail-pg1-x533.google.com ([2607:f8b0:4864:20::533]:37729) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oWHaD-0002cX-Oz for qemu-devel@nongnu.org; Thu, 08 Sep 2022 09:28:43 -0400 Received: by mail-pg1-x533.google.com with SMTP id bh13so16774658pgb.4 for ; Thu, 08 Sep 2022 06:28:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=FMKftuYvZGO/ycJsKzJJ5RksJYejGrCyVdxveZnA9MI=; b=h8kwEXdVGDokAqP2rCEvhGukyr0RiGbCdGsA7BUJlCPuKmvl6fNctVxC0bG7Crybuq LOzzWC4y9/KikhKWLPTCnCHgdsP8uBDGOXezGu3/XnufDvidI8VoBb1tG+mXuQlaL8ut bPWOuqTmVCatmpy7x2PGKkGFzg8PINqIRVnbkXTCrSPxpLS8mbs4CIERsktw9QiMsUEg WY9t/EbZ5I+GeCalSaDJ+1F+/HoE7Ks0FBQrE95x4KHpXkjdiHfESYPFiA/Q3fh/o2/f x9ooV3NJG7EFkEMQ0vZ2JfJ/MEFMbKB+ELM9WVBiO7RKUKrydIIEhp9BiMm/Uv1X4WQV vt9A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date; bh=FMKftuYvZGO/ycJsKzJJ5RksJYejGrCyVdxveZnA9MI=; b=UKhKlAt59Wq8REj54/MJGrmeEKt88Y0J7xnjyJ+C7CQ8BB9McnpeBe3h2fKJeTNhGX Yqd+XU1om+QMdcbHQuhBvXqQWAQLh9SWqfuUygDlqIIeI44wcMV5nzyd44Mf2J1z4dvF PVrJERfmsCgQZyBp0vW4+ZRDaHD8O9OHsS1pRTVB7Ukt/ZPcV/zxLxynn7Z6KOUC+zuv 8YlwXyn+3kd3dYJBpS3bxyG02Oq0nPo/WEVaYyJdecry+FWOst9FJFwNHZoa/6VNitav PHOfg7i0uGQkh/OQEnE2Or1aJMAr8rSWbznRxFx+i5sHSjohwK3jG+B+cGiV2RgOWKgJ semA== X-Gm-Message-State: ACgBeo3cfHJPNBFKHjnE4CgxkZb8evTD6ALxYgCLndrxCjeDN6BPPwEk o9f1HS7f6I6ynii6h/Sd30UnhBKcHLY= X-Google-Smtp-Source: AA6agR47OAjvoYxrDXShyZ06Ym2iju9Rcq4G6Ji2Z0Ey35Xntpi1+TzYTZgUYj3eJZXQXriORK8oVQ== X-Received: by 2002:a63:1157:0:b0:435:200a:2d23 with SMTP id 23-20020a631157000000b00435200a2d23mr4075663pgr.329.1662643720378; Thu, 08 Sep 2022 06:28:40 -0700 (PDT) Received: from ubuntu.. (144.168.56.201.16clouds.com. [144.168.56.201]) by smtp.gmail.com with ESMTPSA id r8-20020a170902be0800b001755ac7dd0asm1731693pls.290.2022.09.08.06.28.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Sep 2022 06:28:40 -0700 (PDT) From: Bin Meng To: qemu-devel@nongnu.org Cc: Bin Meng , =?utf-8?q?Alex_Benn=C3=A9e?= , Beraldo Leal , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Thomas Huth , Wainer dos Santos Moschetta Subject: [PATCH 7/7] .gitlab-ci.d/windows.yml: Test 'make installer' in the CI Date: Thu, 8 Sep 2022 21:28:17 +0800 Message-Id: <20220908132817.1831008-8-bmeng.cn@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220908132817.1831008-1-bmeng.cn@gmail.com> References: <20220908132817.1831008-1-bmeng.cn@gmail.com> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::533; envelope-from=bmeng.cn@gmail.com; helo=mail-pg1-x533.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" From: Bin Meng Now that we have supported packaging DLLs automatically, let's add the 'make installer' in the CI and publish the generated installer file as an artifact. Increase the job timeout to 90 minutes to accommodate to it. Signed-off-by: Bin Meng Reviewed-by: Philippe Mathieu-Daudé --- .gitlab-ci.d/windows.yml | 27 +++++++++++++++++++-------- 1 file changed, 19 insertions(+), 8 deletions(-) diff --git a/.gitlab-ci.d/windows.yml b/.gitlab-ci.d/windows.yml index fffb202658..3a94d40e73 100644 --- a/.gitlab-ci.d/windows.yml +++ b/.gitlab-ci.d/windows.yml @@ -10,7 +10,7 @@ - ${CI_PROJECT_DIR}/msys64/var/cache needs: [] stage: build - timeout: 70m + timeout: 90m before_script: - If ( !(Test-Path -Path msys64\var\cache ) ) { mkdir msys64\var\cache @@ -28,6 +28,11 @@ - .\msys64\usr\bin\bash -lc 'pacman --noconfirm -Syuu' # Core update - .\msys64\usr\bin\bash -lc 'pacman --noconfirm -Syuu' # Normal update - taskkill /F /FI "MODULES eq msys-2.0.dll" + artifacts: + name: "$CI_JOB_NAME-$CI_COMMIT_REF_SLUG" + expire_in: 7 days + paths: + - build/qemu-setup*.exe msys2-64bit: extends: .shared_msys2_builder @@ -51,6 +56,7 @@ msys2-64bit: mingw-w64-x86_64-lzo2 mingw-w64-x86_64-nettle mingw-w64-x86_64-ninja + mingw-w64-x86_64-nsis mingw-w64-x86_64-pixman mingw-w64-x86_64-pkgconf mingw-w64-x86_64-python @@ -60,12 +66,15 @@ msys2-64bit: mingw-w64-x86_64-usbredir mingw-w64-x86_64-zstd " - $env:CHERE_INVOKING = 'yes' # Preserve the current working directory - - $env:MSYSTEM = 'MINGW64' # Start a 64 bit Mingw environment + - $env:MSYSTEM = 'MINGW64' # Start a 64-bit MinGW environment - $env:MSYS = 'winsymlinks:native' # Enable native Windows symlink - - .\msys64\usr\bin\bash -lc './configure --target-list=x86_64-softmmu + - mkdir build + - cd build + - ..\msys64\usr\bin\bash -lc '../configure --target-list=x86_64-softmmu --enable-capstone --without-default-devices' - - .\msys64\usr\bin\bash -lc 'make' - - .\msys64\usr\bin\bash -lc 'make check' + - ..\msys64\usr\bin\bash -lc 'make' + - ..\msys64\usr\bin\bash -lc 'make check' + - ..\msys64\usr\bin\bash -lc 'make installer' msys2-32bit: extends: .shared_msys2_builder @@ -89,6 +98,7 @@ msys2-32bit: mingw-w64-i686-lzo2 mingw-w64-i686-nettle mingw-w64-i686-ninja + mingw-w64-i686-nsis mingw-w64-i686-pixman mingw-w64-i686-pkgconf mingw-w64-i686-python @@ -98,10 +108,11 @@ msys2-32bit: mingw-w64-i686-usbredir mingw-w64-i686-zstd " - $env:CHERE_INVOKING = 'yes' # Preserve the current working directory - - $env:MSYSTEM = 'MINGW32' # Start a 32-bit MinG environment + - $env:MSYSTEM = 'MINGW32' # Start a 32-bit MinGW environment - $env:MSYS = 'winsymlinks:native' # Enable native Windows symlink - - mkdir output - - cd output + - mkdir build + - cd build - ..\msys64\usr\bin\bash -lc "../configure --target-list=ppc64-softmmu" - ..\msys64\usr\bin\bash -lc 'make' - ..\msys64\usr\bin\bash -lc 'make check' + - ..\msys64\usr\bin\bash -lc 'make installer'