help-make
[Top][All Lists]
Advanced

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

Re: error commands commence before first target...


From: Paul D. Smith
Subject: Re: error commands commence before first target...
Date: Tue, 10 Oct 2006 13:47:18 -0400

%% Zuheyr Alsalihi <address@hidden> writes:
> I seem to have a very random error, the famous
> Makefile:147: *** commands commence before first target.  Stop.
    ...
> ifeq ($(COMPILER),gnu)
> F90 = /usr/bin/gfortran
> F90FLAGS_RG = --chk a,e,s --f95 -g \
>                    --trace --xref  --trap -Wa,--32
> F90FLAGS_DEBUG = --chk a,e,s --f95 -g \
>                    --trace --xref  --trap -Wa,--32
>         echo " -GNU COMPILER-"                      <- this is the line
> endif
>
> Is this a bug!? What can I do about this please help.

No, it's not a bug.  You have an invalid syntax there: you can't just
write a shell command like 'echo " -GNU COMPILER-"' in the middle of a
makefile somewhere.  Makefiles are not shell scripts; they have to
obey makefile syntax not shell syntax.

Maybe if you told us what you intend for that line to actually do, we
could tell you how to do what you want.

-- 
-------------------------------------------------------------------------------
 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]