From patchwork Mon Aug 6 14:50:46 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paolo Pisati X-Patchwork-Id: 953921 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=canonical.com Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 41kgZB57kXz9s3x; Tue, 7 Aug 2018 00:50:58 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1fmgqP-0001D4-5G; Mon, 06 Aug 2018 14:50:49 +0000 Received: from youngberry.canonical.com ([91.189.89.112]) by huckleberry.canonical.com with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.86_2) (envelope-from ) id 1fmgqN-0001Cg-Uu for kernel-team@lists.ubuntu.com; Mon, 06 Aug 2018 14:50:47 +0000 Received: from 1.general.ppisati.uk.vpn ([10.172.193.134] helo=canonical.com) by youngberry.canonical.com with esmtpsa (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.76) (envelope-from ) id 1fmgqN-0008TJ-MM for kernel-team@lists.ubuntu.com; Mon, 06 Aug 2018 14:50:47 +0000 From: Paolo Pisati To: kernel-team@lists.ubuntu.com Subject: [PATCH] UBUNTU: snapcraft.yaml: convert prepare, build and install to override-build Date: Mon, 6 Aug 2018 16:50:46 +0200 Message-Id: <1533567046-18118-2-git-send-email-paolo.pisati@canonical.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1533567046-18118-1-git-send-email-paolo.pisati@canonical.com> References: <1533567046-18118-1-git-send-email-paolo.pisati@canonical.com> X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" BugLink: http://bugs.launchpad.net/bugs/1785647 Signed-off-by: Paolo Pisati Acked-by: Stefan Bader Acked-by: Kleber Sacilotto de Souza --- snapcraft.yaml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/snapcraft.yaml b/snapcraft.yaml index a5b4147..f5181ce6 100644 --- a/snapcraft.yaml +++ b/snapcraft.yaml @@ -17,12 +17,11 @@ parts: kconfigflavour: raspi2 kconfigs: - CONFIG_DEBUG_INFO=n + kernel-image-target: zImage override-build: | cp debian/scripts/retpoline-extract-one \ $SNAPCRAFT_PART_BUILD/scripts/ubuntu-retpoline-extract-one snapcraftctl build - kernel-image-target: zImage - install: | tar -C $SNAPCRAFT_PART_INSTALL/dtbs -f $SNAPCRAFT_PART_INSTALL/dtbs/overlays.tgz -czv overlays rm -rf $SNAPCRAFT_PART_INSTALL/dtbs/overlays firmware: @@ -43,13 +42,13 @@ parts: source: . after: - firmware - prepare: | + override-build: | PKGS="http://ppa.launchpad.net/snappy-dev/image/ubuntu/dists/xenial/main/binary-armhf/Packages.gz" PKGPATH="$(wget -q -O- $PKGS|zcat|grep-dctrl raspberrypi-wireless-firmware |\ grep Filename|tail -1| sed 's/^Filename: //')" wget http://ppa.launchpad.net/snappy-dev/image/ubuntu/$PKGPATH dpkg -x $(basename $PKGPATH) unpack/ - install: | + snapcraftctl build mkdir -p $SNAPCRAFT_PART_INSTALL/firmware/brcm mv unpack/usr/share/doc/raspberrypi-wireless-firmware $SNAPCRAFT_PART_INSTALL/firmware/rpi-wlanfw-licenses mv unpack/lib/firmware/brcm/* $SNAPCRAFT_PART_INSTALL/firmware/brcm