OS/2 fixes for new PNG lib

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@16104 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
David Webster
2002-07-09 05:03:37 +00:00
parent 6c0fdfbb42
commit 77aecce0a6
3 changed files with 38 additions and 20 deletions

View File

@@ -8,20 +8,20 @@ LIBTARGET=$(WXDIR)\lib\pngd.lib
!endif
OBJECTS = $D\png.obj \
$D\pngerror.obj \
$D\pngget.obj \
$D\pngmem.obj \
$D\pngpread.obj \
$D\pngread.obj \
$D\pngrio.obj \
$D\pngrtran.obj \
$D\pngrutil.obj \
$D\pngpread.obj \
$D\pngset.obj \
$D\pngtrans.obj \
$D\pngwio.obj \
$D\pngwrite.obj \
$D\pngwtran.obj \
$D\pngwutil.obj \
$D\pngerror.obj \
$D\pngmem.obj \
$D\pngwio.obj \
$D\pngrio.obj \
$D\pngget.obj \
$D\pngset.obj
$D\pngwutil.obj

View File

@@ -82,6 +82,10 @@ const int FARDATA png_pass_dsp_mask[]
#endif
#ifdef __VISAGECPP__
const char png_libpng_ver[18] = "1.2.4";
#endif
/* Tells libpng that we have already handled the first "num_bytes" bytes
* of the PNG file signature. If the PNG data is embedded into another
* stream we can set num_bytes = 8 so that libpng will not attempt to read
@@ -144,7 +148,7 @@ png_zalloc(voidpf png_ptr, uInt items, uInt size)
{
png_uint_32 num_bytes = (png_uint_32)items * size;
png_voidp ptr;
png_structp p=png_ptr;
png_structp p=(png_structp)png_ptr;
png_uint_32 save_flags=p->flags;
p->flags|=PNG_FLAG_MALLOC_NULL_MEM_OK;

View File

@@ -1228,7 +1228,7 @@ typedef z_stream FAR * png_zstreamp;
# endif
# endif /* PNG_IMPEXP */
#else /* !(DLL || non-cygwin WINDOWS) */
# if (defined(__IBMC__) || defined(IBMCPP__)) && defined(__OS2__)
# if (defined(__IBMC__) || defined(__IBMCPP__)) && defined(__OS2__)
# define PNGAPI _System
# define PNG_IMPEXP
# else
@@ -1241,6 +1241,20 @@ typedef z_stream FAR * png_zstreamp;
#endif
#endif
#if defined(__VISAGECPP__)
/* I don't compile with _System linkage, ever! */
# ifdef PNGAPI
# undef PNGAPI
# endif
# define PNGAPI _Optlink
# define PNG_IMPEXP
# define PNG_USE_LOCAL_ARRAYS
# ifdef PNG_USE_GLOBAL_ARRAYS
# undef PNG_USE_GLOBAL_ARRAYS
# endif
extern const char png_libpng_ver[18];
#endif
#ifndef PNGAPI
# define PNGAPI
#endif