Rename __attribute__((packed)) --> __packed
[coreboot.git] / util / cbfstool / compiler.h
blobf218725086e09baed3df0c3cb31f61e6e4a61b0c
1 /*
2 * This file is part of the coreboot project.
4 * Copyright 2017 Google Inc.
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; version 2 of the License.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
16 #ifndef __COMPILER_H__
17 #define __COMPILER_H__
19 #if defined(__WIN32) || defined(__WIN64)
20 #define __packed __attribute__((gcc_struct, packed))
21 #else
22 #define __packed __attribute__((packed))
23 #endif
25 #define __aligned(x) __attribute__((aligned(x)))
26 #define __always_unused __attribute__((unused))
28 #endif