Add #define guard to allow MingW to build PDFio; note that MingW is NOT a supported toolchain for PDFio (Issue #66)

This commit is contained in:
Michael R Sweet 2024-06-24 09:03:46 -04:00
parent 23883268e3
commit f040cc41c2
No known key found for this signature in database
GPG Key ID: BE67C75EC81F3244
2 changed files with 7 additions and 3 deletions

View File

@ -8,6 +8,8 @@ v1.3.0 (Month DD, YYYY)
- Added `pdfioFileGetCatalog` API for accessing the root/catalog object of a - Added `pdfioFileGetCatalog` API for accessing the root/catalog object of a
PDF file (Issue #67) PDF file (Issue #67)
- Updated number support to avoid locale issues (Issue #61) - Updated number support to avoid locale issues (Issue #61)
- Updated the PDFio private header to allow compilation with MingW; note that
MingW is NOT a supported toolchain for PDFio (Issue #66)
- Optimized string pool code. - Optimized string pool code.

View File

@ -38,9 +38,11 @@
# define unlink _unlink # define unlink _unlink
# define vsnprintf _vsnprintf # define vsnprintf _vsnprintf
# define write _write # define write _write
# ifndef F_OK
# define F_OK 00 // POSIX parameters/flags # define F_OK 00 // POSIX parameters/flags
# define W_OK 02 # define W_OK 02
# define R_OK 04 # define R_OK 04
# endif // !F_OK
# define O_RDONLY _O_RDONLY // Map standard POSIX open flags # define O_RDONLY _O_RDONLY // Map standard POSIX open flags
# define O_WRONLY _O_WRONLY # define O_WRONLY _O_WRONLY
# define O_CREAT _O_CREAT # define O_CREAT _O_CREAT