linux-kbuild.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/10] kconfig: various fixes and documentation updates
@ 2009-04-19 13:41 Markus Heidelberg
  2009-04-19 13:41 ` [PATCH 01/10] kconfig: fix typo "mconfig" to "menuconfig" in a comment Markus Heidelberg
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: Markus Heidelberg @ 2009-04-19 13:41 UTC (permalink / raw)
  To: Roman Zippel; +Cc: linux-kbuild, linux-kernel, Markus Heidelberg

Patches  1-3: documentation updates, typo fixes
Patch      4: .gitignore
Patches  5-8: qconf fixes (compiler warnings/errors)
Patches 9-10: environment variable fixes (KCONFIG_CONFIG + KCONFIG_AUTOCONFIG)

Markus Heidelberg (10):
  kconfig: fix typo "mconfig" to "menuconfig" in a comment
  kconfig: add a note about the deps to the 'silentoldconfig' help
  kconfig: resort the documentation of the environment variables
  gitignore: ignore Kconfig i18n files
  kconfig qconf: fix -Wall compiler warnings
  kconfig qconf: fix namespace for Horizontal and Vertical enum values
  kconfig qconf: add namespace for use of Key_ enum values
  kconfig qconf: fix the type of the desktop widget
  kconfig: do not hardcode ".config" filename
  kconfig: do not hardcode "include/config/auto.conf" filename

 Documentation/kbuild/kconfig.txt |  116 +++++++++++++++++++------------------
 README                           |    1 +
 scripts/kconfig/.gitignore       |    2 +
 scripts/kconfig/Makefile         |    4 +-
 scripts/kconfig/conf.c           |    7 +-
 scripts/kconfig/confdata.c       |   20 ++++---
 scripts/kconfig/lkc.h            |    1 +
 scripts/kconfig/qconf.cc         |   48 +++++++++-------
 scripts/kconfig/util.c           |    6 +-
 9 files changed, 112 insertions(+), 93 deletions(-)


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [PATCH 01/10] kconfig: fix typo "mconfig" to "menuconfig" in a comment
  2009-04-19 13:41 [PATCH 00/10] kconfig: various fixes and documentation updates Markus Heidelberg
@ 2009-04-19 13:41 ` Markus Heidelberg
  2009-04-19 13:41 ` [PATCH 02/10] kconfig: add a note about the deps to the 'silentoldconfig' help Markus Heidelberg
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Markus Heidelberg @ 2009-04-19 13:41 UTC (permalink / raw)
  To: Roman Zippel; +Cc: linux-kbuild, linux-kernel, Markus Heidelberg


Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de>
---
 scripts/kconfig/Makefile |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/scripts/kconfig/Makefile b/scripts/kconfig/Makefile
index fa8c2dd..47e3f2e 100644
--- a/scripts/kconfig/Makefile
+++ b/scripts/kconfig/Makefile
@@ -104,7 +104,7 @@ HOST_EXTRACFLAGS += -DLOCALE
 # ===========================================================================
 # Shared Makefile for the various kconfig executables:
 # conf:	  Used for defconfig, oldconfig and related targets
-# mconf:  Used for the mconfig target.
+# mconf:  Used for the menuconfig target
 #         Utilizes the lxdialog package
 # qconf:  Used for the xconfig target
 #         Based on QT which needs to be installed to compile it
-- 
1.6.3.rc1.24.g467d50


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 02/10] kconfig: add a note about the deps to the 'silentoldconfig' help
  2009-04-19 13:41 [PATCH 00/10] kconfig: various fixes and documentation updates Markus Heidelberg
  2009-04-19 13:41 ` [PATCH 01/10] kconfig: fix typo "mconfig" to "menuconfig" in a comment Markus Heidelberg
@ 2009-04-19 13:41 ` Markus Heidelberg
  2009-04-19 13:41 ` [PATCH 03/10] kconfig: resort the documentation of the environment variables Markus Heidelberg
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Markus Heidelberg @ 2009-04-19 13:41 UTC (permalink / raw)
  To: Roman Zippel; +Cc: linux-kbuild, linux-kernel, Markus Heidelberg


Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de>
---
 README                   |    1 +
 scripts/kconfig/Makefile |    2 +-
 2 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/README b/README
index d6c6c74..7a078ff 100644
--- a/README
+++ b/README
@@ -174,6 +174,7 @@ CONFIGURING the kernel:
 	"make silentoldconfig"
 			   Like above, but avoids cluttering the screen
 			   with questions already answered.
+			   Additionally updates the dependencies.
 	"make defconfig"   Create a ./.config file by using the default
 			   symbol values from arch/$ARCH/defconfig.
 	"make allyesconfig"
diff --git a/scripts/kconfig/Makefile b/scripts/kconfig/Makefile
index 47e3f2e..5ddf8be 100644
--- a/scripts/kconfig/Makefile
+++ b/scripts/kconfig/Makefile
@@ -83,7 +83,7 @@ help:
 	@echo  '  xconfig	  - Update current config utilising a QT based front-end'
 	@echo  '  gconfig	  - Update current config utilising a GTK based front-end'
 	@echo  '  oldconfig	  - Update current config utilising a provided .config as base'
