Imagination PowerVR SDK Blog

User a C compiler with PowerVR libraries



I am trying to use the PowerVR lib and includes in a C project. I am getting compiler errors where the same code compiles and runs under C++.

Any ideas,




Hi Jim,

When you say PowerVR lib, are you referring to a graphics driver (e.g. OpenGL ES 2.0) on a target platform or are you referring to one of the deliverables in our SDK (e.g. the SDK framework or PVRTexLib)?

Can you share some more information about your development OS, IDE/makefile set-up, target hardware, target OS and graphics API version (if applicable)?



Hello Joe,

I am developing on a Mac for the BeagleBone Black using the Eclipse IDE. I am using OpenGL ES v1 because it is the closest to OpenGL SC. Because the code is a safety critical software stack it was written in C and not C++. I used the HelloAPI sample source in a C++ Eclipse project that I created and it compiled and ran on the Be agleBone Black. Doing the same for a C Eclipse project failed to compile even though I set up the includes and libs the same. Just knowing that the libs are build for C++ and C is probably enough for me the figure out my problem.


Hi Jim,

Our OpenGL ES reference driver and associated unit tests are written in C, so you shouldn’t have any problems linking with the driver from your C project.

All of our SDK examples are written in C++. We’ve never tried to compile the HelloAPI example as C. You may have to make some changes to it to make it compile correctly.