git.annexia.org
/
libguestfs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
36b236f
)
lib: Add GCC version macro to the header file.
author
Richard W.M. Jones
<rjones@redhat.com>
Tue, 17 May 2011 13:41:34 +0000
(14:41 +0100)
committer
Richard W.M. Jones
<rjones@redhat.com>
Tue, 17 May 2011 16:05:12 +0000
(17:05 +0100)
This will be used to internally enable various GCC enhancements.
generator/generator_c.ml
patch
|
blob
|
history
diff --git
a/generator/generator_c.ml
b/generator/generator_c.ml
index
777b5d9
..
4405d63
100644
(file)
--- a/
generator/generator_c.ml
+++ b/
generator/generator_c.ml
@@
-365,6
+365,11
@@
extern \"C\" {
#include <stdint.h>
#include <stdarg.h>
+#ifdef __GNUC__
+# define GUESTFS_GCC_VERSION \\
+ (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__)
+#endif
+
/* The handle. */
#ifndef GUESTFS_TYPEDEF_H
#define GUESTFS_TYPEDEF_H 1