From mboxrd@z Thu Jan 1 00:00:00 1970 X-GM-THRID: 6584097242600177664 X-Received: by 2002:a2e:7d12:: with SMTP id y18-v6mr166883ljc.9.1533229526972; Thu, 02 Aug 2018 10:05:26 -0700 (PDT) X-BeenThere: isar-users@googlegroups.com Received: by 2002:a19:750b:: with SMTP id y11-v6ls133466lfe.21.gmail; Thu, 02 Aug 2018 10:05:26 -0700 (PDT) X-Google-Smtp-Source: AAOMgpcerUWCIDq4qq9SLeLGXWaR8iABKlQKPsLkQdzO5cRcaz3hDQifl135S50Onj8E3oichkZb X-Received: by 2002:a19:d7de:: with SMTP id q91-v6mr152995lfi.28.1533229526466; Thu, 02 Aug 2018 10:05:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533229526; cv=none; d=google.com; s=arc-20160816; b=YWVORFwZ2ikL45HfOyhDVGcJYxtNFoEA3yNtj1vxZz52EDIPQtZxtrzwYvahMdooW0 Ky4IB1mS9G067J/0TNPRnzrpuc/MyF9dSCXJ2X0VI7n6SjHrnQGhUvge1TWGxqbd8sa6 /KUuC4G4B1guuEUlmD0ZJ69tJOc/biOn+/t8EmNisA48GRY7tx1kx9gP+5izbA2MYtJJ Cdq/xsDJihNbsVEVmNYGWSHhsd29lr03S5O7G3ts1SVUXRGbXZyNh2f9vBMIBihdpDcf MfayLlmFyPGehKivbeSx5S6LnO0h1QSSm1NWfivcWOelhf0wSGkRWDdbht1VzUXTJ2zV +Tlw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:arc-authentication-results; bh=RsQLZGUgJG7zxvVFC+f9ib9utZeuZgddlMFj88SUcNY=; b=VHu3PugYiqy2trz9vSut7XH7RN2yNbyZbm/BtCOjTtUy6uA8Z/E02CZBrIdHJWKefB vftpNv6UwF+FwT22Iw8E3oH4AqQqGlSwLkccJ3Rntgqg1liKCH3VWSCHIThtCSigar2s Y4ELgFpxQaTV5eovPv20XAIcXQKBEG6Tui02svoZXh8DnLlIo+x9C4j52WIyU2jWLYdA xQ4S1abRzTU5E9oO98abkHnKp4m0gNBNKiGntxFqKpHh7Fr+tBRssCN98ScWOyGmB420 EX++8lR30WxtHSpQLuQt07b5mGYJPl/rGOH4ETL802KvOzaL9A5W4o76vCtbAvIcNeNs q66g== ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=pass (google.com: domain of henning.schild@siemens.com designates 194.138.37.39 as permitted sender) smtp.mailfrom=henning.schild@siemens.com Return-Path: Received: from lizzard.sbs.de (lizzard.sbs.de. [194.138.37.39]) by gmr-mx.google.com with ESMTPS id n1-v6si87450ljg.0.2018.08.02.10.05.26 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 02 Aug 2018 10:05:26 -0700 (PDT) Received-SPF: pass (google.com: domain of henning.schild@siemens.com designates 194.138.37.39 as permitted sender) client-ip=194.138.37.39; Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of henning.schild@siemens.com designates 194.138.37.39 as permitted sender) smtp.mailfrom=henning.schild@siemens.com Received: from mail1.sbs.de (mail1.sbs.de [192.129.41.35]) by lizzard.sbs.de (8.15.2/8.15.2) with ESMTPS id w72H5PMW007558 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 2 Aug 2018 19:05:25 +0200 Received: from md1pvb1c.ad001.siemens.net (md1pvb1c.ad001.siemens.net [139.25.68.40]) by mail1.sbs.de (8.15.2/8.15.2) with ESMTP id w72H5Poc024389; Thu, 2 Aug 2018 19:05:25 +0200 Date: Thu, 2 Aug 2018 19:05:24 +0200 From: Henning Schild To: Alexander Smirnov Cc: Subject: Re: [PATCH v5 05/12] build.sh: Add additional parameter Message-ID: <20180802190524.3ee62b68@md1pvb1c.ad001.siemens.net> In-Reply-To: References: <20180730193937.32694-1-asmirnov@ilbers.de> <20180730193937.32694-6-asmirnov@ilbers.de> <45fa7d47-7eed-fd86-ecd2-dbc3c41ca92c@ilbers.de> <20180802095631.7e18b817@md1pvb1c.ad001.siemens.net> X-Mailer: Claws Mail 3.15.0-dirty (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-TUID: c6+jPSdQn8fL Am Thu, 2 Aug 2018 14:05:12 +0300 schrieb Alexander Smirnov : > Hi everybody, > > On 02.08.2018 10:56, Henning Schild wrote: > > Am Wed, 1 Aug 2018 17:51:57 +0300 > > schrieb Alexander Smirnov : > > > >> On 30.07.2018 22:39, Alexander Smirnov wrote: > >>> Pass target architecture as a parameter for build. > >>> > >>> Signed-off-by: Alexander Smirnov > >>> --- > >>> meta/recipes-devtools/buildchroot/files/build.sh | 17 > >>> +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) > >>> > >>> diff --git a/meta/recipes-devtools/buildchroot/files/build.sh > >>> b/meta/recipes-devtools/buildchroot/files/build.sh index > >>> 73c0889..c2967d2 100644 --- > >>> a/meta/recipes-devtools/buildchroot/files/build.sh +++ > >>> b/meta/recipes-devtools/buildchroot/files/build.sh @@ -6,6 +6,19 > >>> @@ > >>> set -e > >>> > >>> +# Create human-readable names > >>> +target_arch=$2 > >>> + > >>> +# Notes: > >>> +# mk-build-deps for jessie and jtretch has different parameter > >>> name to specify +# host architecture. > >>> +debian_version=$(cut -c1 /etc/debian_version) > >>> +if [ $(($debian_version)) -ge 9 ]; then > >> > >> Damn! This doesn't work on stretch: > >> > >> $ cat /etc/debian_version > >> stretch/sid > > > > Maybe that is an old installation when stretch was still sid? > > What does "lsb_release -r" say on that machine? That might be the > > better tool, instead of looking directly at the file. > > And it might be a good idea to turn the logic around. So if the > > check somehow does not work we default to "new". > > > > Sorry for the false alarm, I was in Ubuntu 16.04 chroot. :-( For > Debian it's correct: Did you experiment with building Ubuntu images with Isar? That is something i thought about. Not that i want Ubuntu for anything, the opposite is true, but to get those communities looking at Isar. Henning > $ cat /etc/debian_version > 9.5 > > Alex > > > Henning > > > >> But on jessie there were numbers. Will fix this. > >> > >> Alex > >> > >>> + set_arch="--host-arch $target_arch" > >>> +else > >>> + set_arch="-a $target_arch" > >>> +fi > >>> + > >>> # Go to build directory > >>> cd $1 > >>> > >>> @@ -36,7 +49,7 @@ install_cmd="apt-get -o > >>> Debug::pkgProblemResolver=yes --no-install-recommends -y -o > >>> APT::Get::List-Cleanup="0" > >>> # Install all build deps > >>> - mk-build-deps -t "${install_cmd}" -i -r debian/control > >>> + mk-build-deps $set_arch -t "${install_cmd}" -i -r > >>> debian/control ) 42>/dpkg.lock > >>> > >>> # If autotools files have been created, update their timestamp > >>> to @@ -48,4 +61,4 @@ for i in configure aclocal.m4 Makefile.am > >>> Makefile.in; do done > >>> > >>> # Build the package > >>> -dpkg-buildpackage > >>> +dpkg-buildpackage -a$target_arch > >>> > >> > >