From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 2FB3DA00E6 for ; Thu, 11 Jul 2019 15:06:16 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 142C6322C; Thu, 11 Jul 2019 15:06:15 +0200 (CEST) Received: from proxy.6wind.com (host.76.145.23.62.rev.coltfrance.com [62.23.145.76]) by dpdk.org (Postfix) with ESMTP id 9DFEB1D9E for ; Thu, 11 Jul 2019 15:06:13 +0200 (CEST) Received: from core.dev.6wind.com (unknown [10.0.0.1]) by proxy.6wind.com (Postfix) with ESMTPS id 6B18A2E5662; Thu, 11 Jul 2019 15:06:13 +0200 (CEST) Received: from [10.16.0.195] (helo=6wind.com) by core.dev.6wind.com with smtp (Exim 4.84_2) (envelope-from ) id 1hlYm4-0002Mw-CD; Thu, 11 Jul 2019 15:06:13 +0200 Received: by 6wind.com (sSMTP sendmail emulation); Thu, 11 Jul 2019 15:06:12 +0200 Date: Thu, 11 Jul 2019 15:06:12 +0200 From: Olivier Matz To: Thomas Monjalon Cc: dev@dpdk.org, David Marchand , Bruce Richardson Message-ID: <20190711130612.xwm2znqdgxoqr4md@glumotte.dev.6wind.com> References: <20190523074318.29044-1-olivier.matz@6wind.com> <20190705135822.1797-1-olivier.matz@6wind.com> <12936694.jvCGMiB3o0@xps> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <12936694.jvCGMiB3o0@xps> User-Agent: NeoMutt/20170113 (1.7.2) Subject: Re: [dpdk-dev] [PATCH v2] devtools: better freebsd support 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" On Mon, Jul 08, 2019 at 06:35:25PM +0200, Thomas Monjalon wrote: > 05/07/2019 15:58, Olivier Matz: > > - As "readlink -e" and "readlink -m" do not exist on freebsd, > > use "readlink -f", it should not have any impact in these cases. > > - "sed -ri" is invalid on freebsd and should be replaced by > > "sed -ri=''" > > - Use gmake instead of make. > > > > This fixes the following command: > > SYSDIR=/usr/src/sys ./devtools/test-build.sh \ > > -j4 x86_64-native-freebsd-gcc > > > > Signed-off-by: Olivier Matz > > --- > > --- a/devtools/test-build.sh > > +++ b/devtools/test-build.sh > > +[ -z $MAKE ] && command -v gmake > /dev/null && MAKE=gmake > > +[ -z $MAKE ] && command -v make > /dev/null && MAKE=make > > +[ -z $MAKE ] && echo "Cannot find make or gmake" && exit 1 > > I'm surprised it works, given the -e in this script. > I would be more confortable with "if/elif" constructs. Honnestly, I'm surprised too :) This is the expected. Quoting "man sh": -e errexit If not interactive, exit immediately if any untested command fails. The exit status of a command is considered to be explicitly tested if the command is used to control an if, elif, while, or until; or if the command is the left hand operand of an "&&" or "||" operator.