From nobody Mon Feb 9 09:55:15 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; 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=fail(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1607543960; cv=none; d=zohomail.com; s=zohoarc; b=euqMI+AfRFO3hSqMyD7saywFmkQFwe3/fzpCbenFzmoybXz9SlrUYlZ0zViPEUx5h6r61H0Pwc0RAZxdXvisuCW+USfEq48YLKYo/xiODFRxDIR26jB0Yvl9mcZbmsweTyDBgXb/VyRMzKhjaLpI4XiCSpVv5MymbK6qt1cJo78= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1607543960; 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=fjelfr20ONB8EE1U9iETs2U+O4AtShFet7oBRiVQZlY=; b=L7Izxtob6F/3ZmteLvgUPrMhhT2QAtTMovBZX6DuHyz2gjvn7fnnqh7QPh19j6XIgWiLpRg3cIG4RXUBJEF3qyioZabXcU9QO/9Ml+fhfoCW0rQwzX2lj8CBtvxEjUzI+Kt/8RTNIoqdEokNScGVeYP6Zhx4o0Rup6KkrsZLifU= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; 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=fail 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 1607543960710432.4886999081349; Wed, 9 Dec 2020 11:59:20 -0800 (PST) Received: from localhost ([::1]:39980 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kn311-0007qy-Qo for importer@patchew.org; Wed, 09 Dec 2020 12:12:35 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:36246) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kn2q1-0006WK-DT for qemu-devel@nongnu.org; Wed, 09 Dec 2020 12:01:13 -0500 Received: from mail-wm1-x32a.google.com ([2a00:1450:4864:20::32a]:33519) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kn2px-0000rD-0H for qemu-devel@nongnu.org; Wed, 09 Dec 2020 12:01:12 -0500 Received: by mail-wm1-x32a.google.com with SMTP id w206so1251063wma.0 for ; Wed, 09 Dec 2020 09:01:07 -0800 (PST) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id r128sm4806581wma.5.2020.12.09.09.00.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Dec 2020 09:01:03 -0800 (PST) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 7B6E81FF8F; Wed, 9 Dec 2020 17:00:59 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=fjelfr20ONB8EE1U9iETs2U+O4AtShFet7oBRiVQZlY=; b=n5XjI/nsQ28+DcNSvZ5a97ZM+GV0GKN1MIDusKJkhnkUBZR/igrsMGXwtJUtIS3kJJ ZnoFQrBhyctq6k87a181gY6kZ7djGDTn1AHmj+ULx0QsXkMvUM2Bo5X7QvUNG+HbxfkA eW3E/4FOmIOpw80QpJW5Mv3xxBcxO0A8Xiy8TJW5NF/nZ/KYY16JLwr+tYuQYvkw4cai BZkQlg+YMyAv8Hskg/w5+q4iKb/DLE7/5IO5HsGhUw0C4/6l2++IrbkQ/CExdv5YMzOo d0efMik78z8f5/W8JsquiAxZN/g+uSbxUCN8R8AJG67DrFRIv7Xk6D0ezZug8/QmXmvc gu0w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=fjelfr20ONB8EE1U9iETs2U+O4AtShFet7oBRiVQZlY=; b=OHIUXtjDQOko6XYM2ONxRwfHxe7XiIiXgg/2A1FTCSmkgpUni8bhp6HI+AqoX5KZAs gTnm08uOE0U+Vs23J/cpFdZwD0FjrBW+DNc60z+MMmoNW+0cGLwXjBteBCTCFasKsMce LbC7Ut1VSAk5aUfLhh8Sl97m3w70hslpd9UeUocsctAP+adDvbCnjR9RtdgN24cF8e6V L9uSb+1Qj1BKJSS1Q/UZYxf0q7W7pyDHCMpIcY3YM4svjDeL8NtWZ1NYos8FQphsqF+e 5SvDEtCfeDDCGcGhh5qTVHBpULmFo9lOFOSMLzq35gnXKHkV0ESknmhrlPIzD7IyyR+p qjrQ== X-Gm-Message-State: AOAM533eGfdB4tN4larQnwMaX7laZ/YH+unZNlp58R5Re/ffX8WokKVQ qp3w8QkUNZcEIxv+hv4qM6HYDA== X-Google-Smtp-Source: ABdhPJxVReJSrXB1xHdmLk1mGq2ztzyUii1S2QZajki9G+oVTzBSPRbDkSKMG4erGDOvLmzaUQwtAA== X-Received: by 2002:a1c:6a0e:: with SMTP id f14mr3690801wmc.102.1607533266694; Wed, 09 Dec 2020 09:01:06 -0800 (PST) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v1 3/6] configure: add --without-default-features Date: Wed, 9 Dec 2020 17:00:56 +0000 Message-Id: <20201209170059.20742-4-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20201209170059.20742-1-alex.bennee@linaro.org> References: <20201209170059.20742-1-alex.bennee@linaro.org> 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=2a00:1450:4864:20::32a; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32a.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 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: fam@euphon.net, berrange@redhat.com, stefanb@linux.vnet.ibm.com, =?UTF-8?q?Alex=20Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, cota@braap.org, stefanha@redhat.com, marcandre.lureau@redhat.com, pbonzini@redhat.com, aurelien@aurel32.net Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) By default QEMU enables a lot of features if it can probe and find the support libraries. It also enables a bunch of features by default. This patch adds the ability to build --without-default-features which can be paired with a --without-default-devices for a barely functional build. The main use case for this is testing our build assumptions and for minimising the amount of stuff you build if you just want to test a particular feature on your relatively slow emulated test system. Signed-off-by: Alex Benn=C3=A9e --- configure | 159 ++++++++++++++++++++++++++++++------------------------ 1 file changed, 88 insertions(+), 71 deletions(-) diff --git a/configure b/configure index 8f2095a2db..a08e6c96e0 100755 --- a/configure +++ b/configure @@ -291,10 +291,24 @@ unset target_list_exclude # # Always add --enable-foo and --disable-foo command line args. # Distributions want to ensure that several features are compiled in, and = it -# is impossible without a --enable-foo that exits if a feature is not foun= d. +# is impossible without a --enable-foo that exits if a feature is not +# found. =20 -brlapi=3D"" -curl=3D"" +default_feature=3D"" +default_yes_feature=3D"yes" +# parse CC options second +for opt do + optarg=3D$(expr "x$opt" : 'x[^=3D]*=3D\(.*\)') + case "$opt" in + --without-default-features) + default_feature=3D"no" + default_yes_feature=3D"no" + ;; + esac +done + +brlapi=3D"$default_feature" +curl=3D"$default_feature" iconv=3D"auto" curses=3D"auto" docs=3D"auto" @@ -303,52 +317,52 @@ netmap=3D"no" sdl=3D"auto" sdl_image=3D"auto" virtiofsd=3D"auto" -virtfs=3D"" +virtfs=3D"$default_feature" libudev=3D"auto" mpath=3D"auto" vnc=3D"enabled" sparse=3D"auto" -vde=3D"" +vde=3D"$default_feature" vnc_sasl=3D"auto" vnc_jpeg=3D"auto" vnc_png=3D"auto" xkbcommon=3D"auto" -xen=3D"" -xen_ctrl_version=3D"" +xen=3D"$default_feature" +xen_ctrl_version=3D"$default_feature" xen_pci_passthrough=3D"auto" -linux_aio=3D"" -linux_io_uring=3D"" -cap_ng=3D"" -attr=3D"" -libattr=3D"" -xfs=3D"" +linux_aio=3D"$default_feature" +linux_io_uring=3D"$default_feature" +cap_ng=3D"$default_feature" +attr=3D"$default_feature" +libattr=3D"$default_feature" +xfs=3D"$default_feature" tcg=3D"enabled" -membarrier=3D"" -vhost_net=3D"" -vhost_crypto=3D"" -vhost_scsi=3D"" -vhost_vsock=3D"" +membarrier=3D"$default_feature" +vhost_net=3D"$default_feature" +vhost_crypto=3D"$default_feature" +vhost_scsi=3D"$default_feature" +vhost_vsock=3D"$default_feature" vhost_user=3D"no" vhost_user_blk_server=3D"auto" -vhost_user_fs=3D"" +vhost_user_fs=3D"$default_feature" kvm=3D"auto" hax=3D"auto" hvf=3D"auto" whpx=3D"auto" -rdma=3D"" -pvrdma=3D"" +rdma=3D"$default_feature" +pvrdma=3D"$default_feature" gprof=3D"no" debug_tcg=3D"no" debug=3D"no" sanitizers=3D"no" tsan=3D"no" -fortify_source=3D"" +fortify_source=3D"$default_feature" strip_opt=3D"yes" tcg_interpreter=3D"no" bigendian=3D"no" mingw32=3D"no" gcov=3D"no" -EXESUF=3D"" +EXESUF=3D"$default_feature" HOST_DSOSUF=3D".so" modules=3D"no" module_upgrades=3D"no" @@ -370,81 +384,81 @@ pie=3D"" qom_cast_debug=3D"yes" trace_backends=3D"log" trace_file=3D"trace" -spice=3D"" -rbd=3D"" -smartcard=3D"" +spice=3D"$default_feature" +rbd=3D"$default_feature" +smartcard=3D"$default_feature" u2f=3D"auto" -libusb=3D"" -usb_redir=3D"" -opengl=3D"" +libusb=3D"$default_feature" +usb_redir=3D"$default_feature" +opengl=3D"$default_feature" opengl_dmabuf=3D"no" cpuid_h=3D"no" -avx2_opt=3D"" +avx2_opt=3D"$default_feature" capstone=3D"auto" -lzo=3D"" -snappy=3D"" -bzip2=3D"" -lzfse=3D"" -zstd=3D"" -guest_agent=3D"" +lzo=3D"$default_feature" +snappy=3D"$default_feature" +bzip2=3D"$default_feature" +lzfse=3D"$default_feature" +zstd=3D"$default_feature" +guest_agent=3D"$default_feature" guest_agent_with_vss=3D"no" guest_agent_ntddscsi=3D"no" -guest_agent_msi=3D"" -vss_win32_sdk=3D"" +guest_agent_msi=3D"$default_feature" +vss_win32_sdk=3D"$default_feature" win_sdk=3D"no" -want_tools=3D"" -libiscsi=3D"" -libnfs=3D"" +want_tools=3D"$default_feature" +libiscsi=3D"$default_feature" +libnfs=3D"$default_feature" coroutine=3D"" -coroutine_pool=3D"" +coroutine_pool=3D"$default_feature" debug_stack_usage=3D"no" crypto_afalg=3D"no" -seccomp=3D"" -glusterfs=3D"" +seccomp=3D"$default_feature" +glusterfs=3D"$default_feature" glusterfs_xlator_opt=3D"no" glusterfs_discard=3D"no" glusterfs_fallocate=3D"no" glusterfs_zerofill=3D"no" glusterfs_ftruncate_has_stat=3D"no" glusterfs_iocb_has_stat=3D"no" -gtk=3D"" +gtk=3D"$default_feature" gtk_gl=3D"no" tls_priority=3D"NORMAL" -gnutls=3D"" -nettle=3D"" +gnutls=3D"$default_feature" +nettle=3D"$default_feature" nettle_xts=3D"no" -gcrypt=3D"" +gcrypt=3D"$default_feature" gcrypt_hmac=3D"no" gcrypt_xts=3D"no" qemu_private_xts=3D"yes" -auth_pam=3D"" -vte=3D"" -virglrenderer=3D"" -tpm=3D"" -libssh=3D"" -live_block_migration=3D"yes" -numa=3D"" +auth_pam=3D"$default_feature" +vte=3D"$default_feature" +virglrenderer=3D"$default_feature" +tpm=3D"$default_feature" +libssh=3D"$default_feature" +live_block_migration=3D"$default_yes_feature" +numa=3D"$default_feature" tcmalloc=3D"no" jemalloc=3D"no" -replication=3D"yes" -bochs=3D"yes" -cloop=3D"yes" -dmg=3D"yes" -qcow1=3D"yes" -vdi=3D"yes" -vvfat=3D"yes" -qed=3D"yes" -parallels=3D"yes" +replication=3D"$default_yes_feature" +bochs=3D"$default_yes_feature" +cloop=3D"$default_yes_feature" +dmg=3D"$default_yes_feature" +qcow1=3D"$default_yes_feature" +vdi=3D"$default_yes_feature" +vvfat=3D"$default_yes_feature" +qed=3D"$default_yes_feature" +parallels=3D"$default_yes_feature" sheepdog=3D"no" -libxml2=3D"" +libxml2=3D"$default_feature" debug_mutex=3D"no" -libpmem=3D"" +libpmem=3D"$default_feature" default_devices=3D"yes" plugins=3D"no" fuzzing=3D"no" rng_none=3D"no" -secret_keyring=3D"" -libdaxctl=3D"" +secret_keyring=3D"$default_feature" +libdaxctl=3D"$default_feature" meson=3D"" ninja=3D"" skip_meson=3Dno @@ -453,7 +467,7 @@ gettext=3D"" bogus_os=3D"no" malloc_trim=3D"auto" =20 -# parse CC options first +# parse CC options second for opt do optarg=3D$(expr "x$opt" : 'x[^=3D]*=3D\(.*\)') case "$opt" in @@ -796,7 +810,7 @@ Linux) audio_possible_drivers=3D"oss alsa sdl pa" linux=3D"yes" linux_user=3D"yes" - vhost_user=3D"yes" + vhost_user=3D"$default_yes_feature" ;; esac =20 @@ -940,6 +954,8 @@ for opt do ;; --without-default-devices) default_devices=3D"no" ;; + --without-default-features) # processed above + ;; --enable-gprof) gprof=3D"yes" ;; --enable-gcov) gcov=3D"yes" @@ -1737,7 +1753,8 @@ Advanced options (experts only): --gdb=3DGDB-path gdb to use for gdbstub tests [$gdb_bin] =20 Optional features, enabled with --enable-FEATURE and -disabled with --disable-FEATURE, default is enabled if available: +disabled with --disable-FEATURE, default is enabled if available +(unless built with --without-default-features): =20 system all system emulation targets user supported user emulation targets --=20 2.20.1