Skip to content

Commit cd1657d

Browse files
committed
newlib: Make configure host consistent for all arch's
Add a zephyr case to newlib/configure.host so we get the same config on all arch's. Fix the fact that some arch's like x86 were getting -DMISSING_SYSCALL_NAMES set in newlib which we don't want. Fixes: #221 Signed-off-by: Kumar Gala <[email protected]>
1 parent 887cce0 commit cd1657d

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
From 2599d2e1016beeb8dcfe691940acc334bdc6eb24 Mon Sep 17 00:00:00 2001
2+
From: Kumar Gala <[email protected]>
3+
Date: Thu, 21 May 2020 22:55:16 -0500
4+
Subject: [PATCH] newlib/configure.host: Add host config for zephyr
5+
6+
Add zephyr specific host config so that all arch toolchain variants we
7+
build for zephyr behave the same way. (otherwise we end up getting
8+
-DMISSING_SYSCALL_NAMES set on some arch's like NIOS and x86, but not on
9+
others).
10+
11+
Signed-off-by: Kumar Gala <[email protected]>
12+
---
13+
newlib/configure.host | 11 +++++++++++
14+
1 file changed, 11 insertions(+)
15+
16+
diff --git a/newlib/configure.host b/newlib/configure.host
17+
index 37d2b9b2e..77e855e85 100644
18+
--- a/newlib/configure.host
19+
+++ b/newlib/configure.host
20+
@@ -665,6 +665,17 @@ newlib_cflags="${newlib_cflags} -DCLOCK_PROVIDED -DMALLOC_PROVIDED -DEXIT_PROVID
21+
*-*-tirtos*)
22+
newlib_cflags="${newlib_cflags} -D__DYNAMIC_REENT__ -DMALLOC_PROVIDED"
23+
;;
24+
+ *-zephyr-*)
25+
+ syscall_dir=syscalls
26+
+ case "${host}" in
27+
+ arm*-*-*)
28+
+ if [ "x${newlib_may_supply_syscalls}" = "xyes" ] ; then
29+
+ newlib_cflags="${newlib_cflags} -DARM_RDI_MONITOR"
30+
+ fi
31+
+ ;;
32+
+ *)
33+
+ esac
34+
+ ;;
35+
# UDI doesn't have exec, so system() should fail the right way
36+
a29k-amd-udi)
37+
newlib_cflags="${newlib_cflags} -DNO_EXEC"
38+
--
39+
2.25.4
40+

0 commit comments

Comments
 (0)