From d2e63f5c74e8eaeef202d739637e9ae96264aa52 Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Mon, 2 Nov 2009 14:43:51 +0100 Subject: [PATCH] Set CC to gcc by default. On systems where cc != gcc, compilation likely fails because we are using quite some gccisms in adu. So default to gcc but let the user override the default by setting CC manually. The straight-forward CC ?= gcc does not work with gnu make as make assigns CC the default value "cc". Thanks to Steffen Schmidt for pointing out this shortcoming. --- Makefile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Makefile b/Makefile index 9a0ffb7..c61dff7 100644 --- a/Makefile +++ b/Makefile @@ -20,6 +20,9 @@ CPPFLAGS += -I/usr/local/include LDFLAGS += -L/usr/local/lib PREFIX ?= /usr/local +ifeq "$(origin CC)" "default" + CC := gcc +endif ifeq (,$(findstring BSD,$(uname_S))) -- 2.39.2