aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2010-09-30kconfig: Propagate constMichal Marek1-6/+9
Commit 2e7a091 made struct file->name a const char*, but forgot to constify all users of it. Reported-by: Stephen Rothwell <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-09-30kconfig: Don't go out from read config loop when you read new symbolNaohiro Aota1-2/+3
commit 8baefd30b5b0101aa07aa75da44a9eee881eed28 of linux-next replaced a `switch()' statement with some `if()' statements, but left `break's in the `switch()' statement untouched. This cause read config loop to exit and so "make oldconfig" is not much usable (see below). > $ make oldconfig ><snip> > scripts/kconfig/conf --oldconfig Kconfig > # > # using defaults found in /boot/config-2.6.34-ccs-r1 > # > * > * Restart config... > * > * > * General setup > * > Prompt for development and/or incomplete code/drivers (EXPERIMENTAL) [N/y/?] (NEW) (I've already have "CONFIG_EXPERIMENTAL=y" in the old config file. But that's not read here.) This patch should fix this problem. Signed-off-by: Naohiro Aota <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-09-27Merge branch 'kbuild/kconfig/kbuild-generic-v7' of ↵Michal Marek42-560/+501
http://github.com/lacombar/linux-2.6 into kbuild/kconfig * 'kbuild/kconfig/kbuild-generic-v7' of http://github.com/lacombar/linux-2.6: kbuild: migrate all arch to the kconfig mainmenu upgrade kconfig: expand file names kconfig: use the file's name of sourced file kconfig: constify file name kconfig: don't emit warning upon rootmenu's prompt redefinition kconfig: replace KERNELVERSION usage by the mainmenu's prompt kconfig: delay gconf window initialization kconfig: expand by default the rootmenu's prompt kconfig: add a symbol string expansion helper kconfig: regen parser kconfig: implement the `mainmenu' directive kconfig: allow PACKAGE to be defined on the compiler's command-line kconfig: rephrase help texts/comments not to include the package name kconfig: allow build-time definition of the internal config prefix kconfig: rephrase help text not to mention the internal prefix kconfig: replace a `switch()' statement by a more flexible `if()' statement
2010-09-20kconfig: fix menuconfig on debian lennyJunio C Hamano1-0/+2
In 60f33b8 (kconfig: get rid of stray a.o, support ncursesw, 2006-01-15), support to link menuconfig with ncursesw library was added. To compute the linker command option -l, we check "libncursesw.{so,a,dylib}" to allow ncursesw to be used as a replacement ncurses. However, when checking what header file to include, we do not check /usr/include/ncursesw directory. Add /usr/include/ncursesw to the list of directories that are checked. With this patch, on my Debian Lenny box with libncursesw5-dev package but not libncurses5-dev package, I can say "make menuconfig". Signed-off-by: Junio C Hamano <[email protected]> Acked-by: Sam Ravnborg <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-09-19kbuild: migrate all arch to the kconfig mainmenu upgradeArnaud Lacombe25-137/+12
Signed-off-by: Arnaud Lacombe <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Michal Marek <[email protected]>
2010-09-19kconfig: expand file namesArnaud Lacombe1-2/+5
This will allow to use the following construct in source files: config FOO string default "foo" source "$FOO/Kconfig" Signed-off-by: Arnaud Lacombe <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Michal Marek <[email protected]>
2010-09-19kconfig: use the file's name of sourced fileArnaud Lacombe1-2/+3
Signed-off-by: Arnaud Lacombe <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Michal Marek <[email protected]>
2010-09-19kconfig: constify file nameArnaud Lacombe3-3/+3
Signed-off-by: Arnaud Lacombe <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Michal Marek <[email protected]>
2010-09-19kconfig: don't emit warning upon rootmenu's prompt redefinitionArnaud Lacombe1-1/+1
This silences the warning printed upon prompt redefinition for the rootmenu. We will encounter this redefinition when a "mainmenu" statement is specified and override the default prompt. Signed-off-by: Arnaud Lacombe <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Michal Marek <[email protected]>
2010-09-19kconfig: replace KERNELVERSION usage by the mainmenu's promptArnaud Lacombe5-26/+11
Signed-off-by: Arnaud Lacombe <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Michal Marek <[email protected]>
2010-09-19kconfig: delay gconf window initializationArnaud Lacombe1-6/+6
Delay the window initialization to let the rootmenu's prompt be initialized as it will be used to get the window's title. Signed-off-by: Arnaud Lacombe <[email protected]>
2010-09-19kconfig: expand by default the rootmenu's promptArnaud Lacombe1-0/+4
Signed-off-by: Arnaud Lacombe <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Michal Marek <[email protected]>
2010-09-19kconfig: add a symbol string expansion helperArnaud Lacombe2-0/+50
Signed-off-by: Arnaud Lacombe <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Michal Marek <[email protected]>
2010-09-19kconfig: regen parserArnaud Lacombe2-267/+287
Signed-off-by: Arnaud Lacombe <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Michal Marek <[email protected]>
2010-09-19kconfig: implement the `mainmenu' directiveArnaud Lacombe2-4/+13
If specified, the directive must be placed at the top of the Kconfig file. We need to change the grammar to make the mainmenu directive set the `rootmenu' prompt. This reflect how menu_add_prompt() works internally, ie. set the prompt of the `current_entry', pointing originally to `rootmenu'. Signed-off-by: Arnaud Lacombe <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Michal Marek <[email protected]>
2010-09-19kconfig: allow PACKAGE to be defined on the compiler's command-lineArnaud Lacombe1-0/+3
Signed-off-by: Arnaud Lacombe <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Michal Marek <[email protected]>
2010-09-19kconfig: rephrase help texts/comments not to include the package nameArnaud Lacombe6-54/+45
Signed-off-by: Arnaud Lacombe <[email protected]> Reviewed-by: Randy Dunlap <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Michal Marek <[email protected]>
2010-09-19kconfig: allow build-time definition of the internal config prefixArnaud Lacombe6-34/+43
Signed-off-by: Arnaud Lacombe <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Michal Marek <[email protected]>
2010-09-19kconfig: rephrase help text not to mention the internal prefixArnaud Lacombe2-11/+11
Signed-off-by: Arnaud Lacombe <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Michal Marek <[email protected]>
2010-09-19kconfig: replace a `switch()' statement by a more flexible `if()' statementArnaud Lacombe1-14/+5
With the upcoming dynamical configuration prefix, we can no longer assume that the prefix will start by a 'C'. As such, we can no longer hardcode this value in the `case ...:', so replace the `switch() { ... }' statement by a more flexible 'if () { ... }' statement. Signed-off-by: Arnaud Lacombe <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Michal Marek <[email protected]>
2010-09-17scripts/kconfig/gconf.glade Update broken web addresses.Justin P. Mattock1-1/+0
As discussed, remove the DOCTYPE declaration since libglade validates the file against itself.. Signed-off-by: Justin P. Mattock <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-09-13kconfig: Simplify Makefile for xconfigMichal Marek1-2/+2
Signed-off-by: Michal Marek <[email protected]>
2010-09-13Fix QT4 moc, cflags libs detection on dual QT3/Qt4 systemsAlexander Stein1-6/+4
On system with QT3 and QT4 qmake in PATH may be from QT3. So we use pkg-config for proper QT4 detection. By reqesting cflags and libs for either QtCore, QtGui and QtSupport include dirs and libs get listed several times, but so we won't mis anything Signed-off-by: Alexander Stein <[email protected]> Acked-by: Randy Dunlap <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-09-13nconfig: Fix help for choice menusStephen Boyd1-0/+2
When getting the help for a choice menu with a help section (for example the "Choose SLAB allocator" menu) nconfig pops up a window with nothing inside it. This is due to show_help() passing an empty string to show_scroll_win()'s 3rd argument. The option really does have help though, but it isn't a config symbol, so just add the help text for the option, and don't try to add anything else like the config option name. Signed-off-by: Stephen Boyd <[email protected]> Acked-by: Nir Tzachar <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-09-08kbuild: fix oldnoconfig to do the right thingKyle McMartin1-1/+1
Commit 861b4ea4 broke oldnoconfig when removed the oldnoconfig checks on if (input_mode == nonint_oldconfig || input_mode == oldnoconfig) { if (input_mode == nonint_oldconfig && sym->name && !sym_is_choice_value(sym)) { to avoid oldnoconfig chugging through the else stanza. Fix that to restore expected behaviour (which I've confirmed in the Fedora kernel build that the configs end up looking the same.) Signed-off-by: Kyle McMartin <[email protected]> Acked-by: Sam Ravnborg <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-09-06xconfig: Change the titlebar if using Qt3Michal Marek1-2/+8
Qt4 is now used by default and will get more testing. In case someone still uses Qt3 and reports a bug, make it easy to recognize that this is Qt3. Acked-by: Alexander Stein <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-09-01kconfig qconf: port to QT4Alexander Stein3-146/+168
A straight forward port to QT4 using qt3to4 and compiling against qt3support * Use pkg-config to detect QT4 which is hopefully portable enough * If no QT4, QT3 will by tried instead * Classes renamed using qt3to4 * If build using QT3 renamed to QT3 class names using defines * ConfigInfoView::menu has to be renamed as QT4 moc strips struct from struct menu and creates a name conflict * QT2 support has been dropped * The hidden options inserted in 39a4897c1bb66e8a36043c105d7fd73d8b32b480 are use in native API Signed-off-by: Alexander Stein <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-31kbuild: use getopt_long(), not its _only() variantArnaud Lacombe1-1/+1
NetBSD lacks getopt_long_only() whereas getopt_long() works just fine. Signed-off-by: Arnaud Lacombe <[email protected]> Acked-by: Sam Ravnborg <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-26kbuild: don't overwrite HOST_EXTRACFLAGSArnaud Lacombe1-4/+2
This might be used by the user to specify extra arguments for the host compiler. Signed-off-by: Arnaud Lacombe <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-17kbuild: fix typoArnaud Lacombe1-1/+1
Signed-off-by: Arnaud Lacombe <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-17kbuild: don't include `check-lxdialog' ldflags in global HOST_LOADLIBESArnaud Lacombe1-2/+3
On BSD systems, `check-lxdialog' would select -lcurses as the default curses library which would conflict with -lncurses at runtime: curses' compatible symbols are getting handled by the system's curses library while the ncurses-specific symbols are getting handled by the ports' ncurses. This fixes `nconf' segmentation fault on these systems. Signed-off-by: Arnaud Lacombe <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-17kbuild: confdata.c explicitly reference errno, thus need <errno.h>Arnaud Lacombe1-0/+1
This fixes: % gmake LKC_GENPARSER=1 menuconfig [...] scripts/kconfig/confdata.c:739: error: 'errno' undeclared (first use in this function) scripts/kconfig/confdata.c:739: error: (Each undeclared identifier is reported only once scripts/kconfig/confdata.c:739: error: for each function it appears in.) scripts/kconfig/confdata.c:739: error: 'ENOENT' undeclared (first use in this function) triggered on NetBSD. Signed-off-by: Arnaud Lacombe <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-16nconfig: add search supportNir Tzachar3-180/+208
Remove the old hotkeys feature, and replace it by an interactive string search. From nconfig help: Searching: pressing '/' triggers interactive search mode. nconfig performs a case insensitive search for the string in the menu prompts (no regex support). Pressing the up/down keys highlights the previous/next matching item. Backspace removes one character from the match string. Pressing either '/' again or ESC exits search mode. All other keys behave normally. Miscellaneous other changes (including Rundy's and Justin's input). Signed-off-by: Nir Tzachar <[email protected]> Acked-by: Sam Ravnborg <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-15kconfig: fix segfault when detecting recursive dependencySam Ravnborg1-0/+2
Following sample Kconfig generated a segfault: config FOO bool select PERF_EVENTS if HAVE_HW_BREAKPOINT config PERF_EVENTS bool config HAVE_HW_BREAKPOINT bool depends on PERF_EVENTS Fix by reverting back to a valid property if there was no property on the stack of symbols. The above pattern were seen in sh Kconfig. A fix for the Kconfig file has been sent to the sh folks. Signed-off-by: Sam Ravnborg <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-15kconfig: fix savedefconfig with choice marked optionalSam Ravnborg1-2/+4
savedefconfig failed to save the correct minimal config when it encountered a choice marked optional. Consider following minimal configuration: $cat Kconfig choice prompt "choice" optional config A bool "a" config B bool "b" endchoice $cat .config | grep -v ^# CONFIG_A=y $conf --savedefconfig=defconfig Kconfig would before this fix result in an empty file, because kconfig would assume that CONFIG_A=y is a default value. But because the choice is optional the default is that both A and B are =n. Fix so we handle optional choices correct. Signed-off-by: Sam Ravnborg <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-13kconfig: Fix warning: ignoring return value of 'fgets'Jean Sacren2-2/+16
This fix facilitates fgets() either it returns on success or on error or when end of file occurs. Signed-off-by: Jean Sacren <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-13kconfig: Fix warning: ignoring return value of 'fwrite'Jean Sacren3-2/+9
This fix facilitates fwrite() in both confdata.c and expr.c, either it succeeds in writing, or an error occurs, or the end of file is reached. Signed-off-by: Jean Sacren <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-13nconfig: Fix segfault when menu is emptyAndrej Gelenberg1-0/+2
nconf crush with segfault if press right arrow in empty menu. Signed-off-by: Andrej Gelenberg <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-12kconfig: fix tristate choice with minimal configSam Ravnborg1-35/+67
If a minimal config did not specify the value of all choice values, the resulting configuration could have wrong values. Consider following example: config M def_bool y option modules choice prompt "choice list" config A tristate "a" config B tristate "b" endchoice With a defconfig like this: CONFIG_M=y CONFIG_A=y The resulting configuration would have CONFIG_A=m which was unexpected. The problem was not not all choice values were set and thus kconfig calculated a wrong value. The fix is to set all choice values when we read a defconfig files. conf_set_all_new_symbols() is refactored such that random choice values are now handled by a dedicated function. And new choice values are set by set_all_choice_values(). This was not the minimal fix, but the fix that resulted in the most readable code. Signed-off-by: Sam Ravnborg <[email protected]> Reported-by: Arve Hjønnevåg <[email protected]> Tested-by: Arve Hjønnevåg <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-12kconfig: fix savedefconfig for tristate choicesSam Ravnborg1-4/+3
savedefconfig failed to save choice symbols equal to 'y' for tristate choices. This resulted in this value being lost. In particular is fixes an issue where make ARCH=avr32 atngw100_defconfig make ARCH=avr32 savedefconfig cp defconfig arch/avr32/configs/atngw100_defconfig make ARCH=avr32 atngw100_defconfig diff -u .config .config.old failed to produce an identical .config. Signed-off-by: Sam Ravnborg <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-04Merge commit 'v2.6.35' into kbuild/kconfigMichal Marek15241-690787/+1248926
Conflicts: scripts/kconfig/Makefile
2010-08-03kconfig: add savedefconfigSam Ravnborg6-1/+171
savedefconfig will save a minimal config to a file named "defconfig". The config symbols are saved in the same order as they appear in the menu structure so it should be possible to map them to the relevant menus if desired. The implementation was tested against several minimal configs for arm which was created using brute-force. There was one regression related to default numbers which had their valid range further limited by another symbol. Sample: config FOO int "foo" default 4 config BAR int "bar" range 0 FOO If FOO is set to 3 then BAR cannot take a value higher than 3. But the current implementation will set BAR equal to 4. This is seldomly used and the final configuration is OK, and the fix was non-trivial. So it was documented in the code and left as is. Signed-off-by: Sam Ravnborg <[email protected]> Acked-by: Uwe Kleine-König <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-03kconfig: code refactoring in confdata.cSam Ravnborg1-67/+70
Add a a few local functions to avoid some code duplication No functional changes. Signed-off-by: Sam Ravnborg <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-03kconfig: refactor code in symbol.cSam Ravnborg2-13/+34
Move logic to determine default for a choice to a separate function. No functional changes. Signed-off-by: Sam Ravnborg <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-03kconfig: add alldefconfigSam Ravnborg3-7/+15
alldefconfig create a configuration with all values set to their default value (form the Kconfig files). This may be useful when we try to use more sensible default values and may also be used in combination with the minimal defconfigs. Signed-off-by: Sam Ravnborg <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-03kconfig: print more info when we see a recursive dependencyRoman Zippel1-15/+127
Consider following kconfig file: config TEST1 bool "test 1" depends on TEST2 config TEST2 bool "test 2" depends on TEST1 Previously kconfig would report: foo:6:error: found recursive dependency: TEST2 -> TEST1 -> TEST2 With the following patch kconfig reports: foo:5:error: recursive dependency detected! foo:5: symbol TEST2 depends on TEST1 foo:1: symbol TEST1 depends on TEST2 Note that we now report where the offending symbols are defined. This can be a great help for complex situations involving several files. Patch is originally from Roman Zippel with a few adjustments by Sam. Signed-off-by: Sam Ravnborg <[email protected]> Cc: Roman Zippel <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-03kconfig: save location of config symbolsSam Ravnborg3-0/+5
When we add a new config symbol save the file/line so we later can refer to their location. The information is saved as a property to a config symbol because we may have multiple definitions of the same symbol. This has the side-effect that a symbol always has at least one property. Signed-off-by: Sam Ravnborg <[email protected]> Cc: Roman Zippel <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-03kconfig: change nonint_oldconfig to listnewconfigSam Ravnborg2-27/+14
Rename to a name that better match the other kconfig targets. listnewconfig shall read as: - list new options compared to current configuration New options are now written to stdout so one can redirect the output. Do not exit with an error code if there is new options. These are feature changes compared to the original nonint_oldconfig - but as this feature has not yet been in a released kernel it should not matter. It is still possible to do: make listnewconfig lookup new config options in Kconfig* edit .config Signed-off-by: Sam Ravnborg <[email protected]> Cc: Aristeu Rozanski <[email protected]> Acked-by: Aristeu Rozanski <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-03kconfig: rename loose_nonint_oldconfig => oldnoconfigSam Ravnborg2-11/+10
Rename target to something that fall more in line with the other kconfig targets. oldnoconfig shall read as: - read the old configuration and set all new options to no Signed-off-by: Sam Ravnborg <[email protected]> Cc: Aristeu Rozanski <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2010-08-03kconfig: use long options in confSam Ravnborg2-126/+105
The list of options supported by conf is growing and their abbreviation did not resemble anything usefull. So drop the single letter options in favour of long options. The long options are named equal to what we know from the make target. The internal implmentation was changed to match this, resulting in much more readable code. Support for short options is dropped - no one is supposed to call this program direct anyway. Signed-off-by: Sam Ravnborg <[email protected]> Signed-off-by: Michal Marek <[email protected]>