Post Go back to editing

mcapi yocto recipe is broken

I've been attempting to use MCAPI to converse with the SHARC+ cores on an SC589.

The recipe for doesn't publish header files so you can't actually compile anything with it.

But after a trivial patch, I still can't get a simple program to link using a yocto recipe.  Either my linking with `-lmcapi` isn't right, or there's something else required because I only get "undefined reference to `mcapi_initialize'"

Has anyone ever actually used a yocto built arm mcapi application to talk to a SHARC+ core?

diff --git a/meta-adi-adsp-sc5xx/recipes-icc/libmcapi/ b/meta-adi-adsp-sc5xx/recipes-icc/libmcapi/
index db41169..a503400 100644
--- a/meta-adi-adsp-sc5xx/recipes-icc/libmcapi/
+++ b/meta-adi-adsp-sc5xx/recipes-icc/libmcapi/
@@ -29,9 +29,14 @@ do_compile_prepend(){
        install -d ${D}/usr/bin
-       install -d ${D}/usr/lib 
+       install -d ${D}/usr/lib
+       install -d ${D}/usr/include
        install -m 755 ${S}/tests/.libs/* ${D}/usr/bin/
        install -m 755 ${S}/.libs/ ${D}/usr/lib/
-       ln -s ${D}/usr/lib/ 
-       ln -s ${D}/usr/lib/ 
\ No newline at end of file
+       ln -s ${D}/usr/lib/
+       ln -s ${D}/usr/lib/
+       install ${S}/include/*.h ${D}/usr/include
+FILES_${PN} += "/usr/lib/* /usr/bin/*"
+FILES_${PN}-dev += "/usr/include"

[edited by: rireland at 7:03 PM (GMT -5) on 25 Jan 2022]