Skip to contentSkip to conversation

menuconfig / legacy bug

Buildroot Thomas Petazzoni 4 participants 6 messages Nov 12, 2013 – Nov 13, 2013

lore
Share & tools
lore
#0 lore raw

Hello,

Samuel noticed this today: it seems like we have a bug in menuconfig that is annoying for the legacy thing.

Scenario to reproduce the bug:

* Checkout commit 38dbd33b91adb4543e922e644b09430fa3836068 (which is right before the removal of the BR2_PACKAGE_QT_JAVASCRIPTCORE) option.

* Create a configuration that has BR2_PACKAGE_QT_JAVASCRIPTCORE set.

* Checkout the latest master (or any other commit that has the BR2_PACKAGE_QT_JAVASCRIPTCORE removal commit)

* Run make menuconfig, it shows that Legacy is detected, which is OK.

* Now, go in the Legacy menu, and try to disable the Qt Javascript Core option. It doesn't disable it and instead menuconfig "jumps" at the beginning of the long comment that explains the legacy thing.

The following patch workarounds the problem by removing the problematic lines of the comment. Basically, all lines that contains only "signs" and not actual text seem to confuse menuconfig for some reason.

Ideas?

Thomas

Config.in.legacy +0 -5
index 587afe1..d4bf7a0 100644
@@ -68,20 +68,17 @@ comment "Legacy detected: check the content of the menu below"
 menu "Legacy config options"
 
 if BR2_LEGACY
-comment "----------------------------------------------------"
 comment "Your old configuration uses legacy options that no  "
 comment "longer exist in buildroot, as indicated in the menu "
 comment "below. As long as these options stay selected, or in"
 comment "case of string options are non-empty, the build     "
 comment "will fail.                                          "
-comment "*                                                   "
 comment "Where possible, an automatic conversion from old to "
 comment "new symbols has been performed. Before making any   "
 comment "change in this legacy menu, make sure to exit the   "
 comment "configuration editor a first time and save the      "
 comment "configuration. Otherwise, the automatic conversion  "
 comment "of symbols will be lost.                            "
-comment "*                                                   "
 comment "After this initial save, reopen the configuration   "
 comment "editor, inspect the options selected below, read    "
 comment "their help texts, and verify/update the new         "
@@ -90,12 +87,10 @@ comment "menus. When everything is ok, you can disable the   "
 comment "legacy options in the menu below. Once you have     "
 comment "disabled all legacy options, this text will         "
 comment "disappear and you will be able to start the build.  "
-comment "*                                                   "
 comment "Note: at some point in the future, the oldest legacy"
 comment "options will be removed, and configuration files    "
 comment "that still have those options set, will fail to     "
 comment "build, or run, in unpredictable ways.               "
-comment "----------------------------------------------------"
 endif
 
 ###############################################################################
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
#1 lore raw

Hi Thomas,

Quoted 22 lines · Thomas Petazzoni

Hello,

Samuel noticed this today: it seems like we have a bug in menuconfig that is annoying for the legacy thing.

Scenario to reproduce the bug:

* Checkout commit 38dbd33b91adb4543e922e644b09430fa3836068 (which is right before the removal of the BR2_PACKAGE_QT_JAVASCRIPTCORE) option.

* Create a configuration that has BR2_PACKAGE_QT_JAVASCRIPTCORE set.

* Checkout the latest master (or any other commit that has the BR2_PACKAGE_QT_JAVASCRIPTCORE removal commit)

* Run make menuconfig, it shows that Legacy is detected, which is OK.

* Now, go in the Legacy menu, and try to disable the Qt Javascript Core option. It doesn't disable it and instead menuconfig "jumps" at the beginning of the long comment that explains the legacy thing.

Quoted 5 lines

The following patch workarounds the problem by removing the problematic lines of the comment. Basically, all lines that contains only "signs" and not actual text seem to confuse menuconfig for some reason.

Ideas?

I cannot reproduce this problem on my end. I followed the exact steps as you described.
This is on Linux Mint 15, not sure which packages would be relevant here. Ncurses is:
lib32ncurses5-dev: 5.9-10ubuntu4

Best regards,
Thomas

#2 lore raw
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Thomas" == Thomas De Schampheleire <[email protected]> writes:

Hi,

Quoted 5 lines

I cannot reproduce this problem on my end. I followed the exact steps as you described.
This is on Linux Mint 15, not sure which packages would be relevant here. Ncurses is:
lib32ncurses5-dev: 5.9-10ubuntu4

You need to ensure that you haven't scrolled too far down. The extra comment lines have to be visible on the screen for the bug to occur.

Signature · 1 line
Bye, Peter Korsgaard
#3 lore raw
In reply to Thomas De Schampheleire

Thomas, All,

Quoted 30 lines · On Wednesday 13 November 2013 09:40:53 Thomas De Schampheleire wrote:

Hi Thomas,

Quoted 26 lines · Thomas Petazzoni

Hello,

Samuel noticed this today: it seems like we have a bug in menuconfig that is annoying for the legacy thing.

Scenario to reproduce the bug:

* Checkout commit 38dbd33b91adb4543e922e644b09430fa3836068 (which is right before the removal of the BR2_PACKAGE_QT_JAVASCRIPTCORE) option.

* Create a configuration that has BR2_PACKAGE_QT_JAVASCRIPTCORE set.

