diff options
Diffstat (limited to 'compiler.h')
-rw-r--r-- | compiler.h | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/compiler.h b/compiler.h new file mode 100644 index 0000000..0e59f52 --- /dev/null +++ b/compiler.h @@ -0,0 +1,36 @@ +/* ----------------------------------------------------------------------- * + * + * Copyright 2007 The NASM Authors - All Rights Reserved + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the license given in the file "License" + * distributed in the NASM archive. + * + * ----------------------------------------------------------------------- */ + +/* + * compiler.h + * + * Compiler-specific macros for NASM. Feel free to add support for + * other compilers in here. + */ + +#ifndef COMPILER_H +#define COMPILER_H + +#ifdef __GNUC__ +# if __GNUC__ >= 4 +# define HAVE_GNUC_4 +# endif +# if __GNUC__ >= 3 +# define HAVE_GNUC_3 +# endif +#endif + +#ifdef __GNUC__ +# define _unused __attribute__((unused)) +#else +# define _unused +#endif + +#endif |