[coreboot-gerrit] Change in coreboot[master]: util/cbfstool/compiler: __attribute redefinition
Frans Hendriks (Code Review)
gerrit at coreboot.org
Thu Jul 5 12:27:16 CEST 2018
Frans Hendriks has uploaded this change for review. ( https://review.coreboot.org/27357
Change subject: util/cbfstool/compiler: __attribute redefinition
......................................................................
util/cbfstool/compiler: __attribute redefinition
In Windows Cygwin enviroment, compiler reports
redefinition error at cbfstool/ifwitool.c
on _packed and __aligned.
Skip new defines when vales are already defined.
Change-Id: I3af3c6b8fc57eee345afcef2f871b897138f78ce
Signed-off-by: Frans Hendriks <fhendriks at eltan.com>
---
M util/cbfstool/compiler.h
1 file changed, 5 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/57/27357/1
diff --git a/util/cbfstool/compiler.h b/util/cbfstool/compiler.h
index fc6a36b..cf043d5 100644
--- a/util/cbfstool/compiler.h
+++ b/util/cbfstool/compiler.h
@@ -2,6 +2,7 @@
* This file is part of the coreboot project.
*
* Copyright 2017 Google Inc.
+ * Copyright (c) 2017-2018 Eltan B.V.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -18,14 +19,18 @@
#if !defined(__FreeBSD__)
+#if !defined(__packed)
#if defined(__WIN32) || defined(__WIN64)
#define __packed __attribute__((gcc_struct, packed))
#else
#define __packed __attribute__((packed))
#endif
+#endif
+#if !defined(__aligned)
#define __aligned(x) __attribute__((aligned(x)))
#endif
+#endif
#define __always_unused __attribute__((unused))
#define __must_check __attribute__((warn_unused_result))
--
To view, visit https://review.coreboot.org/27357
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I3af3c6b8fc57eee345afcef2f871b897138f78ce
Gerrit-Change-Number: 27357
Gerrit-PatchSet: 1
Gerrit-Owner: Frans Hendriks <fhendriks at eltan.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.coreboot.org/pipermail/coreboot-gerrit/attachments/20180705/fb88138f/attachment-0001.html>
More information about the coreboot-gerrit
mailing list