[U-Boot] [PATCH] kbuild,tegra124: add dummy obj- for Kbuild

Tom Rini
2014-02-19T20:40:47Z

On Wed, Feb 19, 2014 at 09:36:14AM -0700, Stephen Warren wrote:
> On 02/19/2014 07:46 AM, Albert ARIBAUD wrote:
> > Hi Masahiro,
> >
> > On Wed, 19 Feb 2014 22:26:43 +0900, Masahiro Yamada
> > <yamada.m@jp.panasonic.com> wrote:
> >
> >> In Kbuild, every makefile must have non-empty obj- or obj-y.
> >> Otherwise, built-in.o will not be created and the link stage
> >> will fail.
> ...
> >> diff --git a/arch/arm/cpu/armv7/tegra124/Makefile b/arch/arm/cpu/armv7/tegra124/Makefile
> ...
> >> +# necessary to create built-in.o
> >> +obj- := __dummy__.o
>
> obj- or obj-y?
>
> Adding something to obj-, which presumably isn't used at all, seems very
> odd.

Why do we even need arch/arm/cpu/armv7/tegra124/Makefile ? I assume we
need the config.mk because we can't stick CONFIG_ARCH_DEVICE_TREE into
the config header?

>
> > Is there really no other way than to specify an unexisting __dummy__.o
> > in order to build a useless built-in.o?
>
> I haven't looked at Kbuild at all, but in the build systems I've
> written, for each sub-directory makefile that was included, the
> makefiles would include a "pre-makefile" first and a "post-makefile"
> after. The "post-makefile" could easily do something like:
>
> ifeq ($(obj-y),)
> obg-y := __dummy__.o
> endif
>
> _______________________________________________
> U-Boot mailing list
> U-Boot at lists.denx.de
> http://lists.denx.de/mailman/listinfo/u-boot

--
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20140219/50a2ffd6/attachment.pgp>