From bb01da2d4df4a356bc766164fdcb6b5431bef004 Mon Sep 17 00:00:00 2001 From: Paul Roukema <roukemap@gmail.com> Date: 周三, 05 9月 2018 23:40:26 +0800 Subject: [PATCH] Fix undefined macro warnings for embedded targets Embedded targets may not define e.g. _BSD_SOURCE. Check if these are defined before using their values Also make sure that intenal macros are always defined --- libscpi/Makefile | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) diff --git a/libscpi/Makefile b/libscpi/Makefile index b1e95cb..9a0b5ee 100644 --- a/libscpi/Makefile +++ b/libscpi/Makefile @@ -1,10 +1,9 @@ VERSION = 2.1.0 LIBNAME = scpi -CFLAGS += -std=c99 CFLAGS += -Wextra -Wmissing-prototypes -Wimplicit -Iinc CFLAGS_SHARED += $(CFLAGS) -fPIC -LDFLAGS += -Wl,--as-needed +LDFLAGS += -lm -Wl,--as-needed #TESTCFLAGS += $(CFLAGS) `pkg-config --cflags cunit` #TESTLDFLAGS += $(LDFLAGS) `pkg-config --libs cunit` TESTCFLAGS += $(CFLAGS) -- Gitblit v1.9.1