summaryrefslogtreecommitdiffstats
path: root/meta/recipes-bsp/u-boot/files/0001-Include-cstddef-in-the-header-for-C.patch
blob: 9a006e2cfdcdf5c65c5f8c49c9ec87f385abcc07 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
From 10c9a571f1c0472799f72b1924b039aab231e95f Mon Sep 17 00:00:00 2001
From: Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>
Date: Thu, 16 Dec 2021 16:19:50 +0100
Subject: [PATCH] Include cstddef in the header for C++

So C++ compiler always has access to the definition of size_t.

Signed-off-by: Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>
Signed-off-by: Youngseok Jeong <youngseok1.jeong@lge.com>
Upstream-Status: Backport [v0.3.3 https://github.com/sbabic/libubootenv/pull/19/commits/764226a7de2ea79b182d92829922489537c766fa]
---
 src/libuboot.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/libuboot.h b/src/libuboot.h
index 88f0558..1f305f4 100644
--- a/src/libuboot.h
+++ b/src/libuboot.h
@@ -6,6 +6,8 @@
  */
 
 #ifdef __cplusplus
+#include <cstddef>
+
 extern "C" {
 #endif