Merge pull request #130 from barrybingo/master

Make names visible when using gcc/clang
This commit is contained in:
Victor Bombi
2020-04-20 14:58:34 +02:00
committed by GitHub
3 changed files with 15 additions and 3 deletions

View File

@@ -14,9 +14,13 @@
#ifndef __GNUC__ #ifndef __GNUC__
#define snprintf sprintf_s #define snprintf sprintf_s
#endif #endif
#else
#ifdef __GNUC__
#define API __attribute__((__visibility__("default")))
#else #else
#define API #define API
#endif #endif
#endif
#if defined __cplusplus #if defined __cplusplus
#define EXTERN extern "C" #define EXTERN extern "C"

View File

@@ -11,9 +11,13 @@
#ifndef __GNUC__ #ifndef __GNUC__
#define snprintf sprintf_s #define snprintf sprintf_s
#endif #endif
#else
#ifdef __GNUC__
#define API __attribute__((__visibility__("default")))
#else #else
#define API #define API
#endif #endif
#endif
#if defined __cplusplus #if defined __cplusplus
#define EXTERN extern "C" #define EXTERN extern "C"

View File

@@ -14,9 +14,13 @@
#ifndef __GNUC__ #ifndef __GNUC__
#define snprintf sprintf_s #define snprintf sprintf_s
#endif #endif
#else
#ifdef __GNUC__
#define API __attribute__((__visibility__("default")))
#else #else
#define API #define API
#endif #endif
#endif
#if defined __cplusplus #if defined __cplusplus
#define EXTERN extern "C" #define EXTERN extern "C"