HAL_SITL: Fixing SITL build for OSX.
This commit is contained in:
parent
a694b781c7
commit
bb2a6b8a22
@ -33,6 +33,14 @@ using namespace AVR_SITL;
|
||||
|
||||
#define LISTEN_BASE_PORT 5760
|
||||
|
||||
// On OSX, MSG_NOSIGNAL doesn't exist. The equivalent is to set SO_NOSIGPIPE
|
||||
// in setsockopt for the socket. However, if we just skip that, and don't use
|
||||
// MSG_NOSIGNAL, everything seems to work fine and SIGPIPE doesn't seem to be
|
||||
// generated.
|
||||
#ifndef MSG_NOSIGNAL
|
||||
#define MSG_NOSIGNAL 0
|
||||
#endif
|
||||
|
||||
bool SITLUARTDriver::_console;
|
||||
|
||||
/* UARTDriver method implementations */
|
||||
|
@ -18,7 +18,10 @@ CXXOPTS = -ffunction-sections -fdata-sections -fno-exceptions -fsigned
|
||||
COPTS = -ffunction-sections -fdata-sections -fsigned-char
|
||||
|
||||
ASOPTS = -x assembler-with-cpp
|
||||
|
||||
ifneq ($(SYSTYPE),Darwin)
|
||||
LISTOPTS = -adhlns=$(@:.o=.lst)
|
||||
endif
|
||||
|
||||
CPUFLAGS = -D_GNU_SOURCE
|
||||
CPULDFLAGS = -g
|
||||
@ -31,7 +34,10 @@ CFLAGS += $(WARNFLAGS) $(DEPFLAGS) $(COPTS)
|
||||
ASFLAGS = -g $(CPUFLAGS) $(DEFINES) -Wa,$(LISTOPTS) $(DEPFLAGS)
|
||||
ASFLAGS += $(ASOPTS)
|
||||
LDFLAGS = -g $(CPUFLAGS) $(OPTFLAGS) $(WARNFLAGS)
|
||||
|
||||
ifneq ($(SYSTYPE),Darwin)
|
||||
LDFLAGS += -Wl,--gc-sections -Wl,-Map -Wl,$(SKETCHMAP)
|
||||
endif
|
||||
|
||||
LIBS = -lm
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user