-	@echo  '  silentoldconfig - Same as oldconfig, but quietly'
+	@echo  '  silentoldconfig - Same as oldconfig, but quietly, additionally update deps'
 	@echo  '  randconfig	  - New config with random answer to all options'
 	@echo  '  defconfig	  - New config with default answer to all options'
 	@echo  '  allmodconfig	  - New config selecting modules when possible'
-- 
1.6.3.rc1.24.g467d50


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 03/10] kconfig: resort the documentation of the environment variables
  2009-04-19 13:41 [PATCH 00/10] kconfig: various fixes and documentation updates Markus Heidelberg
  2009-04-19 13:41 ` [PATCH 01/10] kconfig: fix typo "mconfig" to "menuconfig" in a comment Markus Heidelberg
  2009-04-19 13:41 ` [PATCH 02/10] kconfig: add a note about the deps to the 'silentoldconfig' help Markus Heidelberg
@ 2009-04-19 13:41 ` Markus Heidelberg
  2009-04-19 13:41 ` [PATCH 04/10] gitignore: ignore Kconfig i18n files Markus Heidelberg
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Markus Heidelberg @ 2009-04-19 13:41 UTC (permalink / raw)
  To: Roman Zippel; +Cc: linux-kbuild, linux-kernel, Markus Heidelberg

All the KCONFIG_ environment variables were previously located in a
section "Environment variables in 'menuconfig'", but neither are they
restricted to 'menuconfig' nor are they all used by 'menuconfig'.

Introduce the following three sections for these variables:
  * Environment variables for '*config'
  * Environment variables for '{allyes/allmod/allno/rand}config'
  * Environment variables for 'silentoldconfig'

Furthermore this puts MENUCONFIG_MODE next to MENUCONFIG_COLOR into a
common section "User interface options for 'menuconfig'".

Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de>
---
 Documentation/kbuild/kconfig.txt |  116 +++++++++++++++++++------------------
 1 files changed, 60 insertions(+), 56 deletions(-)

diff --git a/Documentation/kbuild/kconfig.txt b/Documentation/kbuild/kconfig.txt
index 26a7c0a..849b5e5 100644
--- a/Documentation/kbuild/kconfig.txt
+++ b/Documentation/kbuild/kconfig.txt
@@ -35,48 +35,26 @@ new .config files to see the differences:
 
 (Yes, we need something better here.)
 
-
-======================================================================
-menuconfig
---------------------------------------------------
-
-SEARCHING for CONFIG symbols
-
-Searching in menuconfig:
-
-	The Search function searches for kernel configuration symbol
-	names, so you have to know something close to what you are
-	looking for.
-
-	Example:
-		/hotplug
-		This lists all config symbols that contain "hotplug",
-		e.g., HOTPLUG, HOTPLUG_CPU, MEMORY_HOTPLUG.
-
-	For search help, enter / followed TAB-TAB-TAB (to highlight
-	<Help>) and Enter.  This will tell you that you can also use
-	regular expressions (regexes) in the search string, so if you
-	are not interested in MEMORY_HOTPLUG, you could try
-
-		/^hotplug
-
-
 ______________________________________________________________________
-Color Themes for 'menuconfig'
+Environment variables for '*config'
 
-It is possible to select different color themes using the variable
-MENUCONFIG_COLOR.  To select a theme use:
+KCONFIG_CONFIG
+--------------------------------------------------
+This environment variable can be used to specify a default kernel config
+file name to override the default name of ".config".
 
-	make MENUCONFIG_COLOR=<theme> menuconfig
+KCONFIG_OVERWRITECONFIG
+--------------------------------------------------
+If you set KCONFIG_OVERWRITECONFIG in the environment, Kconfig will not
+break symlinks when .config is a symlink to somewhere else.
 
-Available themes are:
-  mono       => selects colors suitable for monochrome displays
-  blackbg    => selects a color scheme with black background
-  classic    => theme with blue background. The classic look
-  bluetitle  => a LCD friendly version of classic. (default)
+KCONFIG_NOTIMESTAMP
+--------------------------------------------------
+If this environment variable exists and is non-null, the timestamp line
+in generated .config files is omitted.
 
 ______________________________________________________________________
-Environment variables in 'menuconfig'
+Environment variables for '{allyes/allmod/allno/rand}config'
 
 KCONFIG_ALLCONFIG
 --------------------------------------------------
@@ -95,8 +73,7 @@ values.
 This enables you to create "miniature" config (miniconfig) or custom
 config files containing just the config symbols that you are interested
 in.  Then the kernel config system generates the full .config file,
-including dependencies of your miniconfig file, based on the miniconfig
-file.
+including symbols of your miniconfig file.
 
 This 'KCONFIG_ALLCONFIG' file is a config file which contains
 (usually a subset of all) preset config symbols.  These variable
