mirror of
https://github.com/ultravioletrs/cocos.git
synced 2026-08-07 07:14:50 +00:00
feat: add patch to guard inclusion of linux/scc.h in libsanitizer for compatibility (#613)
CI / lint (push) Has been cancelled
CI / test (agent) (push) Has been cancelled
CI / test (cli) (push) Has been cancelled
CI / test (cmd) (push) Has been cancelled
CI / test (internal) (push) Has been cancelled
CI / test (manager, true) (push) Has been cancelled
CI / test (pkg) (push) Has been cancelled
CI / upload-coverage (push) Has been cancelled
CI / lint (push) Has been cancelled
CI / test (agent) (push) Has been cancelled
CI / test (cli) (push) Has been cancelled
CI / test (cmd) (push) Has been cancelled
CI / test (internal) (push) Has been cancelled
CI / test (manager, true) (push) Has been cancelled
CI / test (pkg) (push) Has been cancelled
CI / upload-coverage (push) Has been cancelled
Signed-off-by: Sammy Oina <sammyoina@gmail.com>
This commit is contained in:
committed by
GitHub
parent
22c14cb438
commit
87f2728cc4
@@ -19,6 +19,9 @@ BR2_PACKAGE_9PFS=y
|
||||
|
||||
# Image
|
||||
BR2_ROOTFS_POST_BUILD_SCRIPT="$(BR2_EXTERNAL_COCOS_PATH)/board/cocos/post-build.sh"
|
||||
|
||||
# Patches for existing Buildroot packages
|
||||
BR2_GLOBAL_PATCH_DIR="$(BR2_EXTERNAL_COCOS_PATH)/patches"
|
||||
|
||||
# Image
|
||||
BR2_ROOTFS_POST_IMAGE_SCRIPT="$(BR2_EXTERNAL_COCOS_PATH)/board/cocos/post-image.sh"
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
--- a/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cpp
|
||||
+++ b/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cpp
|
||||
@@ -151,7 +151,15 @@
|
||||
#include <linux/lp.h>
|
||||
#include <linux/mroute.h>
|
||||
#include <linux/mroute6.h>
|
||||
-#include <linux/scc.h>
|
||||
+#if defined(__has_include)
|
||||
+# if __has_include(<linux/scc.h>)
|
||||
+# include <linux/scc.h>
|
||||
+# define SANITIZER_HAS_LINUX_SCC_H 1
|
||||
+# endif
|
||||
+#else
|
||||
+# include <linux/scc.h>
|
||||
+# define SANITIZER_HAS_LINUX_SCC_H 1
|
||||
+#endif
|
||||
#include <linux/serial.h>
|
||||
#include <sys/msg.h>
|
||||
#include <sys/ipc.h>
|
||||
@@ -517,8 +525,13 @@
|
||||
unsigned struct_kbsentry_sz = sizeof(struct kbsentry);
|
||||
unsigned struct_mtconfiginfo_sz = sizeof(struct mtconfiginfo);
|
||||
unsigned struct_nr_parms_struct_sz = sizeof(struct nr_parms_struct);
|
||||
+#if SANITIZER_HAS_LINUX_SCC_H
|
||||
unsigned struct_scc_modem_sz = sizeof(struct scc_modem);
|
||||
unsigned struct_scc_stat_sz = sizeof(struct scc_stat);
|
||||
+#else
|
||||
+ unsigned struct_scc_modem_sz = 0;
|
||||
+ unsigned struct_scc_stat_sz = 0;
|
||||
+#endif
|
||||
unsigned struct_serial_multiport_struct_sz
|
||||
= sizeof(struct serial_multiport_struct);
|
||||
unsigned struct_serial_struct_sz = sizeof(struct serial_struct);
|
||||
Reference in New Issue
Block a user