#include "udiskserror.h"
#include "udisks-generated.h"
+/* For __GNUC_PREREQ usage below */
+#ifdef __GNUC__
+# include <features.h>
+#endif
+
/**
* SECTION:udisksclient
* @title: UDisksClient
(g_strcmp0 (id_type[n].version, "*") == 0 && strlen (version) > 0))
{
/* we know better than the compiler here */
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wformat-nonliteral"
+#ifdef __GNUC_PREREQ
+# if __GNUC_PREREQ(4,6)
+# pragma GCC diagnostic push
+# pragma GCC diagnostic ignored "-Wformat-nonliteral"
+# endif
+#endif
if (long_string)
ret = g_strdup_printf (g_dpgettext2 (GETTEXT_PACKAGE, "fs-type", id_type[n].long_name), version);
else
ret = g_strdup_printf (g_dpgettext2 (GETTEXT_PACKAGE, "fs-type", id_type[n].short_name), version);
goto out;
-#pragma GCC diagnostic pop
+#ifdef __GNUC_PREREQ
+# if __GNUC_PREREQ(4,6)
+# pragma GCC diagnostic pop
+# endif
+#endif
}
}
}