* [daisy][PATCH 1/4] tcf-agent: add systemd support
@ 2014-05-14 20:30 Otavio Salvador
2014-05-14 20:30 ` [daisy][PATCH 2/4] cryptodev-linux: move to recipes-kernel to be shared with module and tests Otavio Salvador
` (3 more replies)
0 siblings, 4 replies; 8+ messages in thread
From: Otavio Salvador @ 2014-05-14 20:30 UTC (permalink / raw)
To: OpenEmbedded Core Mailing List
From: Chen Qi <Qi.Chen@windriver.com>
Add systemd unit file tcf-agent.service.
(From OE-Core rev: 1a4feebf98780f586bf2e81cf9844e6805a50799)
Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
meta/recipes-devtools/tcf-agent/tcf-agent/tcf-agent.service | 10 ++++++++++
meta/recipes-devtools/tcf-agent/tcf-agent_git.bb | 8 +++++++-
2 files changed, 17 insertions(+), 1 deletion(-)
create mode 100644 meta/recipes-devtools/tcf-agent/tcf-agent/tcf-agent.service
diff --git a/meta/recipes-devtools/tcf-agent/tcf-agent/tcf-agent.service b/meta/recipes-devtools/tcf-agent/tcf-agent/tcf-agent.service
new file mode 100644
index 0000000..5d7a586
--- /dev/null
+++ b/meta/recipes-devtools/tcf-agent/tcf-agent/tcf-agent.service
@@ -0,0 +1,10 @@
+[Unit]
+Description=Target Communication Framework agent
+After=network.target
+
+[Service]
+Type=forking
+ExecStart=@SBINDIR@/tcf-agent -d -L- -l0
+
+[Install]
+WantedBy=multi-user.target
\ No newline at end of file
diff --git a/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb b/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb
index 1eb0021..616a6a7 100644
--- a/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb
+++ b/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb
@@ -12,6 +12,7 @@ PR = "r2"
SRC_URI = "git://git.eclipse.org/gitroot/tcf/org.eclipse.tcf.agent.git \
file://fix_ranlib.patch \
file://tcf-agent.init \
+ file://tcf-agent.service \
"
DEPENDS = "util-linux openssl"
@@ -19,7 +20,9 @@ RDEPENDS_${PN} = "bash"
S = "${WORKDIR}/git"
-inherit update-rc.d
+inherit update-rc.d systemd
+
+SYSTEMD_SERVICE_${PN} = "tcf-agent.service"
INITSCRIPT_NAME = "tcf-agent"
INITSCRIPT_PARAMS = "start 99 3 5 . stop 20 0 1 2 6 ."
@@ -44,5 +47,8 @@ do_install() {
oe_runmake install INSTALLROOT=${D}
install -d ${D}${sysconfdir}/init.d/
install -m 0755 ${WORKDIR}/tcf-agent.init ${D}${sysconfdir}/init.d/tcf-agent
+ install -d ${D}${systemd_unitdir}/system
+ install -m 0644 ${WORKDIR}/tcf-agent.service ${D}${systemd_unitdir}/system
+ sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/tcf-agent.service
}
--
2.0.0.rc2
^ permalink raw reply related [flat|nested] 8+ messages in thread* [daisy][PATCH 2/4] cryptodev-linux: move to recipes-kernel to be shared with module and tests 2014-05-14 20:30 [daisy][PATCH 1/4] tcf-agent: add systemd support Otavio Salvador @ 2014-05-14 20:30 ` Otavio Salvador 2014-05-14 20:30 ` [daisy][PATCH 3/4] cryptodev-linux: create common .inc file to be shared by " Otavio Salvador ` (2 subsequent siblings) 3 siblings, 0 replies; 8+ messages in thread From: Otavio Salvador @ 2014-05-14 20:30 UTC (permalink / raw) To: OpenEmbedded Core Mailing List From: Denys Dmytriyenko <denys@ti.com> (From OE-Core rev: e7aace7658fabe41839a3ec1b596bf28c6a4c02e) Signed-off-by: Denys Dmytriyenko <denys@ti.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> --- .../openssl => recipes-kernel/cryptodev}/cryptodev-linux_1.6.bb | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename meta/{recipes-connectivity/openssl => recipes-kernel/cryptodev}/cryptodev-linux_1.6.bb (100%) diff --git a/meta/recipes-connectivity/openssl/cryptodev-linux_1.6.bb b/meta/recipes-kernel/cryptodev/cryptodev-linux_1.6.bb similarity index 100% rename from meta/recipes-connectivity/openssl/cryptodev-linux_1.6.bb rename to meta/recipes-kernel/cryptodev/cryptodev-linux_1.6.bb -- 2.0.0.rc2 ^ permalink raw reply [flat|nested] 8+ messages in thread
* [daisy][PATCH 3/4] cryptodev-linux: create common .inc file to be shared by module and tests 2014-05-14 20:30 [daisy][PATCH 1/4] tcf-agent: add systemd support Otavio Salvador 2014-05-14 20:30 ` [daisy][PATCH 2/4] cryptodev-linux: move to recipes-kernel to be shared with module and tests Otavio Salvador @ 2014-05-14 20:30 ` Otavio Salvador 2014-05-14 20:30 ` [daisy][PATCH 4/4] cryptodev-tests: recipe for cryptodev test suite based on OpenSSL Otavio Salvador 2014-05-14 22:04 ` [daisy][PATCH 1/4] tcf-agent: add systemd support Khem Raj 3 siblings, 0 replies; 8+ messages in thread From: Otavio Salvador @ 2014-05-14 20:30 UTC (permalink / raw) To: OpenEmbedded Core Mailing List From: Denys Dmytriyenko <denys@ti.com> (From OE-Core rev: a3a834cf9f35682655661a7c6ba66c1de3491320) Signed-off-by: Denys Dmytriyenko <denys@ti.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> --- meta/recipes-kernel/cryptodev/cryptodev-linux_1.6.bb | 11 ++--------- meta/recipes-kernel/cryptodev/cryptodev_1.6.inc | 11 +++++++++++ 2 files changed, 13 insertions(+), 9 deletions(-) create mode 100644 meta/recipes-kernel/cryptodev/cryptodev_1.6.inc diff --git a/meta/recipes-kernel/cryptodev/cryptodev-linux_1.6.bb b/meta/recipes-kernel/cryptodev/cryptodev-linux_1.6.bb index 320716d..43f58f3 100644 --- a/meta/recipes-kernel/cryptodev/cryptodev-linux_1.6.bb +++ b/meta/recipes-kernel/cryptodev/cryptodev-linux_1.6.bb @@ -1,13 +1,6 @@ -SUMMARY = "A /dev/crypto device driver" -HOMEPAGE = "http://cryptodev-linux.org/" +require cryptodev_${PV}.inc -LICENSE = "GPLv2" -LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" - -SRC_URI = "http://download.gna.org/cryptodev-linux/${BPN}-${PV}.tar.gz" - -SRC_URI[md5sum] = "eade38998313c25fd7934719cdf8a2ea" -SRC_URI[sha256sum] = "75f1425c8ea1f8cae523905a5a046a35092327a6152800b0b86efc4e56fb3e2f" +SUMMARY = "A /dev/crypto device driver header file" do_compile() { : diff --git a/meta/recipes-kernel/cryptodev/cryptodev_1.6.inc b/meta/recipes-kernel/cryptodev/cryptodev_1.6.inc new file mode 100644 index 0000000..946faac --- /dev/null +++ b/meta/recipes-kernel/cryptodev/cryptodev_1.6.inc @@ -0,0 +1,11 @@ +HOMEPAGE = "http://cryptodev-linux.org/" + +LICENSE = "GPLv2" +LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" + +SRC_URI = "http://download.gna.org/cryptodev-linux/cryptodev-linux-${PV}.tar.gz" + +SRC_URI[md5sum] = "eade38998313c25fd7934719cdf8a2ea" +SRC_URI[sha256sum] = "75f1425c8ea1f8cae523905a5a046a35092327a6152800b0b86efc4e56fb3e2f" + +S = "${WORKDIR}/cryptodev-linux-${PV}" -- 2.0.0.rc2 ^ permalink raw reply related [flat|nested] 8+ messages in thread
* [daisy][PATCH 4/4] cryptodev-tests: recipe for cryptodev test suite based on OpenSSL 2014-05-14 20:30 [daisy][PATCH 1/4] tcf-agent: add systemd support Otavio Salvador 2014-05-14 20:30 ` [daisy][PATCH 2/4] cryptodev-linux: move to recipes-kernel to be shared with module and tests Otavio Salvador 2014-05-14 20:30 ` [daisy][PATCH 3/4] cryptodev-linux: create common .inc file to be shared by " Otavio Salvador @ 2014-05-14 20:30 ` Otavio Salvador 2014-05-14 22:04 ` [daisy][PATCH 1/4] tcf-agent: add systemd support Khem Raj 3 siblings, 0 replies; 8+ messages in thread From: Otavio Salvador @ 2014-05-14 20:30 UTC (permalink / raw) To: OpenEmbedded Core Mailing List From: Denys Dmytriyenko <denys@ti.com> (From OE-Core rev: c54fa061da6195081cd29817a351a36377b58e53) Signed-off-by: Denys Dmytriyenko <denys@ti.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> --- .../cryptodev/cryptodev-tests_1.6.bb | 23 ++++++++ ...pile-and-install-rules-for-cryptodev-test.patch | 69 ++++++++++++++++++++++ ...ests-Makefile-usage-of-LDLIBS-vs.-LDFLAGS.patch | 29 +++++++++ 3 files changed, 121 insertions(+) create mode 100644 meta/recipes-kernel/cryptodev/cryptodev-tests_1.6.bb create mode 100644 meta/recipes-kernel/cryptodev/files/0001-Add-the-compile-and-install-rules-for-cryptodev-test.patch create mode 100644 meta/recipes-kernel/cryptodev/files/0002-Fix-tests-Makefile-usage-of-LDLIBS-vs.-LDFLAGS.patch diff --git a/meta/recipes-kernel/cryptodev/cryptodev-tests_1.6.bb b/meta/recipes-kernel/cryptodev/cryptodev-tests_1.6.bb new file mode 100644 index 0000000..efc41ae --- /dev/null +++ b/meta/recipes-kernel/cryptodev/cryptodev-tests_1.6.bb @@ -0,0 +1,23 @@ +require cryptodev_${PV}.inc + +SUMMARY = "A test suite for /dev/crypto device driver" + +DEPENDS += "openssl" + +SRC_URI += " \ +file://0001-Add-the-compile-and-install-rules-for-cryptodev-test.patch \ +file://0002-Fix-tests-Makefile-usage-of-LDLIBS-vs.-LDFLAGS.patch \ +" + +EXTRA_OEMAKE='KERNEL_DIR="${STAGING_KERNEL_DIR}" PREFIX="${D}"' + +do_compile() { + oe_runmake testprogs +} + +do_install() { + oe_runmake install_tests +} + +FILES_${PN}-dbg += "${bindir}/tests_cryptodev/.debug" +FILES_${PN} = "${bindir}/tests_cryptodev/*" diff --git a/meta/recipes-kernel/cryptodev/files/0001-Add-the-compile-and-install-rules-for-cryptodev-test.patch b/meta/recipes-kernel/cryptodev/files/0001-Add-the-compile-and-install-rules-for-cryptodev-test.patch new file mode 100644 index 0000000..cb871f6 --- /dev/null +++ b/meta/recipes-kernel/cryptodev/files/0001-Add-the-compile-and-install-rules-for-cryptodev-test.patch @@ -0,0 +1,69 @@ +From 1980a8f4779a955e73285e7a0d86549b69bea5c8 Mon Sep 17 00:00:00 2001 +From: Yu Zongchun <b40527@freescale.com> +Date: Sun, 28 Apr 2013 14:39:22 +0800 +Subject: [PATCH] Add the compile and install rules for cryptodev tests folder + +This is required to install the cryptodev tests folder to rootfs + +Signed-off-by: Yu Zongchun <b40527@freescale.com> + +Upstream-Status: Pending + +--- + Makefile | 6 ++++++ + tests/Makefile | 8 ++++++++ + 2 files changed, 14 insertions(+), 0 deletions(-) + +diff --git a/Makefile b/Makefile +index 2be8825..4cbb865 100644 +--- a/Makefile ++++ b/Makefile +@@ -17,6 +17,9 @@ install: + @echo "Installing cryptodev.h in /usr/include/crypto ..." + @install -D crypto/cryptodev.h /usr/include/crypto/cryptodev.h + ++install_tests: ++ make -C tests install DESTDIR=$(PREFIX) ++ + clean: + make -C $(KERNEL_DIR) SUBDIRS=`pwd` clean + rm -f $(hostprogs) *~ +@@ -25,6 +28,9 @@ clean: + check: + KERNEL_DIR=$(KERNEL_DIR) make -C tests check + ++testprogs: ++ KERNEL_DIR=$(KERNEL_DIR) make -C tests testprogs ++ + FILEBASE = cryptodev-linux-$(VERSION) + TMPDIR ?= /tmp + OUTPUT = $(FILEBASE).tar.gz +diff --git a/tests/Makefile b/tests/Makefile +index 87ca3c7..0488cf6 100644 +--- a/tests/Makefile ++++ b/tests/Makefile +@@ -19,6 +19,12 @@ example-async-hmac-objs := async_hmac.o + example-async-speed-objs := async_speed.o + example-hashcrypt-speed-objs := hashcrypt_speed.c + ++install: ++ install -d $(DESTDIR)/usr/bin/tests_cryptodev ++ for bin in $(hostprogs); do \ ++ install -m 755 $${bin} $(DESTDIR)/usr/bin/tests_cryptodev/; \ ++ done ++ + check: $(hostprogs) + ./cipher + ./hmac +@@ -28,6 +34,8 @@ check: $(hostprogs) + ./cipher-gcm + ./cipher-aead + ++testprogs: $(hostprogs) ++ + clean: + rm -f *.o *~ $(hostprogs) + +-- +1.7.5.4 + diff --git a/meta/recipes-kernel/cryptodev/files/0002-Fix-tests-Makefile-usage-of-LDLIBS-vs.-LDFLAGS.patch b/meta/recipes-kernel/cryptodev/files/0002-Fix-tests-Makefile-usage-of-LDLIBS-vs.-LDFLAGS.patch new file mode 100644 index 0000000..f5ab8b4 --- /dev/null +++ b/meta/recipes-kernel/cryptodev/files/0002-Fix-tests-Makefile-usage-of-LDLIBS-vs.-LDFLAGS.patch @@ -0,0 +1,29 @@ +From 47ff1eb9bb4f872c1d731b93d334ee5865bf3439 Mon Sep 17 00:00:00 2001 +From: Denys Dmytriyenko <denys@ti.com> +Date: Sun, 6 Apr 2014 22:16:30 -0400 +Subject: [PATCH] Fix tests Makefile usage of LDLIBS vs. LDFLAGS + +Libraries must come after objects, as link order matters, especially +when using linker flags like -Wl,--as-needed. + +Signed-off-by: Denys Dmytriyenko <denys@ti.com> + +Upstream-Status: Pending +--- + tests/Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tests/Makefile b/tests/Makefile +index cd202af..67c3c83 100644 +--- a/tests/Makefile ++++ b/tests/Makefile +@@ -39,5 +39,5 @@ testprogs: $(hostprogs) + clean: + rm -f *.o *~ $(hostprogs) + +-${comp_progs}: LDFLAGS += -lssl -lcrypto ++${comp_progs}: LDLIBS += -lssl -lcrypto + ${comp_progs}: %: %.o openssl_wrapper.o +-- +1.9.1 + -- 2.0.0.rc2 ^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [daisy][PATCH 1/4] tcf-agent: add systemd support 2014-05-14 20:30 [daisy][PATCH 1/4] tcf-agent: add systemd support Otavio Salvador ` (2 preceding siblings ...) 2014-05-14 20:30 ` [daisy][PATCH 4/4] cryptodev-tests: recipe for cryptodev test suite based on OpenSSL Otavio Salvador @ 2014-05-14 22:04 ` Khem Raj 2014-05-15 12:24 ` Otavio Salvador 3 siblings, 1 reply; 8+ messages in thread From: Khem Raj @ 2014-05-14 22:04 UTC (permalink / raw) To: Otavio Salvador; +Cc: OpenEmbedded Core Mailing List On Wed, May 14, 2014 at 1:30 PM, Otavio Salvador <otavio@ossystems.com.br> wrote: > + install -d ${D}${systemd_unitdir}/system > + install -m 0644 ${WORKDIR}/tcf-agent.service ${D}${systemd_unitdir}/system > + sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/tcf-agent.service shouldn't this happened if systemd is enabled in distro ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [daisy][PATCH 1/4] tcf-agent: add systemd support 2014-05-14 22:04 ` [daisy][PATCH 1/4] tcf-agent: add systemd support Khem Raj @ 2014-05-15 12:24 ` Otavio Salvador 2014-05-16 2:05 ` ChenQi 0 siblings, 1 reply; 8+ messages in thread From: Otavio Salvador @ 2014-05-15 12:24 UTC (permalink / raw) To: Khem Raj, Chen Qi; +Cc: OpenEmbedded Core Mailing List On Wed, May 14, 2014 at 7:04 PM, Khem Raj <raj.khem@gmail.com> wrote: > On Wed, May 14, 2014 at 1:30 PM, Otavio Salvador > <otavio@ossystems.com.br> wrote: >> + install -d ${D}${systemd_unitdir}/system >> + install -m 0644 ${WORKDIR}/tcf-agent.service ${D}${systemd_unitdir}/system >> + sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/tcf-agent.service > > shouldn't this happened if systemd is enabled in distro Agreed. Added Chen Qi in Cc. -- Otavio Salvador O.S. Systems http://www.ossystems.com.br http://code.ossystems.com.br Mobile: +55 (53) 9981-7854 Mobile: +1 (347) 903-9750 ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [daisy][PATCH 1/4] tcf-agent: add systemd support 2014-05-15 12:24 ` Otavio Salvador @ 2014-05-16 2:05 ` ChenQi 2014-05-16 4:55 ` Khem Raj 0 siblings, 1 reply; 8+ messages in thread From: ChenQi @ 2014-05-16 2:05 UTC (permalink / raw) To: Otavio Salvador, Khem Raj; +Cc: OpenEmbedded Core Mailing List On 05/15/2014 08:24 PM, Otavio Salvador wrote: > On Wed, May 14, 2014 at 7:04 PM, Khem Raj <raj.khem@gmail.com> wrote: >> On Wed, May 14, 2014 at 1:30 PM, Otavio Salvador >> <otavio@ossystems.com.br> wrote: >>> + install -d ${D}${systemd_unitdir}/system >>> + install -m 0644 ${WORKDIR}/tcf-agent.service ${D}${systemd_unitdir}/system >>> + sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/tcf-agent.service >> shouldn't this happened if systemd is enabled in distro > Agreed. Added Chen Qi in Cc. > In systemd.bbclass, there's function to remove things under ${systemdunitdir} if 'systemd' is not in DISTRO_FEATURES. So I think there's no need to add a check here. Below are the related codes. python rm_systemd_unitdir (){ import shutil if not bb.utils.contains('DISTRO_FEATURES', 'systemd', True, False, d): systemd_unitdir = oe.path.join(d.getVar("D", True), d.getVar('systemd_unitdir', True)) if os.path.exists(systemd_unitdir): shutil.rmtree(systemd_unitdir) systemd_libdir = os.path.dirname(systemd_unitdir) if (os.path.exists(systemd_libdir) and not os.listdir(systemd_libdir)): os.rmdir(systemd_libdir) } do_install[postfuncs] += "rm_systemd_unitdir " Best Regards, Chen Qi ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [daisy][PATCH 1/4] tcf-agent: add systemd support 2014-05-16 2:05 ` ChenQi @ 2014-05-16 4:55 ` Khem Raj 0 siblings, 0 replies; 8+ messages in thread From: Khem Raj @ 2014-05-16 4:55 UTC (permalink / raw) To: ChenQi; +Cc: Otavio Salvador, OpenEmbedded Core Mailing List On Thu, May 15, 2014 at 7:05 PM, ChenQi <Qi.Chen@windriver.com> wrote: > On 05/15/2014 08:24 PM, Otavio Salvador wrote: >> >> On Wed, May 14, 2014 at 7:04 PM, Khem Raj <raj.khem@gmail.com> wrote: >>> >>> On Wed, May 14, 2014 at 1:30 PM, Otavio Salvador >>> <otavio@ossystems.com.br> wrote: >>>> >>>> + install -d ${D}${systemd_unitdir}/system >>>> + install -m 0644 ${WORKDIR}/tcf-agent.service >>>> ${D}${systemd_unitdir}/system >>>> + sed -i -e 's,@SBINDIR@,${sbindir},g' >>>> ${D}${systemd_unitdir}/system/tcf-agent.service >>> >>> shouldn't this happened if systemd is enabled in distro >> >> Agreed. Added Chen Qi in Cc. >> > > In systemd.bbclass, there's function to remove things under > ${systemdunitdir} if 'systemd' is not in DISTRO_FEATURES. So I think there's > no need to add a check here. > > Below are the related codes. > > python rm_systemd_unitdir (){ > import shutil > if not bb.utils.contains('DISTRO_FEATURES', 'systemd', True, False, d): > systemd_unitdir = oe.path.join(d.getVar("D", True), > d.getVar('systemd_unitdir', True)) > if os.path.exists(systemd_unitdir): > shutil.rmtree(systemd_unitdir) > systemd_libdir = os.path.dirname(systemd_unitdir) > if (os.path.exists(systemd_libdir) and not > os.listdir(systemd_libdir)): > os.rmdir(systemd_libdir) > } > do_install[postfuncs] += "rm_systemd_unitdir " I see. That makes sense. > > Best Regards, > Chen Qi ^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2014-05-16 4:56 UTC | newest] Thread overview: 8+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2014-05-14 20:30 [daisy][PATCH 1/4] tcf-agent: add systemd support Otavio Salvador 2014-05-14 20:30 ` [daisy][PATCH 2/4] cryptodev-linux: move to recipes-kernel to be shared with module and tests Otavio Salvador 2014-05-14 20:30 ` [daisy][PATCH 3/4] cryptodev-linux: create common .inc file to be shared by " Otavio Salvador 2014-05-14 20:30 ` [daisy][PATCH 4/4] cryptodev-tests: recipe for cryptodev test suite based on OpenSSL Otavio Salvador 2014-05-14 22:04 ` [daisy][PATCH 1/4] tcf-agent: add systemd support Khem Raj 2014-05-15 12:24 ` Otavio Salvador 2014-05-16 2:05 ` ChenQi 2014-05-16 4:55 ` Khem Raj
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox