use -fno-strict-aliasing only on those architectures which complain

This commit is contained in:
2023-02-27 15:23:02 +01:00
parent d5988446c6
commit 92a461fbd9
4 changed files with 7 additions and 2 deletions

View File

@ -23,3 +23,6 @@ ARCH_DEP_LDFLAGS += -Wl,-rpath-link,$(ELDK)/$(GNU_TARGET)/usr/lib
# have no C++11
STD_CXXFLAGS =
# suppress strict alias warnings
CODE_CPPFLAGS += -fno-strict-aliasing

View File

@ -18,6 +18,9 @@ ARCH_DEP_CFLAGS += -funwind-tables
# have no full C++11
STD_CXXFLAGS = -std=c++0x
# suppress strict alias warnings
CODE_CPPFLAGS += -fno-strict-aliasing
# accept4() exists but does not work
# Give fake __rtems__ macro to posix/osdSock.c because that disables accept4()
osdSock_CFLAGS += -D__rtems__

View File

@ -9,7 +9,7 @@
# CONFIG_SITE.<linux-arch>.<linux-arch>
COMMANDLINE_LIBRARY = READLINE
CODE_CPPFLAGS += -fno-strict-aliasing
USR_CXXFLAGS += $(STD_CXXFLAGS)
STD_CXXFLAGS = -std=c++11

View File

@ -68,7 +68,6 @@ GNU_DIR_7 = $(WIND_BASE)/compilers/gnu-$(VX_GNU_VERSION)/$(WIND_HOST_TYPE)
GNU_DIR = $(GNU_DIR_$(VXWORKS_MAJOR_VERSION))
# Operating system flags
OP_SYS_CFLAGS += -fno-strict-aliasing
OP_SYS_INCLUDE_CPPFLAGS_5 += -include $(VX_DIR)/target/h/vxWorks.h
OP_SYS_INCLUDE_CPPFLAGS_5 += -I$(EPICS_BASE)/include/os/vxWorks/vxWorks5