tools: make genboardscfg.py compatible with Python 2.5

The statement "exception ... as ..." can be used in Python 2.6
or lator. Avoid using it.
Tested on Python 2.5.6.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Series-changes: 2
  - Fix git-description.  s/exception/except/
kconfig: convert Kconfig helper script into a shell script

Commit 51148790 added scripts/multiconfig.py written in Python 2
to adjust Kconfig for U-Boot.

It has been hard for Python 3 users because Python 2 and Python 3
are not compatible with each other.

We are not happy about adding a new host tool dependency
(in this case, Python version dependency) for the core build process.
After some discussion, we decided to use only basic tools.

The script may get a bit unreadable by shell scripting, but we believe
it is worthwhile.

In addition, this commit revives "<board>_config" target that is
equivalent to "<board>_defconfig" for backwards compatibility.
It is annoying to adjust various projects which use U-Boot.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Suggested-by: Igor Grinberg <grinberg@compulab.co.il>
Cc: Tom Rini <trini@ti.com>
Cc: Jeroen Hofstee <jeroen@myspectrum.nl>
Cc: Simon Glass <sjg@chromium.org>
Cc: Stephen Warren <swarren@wwwdotorg.org>
Series-cc: Igor Grinberg <grinberg@compulab.co.il>
Series-version: 2
Series-changes: 2
  - Update git-description to mention the support for "<board>_config"

Commit-notes:

To apply this patch cleanly, the following is needed:
http://patchwork.ozlabs.org/patch/380316/

END
kconfig: remove DEFCONFIG_LIST

CONFIG_DEFCONFIG_LIST specifies the default defconfig.
It is used by "make savedefconfig" when .config is missing.
But that's it.  I could not find other useful cases.

As a side effect, CONFIG_DEFCONFIG_LIST="configs/sandbox_defconfig"
is contained in .config of every target board, which some people
think is odd.  So, let's remove it.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Michal Simek <michal.simek@xilinx.com>
kconfig: add CONFIG_LOCALVERSION and CONFIG_LOCALVERSION_AUTO

Copy Kconfig options from "init/Kconfig" of Linux v3.16 tag
and adjust some parts of the help document.

Move CONFIG_SPL, CONFIG_TPL, ... etc. to "Boot images" menu.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
scripts: refetch scripts/setlocalversion from Linux 3.16

Now we have CONFIG_LOCALVERSION and CONFIG_LOCALVERSION_AUTO
in Kconfig so we can use scripts/setlocalversion without
any adjustment.  Copy it from Linux 3.16 as is.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
kconfig: add CONFIG_CC_OPTIMIZE_FOR_SIZE

Copy the Kconfig option from "init/Kconfig" of Linux v3.16 tag
and adjust the help document.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
kconfig: move
cosmetic: Kconfig: fix a typo

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
kconfig: add CONFIG_CROSS_COMPILE

Copy from Linux Kernel (with a few adjustments in comments).
tools: move_config
scripts/Lindent: import from Linux 3.16

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
tools/genboardscfg.py: Do not output SPLCPU field

Prior to Kconfig, the CPU field of boards.cfg could optionally have
":SPLCPU", like "armv7:arm720t".
(Actually this syntax was only used for Tegra platform.)

Now it is not necessary at all because CPU is defined by
CONFIG_SYS_CPU in Kconfig.

For Tegra platform, the Kconfig option is described as follows:

  config SYS_CPU
          string
          default "arm720t" if SPL_BUILD
          default "armv7" if !SPL_BUILD

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Series-cc: sjg
tools: moveconfig.py
tools/genboardscfg.py: facilitate adding new options

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Check if the boards.cfg is up-to-date

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>