From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 904B0A0524; Thu, 4 Feb 2021 14:34:47 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6F4652406EC; Thu, 4 Feb 2021 14:34:47 +0100 (CET) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mails.dpdk.org (Postfix) with ESMTP id 6E2812406DE for ; Thu, 4 Feb 2021 14:34:46 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1612445685; 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; bh=k5qP3sXHV+9b4vsD1LbP9YpfTzkO0PU7oz/3cGXC2/0=; b=NxQt0LZ9dQi1UpM8XFM/IIZqlGIjtc+o5QH5wh0NipFizbGpQIWI2Zh+qgsPxrP0VPB5YL m+KGLWcVZswqMWMcaEWmSCs60bE+AyZUADv66AUNXpcCUChfbwjjj8UA+viRQ675Rs6ili 4MOYvgKbviCtsxvvtYygx95SqgUPeic= 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-349-rzdbwjvEPxG8JJmSmJ6-pA-1; Thu, 04 Feb 2021 08:34:41 -0500 X-MC-Unique: rzdbwjvEPxG8JJmSmJ6-pA-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 7B880107ACC7; Thu, 4 Feb 2021 13:34:40 +0000 (UTC) Received: from dmarchan.remote.csb (unknown [10.40.193.161]) by smtp.corp.redhat.com (Postfix) with ESMTP id B909B5C6B8; Thu, 4 Feb 2021 13:34:38 +0000 (UTC) From: David Marchand To: dev@dpdk.org Cc: thomas@monjalon.net, Bruce Richardson Date: Thu, 4 Feb 2021 14:34:35 +0100 Message-Id: <20210204133435.3117-1-david.marchand@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=david.marchand@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII" Subject: [dpdk-dev] [PATCH] devtools: select targets in build test X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" When a target compilation is broken, one way to skip the target is to uninstall the associated toolchain. But it is not always possible and you end up with hacking the script to avoid this target until a fix is ready. It is also often quicker to check a fix on a failing target before checking compilation on all targets. Introduce a variable to select targets. Example: $ DPDK_BUILD_TEST_TARGETS=build-x86-mingw \ ./devtools/test-meson-builds.sh ninja: Entering directory `/home/dmarchan/builds/build-x86-mingw' [...] Found ninja-1.10.1 at /usr/bin/ninja [19/19] Linking target examples/dpdk-helloworld.exe Signed-off-by: David Marchand --- devtools/test-meson-builds.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/devtools/test-meson-builds.sh b/devtools/test-meson-builds.sh index c11ae87e0d..3e88e8291e 100755 --- a/devtools/test-meson-builds.sh +++ b/devtools/test-meson-builds.sh @@ -92,6 +92,15 @@ load_env () # command -v $targetcc >/dev/null 2>&1 || return 1 } +target_is_selected() +{ + if [ -z "${DPDK_BUILD_TEST_TARGETS:-}" ]; then + return 0 + fi + target_filter=" $DPDK_BUILD_TEST_TARGETS " + ! [ "${target_filter##* $1 }" = "${target_filter}" ] +} + config () # { dir=$1 @@ -149,6 +158,7 @@ install_target () # build () # [meson options] { targetdir=$1 + target_is_selected $targetdir || return 0 shift crossfile= [ -r $1 ] && crossfile=$1 || targetcc=$1 @@ -271,6 +281,8 @@ for f in $srcdir/config/ppc/ppc* ; do build $targetdir $f ABI $use_shared done +target_is_selected build-x86-default || exit 0 + # Test installation of the x86-default target, to be used for checking # the sample apps build using the pkg-config file for cflags and libs load_env cc -- 2.23.0