From mboxrd@z Thu Jan 1 00:00:00 1970 X-GM-THRID: 6464921707679318016 X-Received: by 10.28.21.65 with SMTP id 62mr264335wmv.22.1505302815386; Wed, 13 Sep 2017 04:40:15 -0700 (PDT) X-BeenThere: isar-users@googlegroups.com Received: by 10.28.209.78 with SMTP id i75ls885940wmg.24.gmail; Wed, 13 Sep 2017 04:40:14 -0700 (PDT) X-Google-Smtp-Source: AOwi7QBYkdFadDJJ9AnGrfBtfymXO/lbVv7i1HdjOj0FcOUe8hH2/swKL84VKv1dVYJGqJQFW0TS X-Received: by 10.28.133.68 with SMTP id h65mr257320wmd.1.1505302814904; Wed, 13 Sep 2017 04:40:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1505302814; cv=none; d=google.com; s=arc-20160816; b=EYQyZ2X2PbOJhudIDxLgyDmldSYJMIK/j4U6ZsyMxmK0BKVFpZ9+UJb3GYCktChtzi kf27jKaW+iaYfyRhTPmdpYNR+CcSb+xG2KdCoVdkKiGDfhyEhP6NdRqwq7NVmCme74Qi MjXwbiqqScJK54yHBQWQ21zvs1xhd9SOnX+pGFz2lGjpSjrzHe8rkKimhZ+xP1Eno/cr WKNcwCH2WMHaRbjA8Kyc7u0bfS7MyB95w3jD8ycDo6Ov14zifN9GZyV+F7WwEnq2JYbt mwHTBknqqv3QxC4NvFUyQGMl0wbZLW1mPBfF1CWbpJtDEDvWswhnX9v3JuT98GQ0Twl3 leDw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=user-agent:in-reply-to:content-disposition:content-description :mime-version:references:message-id:subject:cc:to:from:date :arc-authentication-results; bh=sweXtmqbTtwjlx4EUs2GJP7o+L9bPiygG065fEWVGFk=; b=vhqs7bK19D2iJdOvmEMqnoiCc6TBfwbfMdz1HP5DvqSiuf7117vcymgyKiCV0zQK4k KrTx5Wm4fCQdRft6T8vJx35VYTmbEJcaTox5f0mA1hyv/bAWw2BFnw3Qg/x3G9zjPLwc kOmRCGvFzRg+5FZa5y/TFNlkiRqC7phN/Mj0UeJNC4DZP7hdcnc3Z4ekjF26QcjCXd1M sKQVZMUyO/EonxMQlGjLD3SLYDJ54+loq5xH8Pa6wZoX+d/DOdytZhcoBckOiuCGfoiZ HCMvSEFDAynx0NMvPLZ/4qBm01fcBubc9o0J0l2ytYwGk8bna2NQCf6u8jeyMNRFOaDZ 0KJg== ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=neutral (google.com: 192.35.17.28 is neither permitted nor denied by best guess record for domain of andreas.reichel.ext@siemens.com) smtp.mailfrom=andreas.reichel.ext@siemens.com Return-Path: Received: from goliath.siemens.de (goliath.siemens.de. [192.35.17.28]) by gmr-mx.google.com with ESMTPS id s127si57011wme.8.2017.09.13.04.40.14 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 13 Sep 2017 04:40:14 -0700 (PDT) Received-SPF: neutral (google.com: 192.35.17.28 is neither permitted nor denied by best guess record for domain of andreas.reichel.ext@siemens.com) client-ip=192.35.17.28; Authentication-Results: gmr-mx.google.com; spf=neutral (google.com: 192.35.17.28 is neither permitted nor denied by best guess record for domain of andreas.reichel.ext@siemens.com) smtp.mailfrom=andreas.reichel.ext@siemens.com Received: from mail2.sbs.de (mail2.sbs.de [192.129.41.66]) by goliath.siemens.de (8.15.2/8.15.2) with ESMTPS id v8DBeEcW008154 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 13 Sep 2017 13:40:14 +0200 Received: from iiotirae (golem.ppmd.siemens.net [139.25.69.162]) by mail2.sbs.de (8.15.2/8.15.2) with SMTP id v8DBeD80009736; Wed, 13 Sep 2017 13:40:14 +0200 Date: Wed, 13 Sep 2017 13:39:35 +0200 From: Andreas Reichel To: "[ext] Henning Schild" Cc: isar-users@googlegroups.com, Alexander Smirnov , Claudius Heine Subject: Re: [PATCH v2 6/6] recipes-app/example-raw: add an example on how to use dpkg-raw Message-ID: <20170913113934.GA15762@iiotirae> References: <20170912155810.9434-1-henning.schild@siemens.com> <20170912155810.9434-7-henning.schild@siemens.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Description: message Content-Disposition: inline In-Reply-To: <20170912155810.9434-7-henning.schild@siemens.com> User-Agent: Mutt/1.8.3 (2017-05-23) X-TUID: cvq3GowuyBgU On Tue, Sep 12, 2017 at 05:58:10PM +0200, [ext] Henning Schild wrote: > Issue: > It might not be clear to a user how to make use of the class > dpkg-raw. > > Change: > Add an example that demonstrates some features. > > Impact: > This patch does not change the behaviour of Isar. It addresses the issue > partially, documentation would also be useful. > > Signed-off-by: Henning Schild > --- > .../recipes-app/example-raw/example-raw_0.1.bb | 35 ++++++++++++++++++++++ > meta-isar/recipes-app/example-raw/files/README | 1 + > meta-isar/recipes-app/example-raw/files/postinst | 16 ++++++++++ > 3 files changed, 52 insertions(+) > create mode 100644 meta-isar/recipes-app/example-raw/example-raw_0.1.bb > create mode 100644 meta-isar/recipes-app/example-raw/files/README > create mode 100644 meta-isar/recipes-app/example-raw/files/postinst > > diff --git a/meta-isar/recipes-app/example-raw/example-raw_0.1.bb b/meta-isar/recipes-app/example-raw/example-raw_0.1.bb > new file mode 100644 > index 0000000..d548465 > --- /dev/null > +++ b/meta-isar/recipes-app/example-raw/example-raw_0.1.bb > @@ -0,0 +1,35 @@ > +# Sample application using dpkg-raw, which turns a folder (${D}) of > +# files into a .deb > +# > +# This software is a part of ISAR. > + > +DESCRIPTION = "Sample application for ISAR" > +MAINTAINER = "Your name here " > +DEBIAN_DEPENDS = "apt" > + > +SRC_URI = "file://README \ > + file://postinst" > + > +inherit dpkg-raw > + > +do_populate_package() { > + bbnote "Creating ${PN} binary" > + echo "#!/bin/sh" > ${WORKDIR}/${PN} > + echo "echo Hello ISAR! ${PN}_${PV}" >> ${WORKDIR}/${PN} Maybe "Creating executable content"? Nowhere a binary is created... > + > + bbnote "Putting ${PN} into package" > + install -v -d ${D}/usr/local/bin/ > + install -v -m 755 ${WORKDIR}/${PN} ${D}/usr/local/bin/${PN} > + Maybe "Packaging ${PN}" ? > + bbnote "Now copy ${FILESDIR}/README into package" > + install -v -d ${D}/usr/local/doc/ > + install -v -m 644 ${WORKDIR}/README ${D}/usr/local/doc/README-${P} > + > + bbnote "Now for a debian hook, see dpkg-deb" > + install -v -m 755 ${WORKDIR}/postinst ${D}/DEBIAN/postinst > + > + bbnote "Now for a fake config file" Maybe "Generating config file" Kind regards Andreas > + echo "# empty config file" > ${WORKDIR}/${PN}.conf > + install -v -d ${D}/usr/local/etc/ > + install -v -m 644 ${WORKDIR}/${PN}.conf ${D}/usr/local/etc/${PN}.conf > +} > diff --git a/meta-isar/recipes-app/example-raw/files/README b/meta-isar/recipes-app/example-raw/files/README > new file mode 100644 > index 0000000..6e2ce0f > --- /dev/null > +++ b/meta-isar/recipes-app/example-raw/files/README > @@ -0,0 +1 @@ > +This is an example file that we get from FILESDIR in recipe. > diff --git a/meta-isar/recipes-app/example-raw/files/postinst b/meta-isar/recipes-app/example-raw/files/postinst > new file mode 100644 > index 0000000..a28afa3 > --- /dev/null > +++ b/meta-isar/recipes-app/example-raw/files/postinst > @@ -0,0 +1,16 @@ > +#!/bin/sh > + > +set -e > + > +if ! getent group isar >/dev/null; then > + addgroup --quiet --system isar > +fi > + > +if ! getent passwd isar >/dev/null; then > + useradd --system --gid isar --create-home \ > + --home /var/lib/isar --no-user-group \ > + --comment "My isar user" \ > + isar > +fi > + > +chown -R isar:isar /var/lib/isar > -- > 2.13.5 > > -- > You received this message because you are subscribed to the Google Groups "isar-users" group. > To unsubscribe from this group and stop receiving emails from it, send an email to isar-users+unsubscribe@googlegroups.com. > To post to this group, send email to isar-users@googlegroups.com. > To view this discussion on the web visit https://groups.google.com/d/msgid/isar-users/20170912155810.9434-7-henning.schild%40siemens.com. > For more options, visit https://groups.google.com/d/optout. -- Andreas Reichel Dipl.-Phys. (Univ.) Software Consultant Andreas.Reichel@tngtech.com, +49-174-3180074 TNG Technology Consulting GmbH, Betastr. 13a, 85774 Unterfoehring Geschaeftsfuehrer: Henrik Klagges, Dr. Robert Dahlke, Gerhard Mueller Sitz: Unterfoehring * Amtsgericht Muenchen * HRB 135082