help-make
[Top][All Lists]
Advanced

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

Re: unix make to GNU make transition


From: Paul D. Smith
Subject: Re: unix make to GNU make transition
Date: Fri, 16 Aug 2002 23:24:59 -0400

%% "Wendy Vanhonacker" <address@hidden> writes:

  wv> As we want our system to be easier to build on all platfomrs, we
  wv> are planing to install GNU make.  We use unix make right now.

There is no such thing as "unix make".  Virtually every version of Unix
(of which there are many) had their own, slightly different, version of
make.

  wv> Could you give us some hint about the differences between those
  wv> two? Will tthere be a lot of changes on our code?

Without knowing exactly which version of Unix you are migrating from
that's very difficult.  The GNU make manual has a whole chapter on the
differences between GNU make and other versions of make; that's your
best bet to start with.

  wv> I just tested on makefile. Here is the first problem,.

  wv> The old version has :
  wv> ALL:
  wv> !if a==b
  wv> do this
  wv> !else
  wv> do that
  wv> !endif

I'm not extremely familiar with it, but this might be BSD make.

  wv> GNU make doesnt like the if statement with a !.

Correct.  It also doesn't recognize operators like "==".

  wv> Since we have that all over our codes, is there a way to let it
  wv> like that?

No.

  wv> I was wondering if there wasn't a way to add some librraies or
  wv> something like that so that it still understands unix functions..
  wv> Any suggestions?

I don't know what you mean by "unix functions", but there is no way to
extend the make grammar... well, of course GNU make is open source so
you have the source code and can change it to recognize whatever grammar
you like.

On the other hand, if what you're using is BSD make you can just go get
the code for that, compile it for whatever system you need to build on
(assuming it's UNIX--unlike GNU make, AFAIK BSD make won't build easily
on anything except UNIX) and continue to use it.

-- 
-------------------------------------------------------------------------------
 Paul D. Smith <address@hidden>          Find some GNU make tips at:
 http://www.gnu.org                      http://make.paulandlesley.org
 "Please remain calm...I may be mad, but I am a professional." --Mad Scientist




reply via email to

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