libsdl2-compat: fix to work as drop-in replacement for libsdl2

Since libsdl2 and libsdl2-compat are now mutually exclusive
we can afford to rename the .pc file from sdl2-compat.pc to sdl2.pc
This helps other projects which use pkgconfig to find libsdl2

Allow to build libsdl2-compat for native and nativesdk. This is required
to build qemu

Signed-off-by: Markus Volk <f_l_k@t-online.de>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
This commit is contained in:
Markus Volk
2025-04-21 12:32:31 +02:00
committed by Khem Raj
parent 4613cf3854
commit 30a032aa66
@@ -22,7 +22,13 @@ inherit cmake pkgconfig upstream-version-is-even features_check
REQUIRED_DISTRO_FEATURES = "opengl x11"
do_install:append() {
mv ${D}${libdir}/pkgconfig/sdl2_compat.pc ${D}${libdir}/pkgconfig/sdl2.pc
}
FILES:${PN} += "${datadir}/licenses"
RCONFLICTS:${PN} = "libsdl2"
RPROVIDES:${PN} = "libsdl2"
BBCLASSEXTEND = "nativesdk native"