@@ -113,26 +90,14 @@ These examples will disable most options (allnoconfig) but enable or
 disable the options that are explicitly listed in the specified
 mini-config files.
 
+______________________________________________________________________
+Environment variables for 'silentoldconfig'
+
 KCONFIG_NOSILENTUPDATE
 --------------------------------------------------
 If this variable has a non-blank value, it prevents silent kernel
 config udpates (requires explicit updates).
 
-KCONFIG_CONFIG
---------------------------------------------------
-This environment variable can be used to specify a default kernel config
-file name to override the default name of ".config".
-
-KCONFIG_OVERWRITECONFIG
---------------------------------------------------
-If you set KCONFIG_OVERWRITECONFIG in the environment, Kconfig will not
-break symlinks when .config is a symlink to somewhere else.
-
-KCONFIG_NOTIMESTAMP
---------------------------------------------------
-If this environment variable exists and is non-null, the timestamp line
-in generated .config files is omitted.
-
 KCONFIG_AUTOCONFIG
 --------------------------------------------------
 This environment variable can be set to specify the path & name of the
@@ -143,15 +108,54 @@ KCONFIG_AUTOHEADER
 This environment variable can be set to specify the path & name of the
 "autoconf.h" (header) file.  Its default value is "include/linux/autoconf.h".
 
+
+======================================================================
+menuconfig
+--------------------------------------------------
+
+SEARCHING for CONFIG symbols
+
+Searching in menuconfig:
+
+	The Search function searches for kernel configuration symbol
+	names, so you have to know something close to what you are
+	looking for.
+
+	Example:
+		/hotplug
+		This lists all config symbols that contain "hotplug",
+		e.g., HOTPLUG, HOTPLUG_CPU, MEMORY_HOTPLUG.
+
+	For search help, enter / followed TAB-TAB-TAB (to highlight
+	<Help>) and Enter.  This will tell you that you can also use
+	regular expressions (regexes) in the search string, so if you
+	are not interested in MEMORY_HOTPLUG, you could try
+
+		/^hotplug
+
 ______________________________________________________________________
-menuconfig User Interface Options
-----------------------------------------------------------------------
+User interface options for 'menuconfig'
+
+MENUCONFIG_COLOR
+--------------------------------------------------
+It is possible to select different color themes using the variable
+MENUCONFIG_COLOR.  To select a theme use:
+
+	make MENUCONFIG_COLOR=<theme> menuconfig
+
+Available themes are:
+  mono       => selects colors suitable for monochrome displays
+  blackbg    => selects a color scheme with black background
+  classic    => theme with blue background. The classic look
+  bluetitle  => a LCD friendly version of classic. (default)
+
 MENUCONFIG_MODE
 --------------------------------------------------
 This mode shows all sub-menus in one large tree.
 
 Example:
-	MENUCONFIG_MODE=single_menu make menuconfig
+	make MENUCONFIG_MODE=single_menu menuconfig
+
 
 ======================================================================
 xconfig
-- 
1.6.3.rc1.24.g467d50


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 04/10] gitignore: ignore Kconfig i18n files
  2009-04-19 13:41 [PATCH 00/10] kconfig: various fixes and documentation updates Markus Heidelberg
                   ` (2 preceding siblings ...)
  2009-04-19 13:41 ` [PATCH 03/10] kconfig: resort the documentation of the environment variables Markus Heidelberg
@ 2009-04-19 13:41 ` Markus Heidelberg
  2009-04-19 13:41 ` [PATCH 05/10] kconfig qconf: fix -Wall compiler warnings Markus Heidelberg
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Markus Heidelberg @ 2009-04-19 13:41 UTC (permalink / raw)
  To: Roman Zippel; +Cc: linux-kbuild, linux-kernel, Markus Heidelberg


Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de>
---
 scripts/kconfig/.gitignore |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/scripts/kconfig/.gitignore b/scripts/kconfig/.gitignore
index b49584c..01e185f 100644
--- a/scripts/kconfig/.gitignore
+++ b/scripts/kconfig/.gitignore
@@ -8,6 +8,8 @@ lex.*.c
 zconf.hash.c
 *.moc
 lkc_defs.h
+gconf.glade.h
+*.pot
 
 #
 # configuration programs
-- 
1.6.3.rc1.24.g467d50


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 05/10] kconfig qconf: fix -Wall compiler warnings
  2009-04-19 13:41 [PATCH 00/10] kconfig: various fixes and documentation updates Markus Heidelberg
                   ` (3 preceding siblings ...)
  2009-04-19 13:41 ` [PATCH 04/10] gitignore: ignore Kconfig i18n files Markus Heidelberg
@ 2009-04-19 13:41 ` Markus Heidelberg
  2009-04-19 13:41 ` [PATCH 06/10] kconfig qconf: fix namespace for Horizontal and Vertical enum values Markus Heidelberg
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Markus Heidelberg @ 2009-04-19 13:41 UTC (permalink / raw)
  To: Roman Zippel; +Cc: linux-kbuild, linux-kernel, Markus Heidelberg

