changeset 271:f6acfc659dd9

Allow overriding CC, AR, and RANLIB from the environment Rather than unconditionally setting CC, AR, and RANLIB, allow the environment to override them. This is useful in more circumstances than just cross-compiling. Thanks to Tormod Volden <debian.tormod@gmail.com> for bringing this to my notice though his original suggestion was different.
author William Astle <lost@l-w.ca>
date Sun, 07 Apr 2013 01:29:29 -0600
parents 35b6787a5b39
children cfeb196251e4
files Makefile
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/Makefile	Sun Apr 07 01:18:31 2013 -0600
+++ b/Makefile	Sun Apr 07 01:29:29 2013 -0600
@@ -10,13 +10,13 @@
 DESTDIR ?= /usr/local/bin
 
 # C compiler
-CC := $(BUILDTPREFIX)cc
+CC ?= $(BUILDTPREFIX)cc
 
 # ar
-AR := $(BUILDTPREFIX)ar
+AR ?= $(BUILDTPREFIX)ar
 
 # ranlib
-RANLIB := $(BUILDTPREFIX)ranlib
+RANLIB ?= $(BUILDTPREFIX)ranlib
 
 CPPFLAGS += -I lwlib -DPACKAGE_STRING='"lwtools 4.7+"'
 LDFLAGS += -L$(PWD)/lwlib -llw