Makefile.contiki: Added -Os to remove undefined symbol

handle_periodic_timer() in rpl-timers.c relies on the optimizer to
remove the if(0)-guarded call to rpl_ns_periodic() when storing
mode is selected. This does not happen with clang's default options
and thus leads to an error for the undefined reference at link time.

This modification adds -Os to fix this.
This commit is contained in:
Olaf Bergmann committed 2016-06-10 16:41:53 +02:00
1 parent 68d910f4fe
commit 392deff2d7
1 file changed
+1 -1
+1 -1
View File
@@ -23,7 +23,7 @@ endif
all: server
CFLAGS += -ffunction-sections
CFLAGS += -Os -ffunction-sections
LDFLAGS += -Wl,--gc-sections,--undefined=_reset_vector__,--undefined=InterruptVectors,--undefined=_copy_data_init__,--undefined=_clear_bss_init__,--undefined=_end_of_init__
CFLAGS += #-DSHORT_ERROR_RESPONSE -DNDEBUG