The error, you guessed it, because the compiler cannot find the header file png.h
Can you tell me how to enable the framework? Do you use -I and -L?
The correct syntax for enabling a framework with GCC is
gcc -F * dir *
or
gcc -iframework * dir *
Hope this helps
From http://gcc.gnu.org/onlinedocs/gcc/Darwin-Options.html
-Fdir Add a directory to a directory at the top of the list of directories that will look for header files. These directories alternate with the options specified by the -I options and are scanned from left to right.
A framework directory is a directory with frameworks in it. A framework is a directory with a Headers and/or PrivateHeaders directory contained directly in it that ends in .framework. The name of a framework is the name of this directory excluding the .framework. Headers associated with the framework are found in one of those two directories, with Headers being searched first. A subframework is a framework directory that is in a framework Frameworks directory. Includes of subframework headers can only appear in a header of a framework that contains the subframework, or in a sibling subframework header. Two subframeworks are siblings if they occur in the same framework. A subframework should not have the same name as a framework, a warning will be issued if this is violated. Currently a subframework cannot have subframeworks, in the future, the mechanism may be extended to support this. The standard frameworks can be found in /System/Library/Frameworks and /Library/Frameworks. An example include looks like
Dave durbin
source share