From: Henning Schild <henning.schild@siemens.com>
To: isar-users@googlegroups.com
Cc: jan.kiszka@siemens.com, Henning Schild <henning.schild@siemens.com>
Subject: [PATCH 1/2] meta-isar: add example recipe for deploying prebuilt debs
Date: Fri, 12 Feb 2021 14:17:32 +0100 [thread overview]
Message-ID: <20210212131733.9926-1-henning.schild@siemens.com> (raw)
From: Henning Schild <henning.schild@siemens.com>
Signed-off-by: Henning Schild <henning.schild@siemens.com>
---
meta-isar/conf/local.conf.sample | 2 +-
.../example-prebuilt-dummy_0.1.bb | 15 ++++++++++++
.../example-prebuilt/example-prebuilt_0.1.bb | 23 +++++++++++++++++++
3 files changed, 39 insertions(+), 1 deletion(-)
create mode 100644 meta-isar/recipes-app/example-prebuilt-dummy/example-prebuilt-dummy_0.1.bb
create mode 100644 meta-isar/recipes-app/example-prebuilt/example-prebuilt_0.1.bb
diff --git a/meta-isar/conf/local.conf.sample b/meta-isar/conf/local.conf.sample
index 107496c163..cc0b5c66bb 100644
--- a/meta-isar/conf/local.conf.sample
+++ b/meta-isar/conf/local.conf.sample
@@ -172,7 +172,7 @@ CONF_VERSION = "1"
#
# The default list of extra packages to be installed.
-IMAGE_INSTALL = "hello-isar example-raw example-module-${KERNEL_NAME} enable-fsck isar-exclude-docs samefile hello isar-disable-apt-cache cowsay"
+IMAGE_INSTALL = "hello-isar example-raw example-module-${KERNEL_NAME} enable-fsck isar-exclude-docs samefile hello isar-disable-apt-cache cowsay example-prebuilt"
#
# Enable cross-compilation support
diff --git a/meta-isar/recipes-app/example-prebuilt-dummy/example-prebuilt-dummy_0.1.bb b/meta-isar/recipes-app/example-prebuilt-dummy/example-prebuilt-dummy_0.1.bb
new file mode 100644
index 0000000000..92273dc886
--- /dev/null
+++ b/meta-isar/recipes-app/example-prebuilt-dummy/example-prebuilt-dummy_0.1.bb
@@ -0,0 +1,15 @@
+# Sample recipe to create a dummy package used for example-prebuilt
+#
+# This software is a part of ISAR.
+
+DESCRIPTION = "Sample application for ISAR"
+MAINTAINER = "Your name here <you@domain.com>"
+
+SRC_URI = ""
+
+inherit dpkg-raw
+
+# we provide a deb under another name
+do_prepare_build_append() {
+ sed -i 's/example-prebuilt-dummy/example-prebuilt/g' ${S}/debian/*
+}
diff --git a/meta-isar/recipes-app/example-prebuilt/example-prebuilt_0.1.bb b/meta-isar/recipes-app/example-prebuilt/example-prebuilt_0.1.bb
new file mode 100644
index 0000000000..4f224a48ec
--- /dev/null
+++ b/meta-isar/recipes-app/example-prebuilt/example-prebuilt_0.1.bb
@@ -0,0 +1,23 @@
+# Sample recipe to include a prebuilt deb archive into an isar build
+#
+# This software is a part of ISAR.
+
+## hacks for the sake of the example
+DEPENDS += "${PN}-dummy"
+do_fetch[depends] += "${PN}-dummy:do_deploy_deb"
+do_fetch[file-checksums] = ""
+FILESPATH_prepend := "${REPO_ISAR_DIR}/${DISTRO}/pool/main/e/${PN}/:"
+
+## start of real example, the below is relevant
+
+# note the unpack=false
+SRC_URI = "file://${PN}_${PV}_${DISTRO_ARCH}.deb;unpack=false"
+
+inherit dpkg-base
+
+# in case you have multiple debs or PN does not match
+#PROVIDES="foobar blabla"
+
+do_dpkg_build() {
+ bbnote "Not building a package"
+}
--
2.26.2
next reply other threads:[~2021-02-12 13:17 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-02-12 13:17 Henning Schild [this message]
2021-02-12 13:17 ` [PATCH 2/2] doc/user_manual.md: add a section on how to deal with " Henning Schild
2021-02-12 16:39 ` Jan Kiszka
2021-02-12 16:42 ` [PATCH 1/2] meta-isar: add example recipe for deploying " Jan Kiszka
2021-02-12 18:47 ` Henning Schild
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210212131733.9926-1-henning.schild@siemens.com \
--to=henning.schild@siemens.com \
--cc=isar-users@googlegroups.com \
--cc=jan.kiszka@siemens.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox