Re: [PATCH 1/2] rt-tests: Allow cross compilation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On Thu, 22 Aug 2019, Afzal Mohammed wrote:

> $ make CROSS_COMPILE=<my-toolchain-prefix>
> 
> currently does not cause source to be built using the intended
> toolchain, instead will use the host toolchain.
> 
> CC & AR are not updated with CROSS_COMPILE value since they are
> predefined make variables (with default cc & ar respectively) combined
> with the fact that CC & AR variables are updated in the makefile only if
> not already defined due to the usage of '?='.
> 
> Signed-off-by: Afzal Mohammed <afzal.mohd.ma@xxxxxxxxx>
> ---
>  Makefile | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/Makefile b/Makefile
> index 51b8dea..b573408 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -1,6 +1,6 @@
>  VERSION = 1.5
> -CC?=$(CROSS_COMPILE)gcc
> -AR?=$(CROSS_COMPILE)ar
> +CC = $(CROSS_COMPILE)gcc
> +AR = $(CROSS_COMPILE)ar
>  
>  OBJDIR = bld
>  
> -- 
> 2.23.0

Signed-off-by: John Kacur <jkacur@xxxxxxxxxx>



[Index of Archives]     [RT Stable]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux