summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2019-10-10Make 13.1.1 releasev13.1.1Ulf Magnusson
Adds a small fix for some just-rewritten documentation, in commit 4de95f4 ("Mention that standard_kconfig() returns the Kconfig instance").
2019-10-10Mention that standard_kconfig() returns the Kconfig instanceUlf Magnusson
Accidentally left out when the docstring was rewritten.
2019-10-10allnoconfig: Comment nitUlf Magnusson
2019-10-10Make 13.1.0 releasev13.1.0Ulf Magnusson
- Commit e016deb ("Convert standard_kconfig() to argparse for better feedback") improves feedback from the tools and makes their help texts easier to find - Commit 0f56dd9 ("guiconfig: Check for visible nodes before turning off show-all in full-tree mode") fixes an obscure bug in show-all mode in guiconfig
2019-10-10testsuite: Remove unused importsUlf Magnusson
Reported by pylint.
2019-10-10guiconfig: Check for visible nodes before turning off show-all in full-tree modeUlf Magnusson
If there are no visible nodes in the entire tree, guiconfig automatically starts in show-all mode. Previously, there was no check for visible nodes when turning off show-all in full-tree mode in this case, leading to errors. Fix it by checking if there are any visible nodes in the top menu when turning off show-all in full-tree mode. If there aren't, show-all stays on.
2019-10-10Convert standard_kconfig() to argparse for better feedbackUlf Magnusson
Stuff like this is not the pinnacle of helpful design, and hides that the commands actually have long help texts (that can be viewed with pydoc): $ ./menuconfig.py --help [Errno 2] No such file or directory: '--help' Fix it by converting standard_kconfig() to argparse, and add a 'description' argument to it for the command-specific help text. --help now shows the same help text shown by pydoc, and some other error messages are improved as well. Also fix some copy-paste errors and outdated paths in the help texts for the all*config commands.
2019-10-09menuconfig: _sorted_sc_nodes() code formatting nitUlf Magnusson
2019-10-05Mention that menuconfig shows windows-curses hint in READMEUlf Magnusson
2019-10-05Make 13.0.0 release (with Windows packaging change)v13.0.0Ulf Magnusson
Adds commit 21b4c1e ("Do not automatically install windows-curses on Windows"), which fixes installation on MSYS2. See that commit for an explanation, and this issue: https://github.com/ulfalizer/Kconfiglib/issues/77 Also adds commit 72e3d20 ("menuconfig: Give hint when 'curses' can't be imported on Windows"), to make it easy for users to know what to do if stuff breaks. Sorry if this change caused problems!
2019-10-05menuconfig: Give hint when 'curses' can't be imported on WindowsUlf Magnusson
Tell people to install something like windows-curses. Might help avoid some trouble after commit 21b4c1e ("Do not automatically install windows-curses on Windows").
2019-10-05Do not automatically install windows-curses on WindowsUlf Magnusson
It breaks installation with pip on MSYS2, and Kconfiglib can still be useful without the terminal menuconfig. Unfortunately, MSYS2 seems tricky to identify via environment markers (https://www.python.org/dev/peps/pep-0508/#environment-markers). This has breakage/annoyance potential, as windows-curses now needs to be installed manually. The major Kconfiglib version will be increased. Sorry if this change caused problems! Fixes: #77
2019-10-05Mention that the header is sorted by definition locationUlf Magnusson
Handy to know.
2019-09-28Make linux-next dependency loop fix easier to notice in READMEUlf Magnusson
Piggyback fixing a typo.
2019-09-27Link patch with fix for dependency loopUlf Magnusson
Sent upstream.
2019-09-26Simplify _expand_name_iter() a tiny bitUlf Magnusson
Get rid of the 'else'.
2019-09-26Make preprocessor nested parens test slightly trickierUlf Magnusson
Macros should still be expanded within nested parentheses. Test it.
2019-09-26Make 12.14.1 releasev12.14.1Ulf Magnusson
Fixes a preprocessor issue, in commit 720ce88 ("Fix handling of parentheses in macro argument values").
2019-09-26Fix handling of parentheses in macro argument valuesUlf Magnusson
As an oversight, there was no check for nested parentheses in macro arguments, making the preprocessor think the call ended after 'void)' in def_bool $(success,echo 'void foo(void) { asm inline (""); }' | $(CC) -x c - -c -o /dev/null) This broke the latest linux-next kernels, starting with commit eb111869301e1 ("compiler-types.h: add asm_inline definition"). I remember seeing this when going through the C code, but somehow forgot to put it in. Fix it, and clean up _expand_macro() a bit at the same time. Fixes: #76
2019-09-04Make 12.14.0 releasev12.14.0Ulf Magnusson
Adds commit 26e1db6 ("Allow preprocessor user functions to access the parsing location").
2019-09-04Allow preprocessor user functions to access the parsing locationUlf Magnusson
Just requires making Kconfig.filename/linenr public. 'lineno' would be a more standard name, but be consistent with MenuNode.linenr.
2019-08-04Add .pyo to .gitignoreUlf Magnusson
Might come up if people run Kconfiglib from a submodule with 'python -O'.
2019-08-03Make 12.13.0 releasev12.13.0Ulf Magnusson
Mostly to get some cleanups into a release, but adds a tiny improvement in commit a4b5775 ("menuconfig/guiconfig: Print 'default:' with no 's' if there's just one").
2019-08-03Fix duplicated label names in READMEUlf Magnusson
Made PyPI complain.
2019-08-03menuconfig/guiconfig: Print 'default:' with no 's' if there's just oneUlf Magnusson
Most common case, and makes the symbol info read better.
2019-08-03Add some distribution-related files to .gitignoreUlf Magnusson
I always run Git with status.showUntrackedFiles = no, but might be nice for other people.
2019-08-03Add a .gitignore that ignores *.pycUlf Magnusson
Might avoid some pain in projects that use Kconfiglib as a submodule. Fixes https://github.com/ulfalizer/Kconfiglib/issues/74.
2019-07-20Remove tabs in setup.cfgUlf Magnusson
Causes a ConfigParser error when using setuptools with Python 2.
2019-07-13Fix kernel Kconfig doc linksUlf Magnusson
They were converted to RST. Link to rendered versions.
2019-07-13Explain why 'option env' is still supportedUlf Magnusson
It's mostly to stay compatible with older Linux kernels. Hence why Kconfiglib doesn't try to be more compatible than what's needed for those.
2019-07-11'if' removal test code nitUlf Magnusson
2019-07-05Pass set literals instead of tuples to frozenset()Ulf Magnusson
This triggers a different set-to-set code path and makes some of them a bit smaller, e.g. 480 instead of 736 bytes for _RELATIONS. Probably no measurable performance difference, but might as well.
2019-07-04Link syzkaller script as exampleUlf Magnusson
2019-07-04Remove note about test suite failures with old buggy C toolsUlf Magnusson
The test suite would fail anyway now due to (harmless) output format changes.
2019-07-04Move kconfiglib-2-changes.txt over to the 'screenshots' branchUlf Magnusson
Makes the top-level a bit less cluttered. The README still links to it.
2019-07-04Clean up Kconfig.__init__() a bitUlf Magnusson
- Move some assignments closer to related assignments - Remove some blank lines between related assignments - Remove double blank lines between sections. It's probably more messy-looking than helpful.
2019-07-04_name_special_search regex consistency nitUlf Magnusson
Put $ after word characters, like in _command_match and _id_keyword_match.
2019-07-04Turn mainmenu_text into a @propertyUlf Magnusson
Not performance sensitive. Gets rid of a variable.
2019-07-04Indent nitUlf Magnusson
2019-07-04Rename _warn_no_prompt to _warn_assign_no_promptUlf Magnusson
Makes it consistent with the other warn_assign_* variables. Also move the initialization in Kconfig.__init__() next to the other warn_assign_* variables.
2019-07-02Make 12.12.1 releasev12.12.1Ulf Magnusson
Adds commit 29758ae ("setconfig: Use 'orig_type' instead of 'type' in error message").
2019-07-02setconfig: Use 'orig_type' instead of 'type' in error messageUlf Magnusson
It's confusing to have tristate symbols show up as bool in the bad-value error message when modules are disabled. set_value() validates the value against 'orig_type' rather than 'type' as well. Piggyback some quote consistency and make a comment in set_value() more informative.
2019-07-02Make 12.12.0 releasev12.12.0Ulf Magnusson
Adds commit e5e2fe5 ("Catch EnvironmentError instead of OSError/IOError"), which fixes menuconfig.py crashes on I/O errors on Python 2. This might also improve error robustness elsewhere on Python 2 in obscure cases.
2019-07-02Catch EnvironmentError instead of OSError/IOErrorUlf Magnusson
menuconfig.py tended to crash on I/O errors on Python 2, due to forgetting to update some 'except OSError's. Catch EnvironmentError instead. EnvironmentError is a common base class of IOError and OSError on Python 2, and an alias for OSError on Python 3. Use it elsewhere too, as it might help catch obscure I/O errors on Python 2.
2019-07-01Rename Choice._get_selection_from_defaults() to _selection_from_defaults()Ulf Magnusson
Shorter and still clear.
2019-07-01Remove redundant commentUlf Magnusson
2019-07-01Remove redundant parensUlf Magnusson
2019-07-01Get rid of some STRING/INT/HEX testsUlf Magnusson
Things can be simplified a bit knowing that UNKNOWN is falsy.
2019-07-01Merge orig_type and _visited assignments in constructorsUlf Magnusson
Small optimization. We know that UNKNOWN == 0, and it's always tested for by checking truthiness rather than identity within the library, so there can't be trouble even without small integer optimization.
2019-07-01Make 12.11.0 releasev12.11.0Ulf Magnusson
Adds some small documentation improvements: - Commit b133331 ("Mention that passing subexpressions to expr_items() works") - Commit 6016156 ("Mention that the 'encoding' parameter is also used for $(shell)") - Commit 48ec584 ("Simplify eval_string() docstring re. syntax errors") - Commit e44102a ("Make MenuNode.filename documentation more accurate re. absolute paths") Some minor optimizations are included as well.