From 6b419277aaafd9e48ec89bb8fbad81a8340dfc9c Mon Sep 17 00:00:00 2001 From: Jakub Date: Wed, 12 Oct 2022 17:28:34 +0200 Subject: [PATCH] hardcode CC to gcc for windows (#52) Windows doesn't have a `cc` symlnk and this results in build failure: ``` C compiler (cc) not installed. Aborting. ``` Because `?=` operator treats `CC` as already set, since it defaults to `cc`: https://www.gnu.org/software/make/manual/make.html#Implicit-Variables --- makefiles/variables.mk | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/makefiles/variables.mk b/makefiles/variables.mk index 963f5f4..229e4a5 100644 --- a/makefiles/variables.mk +++ b/makefiles/variables.mk @@ -7,7 +7,12 @@ SHELL := bash # the shell used internally by "make" +# Windows does not symlink cc to gcc +ifeq ($(OS), Windows_NT) +CC := gcc +else CC ?= gcc +endif LD := $(CC) #- extra parameters for the Nim compiler