summaryrefslogtreecommitdiffstats
path: root/scripts/compiler.h
Commit message (Collapse)AuthorAgeFilesLines
* scripts: compiler.h: include <sys/types.h>Robert Karszniewicz2020-09-211-0/+1
| | | | | | | ulong is not a standard type, so it has to be defined explicitly. Signed-off-by: Robert Karszniewicz <avoidr@posteo.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* scripts: compiler.h: support BSDs as wellAhmad Fatoum2019-05-281-3/+9
| | | | | | | | | | The BSDs have their endianness changing functions in <sys/endian.h> and define both _BYTE_ORDER as well as BYTE_ORDER (if strict POSIX conformance isn't requested). Extend the header to compile, so it supports these platforms as well. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* scripts: compiler.h: use Linux <endian.h> as defaultAhmad Fatoum2019-05-281-4/+4
| | | | | | | | | Other systems mimic the GNU endianness headers, e.g. Cygwin. Instead of explicitly listing them, just make the Linux case the default case by moving it into the #else clause. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* scripts: compiler.h: add endianness helpers for macOSAhmad Fatoum2019-05-281-1/+17
| | | | | | | | | | These are taken from Mathias Panzenböck's portable_endian.h[1] which he had released it into the public domain. [1]: https://gist.github.com/panzi/6856583 Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* scripts: compiler.h: don't include <stdint.h> twiceAhmad Fatoum2019-05-281-2/+0
| | | | | | | | We already include it a few lines further down, so drop it at this location. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* scripts/compiler.h: inline functions in headers must be staticMichael Olbrich2018-02-091-2/+2
| | | | | | | | | | | | | | | | | | Without this building bareboxenv-target with gcc 7.3 fails with: CC scripts/bareboxenv-target /tmp/cc9G2oOY.o: In function `file_action': bareboxenv.c:(.text+0x14): undefined reference to `xzalloc' /tmp/cc9G2oOY.o: In function `concat_path_file': bareboxenv.c:(.text+0xf4): undefined reference to `xmalloc' /tmp/cc9G2oOY.o: In function `envfs_save': bareboxenv.c:(.text+0x5b4): undefined reference to `xzalloc' /tmp/cc9G2oOY.o: In function `envfs_load': bareboxenv.c:(.text+0x7d8): undefined reference to `xmalloc' collect2: error: ld returned 1 exit status Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* scripts: bareboxcrc32 as host and target userspacetoolMichael Grzeschik2013-12-041-0/+25
| | | | | | | | This patch adds the crc32 command to be build as host and optionally as target tool. Signed-off-by: Michael Grzeschik <m.grzeschik@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* scripts/compiler.h: fixup endianess defines on OS XDirk Hörner2012-06-051-0/+3
| | | | | Signed-off-by: Dirk Hörner <dirker@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* host: introduce compiler.h to handle host includeJean-Christophe PLAGNIOL-VILLARD2010-09-241-0/+107
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>