Formatted print of linux kernel config

Clash Royale CLAN TAG#URR8PPP
up vote
2
down vote
favorite
As the options make menuconfig and make nconfig allow a nice way to configure the kernel options, are there any way to get this hierachical structure for print it?
Something similar to the "tree" command ouput.
linux configuration kernel
migrated from serverfault.com Mar 16 at 22:24
This question came from our site for system and network administrators.
add a comment |Â
up vote
2
down vote
favorite
As the options make menuconfig and make nconfig allow a nice way to configure the kernel options, are there any way to get this hierachical structure for print it?
Something similar to the "tree" command ouput.
linux configuration kernel
migrated from serverfault.com Mar 16 at 22:24
This question came from our site for system and network administrators.
2
I haven't looked at it, but github.com/ulfalizer/Kconfiglib may be a starting point, if you're interested. In particular: github.com/ulfalizer/Kconfiglib/blob/master/examples/â¦
â Jeff Schaller
Mar 16 at 23:49
add a comment |Â
up vote
2
down vote
favorite
up vote
2
down vote
favorite
As the options make menuconfig and make nconfig allow a nice way to configure the kernel options, are there any way to get this hierachical structure for print it?
Something similar to the "tree" command ouput.
linux configuration kernel
As the options make menuconfig and make nconfig allow a nice way to configure the kernel options, are there any way to get this hierachical structure for print it?
Something similar to the "tree" command ouput.
linux configuration kernel
asked Mar 16 at 22:19
Rfraile
26229
26229
migrated from serverfault.com Mar 16 at 22:24
This question came from our site for system and network administrators.
migrated from serverfault.com Mar 16 at 22:24
This question came from our site for system and network administrators.
2
I haven't looked at it, but github.com/ulfalizer/Kconfiglib may be a starting point, if you're interested. In particular: github.com/ulfalizer/Kconfiglib/blob/master/examples/â¦
â Jeff Schaller
Mar 16 at 23:49
add a comment |Â
2
I haven't looked at it, but github.com/ulfalizer/Kconfiglib may be a starting point, if you're interested. In particular: github.com/ulfalizer/Kconfiglib/blob/master/examples/â¦
â Jeff Schaller
Mar 16 at 23:49
2
2
I haven't looked at it, but github.com/ulfalizer/Kconfiglib may be a starting point, if you're interested. In particular: github.com/ulfalizer/Kconfiglib/blob/master/examples/â¦
â Jeff Schaller
Mar 16 at 23:49
I haven't looked at it, but github.com/ulfalizer/Kconfiglib may be a starting point, if you're interested. In particular: github.com/ulfalizer/Kconfiglib/blob/master/examples/â¦
â Jeff Schaller
Mar 16 at 23:49
add a comment |Â
1 Answer
1
active
oldest
votes
up vote
1
down vote
accepted
Thanks to the replay of @jeff-schaller I did a contribution to the project Kconfiglib and now there is a new example script for this task. These are the steps to use it:
Inside the directory with the linux source, clone the repo:
root@23e196045c6f:/usr/src/linux-source-4.9# git clone git://github.com/ulfalizer/Kconfiglib.git
Cloning into 'Kconfiglib'...
remote: Counting objects: 3367, done.
remote: Compressing objects: 100% (57/57), done.
remote: Total 3367 (delta 64), reused 89 (delta 50), pack-reused 3259
Receiving objects: 100% (3367/3367), 1.25 MiB | 1.79 MiB/s, done.
Resolving deltas: 100% (2184/2184), done.
Patch the makefile:
root@23e196045c6f:/usr/src/linux-source-4.9# patch -p1 < Kconfiglib/makefile.patch
patching file scripts/kconfig/Makefile
Configure as needed, basically for get a .config file:
root@23e196045c6f:/usr/src/linux-source-4.9# make menuconfig
Run the script with the config file:
root@23e196045c6f:/usr/src/linux-source-4.9# make scriptconfig SCRIPT=Kconfiglib/examples/print_config_tree.py SCRIPT_ARG=.config
======== Linux/x86 4.9.65 Kernel Configuration ========
[*] 64-bit kernel (64BIT)
General setup
() Cross-compiler tool prefix (CROSS_COMPILE)
[ ] Compile also drivers which will not load (COMPILE_TEST)
() Local version - append to kernel release (LOCALVERSION)
[ ] Automatically append version information to the version string (LOCALVERSION_AUTO)
-*- Kernel compression mode
--> Gzip (KERNEL_GZIP)
Bzip2 (KERNEL_BZIP2)
LZMA (KERNEL_LZMA)
...
But the nice thing is that it is possible to pass differente kernel configurations and match the changes easily:
root@23e196045c6f:/usr/src/linux-source-4.9# make scriptconfig SCRIPT=Kconfiglib/examples/print_config_tree.py SCRIPT_ARG=/tmp/config1 > config1-list.txt
root@23e196045c6f:/usr/src/linux-source-4.9# make scriptconfig SCRIPT=Kconfiglib/examples/print_config_tree.py SCRIPT_ARG=/tmp/config2 > config2-list.txt
And finally now with a diff tool:

