All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] lttng-modules: Add git based recipe
@ 2019-06-12  9:15 zhe.he
  2019-06-12  9:57 ` Richard Purdie
  0 siblings, 1 reply; 5+ messages in thread
From: zhe.he @ 2019-06-12  9:15 UTC (permalink / raw)
  To: openembedded-core

From: He Zhe <zhe.he@windriver.com>

This is based on meta/recipes-kernel/lttng/lttng-modules_2.10.9.bb and is for
those who want to build lttng-modules with bleeding edge kernel, to avoid
regularly backporting patches from upstream.

Note that PREFERRED_VERSION needs to be set to select this recipe instead of the
tar ball one.

Signed-off-by: He Zhe <zhe.he@windriver.com>
---
 meta/recipes-kernel/lttng/lttng-modules_git.bb | 34 ++++++++++++++++++++++++++
 1 file changed, 34 insertions(+)
 create mode 100644 meta/recipes-kernel/lttng/lttng-modules_git.bb

diff --git a/meta/recipes-kernel/lttng/lttng-modules_git.bb b/meta/recipes-kernel/lttng/lttng-modules_git.bb
new file mode 100644
index 0000000..966d342
--- /dev/null
+++ b/meta/recipes-kernel/lttng/lttng-modules_git.bb
@@ -0,0 +1,34 @@
+SECTION = "devel"
+SUMMARY = "Linux Trace Toolkit KERNEL MODULE"
+DESCRIPTION = "The lttng-modules 2.0 package contains the kernel tracer modules"
+LICENSE = "LGPLv2.1 & GPLv2 & MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=3f882d431dc0f32f1f44c0707aa41128 \
+                    "
+DEFAULT_PREFERENCE = "-1"
+
+inherit module
+
+COMPATIBLE_HOST = '(x86_64|i.86|powerpc|aarch64|mips|nios2|arm|riscv).*-linux'
+
+SRC_URI = "git://git.lttng.org/lttng-modules;branch=master \
+           file://Makefile-Do-not-fail-if-CONFIG_TRACEPOINTS-is-not-en.patch \
+           file://BUILD_RUNTIME_BUG_ON-vs-gcc7.patch \
+           "
+SRCREV = "${AUTOREV}"
+PV = "2.11.0-rc+git${SRCPV}"
+S = "${WORKDIR}/git"
+
+export INSTALL_MOD_DIR="kernel/lttng-modules"
+
+EXTRA_OEMAKE += "KERNELDIR='${STAGING_KERNEL_DIR}'"
+
+do_install_append() {
+	# Delete empty directories to avoid QA failures if no modules were built
+	find ${D}/${nonarch_base_libdir} -depth -type d -empty -exec rmdir {} \;
+}
+
+python do_package_prepend() {
+    if not os.path.exists(os.path.join(d.getVar('D'), d.getVar('nonarch_base_libdir')[1:], 'modules')):
+        bb.warn("%s: no modules were created; this may be due to CONFIG_TRACEPOINTS not being enabled in your kernel." % d.getVar('PN'))
+}
+
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] lttng-modules: Add git based recipe
  2019-06-12  9:15 [PATCH] lttng-modules: Add git based recipe zhe.he
@ 2019-06-12  9:57 ` Richard Purdie
  2019-06-12 10:21   ` He Zhe
  0 siblings, 1 reply; 5+ messages in thread
From: Richard Purdie @ 2019-06-12  9:57 UTC (permalink / raw)
  To: zhe.he, openembedded-core

On Wed, 2019-06-12 at 17:15 +0800, zhe.he@windriver.com wrote:
> From: He Zhe <zhe.he@windriver.com>
> 
> This is based on meta/recipes-kernel/lttng/lttng-modules_2.10.9.bb and is for
> those who want to build lttng-modules with bleeding edge kernel, to avoid
> regularly backporting patches from upstream.
> 
> Note that PREFERRED_VERSION needs to be set to select this recipe instead of the
> tar ball one.
> 
> Signed-off-by: He Zhe <zhe.he@windriver.com>
> ---
>  meta/recipes-kernel/lttng/lttng-modules_git.bb | 34 ++++++++++++++++++++++++++
>  1 file changed, 34 insertions(+)
>  create mode 100644 meta/recipes-kernel/lttng/lttng-modules_git.bb

Do we really want/need to duplicate the whole recipe?

Cheers,

Richard



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] lttng-modules: Add git based recipe
  2019-06-12  9:57 ` Richard Purdie
@ 2019-06-12 10:21   ` He Zhe
  2019-06-12 10:27     ` richard.purdie
  0 siblings, 1 reply; 5+ messages in thread
From: He Zhe @ 2019-06-12 10:21 UTC (permalink / raw)
  To: Richard Purdie, openembedded-core



