You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by ya...@apache.org on 2021/12/09 07:57:29 UTC

[incubator-nuttx] 01/02: Revert "sim: Specify -fshort-wchar as NuttX wchar_t is 16-bit"

This is an automated email from the ASF dual-hosted git repository.

yamamoto pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git

commit 334bb9768a0815087acf5721dfee18520ba5604c
Author: Xiang Xiao <xi...@xiaomi.com>
AuthorDate: Mon Nov 1 01:40:48 2021 +0800

    Revert "sim: Specify -fshort-wchar as NuttX wchar_t is 16-bit"
    
    It's better to apply the default compiler option to improve the compatibility
    This reverts commit 3fc06ff2d145adc0fc3e46306e3a9886fa436ed8.
---
 boards/sim/sim/sim/scripts/Make.defs | 11 +++--------
 1 file changed, 3 insertions(+), 8 deletions(-)

diff --git a/boards/sim/sim/sim/scripts/Make.defs b/boards/sim/sim/sim/scripts/Make.defs
index 586ed24..be3fc1f 100644
--- a/boards/sim/sim/sim/scripts/Make.defs
+++ b/boards/sim/sim/sim/scripts/Make.defs
@@ -95,16 +95,11 @@ NM = $(CROSSDEV)nm
 OBJCOPY = $(CROSSDEV)objcopy
 OBJDUMP = $(CROSSDEV)objdump
 
-# Note: -fshort-wchar for the case where NuttX and the host OS have
-# different wchar_t. On NuttX, it's uint16_t. On macOS, it's 32-bit.
 CFLAGS := $(ARCHWARNINGS) $(ARCHOPTIMIZATION) \
-   $(ARCHCPUFLAGS) $(ARCHINCLUDES) $(ARCHDEFINES) $(EXTRAFLAGS) -pipe \
-   -fshort-wchar
+   $(ARCHCPUFLAGS) $(ARCHINCLUDES) $(ARCHDEFINES) $(EXTRAFLAGS) -pipe
 CXXFLAGS := $(ARCHWARNINGSXX) $(ARCHOPTIMIZATION) \
-   $(ARCHCPUFLAGSXX) $(ARCHXXINCLUDES) $(ARCHDEFINES) $(EXTRAFLAGS) -pipe \
-   -fshort-wchar
-CPPFLAGS := $(ARCHINCLUDES) $(ARCHDEFINES) $(EXTRAFLAGS) \
-   -fshort-wchar
+   $(ARCHCPUFLAGSXX) $(ARCHXXINCLUDES) $(ARCHDEFINES) $(EXTRAFLAGS) -pipe
+CPPFLAGS := $(ARCHINCLUDES) $(ARCHDEFINES) $(EXTRAFLAGS)
 AFLAGS := $(CFLAGS) -D__ASSEMBLY__
 
 ifeq ($(CONFIG_LIBCXX),y)