I'm having problems writing png files in c using libpng.
When in my code I write:
I'm told undefined reference to `png_create_write_struct'.Code:png_ptr = png_create_write_struct(PNG_LIBPNG_VER_STRING, NULL, NULL, NULL);
I look into the png.h file and the first occurence 'png_create_write_struct' and find it in:
/* Allocate and initialize png_ptr struct for writing, and any other memory */
What is this code?? Is the function here PNG_EXPORT or PNGARG? I never saw such syntax and don't know how to read it.Code:extern PNG_EXPORT(png_structp,png_create_write_struct) PNGARG((png_const_charp user_png_ver, png_voidp error_ptr, png_error_ptr error_fn, png_error_ptr warn_fn));
Maybe it's that I'm coding in ANSI C while that is some other C incompatible syntax?