help-make
[Top][All Lists]
Advanced

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

Re: Undefined environment variable and operator ?=


From: Paul Smith
Subject: Re: Undefined environment variable and operator ?=
Date: Mon, 17 Apr 2017 15:09:43 -0400

On Mon, 2017-04-17 at 20:24 +0200, zosrothko wrote:
> Le 17/04/2017 à 19:07, Toan Pham a écrit :
> > @Paul,  thank you and have a good day.
> > 
> > On Apr 17, 2017 10:04 AM, "Paul Smith" <address@hidden> wrote:
> > > On Mon, 2017-04-17 at 10:00 -0400, Toan Pham wrote:
> > > > What is the best way to override the default compiler?  is this good 
> > > > practice:
> > > >
> > > > CXX:=$(CROSS_COMPILE)$(CXX)
> > > 
> > > That's the way I would do it, yes.
> > > 
>  Ok, but that does not work for 'ranlib' & 'strip' which are also
> needed for cross compiling

That's because there is no ranlib or strip available in the default set
of variables provided by make:

  $ make -pf/dev/null | grep -i ranlib
  make: *** No targets.  Stop.

  $ make -pf/dev/null | grep -i strip
  make: *** No targets.  Stop.

You'll have to define them yourself, as in:

  RANLIB := $(CROSS_COMPILE)ranlib
  STRIP := $(CROSS_COMPILE)strip

or whatever.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]