Skip to contentSkip to conversation

Can't found the zip.h during bitbake #yocto #devtool

DISCUSSION Jaymin Dabhi 2 participants 2 messages Sep 21, 2020

lore
Share & tools
lore
#0 lore raw

Team,

I need to include zip.h header file in one of my C code (#include <zip.h>). I have created a .bb file and added following command for compilation:

Quoted 2 lines

${CC} -Wall -I/usr/include/libxml2 -o my_code my_code.c -lxml2 -lzip -lz

But, during bitbake it says:

Quoted 7 lines
| In file included from fota_update.c:1:0:
| fota_update.h:5:17: fatal error: zip.h: No such file or directory
|  #include <zip.h>
|                  ^
| compilation terminated.

Using the same compilation command, I am able to compile the code on my PC. But, can't compile with Yocto.

I have tried with lzip and zip packages by adding into local.conf, but didn't work.

Which zip package I need to use for including the zip.h header file?

#1 lore raw

Add

DEPENDS += "libzip"

in failing recipe ( .bb) file.

Quoted 24 lines · Jaymin Dabhi via lists.yoctoproject.org

Team,

I need to include zip.h header file in one of my C code (#include <zip.h>). I have created a .bb file and added following command for compilation:

${CC} -Wall -I/usr/include/libxml2 -o my_code my_code.c -lxml2 -lzip -lz

But, during bitbake it says:

| In file included from fota_update.c:1:0:
| fota_update.h:5:17: fatal error: zip.h: No such file or directory
|  #include <zip.h>
|                  ^
| compilation terminated.

Using the same compilation command, I am able to compile the code on my PC. But, can't compile with Yocto.

I have tried with lzip and zip packages by adding into local.conf, but didn't work.

Which zip package I need to use for including the zip.h header file?