add a comment |Â
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
1
down vote
accepted
Thanks to the replay of @jeff-schaller I did a contribution to the project Kconfiglib and now there is a new example script for this task. These are the steps to use it:
Inside the directory with the linux source, clone the repo:
root@23e196045c6f:/usr/src/linux-source-4.9# git clone git://github.com/ulfalizer/Kconfiglib.git
Cloning into 'Kconfiglib'...
remote: Counting objects: 3367, done.
remote: Compressing objects: 100% (57/57), done.
remote: Total 3367 (delta 64), reused 89 (delta 50), pack-reused 3259
Receiving objects: 100% (3367/3367), 1.25 MiB | 1.79 MiB/s, done.
Resolving deltas: 100% (2184/2184), done.
Patch the makefile:
root@23e196045c6f:/usr/src/linux-source-4.9# patch -p1 < Kconfiglib/makefile.patch
patching file scripts/kconfig/Makefile
Configure as needed, basically for get a .config file:
root@23e196045c6f:/usr/src/linux-source-4.9# make menuconfig
Run the script with the config file:
root@23e196045c6f:/usr/src/linux-source-4.9# make scriptconfig SCRIPT=Kconfiglib/examples/print_config_tree.py SCRIPT_ARG=.config
======== Linux/x86 4.9.65 Kernel Configuration ========
[*] 64-bit kernel (64BIT)
General setup
() Cross-compiler tool prefix (CROSS_COMPILE)
[ ] Compile also drivers which will not load (COMPILE_TEST)
() Local version - append to kernel release (LOCALVERSION)
[ ] Automatically append version information to the version string (LOCALVERSION_AUTO)
-*- Kernel compression mode
--> Gzip (KERNEL_GZIP)
Bzip2 (KERNEL_BZIP2)
LZMA (KERNEL_LZMA)
...
But the nice thing is that it is possible to pass differente kernel configurations and match the changes easily:
root@23e196045c6f:/usr/src/linux-source-4.9# make scriptconfig SCRIPT=Kconfiglib/examples/print_config_tree.py SCRIPT_ARG=/tmp/config1 > config1-list.txt
root@23e196045c6f:/usr/src/linux-source-4.9# make scriptconfig SCRIPT=Kconfiglib/examples/print_config_tree.py SCRIPT_ARG=/tmp/config2 > config2-list.txt
And finally now with a diff tool:

add a comment |Â
up vote
1
down vote
accepted
Thanks to the replay of @jeff-schaller I did a contribution to the project Kconfiglib and now there is a new example script for this task. These are the steps to use it:
Inside the directory with the linux source, clone the repo:
root@23e196045c6f:/usr/src/linux-source-4.9# git clone git://github.com/ulfalizer/Kconfiglib.git
Cloning into 'Kconfiglib'...
remote: Counting objects: 3367, done.
remote: Compressing objects: 100% (57/57), done.
remote: Total 3367 (delta 64), reused 89 (delta 50), pack-reused 3259
Receiving objects: 100% (3367/3367), 1.25 MiB | 1.79 MiB/s, done.
Resolving deltas: 100% (2184/2184), done.
Patch the makefile:
root@23e196045c6f:/usr/src/linux-source-4.9# patch -p1 < Kconfiglib/makefile.patch
patching file scripts/kconfig/Makefile
Configure as needed, basically for get a .config file:
root@23e196045c6f:/usr/src/linux-source-4.9# make menuconfig
Run the script with the config file:
root@23e196045c6f:/usr/src/linux-source-4.9# make scriptconfig SCRIPT=Kconfiglib/examples/print_config_tree.py SCRIPT_ARG=.config
======== Linux/x86 4.9.65 Kernel Configuration ========
[*] 64-bit kernel (64BIT)
General setup
() Cross-compiler tool prefix (CROSS_COMPILE)
[ ] Compile also drivers which will not load (COMPILE_TEST)
() Local version - append to kernel release (LOCALVERSION)
[ ] Automatically append version information to the version string (LOCALVERSION_AUTO)
-*- Kernel compression mode
--> Gzip (KERNEL_GZIP)
Bzip2 (KERNEL_BZIP2)
LZMA (KERNEL_LZMA)
...
But the nice thing is that it is possible to pass differente kernel configurations and match the changes easily:
root@23e196045c6f:/usr/src/linux-source-4.9# make scriptconfig SCRIPT=Kconfiglib/examples/print_config_tree.py SCRIPT_ARG=/tmp/config1 > config1-list.txt
root@23e196045c6f:/usr/src/linux-source-4.9# make scriptconfig SCRIPT=Kconfiglib/examples/print_config_tree.py SCRIPT_ARG=/tmp/config2 > config2-list.txt
And finally now with a diff tool:

