Skip to content

Commit

Permalink
Fix Ubuntu builds without ASAN
Browse files Browse the repository at this point in the history
Avahi doesn't build statically
  • Loading branch information
rojer committed Jan 21, 2020
1 parent d526725 commit f268b30
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions platforms/ubuntu/Makefile.build
Original file line number Diff line number Diff line change
Expand Up @@ -66,14 +66,17 @@ CC = clang
CXX = clang++
C_CXX_FLAGS += -fsanitize=address -fno-omit-frame-pointer
LDFLAGS += -fsanitize=address
endif

ifdef MGOS_HAVE_DNS_SD
LDFLAGS += -lavahi-client -lavahi-common -lstdc++
else
LDFLAGS += -static
endif

CFLAGS = -std=gnu99 $(C_CXX_FLAGS) $(APP_CFLAGS)
CXXFLAGS = -std=gnu++11 -fno-exceptions $(C_CXX_FLAGS) $(APP_CXXFLAGS)
# TODO: Extra libs such as Avahi should be provided via external var.
LDFLAGS += -lavahi-client -lavahi-common -lstdc++
LDFLAGS += -lstdc++

INCDIRS = $(addprefix -I,$(INCLUDES))
AR ?= ar
Expand Down

0 comments on commit f268b30

Please sign in to comment.