diff options
author | Joel Kitching <kitching@google.com> | 2019-06-16 16:09:42 +0800 |
---|---|---|
committer | Julius Werner <jwerner@chromium.org> | 2019-06-24 21:15:14 +0000 |
commit | 393c71c21300a088ff5c46ea263b3b2e28084ce6 (patch) | |
tree | a7c4846871c5d43e3b3af534eec943beb8a8a27f /src/vendorcode | |
parent | 2d6ed31cbd1dfec38630df0f150c20b1e7db8de8 (diff) |
add ctype.h header
Sometimes coreboot needs to compile external code (e.g.
vboot_reference) using its own set of system header files. When
these headers don't line up with C Standard Library, it causes
problems.
Create ctype.h header file. Relocate ctype.h functions from
string.h into ctype.h. Update source files which call ctype.h
functions accordingly.
Note that ctype.h still lacks five functions which are not used
in coreboot source:
isalnum, isalpha, iscntrl, isgraph, ispunct
BUG=b:124141368
TEST=make clean && make test-abuild
BRANCH=none
Change-Id: I31b5e8af49956ec024a392a73c3c9024b9a9c194
Signed-off-by: Joel Kitching <kitching@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33525
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
Diffstat (limited to 'src/vendorcode')
-rw-r--r-- | src/vendorcode/cavium/bdk/lame_string.c | 1 | ||||
-rw-r--r-- | src/vendorcode/cavium/bdk/libdram/dram-spd.c | 1 | ||||
-rw-r--r-- | src/vendorcode/google/chromeos/vpd_mac.c | 1 |
3 files changed, 3 insertions, 0 deletions
diff --git a/src/vendorcode/cavium/bdk/lame_string.c b/src/vendorcode/cavium/bdk/lame_string.c index 11c5add209..3906ca5904 100644 --- a/src/vendorcode/cavium/bdk/lame_string.c +++ b/src/vendorcode/cavium/bdk/lame_string.c @@ -11,6 +11,7 @@ */ #include <assert.h> +#include <ctype.h> #include <string.h> #include <lame_string.h> diff --git a/src/vendorcode/cavium/bdk/libdram/dram-spd.c b/src/vendorcode/cavium/bdk/libdram/dram-spd.c index 1296119b65..84df69a923 100644 --- a/src/vendorcode/cavium/bdk/libdram/dram-spd.c +++ b/src/vendorcode/cavium/bdk/libdram/dram-spd.c @@ -44,6 +44,7 @@ #include <libbdk-hal/bdk-config.h> #include <libbdk-hal/bdk-twsi.h> #include <assert.h> +#include <ctype.h> #include <stdlib.h> #include <string.h> diff --git a/src/vendorcode/google/chromeos/vpd_mac.c b/src/vendorcode/google/chromeos/vpd_mac.c index e3ef04b669..fcd3efec9e 100644 --- a/src/vendorcode/google/chromeos/vpd_mac.c +++ b/src/vendorcode/google/chromeos/vpd_mac.c @@ -15,6 +15,7 @@ #include <boot/coreboot_tables.h> #include <console/console.h> +#include <ctype.h> #include <string.h> #include <drivers/vpd/vpd.h> |