add a comment |Â
up vote
1
down vote
accepted
up vote
1
down vote
accepted
Thanks to the replay of @jeff-schaller I did a contribution to the project Kconfiglib and now there is a new example script for this task. These are the steps to use it:
Inside the directory with the linux source, clone the repo:
root@23e196045c6f:/usr/src/linux-source-4.9# git clone git://github.com/ulfalizer/Kconfiglib.git
Cloning into 'Kconfiglib'...
remote: Counting objects: 3367, done.
remote: Compressing objects: 100% (57/57), done.
remote: Total 3367 (delta 64), reused 89 (delta 50), pack-reused 3259
Receiving objects: 100% (3367/3367), 1.25 MiB | 1.79 MiB/s, done.
Resolving deltas: 100% (2184/2184), done.
Patch the makefile:
root@23e196045c6f:/usr/src/linux-source-4.9# patch -p1 < Kconfiglib/makefile.patch
patching file scripts/kconfig/Makefile
Configure as needed, basically for get a .config file:
root@23e196045c6f:/usr/src/linux-source-4.9# make menuconfig
Run the script with the config file:
root@23e196045c6f:/usr/src/linux-source-4.9# make scriptconfig SCRIPT=Kconfiglib/examples/print_config_tree.py SCRIPT_ARG=.config
======== Linux/x86 4.9.65 Kernel Configuration ========
[*] 64-bit kernel (64BIT)
General setup
() Cross-compiler tool prefix (CROSS_COMPILE)
[ ] Compile also drivers which will not load (COMPILE_TEST)
() Local version - append to kernel release (LOCALVERSION)
[ ] Automatically append version information to the version string (LOCALVERSION_AUTO)
-*- Kernel compression mode
--> Gzip (KERNEL_GZIP)
Bzip2 (KERNEL_BZIP2)
LZMA (KERNEL_LZMA)
...
But the nice thing is that it is possible to pass differente kernel configurations and match the changes easily:
root@23e196045c6f:/usr/src/linux-source-4.9# make scriptconfig SCRIPT=Kconfiglib/examples/print_config_tree.py SCRIPT_ARG=/tmp/config1 > config1-list.txt
root@23e196045c6f:/usr/src/linux-source-4.9# make scriptconfig SCRIPT=Kconfiglib/examples/print_config_tree.py SCRIPT_ARG=/tmp/config2 > config2-list.txt
And finally now with a diff tool:

Thanks to the replay of @jeff-schaller I did a contribution to the project Kconfiglib and now there is a new example script for this task. These are the steps to use it:
Inside the directory with the linux source, clone the repo:
root@23e196045c6f:/usr/src/linux-source-4.9# git clone git://github.com/ulfalizer/Kconfiglib.git
Cloning into 'Kconfiglib'...
remote: Counting objects: 3367, done.
remote: Compressing objects: 100% (57/57), done.
remote: Total 3367 (delta 64), reused 89 (delta 50), pack-reused 3259
Receiving objects: 100% (3367/3367), 1.25 MiB | 1.79 MiB/s, done.
Resolving deltas: 100% (2184/2184), done.
Patch the makefile:
root@23e196045c6f:/usr/src/linux-source-4.9# patch -p1 < Kconfiglib/makefile.patch
patching file scripts/kconfig/Makefile
Configure as needed, basically for get a .config file:
root@23e196045c6f:/usr/src/linux-source-4.9# make menuconfig
Run the script with the config file:
root@23e196045c6f:/usr/src/linux-source-4.9# make scriptconfig SCRIPT=Kconfiglib/examples/print_config_tree.py SCRIPT_ARG=.config
======== Linux/x86 4.9.65 Kernel Configuration ========
[*] 64-bit kernel (64BIT)
General setup
() Cross-compiler tool prefix (CROSS_COMPILE)
[ ] Compile also drivers which will not load (COMPILE_TEST)
() Local version - append to kernel release (LOCALVERSION)
[ ] Automatically append version information to the version string (LOCALVERSION_AUTO)
-*- Kernel compression mode
--> Gzip (KERNEL_GZIP)
Bzip2 (KERNEL_BZIP2)
LZMA (KERNEL_LZMA)
...
But the nice thing is that it is possible to pass differente kernel configurations and match the changes easily:
root@23e196045c6f:/usr/src/linux-source-4.9# make scriptconfig SCRIPT=Kconfiglib/examples/print_config_tree.py SCRIPT_ARG=/tmp/config1 > config1-list.txt
root@23e196045c6f:/usr/src/linux-source-4.9# make scriptconfig SCRIPT=Kconfiglib/examples/print_config_tree.py SCRIPT_ARG=/tmp/config2 > config2-list.txt
And finally now with a diff tool:

answered Mar 20 at 9:45
Rfraile
26229
26229
add a comment |Â
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f430693%2fformatted-print-of-linux-kernel-config%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
2
I haven't looked at it, but github.com/ulfalizer/Kconfiglib may be a starting point, if you're interested. In particular: github.com/ulfalizer/Kconfiglib/blob/master/examples/â¦
â Jeff Schaller
Mar 16 at 23:49