[OE-core] [PATCH 1/3] libsdl: support native compilation

Dmitry Eremin-Solenikov dbaryshkov at gmail.com
Thu Oct 22 13:28:25 UTC 2015


Hello,

2015-10-19 17:44 GMT+03:00 Mark Hatle <mark.hatle at windriver.com>:
> On 10/19/15 9:17 AM, Dmitry Eremin-Solenikov wrote:
>> qemu-native can use SDL backend for graphical output. Currently it is
>> expected to use libsdl provided by the host. However this can lead to
>> library incompatibilities between host and target. Make libsdl recipe
>> support native compilation.
>
> I don't object to the patch.. but we did have multiple problems in the past
> where libsdl (native) did not work with the host systems X11 or what-ever.
>
> Various failure conditions about not linking, linking to the wrong libsdl, or
> execution failing are what made us prefer the host system's libsdl -- or simply
> disabling libsdl altogether.

The issue that get me to this patch was an issue with linking of qemu.
Debian provides versioned symbols in libdbus, OE does not. Libdbus
from sysroot overrode system one. So system libsdl which used system-wide
libpulse* (which expected libdbus with versioned symbols) could not be linked
to the qemu.

Richard: this was tested on my system only. If you don't want to break things
before release, what about merging them after next Yocto/OE-Core release?

>
> --Mark
>
>> Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov at gmail.com>
>> ---
>>  meta/recipes-graphics/libsdl/libsdl_1.2.15.bb | 3 ++-
>>  1 file changed, 2 insertions(+), 1 deletion(-)
>>
>> diff --git a/meta/recipes-graphics/libsdl/libsdl_1.2.15.bb b/meta/recipes-graphics/libsdl/libsdl_1.2.15.bb
>> index c0d5c6a..c9f3e00 100644
>> --- a/meta/recipes-graphics/libsdl/libsdl_1.2.15.bb
>> +++ b/meta/recipes-graphics/libsdl/libsdl_1.2.15.bb
>> @@ -17,6 +17,7 @@ DEPENDS = "${@bb.utils.contains('DISTRO_FEATURES', 'directfb', 'directfb', '', d
>>             ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'virtual/libx11 libxext libxrandr libxrender', '', d)} \
>>             ${@bb.utils.contains('DISTRO_FEATURES', 'x11 opengl', 'libglu', '', d)} \
>>             tslib"
>> +DEPENDS_class-native = "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'virtual/libx11-native libxrandr-native libxrender-native libxext-native', '', d)}"
>>  DEPENDS_class-nativesdk = "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'virtual/nativesdk-libx11 nativesdk-libxrandr nativesdk-libxrender nativesdk-libxext', '', d)}"
>>
>>  PR = "r3"
>> @@ -65,4 +66,4 @@ do_configure_prepend() {
>>          export SYSROOT=$PKG_CONFIG_SYSROOT_DIR
>>  }
>>
>> -BBCLASSEXTEND = "nativesdk"
>> +BBCLASSEXTEND = "native nativesdk"
>>
>



-- 
With best wishes
Dmitry



More information about the Openembedded-core mailing list