ipu.h typedef error

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

ipu.h typedef error

666 Views
chrisroed
Contributor IV

I'm using the latest yocto (2.4) and I built an x11 image.  I've been adding my own library recipes and I'm running into some issues.

The library I'm using includes <linux/ipu.h>, but when I go to compile, the compiler complains

/recipe-sysroot/usr/include/bits/stdint-uintn.h:24:19: error: two or more data types in declaration specifiers
| typedef __uint8_t uint8_t;

recipe-sysroot/usr/include/bits/stdint-uintn.h:25:20: error: two or more data types in declaration specifiers
| typedef __uint16_t uint16_t;

recipe-sysroot/usr/include/bits/stdint-uintn.h:26:20: error: two or more data types in declaration specifiers
| typedef __uint32_t uint32_t;

Now... I know what the issue is...  The first few lines of ipu.h has 

#define uint32_t unsigned int
#define uint16_t unsigned short
#define uint8_t unsigned char

These typedefs are obviously conflicting with the stdint-uintn.h typedefs.

In my old dev system I would just go into the root file system and comment out those lines, but now that I'm compiling with yocto this has become an issue...

Since I have a custom kernel, I can change the file in the kernel source, or patch it in the linux-libc-headers recipe, but it seems to me there is a reason those #define statements are there, and how other developers have gotten around this problem when developing with the ipu

EDIT:  I used the patch method.  I've attached the patch, which should be placed in the recipes-kernel/linux-libc-headers/files folder and included in the linux-libc-headers_4.9.bb SRC_URI_append section

Labels (4)
Tags (2)
0 Kudos
1 Reply

518 Views
gusarambula
NXP TechSupport
NXP TechSupport

Hello Chris Roed,

As you mentioned, you could write a patch that delete the statements that are causing trouble. As for the reason behind those statements I’m afraid I couldn’t find anything in the documentation.

It is my understanding that you are using the Community BSP? It seems that these declarations are not on the ipu.h that are part of the NXP BSP Release.

Regards,

0 Kudos