summaryrefslogtreecommitdiffstats
path: root/src/mesa/glapi
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/glapi')
-rw-r--r--src/mesa/glapi/glX_proto_size.py6
-rw-r--r--src/mesa/glapi/gl_XML.py4
2 files changed, 8 insertions, 2 deletions
diff --git a/src/mesa/glapi/glX_proto_size.py b/src/mesa/glapi/glX_proto_size.py
index d4c8b553e41..63d80dd74c7 100644
--- a/src/mesa/glapi/glX_proto_size.py
+++ b/src/mesa/glapi/glX_proto_size.py
@@ -320,6 +320,9 @@ class PrintGlxSizeStubs_c(PrintGlxSizeStubs_common):
self.printVisibility( "INTERNAL", "internal" )
print ''
print ''
+ print '#if defined(__CYGWIN__) || defined(__MINGW32__)'
+ print '# undef HAVE_ALIAS'
+ print '#endif'
print '#ifdef HAVE_ALIAS'
print '# define ALIAS2(from,to) \\'
print ' INTERNAL PURE FASTCALL GLint __gl ## from ## _size( GLenum e ) \\'
@@ -435,6 +438,9 @@ class PrintGlxReqSize_c(PrintGlxReqSize_common):
print ''
print '#define __GLX_PAD(x) (((x) + 3) & ~3)'
print ''
+ print '#if defined(__CYGWIN__) || defined(__MINGW32__)'
+ print '# undef HAVE_ALIAS'
+ print '#endif'
print '#ifdef HAVE_ALIAS'
print '# define ALIAS2(from,to) \\'
print ' GLint __glX ## from ## ReqSize( const GLbyte * pc, Bool swap ) \\'
diff --git a/src/mesa/glapi/gl_XML.py b/src/mesa/glapi/gl_XML.py
index 3b87b724ab6..808a0a474e7 100644
--- a/src/mesa/glapi/gl_XML.py
+++ b/src/mesa/glapi/gl_XML.py
@@ -194,7 +194,7 @@ class gl_print_base:
"""
self.undef_list.append("FASTCALL")
- print """# if defined(__i386__) && defined(__GNUC__)
+ print """# if defined(__i386__) && defined(__GNUC__) && !defined(__CYGWIN__) && !defined(__MINGW32__)
# define FASTCALL __attribute__((fastcall))
# else
# define FASTCALL
@@ -214,7 +214,7 @@ class gl_print_base:
"""
self.undef_list.append(S)
- print """# if __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 3)
+ print """# if (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 3)) && !defined(__CYGWIN__) && !defined(__MINGW32__)
# define %s __attribute__((visibility("%s")))
# else
# define %s