1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-09 23:34:20 +00:00

Removed some extern "C" declarations from libpng

This commit is contained in:
Tom Poole 2019-06-28 15:34:16 +01:00
parent 5935040d78
commit 0e00e83944
4 changed files with 23 additions and 17 deletions

View file

@ -271,8 +271,8 @@ namespace pnglibNamespace
#define PNG_sCAL_PRECISION 5
#define PNG_sRGB_PROFILE_CHECKS 2
#define PNG_LINKAGE_API inline
#define PNG_LINKAGE_FUNCTION inline
#define PNG_LINKAGE_API
#define PNG_LINKAGE_FUNCTION
#define PNG_ARM_NEON_OPT 0

View file

@ -1,2 +1,4 @@
These files are from the libpng library - http://www.libpng.org/
We have removed all `extern "C"` from the library to prevent symbol collision
with projects that use their own version of libpng.

View file

@ -363,10 +363,11 @@
#ifndef PNG_VERSION_INFO_ONLY
/* Inhibit C++ name-mangling for libpng functions but not for system calls. */
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */
// JUCE modification
///* Inhibit C++ name-mangling for libpng functions but not for system calls. */
//#ifdef __cplusplus
//extern "C" {
//#endif /* __cplusplus */
/* Version information for C files, stored in png.c. This had better match
* the version above.
@ -3238,9 +3239,10 @@ PNG_EXPORT(244, int, png_set_option, (png_structrp png_ptr, int option,
PNG_EXPORT_LAST_ORDINAL(249);
#endif
#ifdef __cplusplus
}
#endif
// JUCE modification
//#ifdef __cplusplus
//}
//#endif
#endif /* PNG_VERSION_INFO_ONLY */
/* Do not put anything past this line */

View file

@ -958,10 +958,11 @@ PNG_INTERNAL_DATA(const png_byte, png_sRGB_delta, [512]);
#endif /* SIMPLIFIED_READ/WRITE */
/* Inhibit C++ name-mangling for libpng functions but not for system calls. */
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */
// JUCE modification
///* Inhibit C++ name-mangling for libpng functions but not for system calls. */
//#ifdef __cplusplus
//extern "C" {
//#endif /* __cplusplus */
/* Internal functions; these are not exported from a DLL however because they
* are used within several of the C source files they have to be C extern.
@ -2144,9 +2145,10 @@ PNG_INTERNAL_FUNCTION(int,
#include "pngdebug.h"
#ifdef __cplusplus
}
#endif
// JUCE modification
//#ifdef __cplusplus
//}
//#endif
#endif /* PNG_VERSION_INFO_ONLY */
#endif /* PNGPRIV_H */