]> git.cworth.org Git - apitrace/blobdiff - wrappers/trace.py
mt trace: glx: track GL context on a per-thread basis
[apitrace] / wrappers / trace.py
index 659fcd9043a4452e2ac4e132c39a237664f318b2..c838dc78a83df0e8e61190b1f30ef774b20e5ba8 100644 (file)
@@ -388,7 +388,14 @@ class Tracer:
         self.footer(api)
 
     def header(self, api):
-        pass
+        print '#ifdef _WIN32'
+        print '#  include <malloc.h> // alloca'
+        print '#  ifndef alloca'
+        print '#    define alloca _alloca'
+        print '#  endif'
+        print '#else'
+        print '#  include <alloca.h> // alloca'
+        print '#endif'
 
     def footer(self, api):
         pass