| Submitter | Saul Wold |
|---|---|
| Date | April 27, 2011, 7:29 a.m. |
| Message ID | <877ce168510cded8f23ea173c33c882f966ebe49.1303889119.git.sgw@linux.intel.com> |
| Download | mbox | patch |
| Permalink | /patch/2955/ |
| State | New, archived |
| Headers | show |
Comments
On 04/27/2011 12:29 AM, Saul Wold wrote: > From: Khem Raj <raj.khem@gmail.com> > > Perf wants elfutils and elfutils on uclibc does not work due to > its usage of obstack_printf functionality missing from uclibc. This appears to silently not build perf when uclibc is being used. Do I have that right? I don't care for implicit changes in functionality without any notification to the user (even then...). However, perf is just automatically built IIRC, and not specified in the image recipe, so there isn't a lot we can do about it without major changes. Perhaps a simple warning in the do_compile_perf_libc-uclibc() and do_install_perf_libc-uclibc() would be sufficient until such time as perf has a real option to explicitly enable it. my bash logging.bbclass hasn't been merged yet, so for now: oe_warn "using uclibc, perf will not be (compiled|installed)" Thanks, -- Darren > > Signed-off-by: Khem Raj <raj.khem@gmail.com> > --- > meta/recipes-kernel/linux/linux-tools.inc | 17 +++++++++++++---- > 1 files changed, 13 insertions(+), 4 deletions(-) > > diff --git a/meta/recipes-kernel/linux/linux-tools.inc b/meta/recipes-kernel/linux/linux-tools.inc > index d64c9be..ef81650 100644 > --- a/meta/recipes-kernel/linux/linux-tools.inc > +++ b/meta/recipes-kernel/linux/linux-tools.inc > @@ -1,6 +1,11 @@ > # included by kernel recipes if they want to build/provide > # perf functionality from their tree. > - > +do_compile_perf_libc-uclibc () { > + : > +} > +do_install_perf_libc-uclibc () { > + : > +} > do_compile_perf() { > oe_runmake -C ${S}/tools/perf CC="${CC}" LD="${LD}" prefix=${prefix} NO_NEWT=1 NO_DWARF=1 > } > @@ -14,6 +19,10 @@ do_install_perf() { > addtask compile_perf after do_compile before do_install > addtask install_perf after do_install before do_package > > -do_compile_perf[depends] = "virtual/libc:do_populate_sysroot" > -do_compile_perf[depends] =+ "elfutils:do_populate_sysroot" > -RDEPENDS_perf += "python perl elfutils" > + > +PERFDEPENDS = "virtual/libc:do_populate_sysroot elfutils:do_populate_sysroot" > +PERFDEPENDS_libc-uclibc = "" > +PERFRDEPENDS = "python perl elfutils" > +PERFRDEPENDS_libc-uclibc = "" > +do_compile_perf[depends] = "${PERFDEPENDS}" > +RDEPENDS_perf += "${PERFRDEPENDS}"
On 04/27/2011 07:34 AM, Darren Hart wrote: > On 04/27/2011 12:29 AM, Saul Wold wrote: >> From: Khem Raj <raj.khem@gmail.com> >> >> Perf wants elfutils and elfutils on uclibc does not work due to >> its usage of obstack_printf functionality missing from uclibc. > > This appears to silently not build perf when uclibc is being used. Do I > have that right? I don't care for implicit changes in functionality > without any notification to the user (even then...). However, perf is > just automatically built IIRC, and not specified in the image recipe, so > there isn't a lot we can do about it without major changes. > > Perhaps a simple warning in the do_compile_perf_libc-uclibc() and > do_install_perf_libc-uclibc() would be sufficient until such time as > perf has a real option to explicitly enable it. > > my bash logging.bbclass hasn't been merged yet, so for now: > > oe_warn "using uclibc, perf will not be (compiled|installed)" Actually, I see Saul included the logging patches later in the series. For the sake of simplicity, I'm fine with this going in as is - if Khem will submit a follow-on patch to add the warning using the new bash logging API: bbwarn "using uclibc, perf cannot be compiled" bbwarn "using uclibc, perf cannot be installed" or something to that effect. >> >> Signed-off-by: Khem Raj <raj.khem@gmail.com> Acked-by: Darren Hart <dvhart@linux.intel.com> >> --- >> meta/recipes-kernel/linux/linux-tools.inc | 17 +++++++++++++---- >> 1 files changed, 13 insertions(+), 4 deletions(-) >> >> diff --git a/meta/recipes-kernel/linux/linux-tools.inc b/meta/recipes-kernel/linux/linux-tools.inc >> index d64c9be..ef81650 100644 >> --- a/meta/recipes-kernel/linux/linux-tools.inc >> +++ b/meta/recipes-kernel/linux/linux-tools.inc >> @@ -1,6 +1,11 @@ >> # included by kernel recipes if they want to build/provide >> # perf functionality from their tree. >> - >> +do_compile_perf_libc-uclibc () { >> + : >> +} >> +do_install_perf_libc-uclibc () { >> + : >> +} >> do_compile_perf() { >> oe_runmake -C ${S}/tools/perf CC="${CC}" LD="${LD}" prefix=${prefix} NO_NEWT=1 NO_DWARF=1 >> } >> @@ -14,6 +19,10 @@ do_install_perf() { >> addtask compile_perf after do_compile before do_install >> addtask install_perf after do_install before do_package >> >> -do_compile_perf[depends] = "virtual/libc:do_populate_sysroot" >> -do_compile_perf[depends] =+ "elfutils:do_populate_sysroot" >> -RDEPENDS_perf += "python perl elfutils" >> + >> +PERFDEPENDS = "virtual/libc:do_populate_sysroot elfutils:do_populate_sysroot" >> +PERFDEPENDS_libc-uclibc = "" >> +PERFRDEPENDS = "python perl elfutils" >> +PERFRDEPENDS_libc-uclibc = "" >> +do_compile_perf[depends] = "${PERFDEPENDS}" >> +RDEPENDS_perf += "${PERFRDEPENDS}" >
On Wed, Apr 27, 2011 at 7:37 AM, Darren Hart <dvhart@linux.intel.com> wrote: > > > On 04/27/2011 07:34 AM, Darren Hart wrote: >> On 04/27/2011 12:29 AM, Saul Wold wrote: >>> From: Khem Raj <raj.khem@gmail.com> >>> >>> Perf wants elfutils and elfutils on uclibc does not work due to >>> its usage of obstack_printf functionality missing from uclibc. >> >> This appears to silently not build perf when uclibc is being used. Do I >> have that right? I don't care for implicit changes in functionality >> without any notification to the user (even then...). However, perf is >> just automatically built IIRC, and not specified in the image recipe, so >> there isn't a lot we can do about it without major changes. >> >> Perhaps a simple warning in the do_compile_perf_libc-uclibc() and >> do_install_perf_libc-uclibc() would be sufficient until such time as >> perf has a real option to explicitly enable it. >> >> my bash logging.bbclass hasn't been merged yet, so for now: >> >> oe_warn "using uclibc, perf will not be (compiled|installed)" > > Actually, I see Saul included the logging patches later in the series. > For the sake of simplicity, I'm fine with this going in as is - if Khem > will submit a follow-on patch to add the warning using the new bash > logging API: > > bbwarn "using uclibc, perf cannot be compiled" > bbwarn "using uclibc, perf cannot be installed" > > or something to that effect. yes that will come with another set of patches. > > >>> >>> Signed-off-by: Khem Raj <raj.khem@gmail.com> > > > Acked-by: Darren Hart <dvhart@linux.intel.com> > > >>> --- >>> meta/recipes-kernel/linux/linux-tools.inc | 17 +++++++++++++---- >>> 1 files changed, 13 insertions(+), 4 deletions(-) >>> >>> diff --git a/meta/recipes-kernel/linux/linux-tools.inc b/meta/recipes-kernel/linux/linux-tools.inc >>> index d64c9be..ef81650 100644 >>> --- a/meta/recipes-kernel/linux/linux-tools.inc >>> +++ b/meta/recipes-kernel/linux/linux-tools.inc >>> @@ -1,6 +1,11 @@ >>> # included by kernel recipes if they want to build/provide >>> # perf functionality from their tree. >>> - >>> +do_compile_perf_libc-uclibc () { >>> + : >>> +} >>> +do_install_perf_libc-uclibc () { >>> + : >>> +} >>> do_compile_perf() { >>> oe_runmake -C ${S}/tools/perf CC="${CC}" LD="${LD}" prefix=${prefix} NO_NEWT=1 NO_DWARF=1 >>> } >>> @@ -14,6 +19,10 @@ do_install_perf() { >>> addtask compile_perf after do_compile before do_install >>> addtask install_perf after do_install before do_package >>> >>> -do_compile_perf[depends] = "virtual/libc:do_populate_sysroot" >>> -do_compile_perf[depends] =+ "elfutils:do_populate_sysroot" >>> -RDEPENDS_perf += "python perl elfutils" >>> + >>> +PERFDEPENDS = "virtual/libc:do_populate_sysroot elfutils:do_populate_sysroot" >>> +PERFDEPENDS_libc-uclibc = "" >>> +PERFRDEPENDS = "python perl elfutils" >>> +PERFRDEPENDS_libc-uclibc = "" >>> +do_compile_perf[depends] = "${PERFDEPENDS}" >>> +RDEPENDS_perf += "${PERFRDEPENDS}" >> > > -- > Darren Hart > Intel Open Source Technology Center > Yocto Project - Linux Kernel >
Patch
diff --git a/meta/recipes-kernel/linux/linux-tools.inc b/meta/recipes-kernel/linux/linux-tools.inc index d64c9be..ef81650 100644 --- a/meta/recipes-kernel/linux/linux-tools.inc +++ b/meta/recipes-kernel/linux/linux-tools.inc @@ -1,6 +1,11 @@ # included by kernel recipes if they want to build/provide # perf functionality from their tree. - +do_compile_perf_libc-uclibc () { + : +} +do_install_perf_libc-uclibc () { + : +} do_compile_perf() { oe_runmake -C ${S}/tools/perf CC="${CC}" LD="${LD}" prefix=${prefix} NO_NEWT=1 NO_DWARF=1 } @@ -14,6 +19,10 @@ do_install_perf() { addtask compile_perf after do_compile before do_install addtask install_perf after do_install before do_package -do_compile_perf[depends] = "virtual/libc:do_populate_sysroot" -do_compile_perf[depends] =+ "elfutils:do_populate_sysroot" -RDEPENDS_perf += "python perl elfutils" + +PERFDEPENDS = "virtual/libc:do_populate_sysroot elfutils:do_populate_sysroot" +PERFDEPENDS_libc-uclibc = "" +PERFRDEPENDS = "python perl elfutils" +PERFRDEPENDS_libc-uclibc = "" +do_compile_perf[depends] = "${PERFDEPENDS}" +RDEPENDS_perf += "${PERFRDEPENDS}"