summaryrefslogtreecommitdiff
path: root/ares.h
diff options
context:
space:
mode:
authorYang Tse <yangsita@gmail.com>2009-10-29 01:02:54 (GMT)
committerYang Tse <yangsita@gmail.com>2009-10-29 01:02:54 (GMT)
commitde18bf75625f52e10c562637ca1e4edc7084e5bc (patch)
treec26422abd285893f6f8e3bf0b5cd3faaa35455aa /ares.h
parent9cac6a46259f102af306840720b3af64d4b8c12a (diff)
downloadc-ares-de18bf75625f52e10c562637ca1e4edc7084e5bc.zip
c-ares-de18bf75625f52e10c562637ca1e4edc7084e5bc.tar.gz
c-ares-de18bf75625f52e10c562637ca1e4edc7084e5bc.tar.bz2
External API function linkage decoration adjustment
Diffstat (limited to 'ares.h')
-rw-r--r--ares.h16
1 files changed, 9 insertions, 7 deletions
diff --git a/ares.h b/ares.h
index c5ff242..88805e3 100644
--- a/ares.h
+++ b/ares.h
@@ -27,8 +27,9 @@
* Define WIN32 when build target is Win32 API
*/
-#if (defined(_WIN32) || defined(__WIN32__)) && !defined(WIN32)
-#define WIN32
+#if (defined(_WIN32) || defined(__WIN32__)) && \
+ !defined(WIN32) && !defined(__SYMBIAN32__)
+# define WIN32
#endif
#include <sys/types.h>
@@ -69,19 +70,20 @@ extern "C" {
*/
#if !defined(CARES_STATICLIB) && \
- (defined(WIN32) || defined(_WIN32) || defined(__SYMBIAN32__))
+ (defined(WIN32) || defined(_WIN32) || defined(__SYMBIAN32__))
/* __declspec function decoration for Win32 and Symbian DLL's */
-# if defined(CARES_BUILDING_LIB)
+# if defined(CARES_BUILDING_LIBRARY)
# define CARES_EXTERN __declspec(dllexport)
# else
# define CARES_EXTERN __declspec(dllimport)
# endif
#else
/* visibility function decoration for other cases */
-# ifdef CARES_HIDDEN_SYMBOLS
-# define CARES_EXTERN CARES_EXTERN_SYMBOL
-# else
+# if !defined(CARES_HIDDEN_SYMBOLS) || \
+ defined(WIN32) || defined(_WIN32) || defined(__SYMBIAN32__)
# define CARES_EXTERN
+# else
+# define CARES_EXTERN CARES_EXTERN_SYMBOL
# endif
#endif