On 6/12/19 5:57 PM, Richard Purdie wrote:
> On Wed, 2019-06-12 at 17:15 +0800, zhe.he@windriver.com wrote:
>> From: He Zhe <zhe.he@windriver.com>
>>
>> This is based on meta/recipes-kernel/lttng/lttng-modules_2.10.9.bb and is for
>> those who want to build lttng-modules with bleeding edge kernel, to avoid
>> regularly backporting patches from upstream.
>>
>> Note that PREFERRED_VERSION needs to be set to select this recipe instead of the
>> tar ball one.
>>
>> Signed-off-by: He Zhe <zhe.he@windriver.com>
>> ---
>>  meta/recipes-kernel/lttng/lttng-modules_git.bb | 34 ++++++++++++++++++++++++++
>>  1 file changed, 34 insertions(+)
>>  create mode 100644 meta/recipes-kernel/lttng/lttng-modules_git.bb
> Do we really want/need to duplicate the whole recipe?

Do you like one .inc plus two .bb s? Then I'll send v2 later.

Zhe

>
> Cheers,
>
> Richard
>
>



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] lttng-modules: Add git based recipe
  2019-06-12 10:21   ` He Zhe
@ 2019-06-12 10:27     ` richard.purdie
  2019-06-12 11:11       ` He Zhe
  0 siblings, 1 reply; 5+ messages in thread
From: richard.purdie @ 2019-06-12 10:27 UTC (permalink / raw)
  To: He Zhe, openembedded-core

On Wed, 2019-06-12 at 18:21 +0800, He Zhe wrote:
> 
> On 6/12/19 5:57 PM, Richard Purdie wrote:
> > On Wed, 2019-06-12 at 17:15 +0800, zhe.he@windriver.com wrote:
> > > From: He Zhe <zhe.he@windriver.com>
> > > 
> > > This is based on meta/recipes-kernel/lttng/lttng-
> > > modules_2.10.9.bb and is for
> > > those who want to build lttng-modules with bleeding edge kernel,
> > > to avoid
> > > regularly backporting patches from upstream.
> > > 
> > > Note that PREFERRED_VERSION needs to be set to select this recipe
> > > instead of the
> > > tar ball one.
> > > 
> > > Signed-off-by: He Zhe <zhe.he@windriver.com>
> > > ---
> > >  meta/recipes-kernel/lttng/lttng-modules_git.bb | 34
> > > ++++++++++++++++++++++++++
> > >  1 file changed, 34 insertions(+)
> > >  create mode 100644 meta/recipes-kernel/lttng/lttng-
> > > modules_git.bb
> > Do we really want/need to duplicate the whole recipe?
> 
> Do you like one .inc plus two .bb s? Then I'll send v2 later.

Yes, or just require the other .bb file and override the pieces needed.
Not quite sure which would look best right now.

Ultimately I'd like to have something like Ross' patch:

http://git.yoctoproject.org/cgit.cgi/poky-contrib/commit/?h=ross/gitup

and use that for cases like this. Requiring the .bb and then tweaking
may allow migration to something like this more easily.

Cheers,

Richard



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] lttng-modules: Add git based recipe
  2019-06-12 10:27     ` richard.purdie
@ 2019-06-12 11:11       ` He Zhe
  0 siblings, 0 replies; 5+ messages in thread
From: He Zhe @ 2019-06-12 11:11 UTC (permalink / raw)
  To: richard.purdie, openembedded-core



On 6/12/19 6:27 PM, richard.purdie@linuxfoundation.org wrote:
> On Wed, 2019-06-12 at 18:21 +0800, He Zhe wrote:
>> On 6/12/19 5:57 PM, Richard Purdie wrote:
>>> On Wed, 2019-06-12 at 17:15 +0800, zhe.he@windriver.com wrote:
>>>> From: He Zhe <zhe.he@windriver.com>
>>>>
>>>> This is based on meta/recipes-kernel/lttng/lttng-
>>>> modules_2.10.9.bb and is for
>>>> those who want to build lttng-modules with bleeding edge kernel,
>>>> to avoid
>>>> regularly backporting patches from upstream.
>>>>
>>>> Note that PREFERRED_VERSION needs to be set to select this recipe
>>>> instead of the
>>>> tar ball one.
>>>>
>>>> Signed-off-by: He Zhe <zhe.he@windriver.com>
>>>> ---
>>>>  meta/recipes-kernel/lttng/lttng-modules_git.bb | 34
>>>> ++++++++++++++++++++++++++
>>>>  1 file changed, 34 insertions(+)
>>>>  create mode 100644 meta/recipes-kernel/lttng/lttng-
>>>> modules_git.bb
>>> Do we really want/need to duplicate the whole recipe?
>> Do you like one .inc plus two .bb s? Then I'll send v2 later.
> Yes, or just require the other .bb file and override the pieces needed.
> Not quite sure which would look best right now.
>
> Ultimately I'd like to have something like Ross' patch:
>
> http://git.yoctoproject.org/cgit.cgi/poky-contrib/commit/?h=ross/gitup
>
> and use that for cases like this. Requiring the .bb and then tweaking
> may allow migration to something like this more easily.

It's been renamed with devupstream. I'll send v3.

Thanks,
Zhe

>
> Cheers,
>
> Richard
>
>



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-06-12 11:12 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-06-12  9:15 [PATCH] lttng-modules: Add git based recipe zhe.he
2019-06-12  9:57 ` Richard Purdie
2019-06-12 10:21   ` He Zhe
2019-06-12 10:27     ` richard.purdie
2019-06-12 11:11       ` He Zhe

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.