All of lore.kernel.org
 help / color / mirror / Atom feed
* libm implementation issue
@ 2014-12-30  9:39 peterengcomau001
  2014-12-30 19:48 ` Benjamin Esquivel
  2014-12-31  9:41 ` Richard Purdie
  0 siblings, 2 replies; 5+ messages in thread
From: peterengcomau001 @ 2014-12-30  9:39 UTC (permalink / raw)
  To: yocto

[-- Attachment #1: Type: text/plain, Size: 3662 bytes --]


 I have some software that uses specific mathematical functions. When
I attempt to compile them with the Yocto cross-compile tools, the
functions are not recognised. E.g. 'pow' in 
According to website
https://wiki.yoctoproject.org/wiki/Minimal_Image, not all eglibc
features are installed as standard, and that I should alter my
local.conf file I have added the following:

DISTRO_FEATURES_LIBC  += " libc-libm "
DISTRO_FEATURES_append = " ${DISTRO_FEATURES_LIBC} "

When I bitbake the image I get the following error: (this is just the
end of the error log - there are many undefined references)

|
/home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/eglibc-2.19/libc/pwd/../nss/getXXbyYY_r.c:213:
undefined reference to `__nss_database_custom'
|
/home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/build-arm-poky-linux-gnueabi/libc_pic.os:
In function `__getpwuid_r':
|
/home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/eglibc-2.19/libc/pwd/../nss/getXXbyYY_r.c:196:
undefined reference to `__nscd_getpwuid_r'
|
/home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/eglibc-2.19/libc/pwd/../nss/getXXbyYY_r.c:213:
undefined reference to `__nss_not_use_nscd_passwd'
|
/home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/eglibc-2.19/libc/pwd/../nss/getXXbyYY_r.c:213:
undefined reference to `__nss_database_custom'
|
/home/lachlan/poky/build-atmel/tmp/sysroots/x86_64-linux/usr/libexec/cortexa5t2hf-vfp-poky-linux-gnueabi.gcc-cross-initial/gcc/arm-poky-linux-gnueabi/4.8.2/ld:
/home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/build-arm-poky-linux-gnueabi/libc.so:
hidden symbol `__nss_not_use_nscd_group' isn't defined
|
/home/lachlan/poky/build-atmel/tmp/sysroots/x86_64-linux/usr/libexec/cortexa5t2hf-vfp-poky-linux-gnueabi.gcc-cross-initial/gcc/arm-poky-linux-gnueabi/4.8.2/ld:
final link failed: Bad value
| collect2: error: ld returned 1 exit status
| ERROR: Function failed: do_compile (log file is located at
/home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/temp/log.do_compile.5266)
ERROR: Task 39
(/home/lachlan/poky/meta/recipes-core/eglibc/eglibc_2.19.bb,
do_compile) failed with exit code '1'

I have reviewed the sample.conf.extended file in the meta-yocto later
and the above code should be OK, except that I have added the '+' and
'append'. If I use DISTRO_FEATURES instead of DISTRO_FEATURES_append,
I get other errros:
Missing or unbuildable dependency chain was:
['packagegroup-base-wifi']
ERROR: Required build target 'atmel-qt5-demo-image' has no buildable
providers
Missing or unbuildable dependency chain was: ['atmel-qt5-demo-image',
'packagegroup-base-wifi']

If I use DISTRO_FEATURES_LIBC = instead of DISTRO_FEATURES_LIBC += ,
I get these errors:
ERROR: Unable to parse
/home/lachlan/poky/meta/recipes-core/packagegroups/packagegroup-core-boot.bb:
Exited with
"1"#                                                       
| ETA:  00:00:39
ERROR: Please ensure that your setting of
VIRTUAL-RUNTIME_init_manager (sysvinit) matches the entries enabled
in DISTRO_FEATURES

I am probably overriding a default setting Is there an alternative
way to include the libc-libm, or is there something else that could 
be causing the erro?

Thanks for any help

Lachlan
---- Message sent via Adam Internet WebMail - http://www.adam.com.au/

[-- Attachment #2: Type: text/html, Size: 3818 bytes --]

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

* Re: libm implementation issue
  2014-12-30  9:39 libm implementation issue peterengcomau001
@ 2014-12-30 19:48 ` Benjamin Esquivel
  2014-12-31  9:01   ` peterengcomau001
  2014-12-31  9:41 ` Richard Purdie
  1 sibling, 1 reply; 5+ messages in thread
From: Benjamin Esquivel @ 2014-12-30 19:48 UTC (permalink / raw)
  To: peterengcomau001; +Cc: yocto

On Tue, 2014-12-30 at 20:09 +1030, peterengcomau001@adam.com.au wrote:
> 
> I have some software that uses specific mathematical functions. When I
> attempt to compile them with the Yocto cross-compile tools, the
> functions are not recognised. E.g. 'pow' in <math>
> According to website https://wiki.yoctoproject.org/wiki/Minimal_Image,
> not all eglibc features are installed as standard, and that I should
> alter my local.conf file. I have added the following:
> 
> DISTRO_FEATURES_LIBC  += " libc-libm "
> DISTRO_FEATURES_append = " ${DISTRO_FEATURES_LIBC} "
> 

it seems like the instructions at:

https://wiki.yoctoproject.org/wiki/Minimal_Image#eglibc_component_configuration_system

are not giving the expected results. I tried it with dizzy and daisy and
I obtained the same ld error as you.

I filed a bug here for such:

https://bugzilla.yoctoproject.org/show_bug.cgi?id=7108
 
I guess we can track it from there.

> When I bitbake the image I get the following error: (this is just the
> end of the error log - there are many undefined references)
> 
> | /home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/eglibc-2.19/libc/pwd/../nss/getXXbyYY_r.c:213: undefined reference to `__nss_database_custom'
> | /home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/build-arm-poky-linux-gnueabi/libc_pic.os: In function `__getpwuid_r':
> | /home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/eglibc-2.19/libc/pwd/../nss/getXXbyYY_r.c:196: undefined reference to `__nscd_getpwuid_r'
> | /home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/eglibc-2.19/libc/pwd/../nss/getXXbyYY_r.c:213: undefined reference to `__nss_not_use_nscd_passwd'
> | /home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/eglibc-2.19/libc/pwd/../nss/getXXbyYY_r.c:213: undefined reference to `__nss_database_custom'
> | /home/lachlan/poky/build-atmel/tmp/sysroots/x86_64-linux/usr/libexec/cortexa5t2hf-vfp-poky-linux-gnueabi.gcc-cross-initial/gcc/arm-poky-linux-gnueabi/4.8.2/ld: /home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/build-arm-poky-linux-gnueabi/libc.so: hidden symbol `__nss_not_use_nscd_group' isn't defined
> | /home/lachlan/poky/build-atmel/tmp/sysroots/x86_64-linux/usr/libexec/cortexa5t2hf-vfp-poky-linux-gnueabi.gcc-cross-initial/gcc/arm-poky-linux-gnueabi/4.8.2/ld: final link failed: Bad value
> | collect2: error: ld returned 1 exit status
> | ERROR: Function failed: do_compile (log file is located
> at /home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/temp/log.do_compile.5266)
> ERROR: Task 39
> (/home/lachlan/poky/meta/recipes-core/eglibc/eglibc_2.19.bb,
> do_compile) failed with exit code '1'
> 
> 
> I have reviewed the sample.conf.extended file in the meta-yocto later
> and the above code should be OK, except that I have added the '+' and
> 'append'. If I use DISTRO_FEATURES instead of DISTRO_FEATURES_append,
> I get other errros:
> Missing or unbuildable dependency chain was:
> ['packagegroup-base-wifi']
> ERROR: Required build target 'atmel-qt5-demo-image' has no buildable
> providers.
> Missing or unbuildable dependency chain was: ['atmel-qt5-demo-image',
> 'packagegroup-base-wifi']
> 
> If I use DISTRO_FEATURES_LIBC = instead of DISTRO_FEATURES_LIBC += , I
> get these errors:
> ERROR: Unable to
> parse /home/lachlan/poky/meta/recipes-core/packagegroups/packagegroup-core-boot.bb: Exited with "1"#                                                        | ETA:  00:00:39
> ERROR: Please ensure that your setting of VIRTUAL-RUNTIME_init_manager
> (sysvinit) matches the entries enabled in DISTRO_FEATURES
> 
> 
> I am probably overriding a default setting. Is there an alternative
> way to include the libc-libm, or is there something else that could
> be causing the erro?
> 
> Thanks for any help
> 
> Lachlan
> ---- Message sent via Adam Internet WebMail - http://www.adam.com.au/




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

* Re: libm implementation issue
  2014-12-30 19:48 ` Benjamin Esquivel
@ 2014-12-31  9:01   ` peterengcomau001
  0 siblings, 0 replies; 5+ messages in thread
From: peterengcomau001 @ 2014-12-31  9:01 UTC (permalink / raw)
  To: benjamin.esquivel; +Cc: yocto

[-- Attachment #1: Type: text/plain, Size: 4584 bytes --]

 
 Thanks,I have continued to struggle on and had just decided to file
a bug myself. Thanks for verifying and filing the bug
already.RegardsLachlan

----- Original Message -----
From: benjamin.esquivel@linux.intel.com
To:
Cc:
Sent:Tue, 30 Dec 2014 13:48:57 -0600
Subject:Re: [yocto] libm implementation issue

 On Tue, 2014-12-30 at 20:09 +1030, peterengcomau001@adam.com.au
wrote:
 > 
 > I have some software that uses specific mathematical functions.
When I
 > attempt to compile them with the Yocto cross-compile tools, the
 > functions are not recognised. E.g. 'pow' in 
 > According to website
https://wiki.yoctoproject.org/wiki/Minimal_Image,
 > not all eglibc features are installed as standard, and that I
should
 > alter my local.conf file. I have added the following:
 > 
 > DISTRO_FEATURES_LIBC += " libc-libm "
 > DISTRO_FEATURES_append = " ${DISTRO_FEATURES_LIBC} "
 > 

 it seems like the instructions at:


https://wiki.yoctoproject.org/wiki/Minimal_Image#eglibc_component_configuration_system

 are not giving the expected results. I tried it with dizzy and daisy
and
 I obtained the same ld error as you.

 I filed a bug here for such:

 https://bugzilla.yoctoproject.org/show_bug.cgi?id=7108

 I guess we can track it from there.

 > When I bitbake the image I get the following error: (this is just
the
 > end of the error log - there are many undefined references)
 > 
 > |
/home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/eglibc-2.19/libc/pwd/../nss/getXXbyYY_r.c:213:
undefined reference to `__nss_database_custom'
 > |
/home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/build-arm-poky-linux-gnueabi/libc_pic.os:
In function `__getpwuid_r':
 > |
/home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/eglibc-2.19/libc/pwd/../nss/getXXbyYY_r.c:196:
undefined reference to `__nscd_getpwuid_r'
 > |
/home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/eglibc-2.19/libc/pwd/../nss/getXXbyYY_r.c:213:
undefined reference to `__nss_not_use_nscd_passwd'
 > |
/home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/eglibc-2.19/libc/pwd/../nss/getXXbyYY_r.c:213:
undefined reference to `__nss_database_custom'
 > |
/home/lachlan/poky/build-atmel/tmp/sysroots/x86_64-linux/usr/libexec/cortexa5t2hf-vfp-poky-linux-gnueabi.gcc-cross-initial/gcc/arm-poky-linux-gnueabi/4.8.2/ld:
/home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/build-arm-poky-linux-gnueabi/libc.so:
hidden symbol `__nss_not_use_nscd_group' isn't defined
 > |
/home/lachlan/poky/build-atmel/tmp/sysroots/x86_64-linux/usr/libexec/cortexa5t2hf-vfp-poky-linux-gnueabi.gcc-cross-initial/gcc/arm-poky-linux-gnueabi/4.8.2/ld:
final link failed: Bad value
 > | collect2: error: ld returned 1 exit status
 > | ERROR: Function failed: do_compile (log file is located
 > at
/home/lachlan/poky/build-atmel/tmp/work/cortexa5t2hf-vfp-poky-linux-gnueabi/eglibc/2.19-r0/temp/log.do_compile.5266)
 > ERROR: Task 39
 > (/home/lachlan/poky/meta/recipes-core/eglibc/eglibc_2.19.bb,
 > do_compile) failed with exit code '1'
 > 
 > 
 > I have reviewed the sample.conf.extended file in the meta-yocto
later
 > and the above code should be OK, except that I have added the '+'
and
 > 'append'. If I use DISTRO_FEATURES instead of
DISTRO_FEATURES_append,
 > I get other errros:
 > Missing or unbuildable dependency chain was:
 > ['packagegroup-base-wifi']
 > ERROR: Required build target 'atmel-qt5-demo-image' has no
buildable
 > providers.
 > Missing or unbuildable dependency chain was:
['atmel-qt5-demo-image',
 > 'packagegroup-base-wifi']
 > 
 > If I use DISTRO_FEATURES_LIBC = instead of DISTRO_FEATURES_LIBC +=
, I
 > get these errors:
 > ERROR: Unable to
 > parse
/home/lachlan/poky/meta/recipes-core/packagegroups/packagegroup-core-boot.bb:
Exited with "1"# | ETA: 00:00:39
 > ERROR: Please ensure that your setting of
VIRTUAL-RUNTIME_init_manager
 > (sysvinit) matches the entries enabled in DISTRO_FEATURES
 > 
 > 
 > I am probably overriding a default setting. Is there an
alternative
 > way to include the libc-libm, or is there something else that
could
 > be causing the erro?
 > 
 > Thanks for any help
 > 
 > Lachlan
 > ---- Message sent via Adam Internet WebMail -
http://www.adam.com.au/

---- Message sent via Adam Internet WebMail - http://www.adam.com.au/

[-- Attachment #2: Type: text/html, Size: 5587 bytes --]

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

* Re: libm implementation issue
  2014-12-30  9:39 libm implementation issue peterengcomau001
  2014-12-30 19:48 ` Benjamin Esquivel
@ 2014-12-31  9:41 ` Richard Purdie
  2015-01-09 21:02   ` peterengcomau001
  1 sibling, 1 reply; 5+ messages in thread
From: Richard Purdie @ 2014-12-31  9:41 UTC (permalink / raw)
  To: peterengcomau001; +Cc: yocto

On Tue, 2014-12-30 at 20:09 +1030, peterengcomau001@adam.com.au wrote:
> 
> I have some software that uses specific mathematical functions. When I
> attempt to compile them with the Yocto cross-compile tools, the
> functions are not recognised. E.g. 'pow' in <math>
> According to website https://wiki.yoctoproject.org/wiki/Minimal_Image,
> not all eglibc features are installed as standard, and that I should
> alter my local.conf file. I have added the following:
> 
> DISTRO_FEATURES_LIBC  += " libc-libm "
> DISTRO_FEATURES_append = " ${DISTRO_FEATURES_LIBC} "

By default the libc we build is fully featured. The only time we cut
down the libc by default is when you use DISTRO = "poky-tiny". Are you
using poky-tiny?

If you're not, the most likely issue you didn't see pow and friends
would be a missing linkage against libm (-lm on the commandline for
gcc/ld).

Cheers,

Richard



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

* Re: libm implementation issue
  2014-12-31  9:41 ` Richard Purdie
@ 2015-01-09 21:02   ` peterengcomau001
  0 siblings, 0 replies; 5+ messages in thread
From: peterengcomau001 @ 2015-01-09 21:02 UTC (permalink / raw)
  To: Richard Purdie, peterengcomau001; +Cc: yocto

[-- Attachment #1: Type: text/plain, Size: 2314 bytes --]

 Hi Richard,I am using the standard poky DISTRO (although the
configuration is DISTRO ?= "poky' so something else my be changing
it. Also The final image is pretty large taking 256Mb.Is there
anything else I can check that may be altering the DISTRO or the
libc. If I look at all the setting in ECLIPSE, there is no reference
to changing any libm or -lm settings.
I am also having problems with some of the libraries being generated
when i use qemu-extra-sdk are not present in the resulting rootfs, so
I have to also run "$bitbake image -c populate_sdk" and manully copy
over the affected libraries. However, since I use eglibc-static in
the extra image features in the config file, I have not had a problem
with missing libc libraries according to the linker, but that doesn't
mean there is not something else wrong.

Also, I have been trying to access the jiffy.h which should be
standard in Linux but is not created as part of the build. It is
created during the build but something is removing it from the image
(or not including it). Do you have any idea what I can do to add
jiffy to the final image?
Thanks for your help.
Lachlan

----- Original Message -----
From: "Richard Purdie" 
To:
Cc:
Sent:Wed, 31 Dec 2014 09:41:33 +0000
Subject:Re: [yocto] libm implementation issue

 On Tue, 2014-12-30 at 20:09 +1030, peterengcomau001@adam.com.au
wrote:
 > 
 > I have some software that uses specific mathematical functions.
When I
 > attempt to compile them with the Yocto cross-compile tools, the
 > functions are not recognised. E.g. 'pow' in 
 > According to website
https://wiki.yoctoproject.org/wiki/Minimal_Image,
 > not all eglibc features are installed as standard, and that I
should
 > alter my local.conf file. I have added the following:
 > 
 > DISTRO_FEATURES_LIBC += " libc-libm "
 > DISTRO_FEATURES_append = " ${DISTRO_FEATURES_LIBC} "

 By default the libc we build is fully featured. The only time we cut
 down the libc by default is when you use DISTRO = "poky-tiny". Are
you
 using poky-tiny?

 If you're not, the most likely issue you didn't see pow and friends
 would be a missing linkage against libm (-lm on the commandline for
 gcc/ld).

 Cheers,

 Richard

---- Message sent via Adam Internet WebMail - http://www.adam.com.au/

[-- Attachment #2: Type: text/html, Size: 3034 bytes --]

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

end of thread, other threads:[~2015-01-09 21:03 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-12-30  9:39 libm implementation issue peterengcomau001
2014-12-30 19:48 ` Benjamin Esquivel
2014-12-31  9:01   ` peterengcomau001
2014-12-31  9:41 ` Richard Purdie
2015-01-09 21:02   ` peterengcomau001

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.