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 A995EA00C2; Fri, 9 Dec 2022 10:02:45 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id A3880427EE; Fri, 9 Dec 2022 10:02:41 +0100 (CET) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mails.dpdk.org (Postfix) with ESMTP id 490A040E03 for ; Fri, 9 Dec 2022 10:02:40 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1670576559; 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=oV0PKE2sJO+I57Feea0CW7aAsoqk50Or5/1bgWz1uy8=; b=H3e46wD3bF20NO9msF2K6kRfJZ2Wu0rEFCSGGr0AY8CvL0TXp9UKRf35hxJNo/XBbkseR8 ZGaruU759gZfCfJjKpHyPMmhsO+uI8tGE2l4ndIFzQsSBAiNtg/dmAkdxufRlZtIDRkJMl NkwA9LoLhDnxDA7Z5P5/CIbwT3Uewqw= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-142-4FTIl7CpNpyiE79XxG-5Rg-1; Fri, 09 Dec 2022 04:02:38 -0500 X-MC-Unique: 4FTIl7CpNpyiE79XxG-5Rg-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 39866185A7A3; Fri, 9 Dec 2022 09:02:38 +0000 (UTC) Received: from localhost.localdomain (ovpn-194-246.brq.redhat.com [10.40.194.246]) by smtp.corp.redhat.com (Postfix) with ESMTP id 1AD4E2024CC0; Fri, 9 Dec 2022 09:02:36 +0000 (UTC) From: David Marchand To: dev@dpdk.org Cc: thomas@monjalon.net, bruce.richardson@intel.com, gakhil@marvell.com, Ferruh Yigit Subject: [PATCH v2 2/2] devtools: configure source repo to use as ABI reference Date: Fri, 9 Dec 2022 10:02:22 +0100 Message-Id: <20221209090222.441690-2-david.marchand@redhat.com> In-Reply-To: <20221209090222.441690-1-david.marchand@redhat.com> References: <20221206122341.3046688-1-ferruh.yigit@amd.com> <20221209090222.441690-1-david.marchand@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.4 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII"; x-default=true 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 From: Ferruh Yigit By default 'test-meson-builds.sh' script clones the repository which the script is in, and selects a configured branch ('DPDK_ABI_REF_VERSION') as a reference for ABI check. This patch enables selecting different repository to clone for reference using 'DPDK_ABI_REF_SRC' environment variable. 'DPDK_ABI_REF_SRC' may refer to a directory containing a cloned git repository, or a remote git repository. It is possible to put these variables to 'devel.config' config file, or provide via command line, like: ` DPDK_ABI_REF_SRC=https://dpdk.org/git/dpdk-stable \ DPDK_ABI_REF_VERSION=v22.11.1 \ DPDK_ABI_REF_DIR=/tmp/dpdk-abiref \ ./devtools/test-meson-builds.sh ` When 'DPDK_ABI_REF_SRC' is not defined, script behaves as it did previously. Other alternative to using 'DPDK_ABI_REF_SRC' variable is adding that other repo as a new 'remote' to the exiting git repository. Signed-off-by: Ferruh Yigit Acked-by: Akhil Goyal Signed-off-by: David Marchand --- Changes since v1: - expanded DPDK_ABI_REF_SRC usage to "non-local" sources, --- devtools/test-meson-builds.sh | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/devtools/test-meson-builds.sh b/devtools/test-meson-builds.sh index 02541c19aa..48f4e52df3 100755 --- a/devtools/test-meson-builds.sh +++ b/devtools/test-meson-builds.sh @@ -19,6 +19,7 @@ srcdir=$(dirname $(readlink -f $0))/.. # - DPDK_MESON_OPTIONS # # - DPDK_ABI_REF_DIR +# - DPDK_ABI_REF_SRC # - DPDK_ABI_REF_VERSION # # - DPDK_BUILD_TEST_EXAMPLES @@ -187,10 +188,15 @@ build () # [meson options] if [ ! -d $abirefdir/$targetdir ]; then # clone current sources if [ ! -d $abirefdir/src ]; then - git clone --local --no-hardlinks \ + abirefsrc=${DPDK_ABI_REF_SRC:-$srcdir} + abirefcloneopts= + if [ -d $abirefsrc ]; then + abirefcloneopts="--local --no-hardlinks" + fi + git clone $abirefcloneopts \ --single-branch \ -b $DPDK_ABI_REF_VERSION \ - $srcdir $abirefdir/src + $abirefsrc $abirefdir/src fi rm -rf $abirefdir/build -- 2.38.1