[yocto] Native packages compiled with host gcc set in PATH and with LD_LIBRARY_PATH to libstd++

Woronicz, Bartosz ( NSN - PL/Wroclaw) bartosz.woronicz at nokia.com
Fri May 6 07:38:55 PDT 2016


Kind regards,
Bartosz Woronicz
Engineer, Software Configuration (SCM)
Nokia Networks - PL/Wroclaw

On 06.05.2016 15:55, EXT Khem Raj wrote:
>
>> On May 6, 2016, at 1:43 AM, Chris Z. <winotu.email at gmail.com 
>> <mailto:winotu.email at gmail.com>> wrote:
>>
>> Hi,
>>
>> Any tips ?
>
> you need to insert your non-standard install of gcc-4.9 and glibc into 
> OE build via BUILD_CFLAGS
> and prepending it to your PATH variable that bitbake will see.
I use such hack in local.conf
BUILD_LDFLAGS_append_class-native = "${BB_EXT_ENV_GLIBCXX_RPATH}"


where BB_EXT_ENV_GLIBCXX_RPATH is

$ export BB_EXT_ENV_GLIBCXX_RPATH="$(echo "$LD_LIBRARY_PATH" | tr ':' 
'\n' | grep gcc | xargs -I % echo " -Wl,-rpath,%" | tr '\n' ' ')"
in my oe-init-buildenv wrapping script
>
>>
>> On Fri, Mar 4, 2016 at 4:13 PM, Chris Z. <winotu.email at gmail.com 
>> <mailto:winotu.email at gmail.com>> wrote:
>>
>>     Hi,
>>
>>     I have set newer gcc(4.9) in PATH and with proper
>>     LD_LIBRARY_PATH. Default system gcc is 4.4.
>>
>>     Bulding cmake-native fails when bootstrap cmake tries to compile
>>     cmake native binary.
>>
>>     This is due to the fact that bootstrap was compiled with newer
>>     glibcxx and it can't be found in system/host /usr/lib, /usr/lib64
>>     nor in -rpath.
>>
>>     rpath is set to
>>     -Wl,-rpath,${STAGING_LIBDIR_NATIVE} \
>>     -Wl,-rpath,${STAGING_BASE_LIBDIR_NATIVE} \
>>
>>     from BUILD_LDFLAGS var in bitbake.conf which is expand in native
>>     class.
>>
>>     What is the correct approach to fix this ? Or I shouldn't use gcc
>>     from PATH for compilation of native packages ?
>>
>>
>> -- 
>> _______________________________________________
>> yocto mailing list
>> yocto at yoctoproject.org <mailto:yocto at yoctoproject.org>
>> https://lists.yoctoproject.org/listinfo/yocto
>
>
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20160506/ff8a4895/attachment.html>


More information about the yocto mailing list