Georgi Georgiev
2018-12-04 07:53:27 UTC
Hello,
As probably all yocto people know the sysrootfs policy changed in yocto rocko 2.4+. So I have the following issue:
I try to make a recipe for a shared library with makefile. The recipe is below (I don't claim it is complete. I simply cannot pass building stage):
#==================
LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://${THISDIR}/files/LICENSE;md5=5959e502cb44bafc53b2cc9400e3d4cd"
PR = "r0"
##### First try from my local repo and then we will use the big one
SRC_URI = "git:///home/w23698/projects/anybus/Generic;branch=anybus-lib-0.0.1"
SRCREV = "2fe4ce39a651d71f3f8de1c751dff2581de2c526"
S = "${WORKDIR}/git"
PACKAGES = "${PN} ${PN}-dev ${PN}-dbg"
#####The only dependency
RDEPENDS_${PN} = "libgpiod"
RDEPENDS_${PN}-dev = "libgpiod"
RDEPENDS_${PN}-dbg = "libgpiod"
do_compile() {
oe_runmake
}
do_install() {
install -d ${D}${libdir}
install -m 0644 ${PN}-m40 ${D}${libdir}
}
What was my surprise when it failed with:
ww.c:6:10: fatal error: gpiod.h: No such file or directory
| #include "gpiod.h"
| ^~~~~~~~~
| compilation terminated.
Then I noticed that the command line is:
arm-poky-linux-gnueabi-gcc -march=armv7-a -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 --sysroot=/<full path>/recipe-sysroot -L/usr/lib -g -Wall -fpic .....
I looked in recipe-sysroot/usr/lib/ and found a minimal set of libraries and libgpiod was not there. Neither the header was there in include...
Any suggestions?
Cordially,
Georgi
As probably all yocto people know the sysrootfs policy changed in yocto rocko 2.4+. So I have the following issue:
I try to make a recipe for a shared library with makefile. The recipe is below (I don't claim it is complete. I simply cannot pass building stage):
#==================
LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://${THISDIR}/files/LICENSE;md5=5959e502cb44bafc53b2cc9400e3d4cd"
PR = "r0"
##### First try from my local repo and then we will use the big one
SRC_URI = "git:///home/w23698/projects/anybus/Generic;branch=anybus-lib-0.0.1"
SRCREV = "2fe4ce39a651d71f3f8de1c751dff2581de2c526"
S = "${WORKDIR}/git"
PACKAGES = "${PN} ${PN}-dev ${PN}-dbg"
#####The only dependency
RDEPENDS_${PN} = "libgpiod"
RDEPENDS_${PN}-dev = "libgpiod"
RDEPENDS_${PN}-dbg = "libgpiod"
do_compile() {
oe_runmake
}
do_install() {
install -d ${D}${libdir}
install -m 0644 ${PN}-m40 ${D}${libdir}
}
What was my surprise when it failed with:
ww.c:6:10: fatal error: gpiod.h: No such file or directory
| #include "gpiod.h"
| ^~~~~~~~~
| compilation terminated.
Then I noticed that the command line is:
arm-poky-linux-gnueabi-gcc -march=armv7-a -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 --sysroot=/<full path>/recipe-sysroot -L/usr/lib -g -Wall -fpic .....
I looked in recipe-sysroot/usr/lib/ and found a minimal set of libraries and libgpiod was not there. Neither the header was there in include...
Any suggestions?
Cordially,
Georgi