[ELDK] ERROR: The function perf_feature_enabled defined in perf-features.inc was already declared in perf.inc.
lothar at denx.de
lothar at denx.de
Tue Aug 20 09:36:18 CEST 2013
Am 2013-08-20 05:39, schrieb Larry Baker:
> Lothar,
>
> On Aug 19, 2013, at 6:44 AM, <lothar at denx.de> <lothar at denx.de> wrote:
>
>> Am 2013-08-19 08:25, schrieb Larry Baker:
>> Hi Larry!
>>
>>> I'm getting an error about 40% of the way through the initial bitbake
>>> "Parsing recipes" step:
>>>> ERROR: The function perf_feature_enabled defined in
>>>> perf-features.inc was already declared in perf.inc. BitBake has a
>>>> global python function namespace so shared functions should be
>>>> declared in a common include file rather than being duplicated, or
>>>> if the functions are different, please use different function names.
>>> I have attached a screen capture of the first few steps of
>>> "MACHINE=generic-armv5te bitbake -k core-image-basic".
>>> I am concerned because there is a difference in the
>>> perf_feature_enabled function in the two files cited:
>>>> [baker at lenovo eldk]$ diff
>>>> /opt/git/eldk/meta-eldk/recipes-kernel/perf/perf.inc
>>>> /opt/git/eldk/meta/recipes-kernel/perf/perf-features.inc
>>>> 1c1
>>>> < PERF_FEATURES_ENABLE ?= ""
>>>> ---
>>>> > PERF_FEATURES_ENABLE ?= "perf-scripting perf-tui"
>>> I do not know what difference this can make.
>>> The perf.inc file under meta-eldk is not visible until after a "git
>>> checkout eldk-5.4".
>>> I don't recall this error message appearing when I first cloned the
>>> ELDK git. I wiped out my previous git clone and made this git clone
>>> Aug 18 22:59 UTC.
>>> Larry Baker
>>> US Geological Survey
>>> 650-329-5608
>>> baker at usgs.gov
>>> _______________________________________________
>>> eldk mailing list
>>> eldk at lists.denx.de
>>> http://lists.denx.de/mailman/listinfo/eldk
>>
>>
>> Thank you very much for sharing your precious observations!
>>
>> As I already mentioned, me too saw something similar:
>> $ MACHINE=generic-armv5te bitbake -n core-image-minimal
>> (...)
>>
>> WARNING: Unable to get checksum for linux-xenomai SRC_URI entry
>> defconfig: file could not be found
>> | ETA: 00:00:18
>> WARNING: Unable to get checksum for sysvinit-enbw-cmc SRC_URI entry
>> install.patch: file could not be found
>> | ETA: 00:00:16
>> WARNING: Unable to get checksum for sysvinit-enbw-cmc SRC_URI entry
>> crypt-lib.patch: file could not be found
>> WARNING: Unable to get checksum for sysvinit-enbw-cmc SRC_URI entry
>> need: file could not be found
>> WARNING: Unable to get checksum for sysvinit-enbw-cmc SRC_URI entry
>> provide: file could not be found
>> WARNING: Unable to get checksum for sysvinit-enbw-cmc SRC_URI entry
>> rcS-default: file could not be found
>> WARNING: Unable to get checksum for sysvinit-enbw-cmc SRC_URI entry
>> rc: file could not be found
>> WARNING: Unable to get checksum for sysvinit-enbw-cmc SRC_URI entry
>> rcS: file could not be found
>> WARNING: Unable to get checksum for gst-omapfb SRC_URI entry
>> gst-omapfb-cross-gcc-fix.patch: file could not be found
>> | ETA: 00:00:11
>> WARNING: Unable to get checksum for gst-omapfb SRC_URI entry
>> 0001-modify-to-use-on-AM3517-with-Qt-Embedded-OMAPFB-over.patch: file
>> could not be found
>> WARNING: Unable to get checksum for gst-omapfb SRC_URI entry
>> 0002-gst-omapfb-modify-to-use-with-Qt-Mobility-extensions.patch: file
>> could not be found
>> ERROR: The function perf_feature_enabled defined in perf-features.inc
>> was already declared in perf.inc. BitBake has a global python function
>> namespace so shared functions should be declared in a common include
>> file rather than being duplicated, or if the functions are different,
>> please use different function names.
>> Parsing recipes: 100%
>> |################################################################################################################################| Time: 00:00:14
>> Parsing of 847 .bb files complete (0 cached, 847 parsed). 1164
>> targets, 55 skipped, 0 masked, 0 errors.
>>
>> In the attachment you'll find my personal solution. It's not an
>> official fix, it just fixed the situation for me, I assumed just a
>> simple mistake in the filename, not perf.inc but perf-feature.inc in
>> the meta-eldk.
>>
>> Again, I have to underline that it is not an official fix! It's my own
>> solution, just what I did to get the error out of my way, and I didn't
>> see any further problems. I'll address the issue when we have more
>> resources to take a look at it.
>>
>> Any further feedback on that I appreciate!!
>>
>> BR,
>> Lothar Rubusch
>>
>> PS: if I arrange some time, I'll try to have a look in this tremendous
>> amount of warnings, too!
>>
>>
>> QUICKFIX:
>> From 160f6eb3260db26bc52ef5c6b030b25eff2ca5ef Mon Sep 17 00:00:00 2001
>> From: Lothar Rubusch <l.rubusch at gmx.ch>
>> Date: Mon, 19 Aug 2013 15:13:02 +0200
>> Subject: [PATCH] perf.inc quickfix
>>
>> ---
>> meta-eldk/recipes-kernel/perf/perf-features.inc | 22
>> ++++++++++++++++++++++
>> meta-eldk/recipes-kernel/perf/perf.inc | 22
>> ----------------------
>> meta-eldk/recipes-kernel/perf/perf_3.6.bb | 2 +-
>> 3 files changed, 23 insertions(+), 23 deletions(-)
>> create mode 100644 meta-eldk/recipes-kernel/perf/perf-features.inc
>> delete mode 100644 meta-eldk/recipes-kernel/perf/perf.inc
>>
>> diff --git a/meta-eldk/recipes-kernel/perf/perf-features.inc
>> b/meta-eldk/recipes-kernel/perf/perf-features.inc
>> new file mode 100644
>> index 0000000..e1a7492
>> --- /dev/null
>> +++ b/meta-eldk/recipes-kernel/perf/perf-features.inc
>> @@ -0,0 +1,22 @@
>> +PERF_FEATURES_ENABLE ?= ""
>> +
>> +def perf_feature_enabled(feature, trueval, falseval, d):
>> + """
>> + Check which perf features are enabled.
>> +
>> + The PERF_FEATURES_ENABLE variable lists the perf features to
>> + enable. Override it if you want something different from what's
>> + listed above, which is the default. If empty, the build won't
>> + enable any features (which may be exactly what you want, just a
>> + barebones perf without any extra baggage, what you get if you
>> + specify an empty feature list).
>> +
>> + Available perf features:
>> + perf-scripting: enable support for Perl and Python bindings
>> + perf-tui: enable support for the perf TUI (via libnewt)
>> +
>> + """
>> + enabled_features = d.getVar("PERF_FEATURES_ENABLE", True) or ""
>> + if feature in enabled_features:
>> + return trueval
>> + return falseval
>> diff --git a/meta-eldk/recipes-kernel/perf/perf.inc
>> b/meta-eldk/recipes-kernel/perf/perf.inc
>> deleted file mode 100644
>> index e1a7492..0000000
>> --- a/meta-eldk/recipes-kernel/perf/perf.inc
>> +++ /dev/null
>> @@ -1,22 +0,0 @@
>> -PERF_FEATURES_ENABLE ?= ""
>> -
>> -def perf_feature_enabled(feature, trueval, falseval, d):
>> - """
>> - Check which perf features are enabled.
>> -
>> - The PERF_FEATURES_ENABLE variable lists the perf features to
>> - enable. Override it if you want something different from what's
>> - listed above, which is the default. If empty, the build won't
>> - enable any features (which may be exactly what you want, just a
>> - barebones perf without any extra baggage, what you get if you
>> - specify an empty feature list).
>> -
>> - Available perf features:
>> - perf-scripting: enable support for Perl and Python bindings
>> - perf-tui: enable support for the perf TUI (via libnewt)
>> -
>> - """
>> - enabled_features = d.getVar("PERF_FEATURES_ENABLE", True) or ""
>> - if feature in enabled_features:
>> - return trueval
>> - return falseval
>> diff --git a/meta-eldk/recipes-kernel/perf/perf_3.6.bb
>> b/meta-eldk/recipes-kernel/perf/perf_3.6.bb
>> index b3a8792..045b1f3 100644
>> --- a/meta-eldk/recipes-kernel/perf/perf_3.6.bb
>> +++ b/meta-eldk/recipes-kernel/perf/perf_3.6.bb
>> @@ -11,7 +11,7 @@ LIC_FILES_CHKSUM =
>> "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
>>
>> PR = "r0"
>>
>> -require perf.inc
>> +require perf-features.inc
>>
>> BUILDPERF_libc-uclibc = "no"
>>
>> --
>> 1.7.10.4
>>
>> _______________________________________________
>> eldk mailing list
>> eldk at lists.denx.de
>> http://lists.denx.de/mailman/listinfo/eldk
>
>
> From the structure of your patch, I take it that files in meta-eldk
> overload files in meta with the same name (a simple path search of
> some kind)?
>
> Thank you,
>
> Larry Baker
> US Geological Survey
> 650-329-5608
> baker at usgs.gov
Hi Larry,
Yes, that's what I'm doing here.
Best,
Lothar
More information about the eldk
mailing list