From b1cdb2756f350ade8d5b425dec85f8207ed39a0d Mon Sep 17 00:00:00 2001 From: Francois Gouget Date: Mon, 21 Nov 2016 19:34:01 +0100 Subject: macros: Add MSVC support to SPICE_GNUC_DEPRECATED Based on the G_DEPRECATED GLib macro. For projects that don't use GLib. Signed-off-by: Francois Gouget --- spice/macros.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'spice/macros.h') diff --git a/spice/macros.h b/spice/macros.h index ae11b3c..1f8a5c8 100644 --- a/spice/macros.h +++ b/spice/macros.h @@ -82,6 +82,8 @@ #define SPICE_GNUC_DEPRECATED G_DEPRECATED #elif __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 1) #define SPICE_GNUC_DEPRECATED __attribute__((__deprecated__)) +#elif defined(_MSC_VER) && (_MSC_VER >= 1300) +#define SPICE_GNUC_DEPRECATED __declspec(deprecated) #else #define SPICE_GNUC_DEPRECATED #endif -- cgit v1.2.3