* Checkout the latest master (or any other commit that has the BR2_PACKAGE_QT_JAVASCRIPTCORE removal commit)

* Run make menuconfig, it shows that Legacy is detected, which is OK.

* Now, go in the Legacy menu, and try to disable the Qt Javascript Core option. It doesn't disable it and instead menuconfig "jumps" at the beginning of the long comment that explains the legacy thing.

The following patch workarounds the problem by removing the problematic lines of the comment. Basically, all lines that contains only "signs" and not actual text seem to confuse menuconfig for some reason.

Quoted 7 lines
Quoted 1 line

Ideas?

I cannot reproduce this problem on my end. I followed the exact steps as you described.
This is on Linux Mint 15, not sure which packages would be relevant here. Ncurses is:
lib32ncurses5-dev: 5.9-10ubuntu4

You have to use 'space' to deselect the option. Using 'n' works as expected.

I have a (quick) fix I need to further test tonight, since it may have some weird side-effects...

Regards,
Yann E. MORIN.

Signature · 6 lines
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +0/33 662376056 | Software  Designer | \ / CAMPAIGN     |   ^                |
| --==< O_o >==-- '------------.-------:  X  AGAINST      |  /e\  There is no  |
| http://ymorin.is-a-geek.org/ | (*_*) | / \ HTML MAIL    |  """  conspiracy.  |
'------------------------------'-------'------------------'--------------------'
#4 lore raw

Hi Yann, all,

Quoted 35 lines · Yann E. MORIN

Thomas, All,

Quoted 32 lines · On Wednesday 13 November 2013 09:40:53 Thomas De Schampheleire wrote:

Hi Thomas,

Quoted 27 lines · Thomas Petazzoni

Hello,

Samuel noticed this today: it seems like we have a bug in menuconfig that is annoying for the legacy thing.

Scenario to reproduce the bug:

* Checkout commit 38dbd33b91adb4543e922e644b09430fa3836068 (which is right before the removal of the BR2_PACKAGE_QT_JAVASCRIPTCORE) option.

* Create a configuration that has BR2_PACKAGE_QT_JAVASCRIPTCORE set.

* Checkout the latest master (or any other commit that has the BR2_PACKAGE_QT_JAVASCRIPTCORE removal commit)

* Run make menuconfig, it shows that Legacy is detected, which is OK.

* Now, go in the Legacy menu, and try to disable the Qt Javascript Core option. It doesn't disable it and instead menuconfig "jumps" at the beginning of the long comment that explains the legacy thing.

The following patch workarounds the problem by removing the problematic lines of the comment. Basically, all lines that contains only "signs" and not actual text seem to confuse menuconfig for some reason.

Ideas?

Quoted 8 lines
Quoted 5 lines

I cannot reproduce this problem on my end. I followed the exact steps as you described.
This is on Linux Mint 15, not sure which packages would be relevant here. Ncurses is:
lib32ncurses5-dev: 5.9-10ubuntu4

You have to use 'space' to deselect the option. Using 'n' works as expected.

Confirmed.
Typing 'space' simply cycles between visible comment lines _not_ containing any letter (number fails too).

Adding a letter on each non-letter line is a workaround:

Config.in.legacy +5 -5
@@ -68,20 +68,20 @@ comment "Legacy detected: check the cont
 menu "Legacy config options"
 
 if BR2_LEGACY
-comment "----------------------------------------------------"
+comment "---------------------------------------------------o"
 comment "Your old configuration uses legacy options that no  "
 comment "longer exist in buildroot, as indicated in the menu "
 comment "below. As long as these options stay selected, or in"
 comment "case of string options are non-empty, the build     "
 comment "will fail.                                          "
-comment "*                                                   "
+comment "*                                                  o"
 comment "Where possible, an automatic conversion from old to "
 comment "new symbols has been performed. Before making any   "
 comment "change in this legacy menu, make sure to exit the   "
 comment "configuration editor a first time and save the      "
 comment "configuration. Otherwise, the automatic conversion  "
 comment "of symbols will be lost.                            "
-comment "*                                                   "
+comment "*                                                  o"
 comment "After this initial save, reopen the configuration   "
 comment "editor, inspect the options selected below, read    "
 comment "their help texts, and verify/update the new         "
@@ -90,12 +90,12 @@ comment "menus. When everything is ok, y
 comment "legacy options in the menu below. Once you have     "
 comment "disabled all legacy options, this text will         "
 comment "disappear and you will be able to start the build.  "
-comment "*                                                   "
+comment "*                                                  o"
 comment "Note: at some point in the future, the oldest legacy"
 comment "options will be removed, and configuration files    "
 comment "that still have those options set, will fail to     "
 comment "build, or run, in unpredictable ways.               "
-comment "----------------------------------------------------"
+comment "---------------------------------------------------o"
 endif
 
 ###############################################################################
Quoted 2 lines

I have a (quick) fix I need to further test tonight, since it may have some weird side-effects...

Could you elaborate a bit, or maybe show the patch?

Best regards,
Thomas

#5 lore raw

Thomas, All,

On 2013-11-13 10:05 +0100, Thomas De Schampheleire spake thusly:

Quoted 5 lines · Yann E. MORIN
Quoted 2 lines

I have a (quick) fix I need to further test tonight, since it may have some weird side-effects...

Could you elaborate a bit, or maybe show the patch?

Now posted to the list. ;-)

Regards,
Yann E. MORIN.

Signature · 6 lines
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'