Yocto Bitbake Recipe for mlpack

30 Views Asked by At

Getting various errors while building mlpack library on yocto mickledore environment with a self written recipe.

Found below errors in CMakeError.log file

/mlpack/4.3.0-r0/recipe-sysroot-native/usr/bin/arm-poky-linux-gnueabi/../../libexec/arm-poky-linux-gnueabi/gcc/arm-poky-linux-gnueabi/9.3.0/ld: CMakeFiles/cmTC_5281c.dir/src.c.o: in function main': /usr/src/debug/mlpack/4.3.0-r0/build/CMakeFiles/CMakeTmp/src.c:11: undefined reference to pthread_create'

/mlpack/4.3.0-r0/recipe-sysroot-native/usr/bin/arm-poky-linux-gnueabi/../../libexec/arm-poky-linux-gnueabi/gcc/arm-poky-linux-gnueabi/9.3.0/ld: /mlpack/4.3.0-r0/build/deps/OpenBLAS-0.3.13/libopenblas.a(blas_server.o): in function openblas_setaffinity': /usr/src/debug/mlpack/4.3.0-r0/build/deps/OpenBLAS-0.3.13/driver/others/blas_server.c:337: undefined reference to pthread_setaffinity_np'

...

Below is the recipe I have written for this task.

    DESCRIPTION = "Recipe for mlpack"
    LICENSE = "BSD"
    LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=8873a4d38115278beec5145f55847d5c"

    SRC_URI = "git://github.com/mlpack/mlpack.git;protocol=https"
    SRCREV = "5e6d6f29ab13e34ce15577c5188f9121a6516b60"

    S = "${WORKDIR}/git"

    DEPENDS = "boost armadillo libcereal gcc-runtime"

    inherit cmake

    EXTRA_OECMAKE += " -DDEBUG=ON -DDOWNLOAD_DEPENDENCIES=ON -DTOOLCHAIN_PREFIX=arm-linux-gnueabi- -DCMAKE_SYSROOT=${STAGING_DIR_NATIVE} -DOPENBLAS_TARGET=ARMV7 -DGFORTRAN=${WORKDIR}/recipe-sysroot-native/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-gfortran"

Also, verify me whether I am specifying DCMAKE_SYSROOT DTOOLCHAIN_PREFIX correctly ?

So, please anyone help me in writing a valid bitbake recipe for mlpack.

0

There are 0 best solutions below