From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9246FC04AB4 for ; Fri, 17 May 2019 11:48:16 +0000 (UTC) Received: from dpdk.org (dpdk.org [92.243.14.124]) by mail.kernel.org (Postfix) with ESMTP id 4606B2184C for ; Fri, 17 May 2019 11:48:16 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4606B2184C Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=intel.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=dev-bounces@dpdk.org Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id BBFE15F34; Fri, 17 May 2019 13:47:55 +0200 (CEST) Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id 06B845B16 for ; Fri, 17 May 2019 13:47:46 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 17 May 2019 04:47:46 -0700 X-ExtLoop1: 1 Received: from silpixa00399126.ir.intel.com (HELO silpixa00399126.ger.corp.intel.com) ([10.237.223.2]) by orsmga008.jf.intel.com with ESMTP; 17 May 2019 04:47:45 -0700 From: Bruce Richardson To: dev@dpdk.org Cc: bluca@debian.org, Bruce Richardson Date: Fri, 17 May 2019 12:47:32 +0100 Message-Id: <20190517114734.7072-4-bruce.richardson@intel.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190517114734.7072-1-bruce.richardson@intel.com> References: <20190503133537.58712-1-bruce.richardson@intel.com> <20190517114734.7072-1-bruce.richardson@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH v2 3/5] devtools/test-meson-builds: add testing of pkg-config file X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 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" The pkg-config file generated as part of the build of DPDK should allow applications to be built with an installed DPDK. We can test this as part of the build by doing an install of DPDK to a temporary directory within the build folder, and by then compiling up a few sample apps using make working off that directory. Signed-off-by: Bruce Richardson Acked-by: Luca Boccassi --- devtools/test-meson-builds.sh | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/devtools/test-meson-builds.sh b/devtools/test-meson-builds.sh index fe11e3c0a..57d1af47e 100755 --- a/devtools/test-meson-builds.sh +++ b/devtools/test-meson-builds.sh @@ -15,6 +15,11 @@ srcdir=$(dirname $(readlink -f $0))/.. MESON=${MESON:-meson} use_shared="--default-library=shared" +if command -v gmake >/dev/null 2>&1 ; then + MAKE=gmake +else + MAKE=make +fi if command -v ninja >/dev/null 2>&1 ; then ninja_cmd=ninja elif command -v ninja-build >/dev/null 2>&1 ; then @@ -92,3 +97,17 @@ if command -v $c >/dev/null 2>&1 ; then $use_shared --cross-file $f done fi + +# 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 +build_path=build-x86-default +export DESTDIR=$(pwd)/$build_path/install-root +$ninja_cmd -C $build_path install + +pc_file=$(find $DESTDIR -name libdpdk.pc) +export PKG_CONFIG_PATH=$(dirname $pc_file):$PKG_CONFIG_PATH + +for example in cmdline helloworld l2fwd l3fwd skeleton timer; do + echo "## Building $example" + $MAKE -C $DESTDIR/usr/local/share/dpdk/examples/$example clean all +done -- 2.21.0