From patchwork Tue Jul 11 09:25:32 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 701497 Delivered-To: patch@linaro.org Received: by 2002:adf:fcc5:0:0:0:0:0 with SMTP id f5csp5613188wrs; Tue, 11 Jul 2023 02:26:01 -0700 (PDT) X-Google-Smtp-Source: APBJJlFQCjP83O3lXFxpvinjltTcO/yV0wOgtO2rF+/AfM1w2OqhM/Y//yTUAOANyls5jvfa4AxB X-Received: by 2002:a0c:e190:0:b0:626:b17:3b97 with SMTP id p16-20020a0ce190000000b006260b173b97mr12349739qvl.65.1689067561038; Tue, 11 Jul 2023 02:26:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689067561; cv=none; d=google.com; s=arc-20160816; b=dT+UC+7NtOSOgW5jOqFdnZjzgDl3J25oML9+O4XLDKmjWjdTLGI/k6Xl2QkcrxKn43 Iwpa6uaaDSXFcct43ckFgwW0am/4xzXqqWH0o4XVJPWUEx1Xx8ZDptUcIm4ciGm8ezPT BJE5yanRh7Qp+4hb+ENzywXiF3I8yEum27+vobheoao3ZfLTsDyHnHH7qFm4Ly+KqK2Z sa/1kxNSrol8BOKns5d0CKAevbdnQxCagP1i5qjxWjJJTRWA2scqY0XURzVC7wrV1Ide +6lALRL2iqaXYDjDeO/HCuPAdC9aHYGOKN18UxK0CQoxxSDZlDYzQmFLgkWChxwPpRr/ H1NQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:message-id:date:subject:cc:to:from:dkim-signature; bh=qMBUsM5cV4dZcFt7kvbGUCTKHF8drcK6kogSoPu1EbE=; fh=H2UqIWroRgrxdKoQ3AIcecdZBRx5lWhVYsSvDhEHvGo=; b=FV8KNdZZ/BiP/knRrU0dz3Qw26Jy0b1Lk6ZpRe6tgOZjTnU0lkB14pcJMUU9IArABo VMAoipXN97/LDgzceuMQe1RneIoxIHEVvk/nwArt8IJiq/ow2A0Zy3tvm/QHOsX9iXIh diebaeWyrcGE3AcWqBYjsPwI7WvYjSevRJoFxrrr2C0tsmbZZU+sdH4HshDysFgBO62k 28BJLkv2GJl4AvjbTYf19/TV++fEbxpGjGiPNyh2a7C5aQ6f6MSUISpeOcdC4++2cyR5 rjRcfDN6lSSMJbqY6Eyu6a2xpJSNvG6WKKByLVverX4p+ZxJX6JPJpodQZE1ExdWrzVZ DfgQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=V0nYz8ZI; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id k1-20020a0cf581000000b0061b79b36c41si603916qvm.36.2023.07.11.02.26.00 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 11 Jul 2023 02:26:01 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=V0nYz8ZI; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qJ9cr-0003r2-RK; Tue, 11 Jul 2023 05:25:41 -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 1qJ9cq-0003qV-ER for qemu-devel@nongnu.org; Tue, 11 Jul 2023 05:25:40 -0400 Received: from mail-wr1-x42a.google.com ([2a00:1450:4864:20::42a]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qJ9cn-0006vg-CM for qemu-devel@nongnu.org; Tue, 11 Jul 2023 05:25:40 -0400 Received: by mail-wr1-x42a.google.com with SMTP id ffacd0b85a97d-3142a9ff6d8so5903568f8f.3 for ; Tue, 11 Jul 2023 02:25:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1689067535; x=1691659535; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=qMBUsM5cV4dZcFt7kvbGUCTKHF8drcK6kogSoPu1EbE=; b=V0nYz8ZIx2KAPsz4kHkypFaPrQ+2nVNuJ0tfP0w/hL0sMGnp8ly/nIkOak1Dx/skAm 4ZIFjBSBws/9+02HHa+qmhb8Ed63CHG11aqQSc/n2E9WSxOkbGg5SpKHZv71UNdc1eDN fr+Mhn5gPWRBaG00yaUIFP0/6GRTOEL/HI/kAsnYnKrisJ3a5hmGLx4x3/t6wpkC5x1A 2ImKh3LzaW7w0vkehw/tmg0CPr30t7bDpxX6EWU9pALdZwiuCrQ4CnQIwEJnBwJO2kwj o9yvxT1otdEE87Hb7UNaCgzBWzAH3k0zIK3g6hieXXE3NIWB8juSSiJjXD2j0ZwKEpdQ h1uA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1689067535; x=1691659535; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=qMBUsM5cV4dZcFt7kvbGUCTKHF8drcK6kogSoPu1EbE=; b=axKbb2piI84ltgWR+f5zSgrBz2xnWLyyd7tODe+ZjqA7sYgDCia/cl3QECVgrp7/mF VuzTY11LdRMjrr823knte/Lzi+xp0JWm6qo+A8UBi9kOtxCgP0Ao3JRi8gX+Q+AYd6uU nnrKRmOpdE4GjCqLVqL8kK57ozhqd/FCv8Fs+A/wp+ZIboBO8Ng6evFNk9hoJIf2q6kG H+W0P0APX2nRV2b/26O5LbifR3tx8ElDajA5jQMFtHdPR43zmuOFz1xJDSannf1/bsMY w910sI/lgAcWBOxOuD2CjMQblm6orLodO/xjaSP2xW5SD3YhkSVHFim9VmlF3rFsim44 HXzg== X-Gm-Message-State: ABy/qLas1afhvBi0Y4wcCeJ0muGvtgxSlXFvvuasPECGXFvMpgcqr5A/ xbcq0N5bIgAHzsjb9RcM0ri9HnTlDpBiyoRisrgq3Q== X-Received: by 2002:adf:e5cb:0:b0:314:545b:4dd with SMTP id a11-20020adfe5cb000000b00314545b04ddmr16204551wrn.20.1689067535518; Tue, 11 Jul 2023 02:25:35 -0700 (PDT) Received: from m1x-phil.lan (mst45-h01-176-184-47-225.dsl.sta.abo.bbox.fr. [176.184.47.225]) by smtp.gmail.com with ESMTPSA id j2-20020a5d4482000000b003143867d2ebsm1711469wrq.63.2023.07.11.02.25.34 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Tue, 11 Jul 2023 02:25:35 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: Thomas Huth , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Paolo Bonzini , =?utf-8?q?Daniel_P=2E_Berrang=C3=A9?= , Michael Tokarev , Alistair Francis , =?utf-8?q?Marc-Andr=C3=A9_Lure?= =?utf-8?q?au?= , Richard Henderson Subject: [hotfix PATCH-for-8.1 v2] meson: Fix cross-building for RISCV host Date: Tue, 11 Jul 2023 11:25:32 +0200 Message-Id: <20230711092532.53929-1-philmd@linaro.org> X-Mailer: git-send-email 2.38.1 MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42a; envelope-from=philmd@linaro.org; helo=mail-wr1-x42a.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, 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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org While when building on native Linux the host architecture is reported as "riscv32" or "riscv64", when cross-compiling it is detected as "riscv". Meson handles the cross-detection but displays a warning: WARNING: Unknown CPU family riscv, please report this at https://github.com/mesonbuild/meson/issues/new Commit 278c1bcef5 was tested on native host but not under cross environment, and now we get on our cross-riscv64-system Gitlab-CI job: ../meson.build:684:6: ERROR: Problem encountered: Unsupported CPU riscv, try --enable-tcg-interpreter Instead of: Found pkg-config: /usr/bin/riscv64-linux-gnu-pkg-config (1.8.1) As a kludge, re-introduce "riscv" in the supported_cpus[] array. Fixes: 278c1bcef5 ("target/riscv: Only unify 'riscv32/64' -> 'riscv' for host cpu in meson") Reported-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé --- meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meson.build b/meson.build index 5fcdb37a71..58e35febb9 100644 --- a/meson.build +++ b/meson.build @@ -55,7 +55,7 @@ qapi_trace_events = [] bsd_oses = ['gnu/kfreebsd', 'freebsd', 'netbsd', 'openbsd', 'dragonfly', 'darwin'] supported_oses = ['windows', 'freebsd', 'netbsd', 'openbsd', 'darwin', 'sunos', 'linux'] -supported_cpus = ['ppc', 'ppc64', 's390x', 'riscv32', 'riscv64', 'x86', 'x86_64', +supported_cpus = ['ppc', 'ppc64', 's390x', 'riscv', 'riscv32', 'riscv64', 'x86', 'x86_64', 'arm', 'aarch64', 'loongarch64', 'mips', 'mips64', 'sparc64'] cpu = host_machine.cpu_family()