menuconfig: wrap long help lines

Help text for certain config options is very extensive (the text
includes the names of all  other options the option in question depends
on). Long lines are not wrapped, making it impossible to see the list
without scrolling horizontally.

This patch adds some logic which wraps help screen lines at word
boundaries to prevent truncating.

Tested by running

  ARCH=powerpc make menuconfig O=/tmp/build

which shows that the long lines are now wrapped, and

 ARCH=powerpc make xconfig O=/tmp/build

to demonstrate that it still compiles and operates as expected.

Signed-off-by: Vadim Bendebury <vbendeb@google.com>
Signed-off-by: Michal Marek <mmarek@suse.cz>
4 files changed