From 12caebdc753fcaa456644328e629a5a04f91c2fe Mon Sep 17 00:00:00 2001 From: Steffen Jaeckel Date: Thu, 18 Apr 2013 16:38:16 +0200 Subject: [PATCH] update makefile to be able to define a target platform prefix --- makefile | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/makefile b/makefile index 70de306..66c3511 100644 --- a/makefile +++ b/makefile @@ -7,6 +7,16 @@ VERSION=0.42.0 CFLAGS += -I./ -Wall -W -Wshadow -Wsign-compare +# Compiler and Linker Names +ifndef PREFIX + PREFIX= +endif + +CC=$(PREFIX)gcc +LD=$(PREFIX)ld +AR=$(PREFIX)ar +RANLIB=$(PREFIX)ranlib + ifndef MAKE MAKE=make endif @@ -87,7 +97,7 @@ bn_mp_to_signed_bin_n.o bn_mp_to_unsigned_bin_n.o $(LIBNAME): $(OBJECTS) $(AR) $(ARFLAGS) $@ $(OBJECTS) - ranlib $@ + $(RANLIB) $@ #make a profiled library (takes a while!!!) #