[oe] RFC: Library file extensions

Richard Purdie rpurdie at rpsys.net
Thu Feb 21 10:21:16 UTC 2008


Hi,

As some may have gathered I made some experiments with using Poky to
cross compile things to run on the iPodTouch which is arm-apple-darwin.
THe good news is they were successful however Darwin creates some
interesting challenges for OE, one of them is the dynamic libraries
being called *.dylib, not *.so.

I've had the following patch in Poky to assist with this problem. It
would need to be rolled out over all .bb files with custom FILES
eventually but it has the advantage that can happen over time so the
question is more whether this is a good idea and whether the approach is
acceptable?

We would probably hit the same issue with windows .dll files and this
solution would solve that too.

Comments welcome...

Cheers,

Richard

#
# old_revision [5fb8cfe19138b98226fe92044d302c9379dad84d]
#
# patch "conf/bitbake.conf"
#  from [a605bd5d4d48054b72d21c74a922a9a0a2d12a76]
#    to [1655c26111af10134f07eafd1e29ef00d8cd8f5f]
#
============================================================
--- conf/bitbake.conf	a605bd5d4d48054b72d21c74a922a9a0a2d12a76
+++ conf/bitbake.conf	1655c26111af10134f07eafd1e29ef00d8cd8f5f
@@ -157,12 +157,17 @@ MULTI_PROVIDER_WHITELIST = "virtual/libi
 
 MULTI_PROVIDER_WHITELIST = "virtual/libintl"
 
+SOLIBS = ".so.*"
+SOLIBS_darwin = ".*.dylib"
+SOLIBSDEV = ".so"
+SOLIBSDEV_darwin = ".dylib"
+
 PACKAGES = "${PN}-dbg ${PN} ${PN}-doc ${PN}-dev ${PN}-locale"
 FILES = ""
 
-FILES_${PN} = "${bindir}/* ${sbindir}/* ${libexecdir}/* ${libdir}/lib*.so.* \
+FILES_${PN} = "${bindir}/* ${sbindir}/* ${libexecdir}/* ${libdir}/lib*${SOLIBS} \
             ${sysconfdir} ${sharedstatedir} ${localstatedir} \
-            ${base_bindir}/* ${base_sbindir}/* ${base_libdir}/*.so* ${datadir}/${PN} ${libdir}/${PN}/* \
+            ${base_bindir}/* ${base_sbindir}/* ${base_libdir}/${SOLIBS} ${datadir}/${PN} ${libdir}/${PN}/* \
             ${datadir}/pixmaps ${datadir}/applications \
             ${datadir}/idl ${datadir}/omf ${datadir}/sounds \
             ${libdir}/bonobo/servers"
@@ -171,7 +176,7 @@ SECTION_${PN}-doc = "doc"
             ${datadir}/gnome/help"
 SECTION_${PN}-doc = "doc"
 
-FILES_${PN}-dev = "${includedir} ${libdir}/lib*.so ${libdir}/*.la \
+FILES_${PN}-dev = "${includedir} ${libdir}/lib*${SOLIBSDEV} ${libdir}/*.la \
                 ${libdir}/*.a ${libdir}/*.o ${libdir}/pkgconfig \
                 ${base_libdir}/*.a ${base_libdir}/*.o ${datadir}/aclocal"
 SECTION_${PN}-dev = "devel"





More information about the Openembedded-devel mailing list