| Author |
debug statements in make
|
|
| aerosmith 2006-07-17, 7:19 pm |
| Hi,
I have several makefiles and I want to add debug statements in these
makefiles to step into and see which line make is executing. The
makefiles do not have any targets. Is there a way to add such debug
statements. Something like a #warning or #error pragma in C++.
Thanks.
| |
| Pascal Bourguignon 2006-07-17, 7:19 pm |
| aerosmith <tyler@pandoras.box> writes:
> Hi,
>
> I have several makefiles and I want to add debug statements in these
> makefiles to step into and see which line make is executing.
make -d
> The
> makefiles do not have any targets.
make -p
> Is there a way to add such debug
> statements. Something like a #warning or #error pragma in C++.
Make is not a procedural language. It's a declarative language. Such
debug "statements" would be meaningless, given that there's no
statement in a makefile. Only attributed declarations of dependency.
--
__Pascal Bourguignon__ http://www.informatimago.com/
NOTE: The most fundamental particles in this product are held
together by a "gluing" force about which little is currently known
and whose adhesive power can therefore not be permanently
guaranteed.
| |
| aerosmith 2006-07-18, 1:29 pm |
| Hi Pascal,
Thank you very much. That was very useful information and is helpful.
Pascal Bourguignon wrote:
> aerosmith <tyler@pandoras.box> writes:
>
>
> make -d
>
>
>
> make -p
>
>
> Make is not a procedural language. It's a declarative language. Such
> debug "statements" would be meaningless, given that there's no
> statement in a makefile. Only attributed declarations of dependency.
>
>
| |
| Henry Townsend 2006-07-24, 1:21 am |
| Pascal Bourguignon wrote:
> aerosmith <tyler@pandoras.box> writes:
>
>
> make -d
More precisely, make does not "execute" any lines at all; it throws
certain chunks of text at the shell under certain circumstances. But if
you find yourself writing a phrase like "which line make is executing",
you should read and/or ponder more about how make works.
HT
|
|
|
|