diff --git a/src/celengine/astro.cpp b/src/celengine/astro.cpp index 8679fa662..6f448d845 100644 --- a/src/celengine/astro.cpp +++ b/src/celengine/astro.cpp @@ -16,7 +16,10 @@ #include "celestia.h" #include "astro.h" #include + +#ifdef __GNUC__ #include +#endif using namespace std; @@ -442,9 +445,11 @@ astro::Date::Date(double jd) tzname = "UTC"; } +#ifdef __GNUC__ bool astro::Date::utf8Locale = false; bool astro::Date::utf8LocaleSet = false; iconv_t astro::Date::utf8Iconv; +#endif const char* astro::Date::toCStr(Format format) const { diff --git a/src/celengine/astro.h b/src/celengine/astro.h index 0325c7ed0..13f3fcc83 100644 --- a/src/celengine/astro.h +++ b/src/celengine/astro.h @@ -15,7 +15,10 @@ #include #include #include + +#ifdef __GNUC__ #include +#endif #define SOLAR_ABSMAG 4.83f #define LN_MAG 1.085736 @@ -58,11 +61,13 @@ namespace astro std::string tzname; // timezone name double seconds; +#ifdef __GNUC__ private: // Static members used to store locale related UTF-8 information static bool utf8Locale; static bool utf8LocaleSet; static iconv_t utf8Iconv; +#endif }; bool parseDate(const std::string&, Date&);