Why am I having a compatibility version using libpng with Xcode?

I am having problems using libpng with Xcode 4.2 on OS X 10.7.1.

My program does not start with an error:

dyld: Library not loaded: /usr/X11/lib/libpng15.15.dylib 

and

 Reason: Incompatible library version: glsl_test requires version 20.0.0 or later, but libpng15.15.dylib provides version 17.0.0 

All I do is add /usr/X11/libpng.dylib to the linked libraries, so where does this "version 20" requirement come from? Why doesn't Xcode just require the version available? How do I tell my program that it is normal to use version 17?

+4
source share
1 answer

Unaware of the intricacies of Xcode, it sounds like something else in your program, requiring a later version of the libpng library. It could even be something that is implicitly included in the build environment.

I would double check that you have a build environment compatible with your target. I also double-checked that you specify the inclusion of the library using the appropriate syntax (for example, using -lpng against the explicit "/usr/X11/libpng.dylib").

0
source

All Articles