aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/libgamma-error.h4
-rw-r--r--src/lib/libgamma-facade.h8
2 files changed, 10 insertions, 2 deletions
diff --git a/src/lib/libgamma-error.h b/src/lib/libgamma-error.h
index 456560c..3a562ee 100644
--- a/src/lib/libgamma-error.h
+++ b/src/lib/libgamma-error.h
@@ -23,12 +23,12 @@
#endif
+#include <sys/types.h>
+
#ifndef __GCC__
# define __attribute__(x)
#endif
-#include <sys/types.h>
-
/**
* Group that the user needs to be a member of if
diff --git a/src/lib/libgamma-facade.h b/src/lib/libgamma-facade.h
index 343114c..a24c0e0 100644
--- a/src/lib/libgamma-facade.h
+++ b/src/lib/libgamma-facade.h
@@ -28,6 +28,10 @@
#include <stddef.h>
#include <stdint.h>
+#ifndef __GCC__
+# define __attribute__(x)
+#endif
+
/**
@@ -565,5 +569,9 @@ int libgamma_crtc_set_gamma_rampsd_f(libgamma_crtc_state_t* restrict this,
libgamma_gamma_rampsd_fun* blue_function) __attribute__((cold));
+#ifndef __GCC__
+# undef __attribute__
+#endif
+
#endif