diff options
author | Emmanuele Bassi <ebassi@gnome.org> | 2017-01-24 15:31:46 +0000 |
---|---|---|
committer | Emmanuele Bassi <ebassi@gnome.org> | 2017-01-25 12:43:17 +0000 |
commit | 0625a74d69f762df8d411bc0451927424aee1f2c (patch) | |
tree | 910d4995114f4accaacaf128427b8f4d0df860e8 /include/epoxy/gl.h | |
parent | 41bea9e0fbea83654b49ea5d0f37650626003b65 (diff) | |
download | libepoxy-0625a74d69f762df8d411bc0451927424aee1f2c.tar.gz |
Add common header
We're going to use this header to provide shared macros. Right now, we
can use it to replace the:
#ifdef __cplusplus
extern "C" {
#endif
…
#ifdef __cplusplus
}
#endif
Stanzas for every installed header, with easier to read macros in the
same spirit of Cairo and GLib.
Diffstat (limited to 'include/epoxy/gl.h')
-rw-r--r-- | include/epoxy/gl.h | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/include/epoxy/gl.h b/include/epoxy/gl.h index 0be3a66..5963013 100644 --- a/include/epoxy/gl.h +++ b/include/epoxy/gl.h @@ -30,12 +30,10 @@ #ifndef EPOXY_GL_H #define EPOXY_GL_H -#ifdef __cplusplus -extern "C" { -#endif - #include <stdbool.h> +#include "epoxy/common.h" + #if defined(__gl_h_) || defined(__glext_h_) #error epoxy/gl.h must be included before (or in place of) GL/gl.h #else @@ -93,12 +91,12 @@ extern "C" { #include "epoxy/gl_generated.h" +EPOXY_BEGIN_DECLS + EPOXY_IMPORTEXPORT bool epoxy_has_gl_extension(const char *extension); EPOXY_IMPORTEXPORT bool epoxy_is_desktop_gl(void); EPOXY_IMPORTEXPORT int epoxy_gl_version(void); -#ifdef __cplusplus -} /* extern "C" */ -#endif +EPOXY_END_DECLS #endif /* EPOXY_GL_H */ |