These compiler warnings occure when adding -Wall to HOSTCXXFLAGS in
/Makefile

scripts/kconfig/qconf.h: In constructor ‘ConfigInfoView::ConfigInfoView(QWidget*, const char*)’:
scripts/kconfig/qconf.h:274: warning: ‘ConfigInfoView::menu’ will be initialized after
scripts/kconfig/qconf.h:273: warning:   ‘symbol* ConfigInfoView::sym’
scripts/kconfig/qconf.cc:922: warning:   when initialized here

scripts/kconfig/qconf.cc: In member function ‘void ConfigMainWindow::setMenuLink(menu*)’:
scripts/kconfig/qconf.cc:1498: warning: enumeration value ‘menuMode’ not handled in switch
scripts/kconfig/qconf.cc:1498: warning: enumeration value ‘listMode’ not handled in switch

scripts/kconfig/qconf.cc: In member function ‘void ConfigMainWindow::saveSettings()’:
scripts/kconfig/qconf.cc:1664: warning: enumeration value ‘menuMode’ not handled in switch
scripts/kconfig/qconf.cc:1664: warning: enumeration value ‘listMode’ not handled in switch

Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de>
---
 scripts/kconfig/qconf.cc |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/scripts/kconfig/qconf.cc b/scripts/kconfig/qconf.cc
index 5d0fd38..2bd6ed0 100644
--- a/scripts/kconfig/qconf.cc
+++ b/scripts/kconfig/qconf.cc
@@ -920,7 +920,7 @@ void ConfigView::updateListAll(void)
 }
 
 ConfigInfoView::ConfigInfoView(QWidget* parent, const char *name)
-	: Parent(parent, name), menu(0), sym(0)
+	: Parent(parent, name), sym(0), menu(0)
 {
 	if (name) {
 		configSettings->beginGroup(name);
@@ -1524,6 +1524,8 @@ void ConfigMainWindow::setMenuLink(struct menu *menu)
 	case fullMode:
 		list = configList;
 		break;
+	default:
+		break;
 	}
 
 	if (list) {
@@ -1673,6 +1675,9 @@ void ConfigMainWindow::saveSettings(void)
 	case fullMode :
 		entry = "full";
 		break;
+
+	default:
+		break;
 	}
 	configSettings->writeEntry("/listMode", entry);
 
-- 
1.6.3.rc1.24.g467d50


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 06/10] kconfig qconf: fix namespace for Horizontal and Vertical enum values
  2009-04-19 13:41 [PATCH 00/10] kconfig: various fixes and documentation updates Markus Heidelberg
                   ` (4 preceding siblings ...)
  2009-04-19 13:41 ` [PATCH 05/10] kconfig qconf: fix -Wall compiler warnings Markus Heidelberg
@ 2009-04-19 13:41 ` Markus Heidelberg
  2009-04-19 13:41 ` [PATCH 07/10] kconfig qconf: add namespace for use of Key_ " Markus Heidelberg
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Markus Heidelberg @ 2009-04-19 13:41 UTC (permalink / raw)
  To: Roman Zippel; +Cc: linux-kbuild, linux-kernel, Markus Heidelberg

They were used as QSplitter::Horizontal resp. QSplitter::Vertical, but
are defined in the 'Qt' namespace.

Fixes the following compiler errors after a quick conversion with 'qt3to4',
which occured with g++ 3.4.6 and 4.1.2, but not anymore with 4.3.2.

scripts/kconfig/qconf.cc: In constructor 'ConfigSearchWindow::ConfigSearchWindow(ConfigMainWindow*, const char*)':
scripts/kconfig/qconf.cc:1213: error: 'Vertical' is not a member of 'QSplitter'

scripts/kconfig/qconf.cc: In constructor 'ConfigMainWindow::ConfigMainWindow()':
scripts/kconfig/qconf.cc:1304: error: 'Horizontal' is not a member of 'QSplitter'
scripts/kconfig/qconf.cc:1311: error: 'Vertical' is not a member of 'QSplitter'

Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de>
---
 scripts/kconfig/qconf.cc |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/scripts/kconfig/qconf.cc b/scripts/kconfig/qconf.cc
