Recursive Makefile howto

Kristof Provost kristof at sigsegv.be
Fri Jan 27 07:37:35 EST 2012


On 2012-01-27 17:38:11 (+0530), Manavendra Nath Manav <mnm.kernel at gmail.com> wrote:
> Now, I am getting error in the make part of "Build_sqllib" but the
> makefile continues to next line. I guess, I need to add "|| exit" also
> with this make command. Kristof, can you pls also explain me the
> meanings of $$d, $@, and $? as used in Makefiles.

$$d is not a make variable, but a shell variable. The double '$' is an
escape sequence. In fact, $? should be $$?, because we want the shell
to interpret it. I suspect it gets replaced by an empty string, and in
that case exit returns the exit status from the previous command.
We can just remove $$? in other words.

$@ is a make variable, an automatic variable. It always contains the
file name of the target. 

Regards,
Kristof




More information about the Kernelnewbies mailing list