On Mon, Sep 19, 2016 at 12:11:04PM +0200, Alexander Aring wrote:
> I currently try to use some install_copy command with $(FOO_BUILDDIR)
> location for testing purpose.
> Then I tried a grep on ptxdist rules file to look for an example (I
> think this exists somewhere), I did a grep on "BUILD_DIR" which is wrong
> and I got some hit at [0].
> Should:
> pkg_build_dir="$(call ptx/escape,$($(1)_BUILD_DIR))"
> not be:
> pkg_build_dir="$(call ptx/escape,$($(1)_BUILDDIR))"
> and $(1) is the FOO replacement, so far I understood?

The whole thing is a bit tricky because some of the logic (foo OOT) is in
the shell code, and that's not available in your makefile.

If you don't build out of tree, then just use FOO_DIR and ignore the rest.
If you want to build out of tree, then you can:

 - use $(FOO_DIR)-build/
 - set FOO_BUILD_DIR = $(FOO_DIR)-build
 - use $(FOO_BUILD_DIR)

Setting FOO_BUILD_DIR to anything other than FOO_DIR implies OOT.
Not that FOO_BUILD_OOT and FOO_BUILD_DIR follow the same naming theme.

FOO_BUILDDIR is a really old variable that is used the as a fallback for
FOO_BUILD_DIR if set, but should not be used. We should really remove the
handling for this.


Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

ptxdist mailing list

Reply via email to