On 2006-5-12 20:01 UTC, Robert P. J. Day wrote:
>
> ${MAKE} \
> -C $@ \
> --no-print-directory \
> -f ${CURDIR}/Makefile \
> SRCDIR="${CURDIR}" \
> -I${CURDIR} \
> CPPFLAGS="${CPPFLAGS}" \
> ${MAKECMDGOALS}
Looks good. In particular, I think we always need to pass
> SRCDIR="${CURDIR}" \
with this technique.
As for
> -I${CURDIR} \
I avoid 'make --include-dir' because I couldn't find a way to prevent
"macro" makefiles (that are included in many makefiles) from being
remade repeatedly, unless I included them by absolute pathname:
include $(SRCDIR)/configuration.make
As for
> CPPFLAGS += -I${CURDIR}
(which you write outside the $(MAKE) command of course), don't you
really want '-I${CURDIR}' at the beginning of your include list?
If someone does 'make CPPFLAGS="-I/foo/bar/"' and /foo/bar/ just
happens to have a header whose name shadows one of yours, then
yours in SRCDIR won't be used.
_______________________________________________
Help-make mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-make