From 0ca506611c161bf42ecfa6dc09c25479534230b4 Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Sun, 18 Aug 2013 23:18:11 -0700 Subject: [PATCH] Fixed warnings building with gcc 2 and gcc 4 on Haiku --- include/begin_code.h | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/include/begin_code.h b/include/begin_code.h index dd1f0616d..bed798414 100644 --- a/include/begin_code.h +++ b/include/begin_code.h @@ -35,13 +35,7 @@ /* Some compilers use a special export keyword */ #ifndef DECLSPEC -# if defined(__BEOS__) || defined(__HAIKU__) -# if defined(__GNUC__) -# define DECLSPEC __declspec(dllexport) -# else -# define DECLSPEC __declspec(export) -# endif -# elif defined(__WIN32__) +# if defined(__WIN32__) # ifdef __BORLANDC__ # ifdef BUILD_SDL # define DECLSPEC @@ -54,6 +48,8 @@ # else # if defined(__GNUC__) && __GNUC__ >= 4 # define DECLSPEC __attribute__ ((visibility("default"))) +# elif defined(__GNUC__) && __GNUC__ >= 2 +# define DECLSPEC __declspec(dllexport) # else # define DECLSPEC # endif