From 4087ec556b1ccee15d8e97153f3800b79982f8ba Mon Sep 17 00:00:00 2001 From: Paul Mackerras Date: Fri, 1 Jan 2021 19:44:07 +1100 Subject: Add cross-compilation support on Linux This adds three new command-line options to the configure script: --cross_compile= (default "") --cc= (default cc) --cflags= (default -g -O2 -pipe) These get propagated to the Makefiles in the subdirectories. The cross-compile prefix is prepended to the CC value, so for example if you do "./configure --cross_compile=powerpc64le-linux-" then everything gets compiled and linked using powerpc64le-linux-cc. Signed-off-by: Paul Mackerras --- chat/Makefile.linux | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'chat') diff --git a/chat/Makefile.linux b/chat/Makefile.linux index f082dab..407cc12 100644 --- a/chat/Makefile.linux +++ b/chat/Makefile.linux @@ -1,4 +1,6 @@ -# $Id: Makefile.linux,v 1.15 2006/06/04 05:07:46 paulus Exp $ +CROSS_COMPILE=@CROSS_COMPILE@ +CC=$(CROSS_COMPILE)@CC@ +COPTS=@CFLAGS@ DESTDIR = $(INSTROOT)@DESTDIR@ BINDIR = $(DESTDIR)/sbin @@ -10,7 +12,6 @@ CDEF3= -UNO_SLEEP # Use the usleep function CDEF4= -DFNDELAY=O_NDELAY # Old name value CDEFS= $(CDEF1) $(CDEF2) $(CDEF3) $(CDEF4) -COPTS= -O2 -g -pipe CFLAGS= $(COPTS) $(CDEFS) INSTALL= install -- cgit v1.2.1