1 #ifndef _WIMLIB_COMPILER_H
2 #define _WIMLIB_COMPILER_H
5 # if defined(__CYGWIN__) || defined(__WIN32__)
6 # define WIMLIBAPI __declspec(dllexport)
8 # define WIMLIBAPI __attribute__((visibility("default")))
10 # define ALWAYS_INLINE inline __attribute__((always_inline))
11 # define PACKED __attribute__((packed))
12 # define FORMAT(type, format_str, args_start) \
13 /*__attribute__((format(type, format_str, args_start))) */
14 # if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4)
15 # define COLD __attribute__((cold))
21 # define ALWAYS_INLINE inline
22 # define FORMAT(type, format_str, args_start)
27 #endif /* _WIMLIB_COMPILER_H */