From 6c1baa5e21a16f9ae693695c4c5190c548858fe1 Mon Sep 17 00:00:00 2001 From: Sergey Kvachonok Date: Thu, 23 Sep 2010 11:54:05 +0300 Subject: [PATCH] Make CROSS_COMPILE configure script variable. --- configure.ac | 4 ++++ usbboot/src/Makefile.am | 4 ++-- xbboot/host-app/Makefile.am | 2 +- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/configure.ac b/configure.ac index fa6c1a3..62047ec 100644 --- a/configure.ac +++ b/configure.ac @@ -21,6 +21,10 @@ no) firmware=false ;; esac],[firmware=false]) AM_CONDITIONAL([COND_FIRMWARE], [test "$firmware" = true]) +AC_ARG_VAR([CROSS_COMPILE], + [Cross compiler prefix for building firmware, ] + [e.g. CROSS_COMPILE=mipsel-openwrt-linux-.]) + # Checks for programs. AC_PROG_CC AC_PROG_CXX diff --git a/usbboot/src/Makefile.am b/usbboot/src/Makefile.am index 6a5c51f..ac6516b 100644 --- a/usbboot/src/Makefile.am +++ b/usbboot/src/Makefile.am @@ -23,7 +23,7 @@ cfg_DATA = ../doc/usbboot.cfg EXTRA_DIST = $(pkgdatadir) $(cfgdir) ../xburst_stage1/xburst_stage1.bin: - $(MAKE) CROSS_COMPILE=mipsel-openwrt-linux- -C ../xburst_stage1 + $(MAKE) CROSS_COMPILE=$(CROSS_COMPILE) -C ../xburst_stage1 ../xburst_stage2/xburst_stage2.bin: - $(MAKE) CROSS_COMPILE=mipsel-openwrt-linux- -C ../xburst_stage2 + $(MAKE) CROSS_COMPILE=$(CROSS_COMPILE) -C ../xburst_stage2 diff --git a/xbboot/host-app/Makefile.am b/xbboot/host-app/Makefile.am index b850984..37a93ec 100644 --- a/xbboot/host-app/Makefile.am +++ b/xbboot/host-app/Makefile.am @@ -18,4 +18,4 @@ endif EXTRA_DIST = $(pkgdatadir) ../target-stage1/stage1.bin: - $(MAKE) CROSS_COMPILE=mipsel-openwrt-linux- -C ../target-stage1 + $(MAKE) CROSS_COMPILE=$(CROSS_COMPILE) -C ../target-stage1