Praveen Kumar
VVDN Technologies Pvt Ltd
LlBest RegardsHi guys,I have wrote this Pjsip Yocto recipe, but when I try to copy all static (.a) libraries into target I have the following error:Pjsip Yocto Recipe============================================================ ======================
DEPENDS += "alsa-lib openssl"
SRC_URI = " \
file://pjproject-2.5.5 \
"
S = "${WORKDIR}/pjproject-2.5.5"
inherit autotools pkgconfig
do_configure_prepend() {
export LD="${CXX}"
}
do_configure() {
cd ${WORKDIR}/pjproject-2.5.5
./aconfigure --host=arm-poky-linux-gnueabi --disable-libwebrtc --target=arm-poky-linux-gnueabi CFLAGS="" LDFLAGS="" --prefix=${WORKDIR}/pjproject- 2.5.5
}
do_compile_prepend() {
cd ${WORKDIR}/pjproject-2.5.5
oe_runmake dep
oe_runmake
}
do_install() {
install -d ${D}/usr
install -d ${D}/usr/local
install -d ${D}/usr/local/include
install -d ${D}/usr/local/lib
cp -RLf ${WORKDIR}/pjproject-2.5.5/pjlib/include/* ${D}/usr/local/include
cp -RLf ${WORKDIR}/pjproject-2.5.5/pjlib-util/include/* ${D}/usr/local/include
cp -RLf ${WORKDIR}/pjproject-2.5.5/pjnath/include/* ${D}/usr/local/include
cp -RLf ${WORKDIR}/pjproject-2.5.5/pjmedia/include/* ${D}/usr/local/include
cp -RLf ${WORKDIR}/pjproject-2.5.5/pjsip/include/* ${D}/usr/local/include
cp -Lf ${WORKDIR}/pjproject-2.5.5/pjsip/lib/libpjsua2-arm-poky- linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/pjsip/lib/libpjsua-arm-poky- linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/pjsip/lib/libpjsip-ua-arm- poky-linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/pjsip/lib/libpjsip-simple-arm- poky-linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/pjsip/lib/libpjsip-arm-poky- linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/pjmedia/lib/libpjmedia-codec- arm-poky-linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/pjmedia/lib/libpjmedia- videodev-arm-poky-linux- gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/pjmedia/lib/libpjmedia-arm- poky-linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/pjmedia/lib/libpjmedia- audiodev-arm-poky-linux- gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/pjnath/lib/libpjnath-arm-poky- linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/pjlib-util/lib/libpjlib-util- arm-poky-linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/pjlib/lib/libpj-arm-poky- linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/third_party/lib/libsrtp-arm- poky-linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/third_party/lib/libresample- arm-poky-linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/third_party/lib/libgsmcodec- arm-poky-linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/third_party/lib/libspeex-arm- poky-linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/third_party/lib/libilbccodec- arm-poky-linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/third_party/lib/libg7221codec- arm-poky-linux-gnueabi.a ${D}/usr/local/lib
# cp -Lf ${WORKDIR}/pjproject-2.5.5/third_party/lib/libportaudio- arm-poky-linux-gnueabi.a ${D}/usr/local/lib
cp -Lf ${WORKDIR}/pjproject-2.5.5/third_party/lib/libyuv-arm- poky-linux-gnueabi.a ${D}/usr/local/lib
}
FILES_${PN} += "${libdir}/* \
/usr/local/* \
/usr/local/include/* \
/usr/local/lib/* \
/usr/local/lib/libpjsua2-arm-poky-linux-gnueabi.a \
/usr/local/lib/libpjsua-arm-poky-linux-gnueabi.a \
/usr/local/lib/libpjsip-ua-arm-poky-linux-gnueabi.a \
/usr/local/lib/libpjsip-simple-arm-poky-linux-gnueabi. a \
/usr/local/lib/libpjsip-arm-poky-linux-gnueabi.a \
/usr/local/lib/libpjmedia-codec-arm-poky-linux-gnueabi.a \
/usr/local/lib/libpjmedia-videodev-arm-poky-linux- gnueabi.a \
/usr/local/lib/libpjmedia-arm-poky-linux-gnueabi.a \
/usr/local/lib/libpjmedia-audiodev-arm-poky-linux- gnueabi.a \
/usr/local/lib/libpjnath-arm-poky-linux-gnueabi.a \
/usr/local/lib/libpjlib-util-arm-poky-linux-gnueabi.a \
/usr/local/lib/libpj-arm-poky-linux-gnueabi.a \
/usr/local/lib/libsrtp-arm-poky-linux-gnueabi.a \
/usr/local/lib/libresample-arm-poky-linux-gnueabi.a \
/usr/local/lib/libgsmcodec-arm-poky-linux-gnueabi.a \
/usr/local/lib/libspeex-arm-poky-linux-gnueabi.a \
/usr/local/lib/libilbccodec-arm-poky-linux-gnueabi.a \
/usr/local/lib/libg7221codec-arm-poky-linux-gnueabi.a \
/usr/local/lib/libyuv-arm-poky-linux-gnueabi.a \
"
============================================================ ====================== Obtained error:
ERROR: pjproject-1.0-r0 do_package_qa: QA Issue: non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libresample-arm- poky-linux-gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libpjsip-ua-arm- poky-linux-gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libpjsip-simple- arm-poky-linux-gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libpjlib-util- arm-poky-linux-gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libilbccodec- arm-poky-linux-gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libpjsua2-arm- poky-linux-gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libpjsua-arm- poky-linux-gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libpjnath-arm- poky-linux-gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libsrtp-arm- poky-linux-gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libyuv-arm-poky- linux-gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libpjmedia- videodev-arm-poky-linux- gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libpjmedia- audiodev-arm-poky-linux- gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libpjsip-arm- poky-linux-gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libpjmedia-arm- poky-linux-gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libspeex-arm- poky-linux-gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libpj-arm-poky- linux-gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libg7221codec- arm-poky-linux-gnueabi.a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libpjmedia- codec-arm-poky-linux-gnueabi. a'
non -staticdev package contains static .a library: pjproject path 'work/cortexa9hf-neon-poky-linux-gnueabi/pjproject/1.0- r0/packages-split/pjproject/ usr/local/lib/libgsmcodec-arm- poky-linux-gnueabi.a' [staticdev]
ERROR: pjproject-1.0-r0 do_package_qa: QA run found fatal errors. Please consider fixing them.
ERROR: pjproject-1.0-r0 do_package_qa: Function failed: do_package_qa
ERROR: Logfile of failure stored in: /home/user/krogoth/fsl-release-bsp/icoremx6quad/tmp/ work/cortexa9hf-neon-poky- linux-gnueabi/pjproject/1.0- r0/temp/log.do_package_qa. 44126 How can I solve this problem? Thanks in advice.2017-03-27 8:24 GMT+02:00 Praveen Kumar <praveen.kumar@xxxxxxxxxxxx>:Yes. You can copy the required files in 'do_install' task so that they get copied in the target file system.On Fri, Mar 24, 2017 at 8:45 PM, Lele <86eldnl@xxxxxxxxx> wrote:Hi Kumar,
Thanks for the support. I have been used your recipe and bitbake is working fine, but when I run bitbake of Yocto Image that includes pjsiproject (thus pjsip recipe), in the target filesystem there aren't PJSIP libraries. Should I copy some directories in do_install task? Thanks in advice
Best Regards
Ll
Da: pjsip [mailto:pjsip-bounces@xxxxxxxx
sip.org ] Per conto di Praveen Kumar
Inviato: Thursday, March 23, 2017 12:51
A: pjsip list <pjsip@xxxxxxxxxxxxxxx>
Oggetto: Re: Pjsip Recipe for Yocto
Hi Lele,
You can use the following recipe as a reference & give it a shot. Please note that I'm manually downloading the PJSIP code (rather than bitbake recipe fetch it) & placing it source code.
Also, I'm installing all the PJSIP libs & includes in my source directory itself using 'prefix' while configuring. You can customize as per you need.
DESCRIPTION = "PJ Project"
SECTION = "app"
LICENSE = ""
PR = ""
DEPENDS = "alsa-lib openssl"
inherit autotools pkgconfig
do_configure_prepend () {
export LD="${CXX}"
}
do_configure() {
cd ${TOPDIR}/../sources/meta-eliu
accs/recipes-app/pjproject-lib /pjproject-lib ./aconfigure --host=arm-poky-linux-gnueabi --disable-libwebrtc --target=arm-poky-linux-gnueab
i --prefix=${TOPDIR}/../sources/ meta-eliuaccs/recipes-app/pjpr oject-lib }
do_compile_prepend() {
cd ${TOPDIR}/../sources/meta-eliu
accs/recipes-app/pjproject-lib /pjproject-lib oe_runmake dep
oe_runmake
}
do_install() {
cd ${TOPDIR}/../sources/meta-eliu
accs/recipes-app/pjproject-lib /pjproject-lib oe_runmake install
}
do_pre_clean() {
cd ${TOPDIR}/../sources/meta-eliu
accs/recipes-app/pjproject-lib /pjproject-lib oe_runmake clean
rm -rf ${TOPDIR}/../sources/meta-eliu
accs/recipes-app/pjproject-lib /include rm -rf ${TOPDIR}/../sources/meta-eliu
accs/recipes-app/pjproject-lib /lib }
addtask do_pre_clean after do_clean
On Thu, Mar 23, 2017 at 5:06 PM, Lele <86eldnl@xxxxxxxxx> wrote:
Hi guys,
I’m trying to build and install Pjsip library on ARM target with Yocto.
I have wrote the following recipe but it’s not working properly. Yocto Image has been compiled successfully but in the destination Target there aren’t pjsip libraries (probably there is some misconfiguration on do_install task):
==============================
============================== ============================== =========
DESCRIPTION = “”
SECTION = ””
HOMEPAGE = HTTP://www.pjsip.org/
LICENSE = ””
DEPENDS = “alsa-lib libv4l openssll util-linux”
PARALLEL_MAKE = “”
SRC_URI = “ file://...”
S = “${WORKDIR}/pjproject-2.5.5”
Inherit autotools-brokensep pkgconfig pythonnative
do_configure_prepend() {
export LD= ”${CC}”
echo “export CFLAGS += -Fpic” > user.mak
echo “export LDFLAGS += -fuse-ld=bfd” > user.mak
}
do_compile_prepend() {
make dep
}
do_compile_append() {
make
}
do_install_prepend() {}
do_install_append() {
# remove the absolute path to the host’s include dir
sed -i ‘s:\-I/usr/include::’ ${D}/usr/lib/pkgconfig/libpjpr
oject.pc # remove the fdebug-prefix-map options
Sed -I ‘s:\-fdebug-prefix-map[a-Za-Z0
-9\._\/=\-]*::g’ ${D}/usr/lib/pkgconfig/libpjpr oject.pc }
ALLOW_EMPTY_${PN} = “1”
==============================
============================== ============================== =========
How can I write a recipe for a Pjsip libraries? Thanks in advice
Best Regards
Ll
_______________________________________________
Visit our blog: http://blog.pjsip.org
pjsip mailing list
pjsip@xxxxxxxxxxxxxxx
http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.or g
_______________________________________________
Visit our blog: http://blog.pjsip.org
pjsip mailing list
pjsip@xxxxxxxxxxxxxxx
http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.or g
_______________________________________________
Visit our blog: http://blog.pjsip.org
pjsip mailing list
pjsip@xxxxxxxxxxxxxxx
http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip. org
_______________________________________________
Visit our blog: http://blog.pjsip.org
pjsip mailing list
pjsip@xxxxxxxxxxxxxxx
http://lists.pjsip.org/mailman/listinfo/pjsip_lists. pjsip.org
_______________________________________________ Visit our blog: http://blog.pjsip.org pjsip mailing list pjsip@xxxxxxxxxxxxxxx http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org