index 2bd6ed0..7433dac 100644
--- a/scripts/kconfig/qconf.cc
+++ b/scripts/kconfig/qconf.cc
@@ -1199,7 +1199,7 @@ ConfigSearchWindow::ConfigSearchWindow(ConfigMainWindow* parent, const char *nam
 	layout1->addLayout(layout2);
 
 	split = new QSplitter(this);
-	split->setOrientation(QSplitter::Vertical);
+	split->setOrientation(Qt::Vertical);
 	list = new ConfigView(split, name);
 	list->list->mode = listMode;
 	info = new ConfigInfoView(split, name);
@@ -1290,14 +1290,14 @@ ConfigMainWindow::ConfigMainWindow(void)
 		move(x, y);
 
 	split1 = new QSplitter(this);
-	split1->setOrientation(QSplitter::Horizontal);
+	split1->setOrientation(Qt::Horizontal);
 	setCentralWidget(split1);
 
 	menuView = new ConfigView(split1, "menu");
 	menuList = menuView->list;
 
 	split2 = new QSplitter(split1);
-	split2->setOrientation(QSplitter::Vertical);
+	split2->setOrientation(Qt::Vertical);
 
 	// create config tree
 	configView = new ConfigView(split2, "config");
-- 
1.6.3.rc1.24.g467d50


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 07/10] kconfig qconf: add namespace for use of Key_ enum values
  2009-04-19 13:41 [PATCH 00/10] kconfig: various fixes and documentation updates Markus Heidelberg
                   ` (5 preceding siblings ...)
  2009-04-19 13:41 ` [PATCH 06/10] kconfig qconf: fix namespace for Horizontal and Vertical enum values Markus Heidelberg
@ 2009-04-19 13:41 ` Markus Heidelberg
  2009-04-19 13:41 ` [PATCH 08/10] kconfig qconf: fix the type of the desktop widget Markus Heidelberg
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Markus Heidelberg @ 2009-04-19 13:41 UTC (permalink / raw)
  To: Roman Zippel; +Cc: linux-kbuild, linux-kernel, Markus Heidelberg

They are defined in the 'Qt' namespace.

Fixes the following compiler errors after a quick conversion with 'qt3to4',
which occured with g++ 3.4.6 and 4.1.2, but not anymore with 4.3.2.

scripts/kconfig/qconf.cc: In member function 'virtual void ConfigLineEdit::keyPressEvent(QKeyEvent*)':
scripts/kconfig/qconf.cc:311: error: 'Key_Escape' was not declared in this scope
scripts/kconfig/qconf.cc:313: error: 'Key_Return' was not declared in this scope
scripts/kconfig/qconf.cc:314: error: 'Key_Enter' was not declared in this scope

scripts/kconfig/qconf.cc: In member function 'virtual void ConfigList::keyPressEvent(QKeyEvent*)':
scripts/kconfig/qconf.cc:653: error: 'Key_Escape' was not declared in this scope
scripts/kconfig/qconf.cc:666: error: 'Key_Return' was not declared in this scope
scripts/kconfig/qconf.cc:667: error: 'Key_Enter' was not declared in this scope
scripts/kconfig/qconf.cc:681: error: 'Key_Space' was not declared in this scope
scripts/kconfig/qconf.cc:684: error: 'Key_N' was not declared in this scope
scripts/kconfig/qconf.cc:687: error: 'Key_M' was not declared in this scope
scripts/kconfig/qconf.cc:690: error: 'Key_Y' was not declared in this scope

scripts/kconfig/qconf.cc: In constructor 'ConfigMainWindow::ConfigMainWindow()':
scripts/kconfig/qconf.cc:1329: error: 'CTRL' was not declared in this scope
scripts/kconfig/qconf.cc:1329: error: 'Key_Q' was not declared in this scope
scripts/kconfig/qconf.cc:1331: error: 'Key_L' was not declared in this scope
scripts/kconfig/qconf.cc:1333: error: 'Key_S' was not declared in this scope
scripts/kconfig/qconf.cc:1340: error: 'Key_F' was not declared in this scope

Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de>
---
 scripts/kconfig/qconf.cc |   28 ++++++++++++++--------------
 1 files changed, 14 insertions(+), 14 deletions(-)

