From bc025530248c52e31a629b2a8943b2f68e919caa Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Mon, 2 Nov 2009 14:39:16 +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 osl. 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 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index ef12cb8..76925a6 100644 --- a/Makefile +++ b/Makefile @@ -12,7 +12,9 @@ executables := oslfsck man_pages := oslfsck.1 INSTALL := install -CC := gcc +ifeq "$(origin CC)" "default" + CC := gcc +endif MKDIR := mkdir -p RM := rm -f LN := ln -- 2.39.5