help-make
[Top][All Lists]
Advanced

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

Re: make -n executes RCS commands


From: Noel Yap
Subject: Re: make -n executes RCS commands
Date: Thu, 20 Jan 2005 18:25:38 -0500
User-agent: Mozilla Thunderbird 0.5 (Windows/20040212)

Also "gmake -r" will disable builtin rules.

HTH,
Noel

Paul D. Smith wrote:

%% "Aaron S. Hawley" <address@hidden> writes:

  ash> The following behavior seems broken.
  ash> $ ls script.awk
  ash> ls: script.awk: No such file or directory

  ash> $ ls RCS/script.awk,v
  ash> RCS/script.awk,v

  ash> $ make -n script.awk
  ash> co  RCS/script.awk,v script.awk
  ash> RCS/script.awk,v  -->  script.awk
  ash> revision 1.1
  ash> done

  ash> $ ls script.awk
  ash> script.awk

  ash> Couldn't find any mention of this behavior in the manual.

The builtin rule for checking things out of source uses the "+" prefix
character.  You can find the builtin rules with the -p option, something
like this:

    $ make -pf /dev/null
        ...
    # default
    CHECKOUT,v = +$(if $(wildcard $@),,$(CO) $(COFLAGS) $< $@)
        ...
    %:: RCS/%,v
    #  commands to execute (built-in):
            $(CHECKOUT,v)

The "+" token tells GNU make to run this command line even if -n is
given.





reply via email to

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