26 Feb, 2014
18 commits
-
Same as the previous commit.
Move sanity check to prepare1 target to avoid nasty troubles.Before this commit, LDSCRIPT existence was not checked
when it was specified by CONFIG_SYS_LDSCRIPT.
Now LDSCRIPT existence is checked for all boards.$(wildcard $(LDSCRIPT)) must point to the linker scripts
with absolute path.
Otherwise, make will terminate with a false error
on out-of-tree build.Signed-off-by: Masahiro Yamada
-
Before this commit, make terminated with an error
where is shouldn't under some condition.This bug happened when we built a board unsupporting
generic board right after building with generic board.For example, the following sequence failed.
(harmony uses generic board but microblaze-generic does not
support it)$ make harmony_config
Configuring for harmony board...
$ make CROSS_COMPILE=arm-linux-gnueabi-
[ Build succeed ]
$ make microblaze-generic_config
Configuring for microblaze-generic board...
$ make CROSS_COMPILE=microblaze-linux-
Makefile:488: *** Your architecture does not support generic board.
Please undefined CONFIG_SYS_GENERIC_BOARD in your board config file. Stop.We had to do "make clean" before building the microblaze board.
This commit fixes this unconvenience.
Move generic board sanity check to "prepare1" target,
which is run after generation of include/autoconf.mk.Signed-off-by: Masahiro Yamada
-
Commit 6ab6b2af deleted ./u-boot.dtb because it was a copy
of dts/dt.dtb.But Simon suggested to keep u-boot.dtb at the top directory
because it is a build output.After discussions, we agreed on revival of ./u-boot.dtb.
Signed-off-by: Masahiro Yamada
Cc: Simon Glass
Cc: Tom Rini
Acked-by: Simon Glass -
"help" target has been copied from Linux 3.13 and adjusted
for U-Boot.
Unlike Linux, cleaning is done on 4 levels:
clean, clobber, mrproper, distclean.Signed-off-by: Masahiro Yamada
-
Import build rules of single targets from Linux 3.13.
Signed-off-by: Masahiro Yamada
-
This commit avoids generating ./SPL twice.
- Fist time descending to spl/
- Second time as a prerequisite of u-boot-with-spl.imx,
u-boot-with-nand-spl.imx.Signed-off-by: Masahiro Yamada
-
Signed-off-by: Masahiro Yamada
-
Signed-off-by: Masahiro Yamada
-
Move sandbox-specific link rule to arch/sandbox/config.mk.
Signed-off-by: Masahiro Yamada
-
Signed-off-by: Masahiro Yamada
-
Signed-off-by: Masahiro Yamada
-
Signed-off-by: Masahiro Yamada
-
Signed-off-by: Masahiro Yamada
-
Signed-off-by: Masahiro Yamada
Acked-by: Simon Glass -
Rename OBJCFLAGS to OBJCOPYFLAGS beforehand to use
"cmd_objcopy" in scripts/Makefile.lib in an upcoming commit.Signed-off-by: Masahiro Yamada
-
Generate include/generated/generic-asm-offsets.h and
include/generated/asm-offsets.h in ./Kbuild.This commit also changes the include guard.
Before this commit, __ASM_OFFSETS_H__ was used for both of them.
So we could not include generic-asm-offsets.h and asm-offsets.h
at the same time.This commit renames the include guard of the former to
__GENERIC_ASM_OFFSETS_H__.Signed-off-by: Masahiro Yamada
-
This commit moves include/generated/{generic-asm-offsets.h, asm-offsets.h}
from "depend" targets to "prepare" targets and deletes "depend" targets.Signed-off-by: Masahiro Yamada
-
- Generate include/generated/{timestamp.h, version.h}
more simply by using filechk rule.- Add $(UBOOTRELEASE) variable and re-write u-boot.imx rule
more simply.- Rename U_BOOT_VERSION in Makefile to UBOOTVERSION
Before this commit, the same variable name, "U_BOOT_VERSION"
was used for two different strings.One of them was defined in Makefile.
It takes the form like "2014.01-rc1" and used in
makefiles and script files.The other is defined in include/generated/version.h
It takes the form like "U-Boot 2014.01-rc1-00010-gbe6d426-dirty"
and used in C and Aseembler.It is confusing when grepping the source tree. So, this commit
renames the former to UBOOTVERSION.Signed-off-by: Masahiro Yamada
25 Feb, 2014
1 commit
-
If -fstack-usage option is given to crosstools
that do not support it, gcc displays a warning message
but still exits with status 0.This means we can not rely on $(call cc-option,...)
to detect if -fstack-usage option is supported or not.Signed-off-by: Masahiro Yamada
22 Feb, 2014
2 commits
-
Signed-off-by: Masahiro Yamada
Reported-by: Nishanth Menon -
The pattern rule "MLO*" can delete both MLO and MLO.byteswap.
Signed-off-by: Masahiro Yamada
20 Feb, 2014
19 commits
-
Conflicts:
Makefile
drivers/net/npe/MakefileThese two conflicts arise from commit 0b2d3f20
("ARM: NET: Remove the IXP NPE ethernet driver") and are
resolved by deleting the drivers/net/npe/Makefile file
and removing the CONFIG_IXP4XX_NPE line from Makefile. -
Signed-off-by: Tom Rini
-
Useful rules in scripts/Makefile.lib allows us to easily
generate a device tree blob and wrap it in assembly code.We do not need to parse a linker script to get output format and arch.
This commit deletes ./u-boot.dtb since it is a copy of dts/dt.dtb.
Signed-off-by: Masahiro Yamada
-
tools/kernel-doc/docproc.c and tools/kernel-doc/kernel-doc are
files imported from Linux Kernel.They originally resided under scripts/ directory in Linux Kernel.
This commit moves them to the original location.
Signed-off-by: Masahiro Yamada
Acked-by: Simon Glass -
For out-of-tree build
- Check if the source tree is clean
- Create a Makefile in the output directorySigned-off-by: Masahiro Yamada
-
This commit fixes two problems:
[1] We could not do board configuration and "make all"
in one command line.For example, the following did not work as we expect:
$ make sandbox_config all
Configuring for sandbox board...
make: Nothing to be done for `all'.[2] mixed-target build did not work with -j option
For example, the following did not work:
$ make -j8 sandbox_config u-boot
Makefile:481: *** "System not configured - see README". Stop.
make: *** [u-boot] Error 2
make: *** Waiting for unfinished jobs....
Configuring for sandbox board...Going forward, we can do
$ make -j8 sandbox_config allThis is the same as
$ make sandbox_config
$ make -j8Signed-off-by: Masahiro Yamada
-
This commit refactors cleaning targets such as
clean, clobber, mrpropper, distclean
with scripts/Makefile.clean.By using scripts/Makefile.clean, we can recursively descend
into subdirectories and delete generated files there.We do not need add a big list of generated files
to the "clean" target.Signed-off-by: Masahiro Yamada
-
- Move "easylogo", "gdb" tagets to tools/Makefile
- Delete "gdbtools" target (same as "gdb")Signed-off-by: Masahiro Yamada
-
$(MTD_VERSION) is used in tools/env/Makefile
If you specify a variable at a command line like:
$ make MTD_VERSION=old env
or specify it thru an envrionment variable like:
$ export MTD_VERSION=old
$ make env
it is inherited to the sub-make too.
We do not need to pass it from the top Makefile explicitely.Signed-off-by: Masahiro Yamada
-
This commit refactors rules of directory descending
and defines u-boot-dirs and u-boot-all-dirs.
(We will need u-boot-all-dirs when using
scripts/Makefile.clean)Additionally, rename LIBS-y to libs-y.
Signed-off-by: Masahiro Yamada
-
Signed-off-by: Masahiro Yamada
-
This commit changes the top Makefile to handle various targets
nicely.
Make targets are divided into four categories:- mixed-targets
We can call a configuration target and build targets
at one command line like follows:
$ make _config u-bootThey are handled one by one.
- config targets
_config- no-dot-config-targets
Targets we can run without board configuration such as
clean, mrproper, distclean, TAGS, %docs, etc.- build targets
The other target which need board configuration.Signed-off-by: Masahiro Yamada
-
Before this commit, "make tidy" did
"make clean" + delete "*.depend*" files.But, we do not have "*.depend*" files any more,
which means "make tidy" is the same as "make clean".This commit removes the redandant target "tidy".
Signed-off-by: Masahiro Yamada
-
Before this commit, {spl,tpl}-autoconf.mk was always generated
at the top Makefile even if SPL(TPL) build was not selected.This commit moves the build rule of {spl,tpl}-autoconf.mk
from the top Makefile to spl/Makefile.
It prevents unnecessary {spl,tpl}-autoconf.mk from being
generated.Signed-off-by: Masahiro Yamada
-
We can get Kbuild-ish log style like this:
GEN include/autoconf.mk
GEN include/autoconf.mk.depWe do not need XECHO any more.
And also change checkstack target like Linux Kernel.
Signed-off-by: Masahiro Yamada
-
Signed-off-by: Masahiro Yamada
-
Now we are ready to switch over to real Kbuild.
This commit disables temporary scripts:
scripts/{Makefile.build.tmp, Makefile.host.tmp}
and enables real Kbuild scripts:
scripts/{Makefile.build,Makefile.host,Makefile.lib}.This switch is triggered by the line in scripts/Kbuild.include
-build := -f $(if $(KBUILD_SRC),$(srctree)/)scripts/Makefile.build.tmp obj
+build := -f $(if $(KBUILD_SRC),$(srctree)/)scripts/Makefile.build objWe need to adjust some build scripts for U-Boot.
But smaller amount of modification is preferable.Additionally, we need to fix compiler flags which are
locally added or removed.In Kbuild, it is not allowed to change CFLAGS locally.
Instead, ccflags-y, asflags-y, cppflags-y,
CFLAGS_$(basetarget).o, CFLAGS_REMOVE_$(basetarget).o
are prepared for that purpose.Signed-off-by: Masahiro Yamada
Tested-by: Gerhard Sittig -
This commit changes the working directory
where the build process occurs.Before this commit, build process occurred under the source
tree for both in-tree and out-of-tree build.That's why we needed to add $(obj) prefix to all generated
files in makefiles like follows:
$(obj)u-boot.bin: $(obj)u-bootHere, $(obj) is empty for in-tree build, whereas it points
to the output directory for out-of-tree build.And our old build system changes the current working directory
with "make -C " syntax when descending into the
sub-directories.On the other hand, Kbuild uses a different idea
to handle out-of-tree build and directory descending.The build process of Kbuild always occurs under the output tree.
When "O=dir/to/store/output/files" is given, the build system
changes the current working directory to that directory and
restarts the make.Kbuild uses "make -f $(srctree)/scripts/Makefile.build obj="
syntax for descending into sub-directories.
(We can write it like "make $(obj)=" with a shorthand.)
This means the current working directory is always the top
of the output directory.Signed-off-by: Masahiro Yamada
Tested-by: Gerhard Sittig -
Signed-off-by: Masahiro Yamada