diff --git a/scripts/kconfig/qconf.cc b/scripts/kconfig/qconf.cc
index 7433dac..afae613 100644
--- a/scripts/kconfig/qconf.cc
+++ b/scripts/kconfig/qconf.cc
@@ -297,10 +297,10 @@ void ConfigLineEdit::show(ConfigItem* i)
 void ConfigLineEdit::keyPressEvent(QKeyEvent* e)
 {
 	switch (e->key()) {
-	case Key_Escape:
+	case Qt::Key_Escape:
 		break;
-	case Key_Return:
-	case Key_Enter:
+	case Qt::Key_Return:
+	case Qt::Key_Enter:
 		sym_set_string_value(item->menu->sym, text().latin1());
 		parent()->updateList(item);
 		break;
@@ -639,7 +639,7 @@ void ConfigList::keyPressEvent(QKeyEvent* ev)
 	struct menu *menu;
 	enum prop_type type;
 
-	if (ev->key() == Key_Escape && mode != fullMode && mode != listMode) {
+	if (ev->key() == Qt::Key_Escape && mode != fullMode && mode != listMode) {
 		emit parentSelected();
 		ev->accept();
 		return;
@@ -652,8 +652,8 @@ void ConfigList::keyPressEvent(QKeyEvent* ev)
 	item = (ConfigItem*)i;
 
 	switch (ev->key()) {
-	case Key_Return:
-	case Key_Enter:
+	case Qt::Key_Return:
+	case Qt::Key_Enter:
 		if (item->goParent) {
 			emit parentSelected();
 			break;
@@ -667,16 +667,16 @@ void ConfigList::keyPressEvent(QKeyEvent* ev)
 			emit menuSelected(menu);
 			break;
 		}
-	case Key_Space:
+	case Qt::Key_Space:
 		changeValue(item);
 		break;
-	case Key_N:
+	case Qt::Key_N:
 		setValue(item, no);
 		break;
-	case Key_M:
+	case Qt::Key_M:
 		setValue(item, mod);
 		break;
-	case Key_Y:
+	case Qt::Key_Y:
 		setValue(item, yes);
 		break;
 	default:
@@ -1315,18 +1315,18 @@ ConfigMainWindow::ConfigMainWindow(void)
 	backAction = new QAction("Back", QPixmap(xpm_back), _("Back"), 0, this);
 	  connect(backAction, SIGNAL(activated()), SLOT(goBack()));
 	  backAction->setEnabled(FALSE);
-	QAction *quitAction = new QAction("Quit", _("&Quit"), CTRL+Key_Q, this);
+	QAction *quitAction = new QAction("Quit", _("&Quit"), Qt::CTRL + Qt::Key_Q, this);
 	  connect(quitAction, SIGNAL(activated()), SLOT(close()));
-	QAction *loadAction = new QAction("Load", QPixmap(xpm_load), _("&Load"), CTRL+Key_L, this);
+	QAction *loadAction = new QAction("Load", QPixmap(xpm_load), _("&Load"), Qt::CTRL + Qt::Key_L, this);
 	  connect(loadAction, SIGNAL(activated()), SLOT(loadConfig()));
-	saveAction = new QAction("Save", QPixmap(xpm_save), _("&Save"), CTRL+Key_S, this);
+	saveAction = new QAction("Save", QPixmap(xpm_save), _("&Save"), Qt::CTRL + Qt::Key_S, this);
 	  connect(saveAction, SIGNAL(activated()), SLOT(saveConfig()));
 	conf_set_changed_callback(conf_changed);
 	// Set saveAction's initial state
 	conf_changed();
 	QAction *saveAsAction = new QAction("Save As...", _("Save &As..."), 0, this);
 	  connect(saveAsAction, SIGNAL(activated()), SLOT(saveConfigAs()));
-	QAction *searchAction = new QAction("Find", _("&Find"), CTRL+Key_F, this);
+	QAction *searchAction = new QAction("Find", _("&Find"), Qt::CTRL + Qt::Key_F, this);
 	  connect(searchAction, SIGNAL(activated()), SLOT(searchConfig()));
 	QAction *singleViewAction = new QAction("Single View", QPixmap(xpm_single_view), _("Single View"), 0, this);
 	  connect(singleViewAction, SIGNAL(activated()), SLOT(showSingleView()));
-- 
1.6.3.rc1.24.g467d50


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 08/10] kconfig qconf: fix the type of the desktop widget
  2009-04-19 13:41 [PATCH 00/10] kconfig: various fixes and documentation updates Markus Heidelberg
                   ` (6 preceding siblings ...)
  2009-04-19 13:41 ` [PATCH 07/10] kconfig qconf: add namespace for use of Key_ " Markus Heidelberg
@ 2009-04-19 13:41 ` Markus Heidelberg
  2009-04-19 13:41 ` [PATCH 09/10] kconfig: do not hardcode ".config" filename Markus Heidelberg
  2009-04-19 13:41 ` [PATCH 10/10] kconfig: do not hardcode "include/config/auto.conf" filename Markus Heidelberg
  9 siblings, 0 replies; 11+ messages in thread
From: Markus Heidelberg @ 2009-04-19 13:41 UTC (permalink / raw)
  To: Roman Zippel; +Cc: linux-kbuild, linux-kernel, Markus Heidelberg

QApplication::desktop() returns a pointer to QDesktopWidget, not to
QWidget.

Fixes the following compiler error after a quick conversion with 'qt3to4',
which occured with g++ 3.4.6 and 4.1.2, but not anymore with 4.3.2.

scripts/kconfig/qconf.cc: In constructor 'ConfigMainWindow::ConfigMainWindow()':
scripts/kconfig/qconf.cc:1289: error: cannot convert 'QDesktopWidget*' to 'QWidget*' in initialization

Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de>
---
 scripts/kconfig/qconf.cc |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/scripts/kconfig/qconf.cc b/scripts/kconfig/qconf.cc
index afae613..19811fc 100644
--- a/scripts/kconfig/qconf.cc
+++ b/scripts/kconfig/qconf.cc
@@ -5,6 +5,7 @@
 
 #include <qapplication.h>
 #include <qmainwindow.h>
+#include <qdesktopwidget.h>
 #include <qtoolbar.h>
 #include <qlayout.h>
 #include <qvbox.h>
@@ -1275,7 +1276,7 @@ ConfigMainWindow::ConfigMainWindow(void)
 	int x, y, width, height;
 	char title[256];
 
-	QWidget *d = configApp->desktop();
+	QDesktopWidget *d = configApp->desktop();
 	snprintf(title, sizeof(title), _("Linux Kernel v%s Configuration"),
 		getenv("KERNELVERSION"));
 	setCaption(title);
-- 
1.6.3.rc1.24.g467d50


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 09/10] kconfig: do not hardcode ".config" filename
  2009-04-19 13:41 [PATCH 00/10] kconfig: various fixes and documentation updates Markus Heidelberg
                   ` (7 preceding siblings ...)
  2009-04-19 13:41 ` [PATCH 08/10] kconfig qconf: fix the type of the desktop widget Markus Heidelberg
@ 2009-04-19 13:41 ` Markus Heidelberg
  2009-04-19 13:41 ` [PATCH 10/10] kconfig: do not hardcode "include/config/auto.conf" filename Markus Heidelberg
  9 siblings, 0 replies; 11+ messages in thread
From: Markus Heidelberg @ 2009-04-19 13:41 UTC (permalink / raw)
  To: Roman Zippel; +Cc: linux-kbuild, linux-kernel, Markus Heidelberg

Rather than hardcoding ".config" use conf_get_configname(), which also
respects the environment variable KCONFIG_CONFIG.

This fixes "make silentoldconfig" when KCONFIG_CONFIG is used and also
suggests the given filename for "Load" and "Save as" in qconf.

Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de>
---
 scripts/kconfig/conf.c   |    7 ++++---
 scripts/kconfig/qconf.cc |    4 ++--
 2 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/scripts/kconfig/conf.c b/scripts/kconfig/conf.c
index d190092..3baaaec 100644
--- a/scripts/kconfig/conf.c
+++ b/scripts/kconfig/conf.c
@@ -498,14 +498,15 @@ int main(int ac, char **av)
 	conf_parse(name);
 	//zconfdump(stdout);
 	if (sync_kconfig) {
-		if (stat(".config", &tmpstat)) {
+		name = conf_get_configname();
+		if (stat(name, &tmpstat)) {
 			fprintf(stderr, _("***\n"
 				"*** You have not yet configured your kernel!\n"
-				"*** (missing kernel .config file)\n"
+				"*** (missing kernel config file \"%s\")\n"
 				"***\n"
 				"*** Please run some configurator (e.g. \"make oldconfig\" or\n"
 				"*** \"make menuconfig\" or \"make xconfig\").\n"
-				"***\n"));
+				"***\n"), name);
 			exit(1);
 		}
 	}
diff --git a/scripts/kconfig/qconf.cc b/scripts/kconfig/qconf.cc
index 19811fc..ce7d508 100644
--- a/scripts/kconfig/qconf.cc
+++ b/scripts/kconfig/qconf.cc
@@ -1448,7 +1448,7 @@ ConfigMainWindow::ConfigMainWindow(void)
 
 void ConfigMainWindow::loadConfig(void)
 {
-	QString s = QFileDialog::getOpenFileName(".config", NULL, this);
+	QString s = QFileDialog::getOpenFileName(conf_get_configname(), NULL, this);
 	if (s.isNull())
 		return;
 	if (conf_read(QFile::encodeName(s)))
@@ -1464,7 +1464,7 @@ void ConfigMainWindow::saveConfig(void)
 
 void ConfigMainWindow::saveConfigAs(void)
 {
-	QString s = QFileDialog::getSaveFileName(".config", NULL, this);
+	QString s = QFileDialog::getSaveFileName(conf_get_configname(), NULL, this);
 	if (s.isNull())
 		return;
 	if (conf_write(QFile::encodeName(s)))
-- 
1.6.3.rc1.24.g467d50


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 10/10] kconfig: do not hardcode "include/config/auto.conf" filename
  2009-04-19 13:41 [PATCH 00/10] kconfig: various fixes and documentation updates Markus Heidelberg
                   ` (8 preceding siblings ...)
  2009-04-19 13:41 ` [PATCH 09/10] kconfig: do not hardcode ".config" filename Markus Heidelberg
@ 2009-04-19 13:41 ` Markus Heidelberg
  9 siblings, 0 replies; 11+ messages in thread
From: Markus Heidelberg @ 2009-04-19 13:41 UTC (permalink / raw)
  To: Roman Zippel; +Cc: linux-kbuild, linux-kernel, Markus Heidelberg

Regardless of KCONFIG_AUTOCONFIG, the filename written as a Make target
into "include/config/auto.conf.cmd" was always the default one.

Of course this doesn't make it work for the Kernel kbuild system, since
there the filename is hardcoded at several places in the Makefiles.

Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de>
---
 scripts/kconfig/confdata.c |   20 ++++++++++++--------
 scripts/kconfig/lkc.h      |    1 +
 scripts/kconfig/util.c     |    6 +++---
 3 files changed, 16 insertions(+), 11 deletions(-)

diff --git a/scripts/kconfig/confdata.c b/scripts/kconfig/confdata.c
index 273d738..a04da34 100644
--- a/scripts/kconfig/confdata.c
+++ b/scripts/kconfig/confdata.c
@@ -41,6 +41,13 @@ const char *conf_get_configname(void)
 	return name ? name : ".config";
 }
 
+const char *conf_get_autoconfig_name(void)
+{
+	char *name = getenv("KCONFIG_AUTOCONFIG");
+
+	return name ? name : "include/config/auto.conf";
+}
+
 static char *conf_expand_value(const char *in)
 {
 	struct symbol *sym;
@@ -555,15 +562,14 @@ int conf_write(const char *name)
 
 int conf_split_config(void)
 {
-	char *name, path[128];
+	const char *name;
+	char path[128];
 	char *s, *d, c;
 	struct symbol *sym;
 	struct stat sb;
 	int res, i, fd;
 
-	name = getenv("KCONFIG_AUTOCONFIG");
-	if (!name)
-		name = "include/config/auto.conf";
+	name = conf_get_autoconfig_name();
 	conf_read_simple(name, S_DEF_AUTO);
 
 	if (chdir("include/config"))
@@ -670,7 +676,7 @@ int conf_write_autoconf(void)
 {
 	struct symbol *sym;
 	const char *str;
-	char *name;
+	const char *name;
 	FILE *out, *out_h;
 	time_t now;
 	int i, l;
@@ -773,9 +779,7 @@ int conf_write_autoconf(void)
 		name = "include/linux/autoconf.h";
 	if (rename(".tmpconfig.h", name))
 		return 1;
-	name = getenv("KCONFIG_AUTOCONFIG");
-	if (!name)
-		name = "include/config/auto.conf";
+	name = conf_get_autoconfig_name();
 	/*
 	 * This must be the last step, kbuild has a dependency on auto.conf
 	 * and this marks the successful completion of the previous steps.
diff --git a/scripts/kconfig/lkc.h b/scripts/kconfig/lkc.h
index 4a9af6f..f379b0b 100644
--- a/scripts/kconfig/lkc.h
+++ b/scripts/kconfig/lkc.h
@@ -74,6 +74,7 @@ char *zconf_curname(void);
 
 /* confdata.c */
 const char *conf_get_configname(void);
+const char *conf_get_autoconfig_name(void);
 char *conf_get_default_confname(void);
 void sym_set_change_count(int count);
 void sym_add_change_count(int count);
diff --git a/scripts/kconfig/util.c b/scripts/kconfig/util.c
index 3cc9f93..b6b2a46 100644
--- a/scripts/kconfig/util.c
+++ b/scripts/kconfig/util.c
@@ -46,8 +46,8 @@ int file_write_dep(const char *name)
 		else
 			fprintf(out, "\t%s\n", file->name);
 	}
-	fprintf(out, "\ninclude/config/auto.conf: \\\n"
-		     "\t$(deps_config)\n\n");
+	fprintf(out, "\n%s: \\\n"
+		     "\t$(deps_config)\n\n", conf_get_autoconfig_name());
 
 	expr_list_for_each_sym(sym_env_list, e, sym) {
 		struct property *prop;
@@ -61,7 +61,7 @@ int file_write_dep(const char *name)
 		if (!value)
 			value = "";
 		fprintf(out, "ifneq \"$(%s)\" \"%s\"\n", env_sym->name, value);
-		fprintf(out, "include/config/auto.conf: FORCE\n");
+		fprintf(out, "%s: FORCE\n", conf_get_autoconfig_name());
 		fprintf(out, "endif\n");
 	}
 
-- 
1.6.3.rc1.24.g467d50


^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2009-04-19 13:41 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-04-19 13:41 [PATCH 00/10] kconfig: various fixes and documentation updates Markus Heidelberg
2009-04-19 13:41 ` [PATCH 01/10] kconfig: fix typo "mconfig" to "menuconfig" in a comment Markus Heidelberg
2009-04-19 13:41 ` [PATCH 02/10] kconfig: add a note about the deps to the 'silentoldconfig' help Markus Heidelberg
2009-04-19 13:41 ` [PATCH 03/10] kconfig: resort the documentation of the environment variables Markus Heidelberg
2009-04-19 13:41 ` [PATCH 04/10] gitignore: ignore Kconfig i18n files Markus Heidelberg
2009-04-19 13:41 ` [PATCH 05/10] kconfig qconf: fix -Wall compiler warnings Markus Heidelberg
2009-04-19 13:41 ` [PATCH 06/10] kconfig qconf: fix namespace for Horizontal and Vertical enum values Markus Heidelberg
2009-04-19 13:41 ` [PATCH 07/10] kconfig qconf: add namespace for use of Key_ " Markus Heidelberg
2009-04-19 13:41 ` [PATCH 08/10] kconfig qconf: fix the type of the desktop widget Markus Heidelberg
2009-04-19 13:41 ` [PATCH 09/10] kconfig: do not hardcode ".config" filename Markus Heidelberg
2009-04-19 13:41 ` [PATCH 10/10] kconfig: do not hardcode "include/config/auto.conf" filename Markus Heidelberg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).