From nobody Fri Apr 26 00:22:14 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; 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=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1622314728; cv=none; d=zohomail.com; s=zohoarc; b=dQVnxUjDce/sZwN+t/M8Ynh3aWMYN9vCU27GnXI2FYxaHNZBaKnAxklvi88pG7GLT4nmceeODnIye4X6Bw1ecXM1ypoQwMs7yk5/Hp2FD43KLOr6UDMJn323ki1MtaLcZUW2+s9rky2flCHewHU/OTeHH4f+NHAZHoqj2oVCBuM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1622314728; 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:References:Sender:Subject:To; bh=CZcM5vbj6VjzAVNV5sUsj5b8+5r+4sY34YcWYeKnGoI=; b=gyMzRgPH80fNwemfx5ZScKvhLKmovVY7ok+XA0A0p2In/eZ7fRucfzKXmuV1KlQcFT2b3ZFwaSS8OFV+rWJ1SyEVUBDBRHma/Gfc8ezxOpx1ODQby3tYi5ztLRjXniGjRAO2DVrErHm/PzkpJikYCUsVXzAmVqmZakx4B0207po= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; 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) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1622314728979365.8028552016706; Sat, 29 May 2021 11:58:48 -0700 (PDT) Received: from localhost ([::1]:57558 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ln4AZ-0007gn-Nz for importer@patchew.org; Sat, 29 May 2021 14:58:47 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40080) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ln47j-0003WK-8D for qemu-devel@nongnu.org; Sat, 29 May 2021 14:55:51 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:39727) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ln47h-0005dz-AU for qemu-devel@nongnu.org; Sat, 29 May 2021 14:55:50 -0400 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-104-2qFXNQo_OU-rPGPO00oSIw-1; Sat, 29 May 2021 14:55:45 -0400 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 083AB107ACCA; Sat, 29 May 2021 18:55:45 +0000 (UTC) Received: from localhost (unknown [10.36.110.2]) by smtp.corp.redhat.com (Postfix) with ESMTP id AF43E687CD; Sat, 29 May 2021 18:55:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1622314548; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=CZcM5vbj6VjzAVNV5sUsj5b8+5r+4sY34YcWYeKnGoI=; b=eeydtBX6jDAx0xgRtWp1/TLBIDJCZT4lHg0yTo/QRcE7Lq0RM/I10HSUxNrM6sVcqDXoFU Fs54wjVpDhWC4B0txetud4xV1E6xTKyLoNIme4oXppiW4nTCLXxz5CUahrEvUhFk2lGbOa e6fidST6BdxzXxhh4QQ1VByQuWu0Zr8= X-MC-Unique: 2qFXNQo_OU-rPGPO00oSIw-1 From: marcandre.lureau@redhat.com To: peter.maydell@linaro.org, qemu-devel@nongnu.org Subject: [PULL 2/2] build-sys: make libslirp a meson subproject Date: Sat, 29 May 2021 22:55:22 +0400 Message-Id: <20210529185522.78816-3-marcandre.lureau@redhat.com> In-Reply-To: <20210529185522.78816-1-marcandre.lureau@redhat.com> References: <20210529185522.78816-1-marcandre.lureau@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=marcandre.lureau@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com 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=170.10.133.124; envelope-from=marcandre.lureau@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -30 X-Spam_score: -3.1 X-Spam_bar: --- X-Spam_report: (-3.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.373, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_SBL_A=0.1 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: samuel.thibault@ens-lyon.org, =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: pass (identity @redhat.com) From: Marc-Andr=C3=A9 Lureau Remove the manual build. Moving projects to subprojects/ is required when using meson subproject(): https://mesonbuild.com/Subprojects.html#why-must-all-subprojects-be-inside-= a-single-directory Tested-by: Joelle van Dyne Signed-off-by: Marc-Andr=C3=A9 Lureau --- configure | 2 +- meson.build | 63 +++-------------------------------- .gitmodules | 4 +-- slirp =3D> subprojects/libslirp | 0 4 files changed, 7 insertions(+), 62 deletions(-) rename slirp =3D> subprojects/libslirp (100%) diff --git a/configure b/configure index 90c0807347..b59ec8bd39 100755 --- a/configure +++ b/configure @@ -5279,7 +5279,7 @@ fi case "$slirp" in auto | enabled | internal) # Simpler to always update submodule, even if not needed. - git_submodules=3D"${git_submodules} slirp" + git_submodules=3D"${git_submodules} subprojects/libslirp" ;; esac =20 diff --git a/meson.build b/meson.build index 20d7035e44..3bf0686985 100644 --- a/meson.build +++ b/meson.build @@ -1513,7 +1513,7 @@ slirp_opt =3D 'disabled' if have_system slirp_opt =3D get_option('slirp') if slirp_opt in ['enabled', 'auto', 'system'] - have_internal =3D fs.exists(meson.current_source_dir() / 'slirp/meson.= build') + have_internal =3D fs.exists(meson.current_source_dir() / 'subprojects/= libslirp/meson.build') slirp =3D dependency('slirp', kwargs: static_kwargs, method: 'pkg-config', required: slirp_opt =3D=3D 'system' or @@ -1527,64 +1527,9 @@ if have_system endif endif if slirp_opt =3D=3D 'internal' - slirp_deps =3D [] - if targetos =3D=3D 'windows' - slirp_deps =3D cc.find_library('iphlpapi') - endif - slirp_conf =3D configuration_data() - slirp_conf.set('SLIRP_MAJOR_VERSION', meson.project_version().split('.= ')[0]) - slirp_conf.set('SLIRP_MINOR_VERSION', meson.project_version().split('.= ')[1]) - slirp_conf.set('SLIRP_MICRO_VERSION', meson.project_version().split('.= ')[2]) - slirp_conf.set_quoted('SLIRP_VERSION_STRING', meson.project_version()) - slirp_cargs =3D ['-DG_LOG_DOMAIN=3D"Slirp"'] - slirp_files =3D [ - 'slirp/src/arp_table.c', - 'slirp/src/bootp.c', - 'slirp/src/cksum.c', - 'slirp/src/dhcpv6.c', - 'slirp/src/dnssearch.c', - 'slirp/src/if.c', - 'slirp/src/ip6_icmp.c', - 'slirp/src/ip6_input.c', - 'slirp/src/ip6_output.c', - 'slirp/src/ip_icmp.c', - 'slirp/src/ip_input.c', - 'slirp/src/ip_output.c', - 'slirp/src/mbuf.c', - 'slirp/src/misc.c', - 'slirp/src/ncsi.c', - 'slirp/src/ndp_table.c', - 'slirp/src/sbuf.c', - 'slirp/src/slirp.c', - 'slirp/src/socket.c', - 'slirp/src/state.c', - 'slirp/src/stream.c', - 'slirp/src/tcp_input.c', - 'slirp/src/tcp_output.c', - 'slirp/src/tcp_subr.c', - 'slirp/src/tcp_timer.c', - 'slirp/src/tftp.c', - 'slirp/src/udp.c', - 'slirp/src/udp6.c', - 'slirp/src/util.c', - 'slirp/src/version.c', - 'slirp/src/vmstate.c', - ] - - configure_file( - input : 'slirp/src/libslirp-version.h.in', - output : 'libslirp-version.h', - configuration: slirp_conf) - - slirp_inc =3D include_directories('slirp', 'slirp/src') - libslirp =3D static_library('slirp', - build_by_default: false, - sources: slirp_files, - c_args: slirp_cargs, - include_directories: slirp_inc) - slirp =3D declare_dependency(link_with: libslirp, - dependencies: slirp_deps, - include_directories: slirp_inc) + libslirp =3D subproject('libslirp', + default_options: ['default_library=3Dstatic']) + slirp =3D libslirp.get_variable('libslirp_dep') endif endif =20 diff --git a/.gitmodules b/.gitmodules index 08b1b48a09..447bb3a4df 100644 --- a/.gitmodules +++ b/.gitmodules @@ -49,8 +49,8 @@ [submodule "roms/edk2"] path =3D roms/edk2 url =3D https://gitlab.com/qemu-project/edk2.git -[submodule "slirp"] - path =3D slirp +[submodule "subprojects/libslirp"] + path =3D subprojects/libslirp url =3D https://gitlab.com/qemu-project/libslirp.git [submodule "roms/opensbi"] path =3D roms/opensbi diff --git a/slirp b/subprojects/libslirp similarity index 100% rename from slirp rename to subprojects/libslirp --=20 2.29.0