From 8f9c4a78a4c8bf42b63c32917c246829836368a6 Mon Sep 17 00:00:00 2001 From: Thomas Deniau Date: Fri, 19 Jun 2009 16:34:00 +0200 Subject: [PATCH] Use $CC and $CPP if provided Let the user select the compiler he wants to use to compile Factor by using the supplied $CC and $CPP instead of just discarding them. If not present, we default to gcc and g++ (the current behaviour). --- Makefile | 4 ++-- build-support/factor.sh | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 18cb7d15c7..50cef84a21 100755 --- a/Makefile +++ b/Makefile @@ -1,5 +1,5 @@ -CC = gcc -CPP = g++ +CC ?= gcc +CPP ?= g++ AR = ar LD = ld diff --git a/build-support/factor.sh b/build-support/factor.sh index d5b8bd5411..e059a7d84f 100755 --- a/build-support/factor.sh +++ b/build-support/factor.sh @@ -97,7 +97,7 @@ set_md5sum() { set_gcc() { case $OS in openbsd) ensure_program_installed egcc; CC=egcc;; - *) CC=gcc;; + *) CC=${CC:=gcc};; esac }