[Top][All Lists]

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

Re: GNU make troubleshooting

From: Alejandro Colomar
Subject: Re: GNU make troubleshooting
Date: Sun, 16 Jul 2023 15:58:33 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.12.0

Hi Dmitry!

On 2023-07-15 17:28, Dmitry Goncharov wrote:

> $ make -d |tail +7 |head
> Reading makefiles...
> Reading makefile 'makefile'...
> Updating makefiles....
>  Considering target file 'makefile'.
>   Looking for an implicit rule for 'makefile'.
>    Trying pattern rule '%: %.o' with stem 'makefile'.
>    Trying implicit prerequisite 'makefile.o'.
>    Not found 'makefile.o'.
>    Trying pattern rule '%: %.c' with stem 'makefile'.
>    Trying implicit prerequisite 'makefile.c'.
> $
> Upon startup make looks for a rule to update the makefile. (see How
> Makefiles Are Remade). This is what the initial portion of this debug
> output is about. If we don’t need your makefile to be remade, we can
> instruct make to skip this update process.
> $ cat makefile
> all: hello
> makefile::;
> $ make -d |tail +7 |wc
>     730    4101   32848
> Note, we added rule
> makefile::;
> This addition cut the debug output from 1338 to 730 lines.

Wow!  That's a great help for debugging the Linux man-pages's makefiles,
which don't need to be remade.  It was very painful to me to ignore so
much make -d output.  I applied the following patch, and it works like
a charm.


Thanks a lot!

GPG key fingerprint: A9348594CE31283A826FBDD8D57633D441E25BB5

Attachment: OpenPGP_signature
Description: OpenPGP digital signature

reply via email to

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