diff options
author | Stefan Reinauer <stefan.reinauer@coreboot.org> | 2015-07-04 11:28:03 -0700 |
---|---|---|
committer | Stefan Reinauer <stefan.reinauer@coreboot.org> | 2015-07-07 18:30:00 +0200 |
commit | 19ba110c2d04452553b9e07d910ccf6458be4f9b (patch) | |
tree | 72ef35de95273a99fafb720b8c314aee1b9b8bfa /util/cbfstool/flashmap | |
parent | 5e4d53e12be94e697f9f3fd6b2cd8ca87ce20c74 (diff) | |
download | coreboot-19ba110c2d04452553b9e07d910ccf6458be4f9b.tar.gz coreboot-19ba110c2d04452553b9e07d910ccf6458be4f9b.tar.bz2 coreboot-19ba110c2d04452553b9e07d910ccf6458be4f9b.zip |
cbfstool: Fix kv_pair on Windows
On Windows systems the archetype printf defaults to ms_printf
instead of gnu_printf. Keep the archetype print for all non-
Windows compiles to not break compatibility with other systems
out there.
Change-Id: Iad8441f4dc814366176646f6a7a5df653fda4c15
Signed-off-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Signed-off-by: Scott Duplichan <scott@notabs.org>
Reviewed-on: http://review.coreboot.org/10793
Tested-by: build bot (Jenkins)
Diffstat (limited to 'util/cbfstool/flashmap')
-rw-r--r-- | util/cbfstool/flashmap/kv_pair.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/util/cbfstool/flashmap/kv_pair.h b/util/cbfstool/flashmap/kv_pair.h index 7024dd306177..1185a08d5259 100644 --- a/util/cbfstool/flashmap/kv_pair.h +++ b/util/cbfstool/flashmap/kv_pair.h @@ -108,7 +108,11 @@ extern struct kv_pair *kv_pair_add_bool(struct kv_pair *kv_list, */ extern struct kv_pair *kv_pair_fmt(struct kv_pair *kv_list, const char *kv_key, const char *format, ...) +#if defined(_WIN32) || (_WIN64) + __attribute__((format(gnu_printf, 3, 4))); +#else __attribute__((format(printf, 3, 4))); +#endif /* * kv_pair_free - clean a key=value pair list |