Merge branch 'trunk' into multilib

This commit is contained in:
Thomas Trepl 2023-08-01 22:49:01 +02:00
commit 3ecf6ae99d
27 changed files with 605 additions and 121 deletions

View File

@ -40,6 +40,36 @@
appropriate for the entry or if needed the entire day's listitem. appropriate for the entry or if needed the entire day's listitem.
--> -->
<listitem>
<para>2023-08-01</para>
<itemizedlist>
<listitem>
<para>[bdubbs] - Update to vim-9.0.1677. Addresses
<ulink url='&lfs-ticket-root;4500'>#4500</ulink>.</para>
</listitem>
<listitem>
<para>[bdubbs] - Update to openssl-3.1.2. Fixes
<ulink url='&lfs-ticket-root;5305'>#5305</ulink>.</para>
</listitem>
<listitem>
<para>[bdubbs] - Update to man-pages-6.05. Fixes
<ulink url='&lfs-ticket-root;5303'>#5303</ulink>.</para>
</listitem>
<listitem>
<para>[bdubbs] - Update to binutils-2.41. Fixes
<ulink url='&lfs-ticket-root;5300'>#5300</ulink>.</para>
</listitem>
<listitem>
<para>[bdubbs] - Update to gmp-6.3.0. Fixes
<ulink url='&lfs-ticket-root;5301'>#5301</ulink>.</para>
</listitem>
<listitem>
<para>[bdubbs] - Update to glibc-2.38. Fixes
<ulink url='&lfs-ticket-root;5302'>#5302</ulink>.</para>
</listitem>
</itemizedlist>
</listitem>
<listitem> <listitem>
<para>2023-07-28</para> <para>2023-07-28</para>
<itemizedlist> <itemizedlist>

View File

@ -64,9 +64,9 @@
<listitem> <listitem>
<para>Bc &bc-version;</para> <para>Bc &bc-version;</para>
</listitem> </listitem>
<!--<listitem> <listitem>
<para>Binutils-&binutils-version;</para> <para>Binutils-&binutils-version;</para>
</listitem>--> </listitem>
<!--<listitem> <!--<listitem>
<para>Bison-&bison-version;</para> <para>Bison-&bison-version;</para>
</listitem>--> </listitem>-->
@ -124,12 +124,12 @@
<listitem> <listitem>
<para>Gettext-&gettext-version;</para> <para>Gettext-&gettext-version;</para>
</listitem> </listitem>
<!--<listitem> <listitem>
<para>Glibc-&glibc-version;</para> <para>Glibc-&glibc-version;</para>
</listitem>--> </listitem>
<!--<listitem> <listitem>
<para>GMP-&gmp-version;</para> <para>GMP-&gmp-version;</para>
</listitem>--> </listitem>
<!--<listitem> <!--<listitem>
<para>Gperf-&gperf-version;</para> <para>Gperf-&gperf-version;</para>
</listitem>--> </listitem>-->

View File

@ -45,7 +45,9 @@
<para>Prepare Diffutils for compilation:</para> <para>Prepare Diffutils for compilation:</para>
<screen><userinput remap="configure">./configure --prefix=/usr --host=$LFS_TGT</userinput></screen> <screen><userinput remap="configure">./configure --prefix=/usr \
--host=$LFS_TGT \
--build=$(./build-aux/config.guess)</userinput></screen>
<para>Compile the package:</para> <para>Compile the package:</para>

View File

@ -45,8 +45,9 @@
<para>Prepare Grep for compilation:</para> <para>Prepare Grep for compilation:</para>
<screen><userinput remap="configure">./configure --prefix=/usr \ <screen><userinput remap="configure">./configure --prefix=/usr \
--host=$LFS_TGT</userinput></screen> --host=$LFS_TGT \
--build=$(./build-aux/config.guess)</userinput></screen>
<para>Compile the package:</para> <para>Compile the package:</para>

View File

@ -45,8 +45,9 @@
<para>Prepare Sed for compilation:</para> <para>Prepare Sed for compilation:</para>
<screen><userinput remap="configure">./configure --prefix=/usr \ <screen><userinput remap="configure">./configure --prefix=/usr \
--host=$LFS_TGT</userinput></screen> --host=$LFS_TGT \
--build=$(./build-aux/config.guess)</userinput></screen>
<para>Compile the package:</para> <para>Compile the package:</para>

View File

@ -163,6 +163,8 @@ cd build</userinput></screen>
<option>--enable-default-pie</option> and <option>--enable-default-pie</option> and
<option>--enable-default-ssp</option> options are passed to GCC.</para> <option>--enable-default-ssp</option> options are passed to GCC.</para>
<para>Three tests in the gprofng suite are also known to fail.</para>
<para>Install the package:</para> <para>Install the package:</para>
<screen><userinput remap="install">make tooldir=/usr install</userinput></screen> <screen><userinput remap="install">make tooldir=/usr install</userinput></screen>

View File

@ -173,10 +173,12 @@ esac</userinput></screen>
is known to fail in the LFS chroot environment.</para> is known to fail in the LFS chroot environment.</para>
</listitem> </listitem>
<!-- Did not fail with glibc-2.38
<listitem> <listitem>
<para><emphasis>misc/tst-ttyname</emphasis> <para><emphasis>misc/tst-ttyname</emphasis>
is known to fail in the LFS chroot environment.</para> is known to fail in the LFS chroot environment.</para>
</listitem> </listitem>
-->
<!-- https://sourceware.org/pipermail/libc-alpha/2022-August/141567.html --> <!-- https://sourceware.org/pipermail/libc-alpha/2022-August/141567.html -->
<listitem> <listitem>

View File

@ -110,7 +110,7 @@ make html</userinput></screen>
instruction". In this case, gmp should be reconfigured with the option instruction". In this case, gmp should be reconfigured with the option
<option>--host=none-linux-gnu</option> and rebuilt.</para></caution> <option>--host=none-linux-gnu</option> and rebuilt.</para></caution>
<para>Ensure that all 197 tests in the test suite passed. <para>Ensure that all 199 tests in the test suite passed.
Check the results by issuing the following command:</para> Check the results by issuing the following command:</para>
<screen><userinput remap="test">awk '/# PASS:/{total+=$3} ; END{print total}' gmp-check-log</userinput></screen> <screen><userinput remap="test">awk '/# PASS:/{total+=$3} ; END{print total}' gmp-check-log</userinput></screen>

View File

@ -107,7 +107,7 @@ done</userinput><userinput>
online_usrbin="bash find strip" online_usrbin="bash find strip"
online_usrlib="libbfd-&binutils-version;.so online_usrlib="libbfd-&binutils-version;.so
libsframe.so.0.0.0 libsframe.so.&libsframe-version;
libhistory.so.&readline-soversion; libhistory.so.&readline-soversion;
libncursesw.so.&ncurses-version; libncursesw.so.&ncurses-version;
libm.so.6 libm.so.6

View File

@ -130,84 +130,15 @@
<para>Be sure to enable/disable/set the following features or the system might <para>Be sure to enable/disable/set the following features or the system might
not work correctly or boot at all:</para> not work correctly or boot at all:</para>
<screen role="nodump" revision="sysv">General setup ---&gt; <!-- To editors: for updating kernel configuration, edit
[ ] Compile the kernel with warnings as errors [CONFIG_WERROR] kernel/*.toml and regenerate kernel/*.xml with
CPU/Task time and stats accounting ---&gt; "make -C kernel KERNEL_TREE=</usr/src/linux-&linux-version> -->
[*] Pressure stall information tracking [CONFIG_PSI]
[ ] Require boot parameter to enable pressure stall information tracking
[CONFIG_PSI_DEFAULT_DISABLED]
&lt; &gt; Enable kernel headers through /sys/kernel/kheaders.tar.xz [CONFIG_IKHEADERS]
[*] Control Group support [CONFIG_CGROUPS] ---&gt;
[*] Memory controller [CONFIG_MEMCG]
[ ] Configure standard kernel features (expert users) [CONFIG_EXPERT]
Processor type and features ---&gt; <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
[*] Build a relocatable kernel [CONFIG_RELOCATABLE] href="kernel/sysv.xml"/>
[*] Randomize the address of the kernel image (KASLR) [CONFIG_RANDOMIZE_BASE]
General architecture-dependent options ---&gt; <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
[*] Stack Protector buffer overflow detection [CONFIG_STACKPROTECTOR] href="kernel/systemd.xml"/>
[*] Strong Stack Protector [CONFIG_STACKPROTECTOR_STRONG]
Device Drivers ---&gt;
Generic Driver Options ---&gt;
[ ] Support for uevent helper [CONFIG_UEVENT_HELPER]
[*] Maintain a devtmpfs filesystem to mount at /dev [CONFIG_DEVTMPFS]
[*] Automount devtmpfs at /dev, after the kernel mounted the rootfs
[CONFIG_DEVTMPFS_MOUNT]
Graphics support ---&gt;
Frame buffer Devices ---&gt;
&lt;*&gt; Support for frame buffer devices ---&gt;
Console display driver support ---&gt;
[*] Framebuffer Console support [CONFIG_FRAMEBUFFER_CONSOLE]</screen>
<screen role="nodump" revision="systemd">
General setup ---&gt;
[ ] Compile the kernel with warnings as errors [CONFIG_WERROR]
[ ] Auditing Support [CONFIG_AUDIT]
CPU/Task time and stats accounting ---&gt;
[*] Pressure stall information tracking [CONFIG_PSI]
[ ] Require boot parameter to enable pressure stall information tracking
[CONFIG_PSI_DEFAULT_DISABLED]
&lt; &gt; Enable kernel headers through /sys/kernel/kheaders.tar.xz [CONFIG_IKHEADERS]
[*] Control Group support [CONFIG_CGROUPS] ---&gt;
[*] Memory controller [CONFIG_MEMCG]
[ ] Configure standard kernel features (expert users) [CONFIG_EXPERT]
Processor type and features ---&gt;
[*] Build a relocatable kernel [CONFIG_RELOCATABLE]
[*] Randomize the address of the kernel image (KASLR) [CONFIG_RANDOMIZE_BASE]
General architecture-dependent options ---&gt;
[*] Enable seccomp to safely compute untrusted bytecode [CONFIG_SECCOMP]
[*] Stack Protector buffer overflow detection [CONFIG_STACKPROTECTOR]
[*] Strong Stack Protector [CONFIG_STACKPROTECTOR_STRONG]
[*] Networking support ---&gt; [CONFIG_NET]
Networking options ---&gt;
[*] TCP/IP networking [CONFIG_INET]
&lt;*&gt; The IPv6 protocol [CONFIG_IPV6]
Device Drivers ---&gt;
Generic Driver Options ---&gt;
[ ] Support for uevent helper [CONFIG_UEVENT_HELPER]
[*] Maintain a devtmpfs filesystem to mount at /dev [CONFIG_DEVTMPFS]
[*] Automount devtmpfs at /dev, after the kernel mounted the rootfs
[CONFIG_DEVTMPFS_MOUNT]
Firmware Loader ---&gt;
[ ] Enable the firmware sysfs fallback mechanism [CONFIG_FW_LOADER_USER_HELPER]
Firmware Drivers ---&gt;
[*] Export DMI identification via sysfs to userspace [CONFIG_DMIID]
Graphics support ---&gt;
Frame buffer Devices ---&gt;
&lt;*&gt; Support for frame buffer devices ---&gt;
Console display driver support ---&gt;
[*] Framebuffer Console support [CONFIG_FRAMEBUFFER_CONSOLE]
File systems ---&gt;
[*] Inotify support for userspace [CONFIG_INOTIFY_USER]
Pseudo filesystems ---&gt;
[*] Tmpfs POSIX Access Control Lists [CONFIG_TMPFS_POSIX_ACL]</screen>
<para>Enable some additional features if you are building a 64-bit <para>Enable some additional features if you are building a 64-bit
system. If you are using menuconfig, enable them in the order of system. If you are using menuconfig, enable them in the order of
@ -216,31 +147,23 @@ File systems ---&gt;
<parameter>CONFIG_X86_X2APIC</parameter> because an option only <parameter>CONFIG_X86_X2APIC</parameter> because an option only
shows up after its dependencies are selected.</para> shows up after its dependencies are selected.</para>
<screen role="nodump">Processor type and features ---&gt; <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
[*] Support x2apic [CONFIG_X86_X2APIC] href="kernel/x2apic.xml"/>
Device Drivers ---&gt;
[*] PCI Support ---&gt; [CONFIG_PCI]
[*] Message Signaled Interrupts (MSI and MSI-X) [CONFIG_PCI_MSI]
[*] IOMMU Hardware Support ---&gt; [CONFIG_IOMMU_SUPPORT]
[*] Support for Interrupt Remapping [CONFIG_IRQ_REMAP]</screen>
<para>If you are building a 32-bit system running on a hardware <para>If you are building a 32-bit system running on a hardware
with RAM more than 4GB, adjust the configuration so the kernel will with RAM more than 4GB, adjust the configuration so the kernel will
be able to use up to 64GB physical RAM:</para> be able to use up to 64GB physical RAM:</para>
<screen role="nodump">Processor type and features ---&gt; <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
High Memory Support ---&gt; href="kernel/highmem.xml"/>
(X) 64GB [CONFIG_HIGHMEM64G]</screen>
<para>If the partition for the LFS system is in a NVME SSD (i. e. the <para>If the partition for the LFS system is in a NVME SSD (i. e. the
device node for the partition is <filename>/dev/nvme*</filename> device node for the partition is <filename>/dev/nvme*</filename>
instead of <filename>/dev/sd*</filename>), enable NVME support or instead of <filename>/dev/sd*</filename>), enable NVME support or
the LFS system won't boot:</para> the LFS system won't boot:</para>
<screen role="nodump">Device Drivers ---&gt; <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
NVME Support ---&gt; href="kernel/nvme.xml"/>
&lt;*&gt; NVM Express block device [CONFIG_BLK_DEV_NVME]</screen>
</note> </note>
<note revision="systemd"> <note revision="systemd">

2
chapter10/kernel/.gitignore vendored Normal file
View File

@ -0,0 +1,2 @@
__pycache__
s-kernel-version

19
chapter10/kernel/Makefile Normal file
View File

@ -0,0 +1,19 @@
INPUT = $(wildcard *.toml)
OUTPUT = $(patsubst %.toml, %.xml, $(INPUT))
ifeq ($(KERNEL_TREE),)
$(error "must set KERNEL_TREE=/path/to/kernel/source")
endif
all: $(OUTPUT)
kernel.version: s-kernel-version; @true
s-kernel-version: Makefile kernel_version.py
./kernel_version.py $(KERNEL_TREE) > tmp-kernel.version
if ! diff tmp-kernel.version $@ 2>/dev/null >/dev/null; then \
mv tmp-kernel.version kernel.version; \
fi
touch s-kernel-version
%.xml: %.toml kernel-config.py kernel_version.py kernel.version
./kernel-config.py $(KERNEL_TREE) $< > $@

View File

@ -0,0 +1 @@
HIGHMEM64G='X'

View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE note PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
<!-- Automatically generated by kernel-config.py
DO NOT EDIT! -->
<screen role="nodump"><emphasis role='blue'>P</emphasis>rocessor type and features ---&gt;
H<emphasis role='blue'>i</emphasis>gh Memory Support ---&gt;
(X) <emphasis role='blue'>6</emphasis>4GB [HIGHMEM64G]</screen>

298
chapter10/kernel/kernel-config.py Executable file
View File

@ -0,0 +1,298 @@
#!/usr/bin/env python3
# SPDX-License-Identifier: MIT
# Copyright 2023 The LFS Editors
# Stupid script to render "mconf"-style kernel configuration
# Usage: kernel-config.py [path to kernel tree] [needed config].toml
# The toml file should be like:
# for bool and tristate:
# EXT4="*"
# DRM="*M"
# EXPERT=" "
# DRM_I915="*M"
# for choice:
# HIGHMEM64G="X"
# an entry with comment:
# DRM_I915 = { value = " *M", comment = "for i915, crocus, or iris" }
choice_bit = 1 << 30
ind0 = 0
ind1 = 0
menu_id = 1
stack = []
if_stack = []
expand_var_mp = { 'SRCARCH': 'x86' }
main_dep = {}
def expand_var(s):
for k in expand_var_mp:
s = s.replace('$(' + k + ')', expand_var_mp[k])
return s
def pop_stack(cond):
global ind0, ind1, stack
assert(cond(stack[-1][0]))
s, i0, i1, _ = stack[-1]
stack = stack[:-1]
ind0 -= i0
ind1 -= i1
def pop_stack_while(cond):
while stack and cond(stack[-1][0]):
pop_stack(cond)
def cur_menu():
global stack
return stack[-1][3] if stack else 0
def cur_if():
global if_stack
return if_stack[-1][:] if if_stack else []
def clean_dep(d):
d = d.strip()
if d.endswith('=y') or d.endswith('=M'):
d = d[:-2]
elif d.endswith(' != ""'):
d = d[:-6]
return d
def parse_config(buf):
global ind0, ind1, stack, menu_id
is_choice = buf[0].strip() == 'choice'
is_menu = buf[0].startswith('menu') or is_choice
is_nonconfig_menu = buf[0].startswith('menu ') or is_choice
key = None if is_nonconfig_menu else buf[0].split()[1].strip()
title = buf[0][len('menu '):] if is_nonconfig_menu else None
deps = ['menu'] + cur_if()
klass = None
for line in buf[1:]:
line = line.strip()
if line.startswith('depends on '):
new_deps = line[len('depends on '):].split('&&')
deps += [clean_dep(x) for x in new_deps]
elif line.startswith('prompt'):
title = line[len('prompt '):]
else:
for prefix in ['tristate', 'bool', 'string']:
if line.startswith(prefix + ' '):
title = line[len(prefix) + 1:]
klass = prefix
elif line == prefix:
klass = prefix
elif line.startswith('def_' + prefix + ' '):
klass = prefix
else:
continue
if '"' in line:
tail = line[line.rfind('"') + 1:].strip()
if tail[:3] == 'if ':
deps += [clean_dep(x) for x in tail[3:].split('&&')]
pop_stack_while(lambda x: x not in deps)
menu_id += is_menu
internal_key = key or menu_id
if stack:
fa = stack[-1][0]
if fa == 'menu':
fa = cur_menu() & ~choice_bit
main_dep[internal_key] = fa
val = known_config.get(key)
comment = None
forced = None
if type(val) == dict:
comment = val.get('comment')
forced = val.get('forced')
val = val['value']
klass = klass or 'string'
if title:
title = title.strip().lstrip('"')
title = title[:title.find('"')]
if not val:
pass
elif klass == 'string':
val = '(' + val + ')'
else:
assert((val == 'X') == bool(cur_menu() & choice_bit))
if (val == 'X'):
val = '(X)'
else:
val = list(val)
val.sort()
for c in val:
if c not in 'M* ' or (c == 'M' and klass != 'tristate'):
raise Exception('unknown setting %s for %s' % (c, key))
bracket = None
if klass == 'tristate' and forced != '*' :
bracket = '{}' if forced else '<>'
else:
bracket = '--' if forced else '[]'
val = bracket[0] + '/'.join(val) + bracket[1]
arrow = ' --->' if is_menu else ''
r = [ind0, val, ind1, title, arrow, internal_key, cur_menu(), comment]
# Don't indent for untitled (internal) entries
x = 2 if title else 0
key = key or 'menu'
menu = (menu_id if is_menu else cur_menu())
menu |= choice_bit if is_choice else 0
stack_ent = (key, 2, 0, menu) if is_menu else (key, 0, x, menu)
ind0 += stack_ent[1]
ind1 += stack_ent[2]
stack += [stack_ent]
return r
def load_kconfig(file):
global ind0, ind1, stack, path, menu_id, if_stack
r = []
config_buf = []
with open(path + file) as f:
for line in f:
if config_buf:
if not (line.startswith('\t') or line.startswith(' ')):
r += [parse_config(config_buf)]
config_buf = []
else:
config_buf += [line]
continue
if line.startswith('source') or line.startswith('\tsource'):
sub = expand_var(line.strip().split()[1].strip('"'))
r += load_kconfig(sub)
elif line.startswith('config') or line.startswith('menu'):
config_buf = [line]
elif line.startswith('choice'):
config_buf = [line]
elif line.startswith('endmenu') or line.startswith('endchoice'):
pop_stack_while(lambda x: x != 'menu')
pop_stack(lambda x: x == 'menu')
elif line.startswith('if '):
line = line[3:]
top = cur_if()
top += [x.strip() for x in line.split("&&")]
if_stack += [top]
elif line.startswith('endif'):
if_stack = if_stack[:-1]
return r
known_config = {}
def escape(x):
return x.replace('<', '&lt;').replace('>', '&gt;')
from sys import argv
import tomllib
path = argv[1]
if path[-1] != '/':
path += '/'
with open(argv[2], 'rb') as f:
known_config = tomllib.load(f)
r = load_kconfig('Kconfig')
# Refcount all menus
index_ikey = {}
for i in reversed(range(len(r))):
index_ikey[r[i][5]] = i
for i in reversed(range(len(r))):
if r[i][1] != None:
key = r[i][5]
fa = main_dep.get(key)
if not fa:
continue
j = index_ikey[fa]
if type(fa) == int or not r[j][3]:
# The main dependency is a menu or untitled magic entry,
# just mark it used
r[j][1] = ''
if r[j][1] is None:
raise Exception('[%s] needs unselected [%s]' % (key, fa))
r = [i for i in r if i[1] != None and i[3]]
# Now we are going to pretty-print r
## Calculate the maximum value length for each menu
max_val_len = {}
for _, val, _, _, _, _, menu, _ in r:
x = max_val_len.get(menu) or 0
max_val_len[menu] = max(x, len(val))
## Output
max_line = 80
buf = []
done = [x[5] for x in r] + ['revision']
for i in known_config:
if i not in done:
raise Exception("%s seems not exist" % i)
sep = known_config.get('separate_toplevel_menu')
for i0, val, i1, title, arrow, key, menu, comment in r:
rem = max_line
if val:
val += (max_val_len[menu] - len(val)) * ' '
rem -= i0 + i1 + bool(val) + len(val)
line = i0 * ' ' + escape(val) + (i1 + bool(val)) * ' '
rem -= len(arrow)
if len(title) > rem:
title = title[:rem - 3] + '...'
b = title.lstrip('YyMmNnHh')
a = title[:len(title) - len(b)]
b0 = "<emphasis role='blue'>" + escape(b[0]) + "</emphasis>"
line += escape(a) + b0 + escape(b[1:]) + escape(arrow)
rem -= len(title)
key = ' [' + key + ']' if type(key) == str else ''
if len(key) <= rem:
line += (rem - len(key)) * ' ' + key
else:
key = '... ' + key
line += '\n' + ' ' * (max_line - len(key)) + key
if type(comment) == str:
comment = [comment]
if comment:
comment = '\n'.join([' ' * i0 + '# ' + line for line in comment])
buf += [escape(comment) + ':']
if not menu and buf:
buf += ['']
buf += [line.rstrip()]
from jinja2 import Template
t = Template('''<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE note PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
<!-- Automatically generated by kernel-config.py
DO NOT EDIT! -->
<screen role="nodump"{{ rev }}>{{ '\n'.join(buf) }}</screen>''')
rev = known_config.get('revision')
rev = ' revision="%s"' % rev if rev else ''
print(t.render(rev = rev, buf = buf))

View File

@ -0,0 +1 @@
6.4.7

View File

@ -0,0 +1,27 @@
#!/usr/bin/env python3
def kernel_version(path):
version = None
patchlevel = None
sublevel = None
with open(path + 'Makefile') as f:
for line in f:
if line.startswith('VERSION ='):
version = line[len('VERSION ='):].strip()
elif line.startswith('PATCHLEVEL ='):
patchlevel = line[len('PATCHLEVEL ='):].strip()
elif line.startswith('SUBLEVEL ='):
sublevel = line[len('SUBLEVEL ='):].strip()
assert(version and patchlevel and sublevel)
return '.'.join([version, patchlevel, sublevel])
if __name__ == '__main__':
from sys import argv
path = argv[1]
if path[:-1] != '/':
path += '/'
print(kernel_version(path))

View File

@ -0,0 +1 @@
BLK_DEV_NVME='*'

View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE note PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
<!-- Automatically generated by kernel-config.py
DO NOT EDIT! -->
<screen role="nodump"><emphasis role='blue'>D</emphasis>evice Drivers ---&gt;
N<emphasis role='blue'>V</emphasis>ME Support ---&gt;
&lt;*&gt; N<emphasis role='blue'>V</emphasis>M Express block device [BLK_DEV_NVME]</screen>

View File

@ -0,0 +1,30 @@
# This part should be sync with sysv.toml
WERROR=' '
PSI='*'
PSI_DEFAULT_DISABLED=' '
IKHEADERS=' '
CGROUPS='*'
MEMCG='*'
EXPERT=' '
RELOCATABLE='*'
RANDOMIZE_BASE='*'
STACKPROTECTOR='*'
STACKPROTECTOR_STRONG='*'
UEVENT_HELPER=' '
DEVTMPFS='*'
DEVTMPFS_MOUNT='*'
FB='*'
FRAMEBUFFER_CONSOLE='*'
AUDIT=' '
NET='*'
INET='*'
IPV6='*'
FW_LOADER=' *'
FW_LOADER_USER_HELPER='*'
DMIID='*'
INOTIFY_USER='*'
TMPFS='*'
TMPFS_POSIX_ACL='*'
revision='systemd'

View File

@ -0,0 +1,53 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE note PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
<!-- Automatically generated by kernel-config.py
DO NOT EDIT! -->
<screen role="nodump" revision="systemd"><emphasis role='blue'>G</emphasis>eneral setup ---&gt;
[ ] <emphasis role='blue'>C</emphasis>ompile the kernel with warnings as errors [WERROR]
[ ] <emphasis role='blue'>A</emphasis>uditing support [AUDIT]
<emphasis role='blue'>C</emphasis>PU/Task time and stats accounting ---&gt;
[*] <emphasis role='blue'>P</emphasis>ressure stall information tracking [PSI]
[ ] <emphasis role='blue'>R</emphasis>equire boot parameter to enable pressure stall information tracking
... [PSI_DEFAULT_DISABLED]
&lt; &gt; <emphasis role='blue'>E</emphasis>nable kernel headers through /sys/kernel/kheaders.tar.xz [IKHEADERS]
[*] <emphasis role='blue'>C</emphasis>ontrol Group support ---&gt; [CGROUPS]
[*] M<emphasis role='blue'>e</emphasis>mory controller [MEMCG]
[ ] <emphasis role='blue'>C</emphasis>onfigure standard kernel features (expert users) ---&gt; [EXPERT]
<emphasis role='blue'>P</emphasis>rocessor type and features ---&gt;
[*] <emphasis role='blue'>B</emphasis>uild a relocatable kernel [RELOCATABLE]
[*] <emphasis role='blue'>R</emphasis>andomize the address of the kernel image (KASLR) [RANDOMIZE_BASE]
<emphasis role='blue'>G</emphasis>eneral architecture-dependent options ---&gt;
[*] <emphasis role='blue'>S</emphasis>tack Protector buffer overflow detection [STACKPROTECTOR]
[*] <emphasis role='blue'>S</emphasis>trong Stack Protector [STACKPROTECTOR_STRONG]
[*] N<emphasis role='blue'>e</emphasis>tworking support ---&gt; [NET]
N<emphasis role='blue'>e</emphasis>tworking options ---&gt;
[*] <emphasis role='blue'>T</emphasis>CP/IP networking [INET]
&lt;*&gt; <emphasis role='blue'>T</emphasis>he IPv6 protocol ---&gt; [IPV6]
<emphasis role='blue'>D</emphasis>evice Drivers ---&gt;
<emphasis role='blue'>G</emphasis>eneric Driver Options ---&gt;
[ ] <emphasis role='blue'>S</emphasis>upport for uevent helper [UEVENT_HELPER]
[*] M<emphasis role='blue'>a</emphasis>intain a devtmpfs filesystem to mount at /dev [DEVTMPFS]
[*] <emphasis role='blue'>A</emphasis>utomount devtmpfs at /dev, after the kernel mounted the rootfs
... [DEVTMPFS_MOUNT]
<emphasis role='blue'>F</emphasis>irmware loader ---&gt;
&lt; /*&gt; <emphasis role='blue'>F</emphasis>irmware loading facility [FW_LOADER]
[*] <emphasis role='blue'>E</emphasis>nable the firmware sysfs fallback mechanism
... [FW_LOADER_USER_HELPER]
<emphasis role='blue'>F</emphasis>irmware Drivers ---&gt;
[*] <emphasis role='blue'>E</emphasis>xport DMI identification via sysfs to userspace [DMIID]
<emphasis role='blue'>G</emphasis>raphics support ---&gt;
<emphasis role='blue'>F</emphasis>rame buffer Devices ---&gt;
&lt;*&gt; <emphasis role='blue'>S</emphasis>upport for frame buffer devices ---&gt; [FB]
<emphasis role='blue'>C</emphasis>onsole display driver support ---&gt;
[*] <emphasis role='blue'>F</emphasis>ramebuffer Console support [FRAMEBUFFER_CONSOLE]
<emphasis role='blue'>F</emphasis>ile systems ---&gt;
[*] <emphasis role='blue'>I</emphasis>notify support for userspace [INOTIFY_USER]
<emphasis role='blue'>P</emphasis>seudo filesystems ---&gt;
[*] <emphasis role='blue'>T</emphasis>mpfs virtual memory file system support (former shm fs) [TMPFS]
[*] <emphasis role='blue'>T</emphasis>mpfs POSIX Access Control Lists [TMPFS_POSIX_ACL]</screen>

View File

@ -0,0 +1,18 @@
WERROR=' '
PSI='*'
PSI_DEFAULT_DISABLED=' '
IKHEADERS=' '
CGROUPS='*'
MEMCG='*'
EXPERT=' '
RELOCATABLE='*'
RANDOMIZE_BASE='*'
STACKPROTECTOR='*'
STACKPROTECTOR_STRONG='*'
UEVENT_HELPER=' '
DEVTMPFS='*'
DEVTMPFS_MOUNT='*'
FB='*'
FRAMEBUFFER_CONSOLE='*'
revision='sysv'

35
chapter10/kernel/sysv.xml Normal file
View File

@ -0,0 +1,35 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE note PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
<!-- Automatically generated by kernel-config.py
DO NOT EDIT! -->
<screen role="nodump" revision="sysv"><emphasis role='blue'>G</emphasis>eneral setup ---&gt;
[ ] <emphasis role='blue'>C</emphasis>ompile the kernel with warnings as errors [WERROR]
<emphasis role='blue'>C</emphasis>PU/Task time and stats accounting ---&gt;
[*] <emphasis role='blue'>P</emphasis>ressure stall information tracking [PSI]
[ ] <emphasis role='blue'>R</emphasis>equire boot parameter to enable pressure stall information tracking
... [PSI_DEFAULT_DISABLED]
&lt; &gt; <emphasis role='blue'>E</emphasis>nable kernel headers through /sys/kernel/kheaders.tar.xz [IKHEADERS]
[*] <emphasis role='blue'>C</emphasis>ontrol Group support ---&gt; [CGROUPS]
[*] M<emphasis role='blue'>e</emphasis>mory controller [MEMCG]
[ ] <emphasis role='blue'>C</emphasis>onfigure standard kernel features (expert users) ---&gt; [EXPERT]
<emphasis role='blue'>P</emphasis>rocessor type and features ---&gt;
[*] <emphasis role='blue'>B</emphasis>uild a relocatable kernel [RELOCATABLE]
[*] <emphasis role='blue'>R</emphasis>andomize the address of the kernel image (KASLR) [RANDOMIZE_BASE]
<emphasis role='blue'>G</emphasis>eneral architecture-dependent options ---&gt;
[*] <emphasis role='blue'>S</emphasis>tack Protector buffer overflow detection [STACKPROTECTOR]
[*] <emphasis role='blue'>S</emphasis>trong Stack Protector [STACKPROTECTOR_STRONG]
<emphasis role='blue'>D</emphasis>evice Drivers ---&gt;
<emphasis role='blue'>G</emphasis>eneric Driver Options ---&gt;
[ ] <emphasis role='blue'>S</emphasis>upport for uevent helper [UEVENT_HELPER]
[*] M<emphasis role='blue'>a</emphasis>intain a devtmpfs filesystem to mount at /dev [DEVTMPFS]
[*] <emphasis role='blue'>A</emphasis>utomount devtmpfs at /dev, after the kernel mounted the rootfs
... [DEVTMPFS_MOUNT]
<emphasis role='blue'>G</emphasis>raphics support ---&gt;
<emphasis role='blue'>F</emphasis>rame buffer Devices ---&gt;
&lt;*&gt; <emphasis role='blue'>S</emphasis>upport for frame buffer devices ---&gt; [FB]
<emphasis role='blue'>C</emphasis>onsole display driver support ---&gt;
[*] <emphasis role='blue'>F</emphasis>ramebuffer Console support [FRAMEBUFFER_CONSOLE]</screen>

View File

@ -0,0 +1,5 @@
X86_X2APIC='*'
PCI='*'
PCI_MSI='*'
IOMMU_SUPPORT='*'
IRQ_REMAP='*'

View File

@ -0,0 +1,13 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE note PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
<!-- Automatically generated by kernel-config.py
DO NOT EDIT! -->
<screen role="nodump"><emphasis role='blue'>P</emphasis>rocessor type and features ---&gt;
[*] <emphasis role='blue'>S</emphasis>upport x2apic [X86_X2APIC]
<emphasis role='blue'>D</emphasis>evice Drivers ---&gt;
[*] <emphasis role='blue'>P</emphasis>CI support ---&gt; [PCI]
[*] M<emphasis role='blue'>e</emphasis>ssage Signaled Interrupts (MSI and MSI-X) [PCI_MSI]
[*] <emphasis role='blue'>I</emphasis>OMMU Hardware Support ---&gt; [IOMMU_SUPPORT]
[*] <emphasis role='blue'>S</emphasis>upport for Interrupt Remapping [IRQ_REMAP]</screen>

View File

@ -66,10 +66,10 @@
<!ENTITY bc-fin-du "7.6 MB"> <!ENTITY bc-fin-du "7.6 MB">
<!ENTITY bc-fin-sbu "less than 0.1 SBU"> <!ENTITY bc-fin-sbu "less than 0.1 SBU">
<!ENTITY binutils-version "2.40"> <!ENTITY binutils-version "2.41">
<!ENTITY binutils-size "24,650 KB"> <!ENTITY binutils-size "26,139 KB">
<!ENTITY binutils-url "https://sourceware.org/pub/binutils/releases/binutils-&binutils-version;.tar.xz"> <!ENTITY binutils-url "https://sourceware.org/pub/binutils/releases/binutils-&binutils-version;.tar.xz">
<!ENTITY binutils-md5 "007b59bd908a737c06e5a8d3d2c737eb"> <!ENTITY binutils-md5 "256d7e0ad998e423030c84483a7c1e30">
<!ENTITY binutils-home "&gnu-software;binutils/"> <!ENTITY binutils-home "&gnu-software;binutils/">
<!ENTITY binutils-tmpp1-du "639 MB"> <!ENTITY binutils-tmpp1-du "639 MB">
<!ENTITY binutils-tmpp1-sbu "1 SBU"> <!ENTITY binutils-tmpp1-sbu "1 SBU">
@ -77,6 +77,7 @@
<!ENTITY binutils-tmpp2-sbu "0.4 SBU"> <!ENTITY binutils-tmpp2-sbu "0.4 SBU">
<!ENTITY binutils-fin-du "2.6 GB"> <!ENTITY binutils-fin-du "2.6 GB">
<!ENTITY binutils-fin-sbu "2.2 SBU"> <!ENTITY binutils-fin-sbu "2.2 SBU">
<!ENTITY libsframe-version "1.0.0">
<!ENTITY bison-version "3.8.2"> <!ENTITY bison-version "3.8.2">
<!ENTITY bison-size "2,752 KB"> <!ENTITY bison-size "2,752 KB">
@ -256,20 +257,20 @@
<!ENTITY gettext-fin-du "241 MB"> <!ENTITY gettext-fin-du "241 MB">
<!ENTITY gettext-fin-sbu "1.3 SBU"> <!ENTITY gettext-fin-sbu "1.3 SBU">
<!ENTITY glibc-version "2.37"> <!ENTITY glibc-version "2.38">
<!ENTITY glibc-size "18,244 KB"> <!ENTITY glibc-size "18,471 KB">
<!ENTITY glibc-url "&gnu;glibc/glibc-&glibc-version;.tar.xz"> <!ENTITY glibc-url "&gnu;glibc/glibc-&glibc-version;.tar.xz">
<!ENTITY glibc-md5 "e89cf3dcb64939d29f04b4ceead5cc4e"> <!ENTITY glibc-md5 "778cce0ea6bf7f84ca8caacf4a01f45b">
<!ENTITY glibc-home "&gnu-software;libc/"> <!ENTITY glibc-home "&gnu-software;libc/">
<!ENTITY glibc-tmp-du "822 MB"> <!ENTITY glibc-tmp-du "822 MB">
<!ENTITY glibc-tmp-sbu "1.5 SBU"> <!ENTITY glibc-tmp-sbu "1.5 SBU">
<!ENTITY glibc-fin-du "2.9 GB"> <!ENTITY glibc-fin-du "2.9 GB">
<!ENTITY glibc-fin-sbu "11 SBU"> <!ENTITY glibc-fin-sbu "11 SBU">
<!ENTITY gmp-version "6.2.1"> <!ENTITY gmp-version "6.3.0">
<!ENTITY gmp-size "1,980 KB"> <!ENTITY gmp-size "2,046 KB">
<!ENTITY gmp-url "&gnu;gmp/gmp-&gmp-version;.tar.xz"> <!ENTITY gmp-url "&gnu;gmp/gmp-&gmp-version;.tar.xz">
<!ENTITY gmp-md5 "0b82665c4a92fd2ade7440c13fcaa42b"> <!ENTITY gmp-md5 "956dc04e864001a9c22429f761f2c283">
<!ENTITY gmp-home "&gnu-software;gmp/"> <!ENTITY gmp-home "&gnu-software;gmp/">
<!ENTITY gmp-fin-du "52 MB"> <!ENTITY gmp-fin-du "52 MB">
<!ENTITY gmp-fin-sbu "0.3 SBU"> <!ENTITY gmp-fin-sbu "0.3 SBU">
@ -486,10 +487,10 @@
<!ENTITY man-db-fin-du "40 MB"> <!ENTITY man-db-fin-du "40 MB">
<!ENTITY man-db-fin-sbu "0.2 SBU"> <!ENTITY man-db-fin-sbu "0.2 SBU">
<!ENTITY man-pages-version "6.04"> <!ENTITY man-pages-version "6.05">
<!ENTITY man-pages-size "2,137 KB"> <!ENTITY man-pages-size "2,144 KB">
<!ENTITY man-pages-url "&kernel;linux/docs/man-pages/man-pages-&man-pages-version;.tar.xz"> <!ENTITY man-pages-url "&kernel;linux/docs/man-pages/man-pages-&man-pages-version;.tar.xz">
<!ENTITY man-pages-md5 "bbce1456edfa75a66c189cc594af6c4d"> <!ENTITY man-pages-md5 "5e639b0495b84dbc3c93c3294234f6a3">
<!ENTITY man-pages-home "https://www.kernel.org/doc/man-pages/"> <!ENTITY man-pages-home "https://www.kernel.org/doc/man-pages/">
<!ENTITY man-pages-fin-du "32 MB"> <!ENTITY man-pages-fin-du "32 MB">
<!ENTITY man-pages-fin-sbu "less than 0.1 SBU"> <!ENTITY man-pages-fin-sbu "less than 0.1 SBU">
@ -544,10 +545,10 @@
<!ENTITY ninja-fin-du "77 MB"> <!ENTITY ninja-fin-du "77 MB">
<!ENTITY ninja-fin-sbu "0.3 SBU"> <!ENTITY ninja-fin-sbu "0.3 SBU">
<!ENTITY openssl-version "3.1.1"> <!ENTITY openssl-version "3.1.2">
<!ENTITY openssl-size "15,181 KB"> <!ENTITY openssl-size "15,196 KB">
<!ENTITY openssl-url "https://www.openssl.org/source/openssl-&openssl-version;.tar.gz"> <!ENTITY openssl-url "https://www.openssl.org/source/openssl-&openssl-version;.tar.gz">
<!ENTITY openssl-md5 "1864b75e31fb4a6e0a07fd832529add3"> <!ENTITY openssl-md5 "1d7861f969505e67b8677e205afd9ff4">
<!ENTITY openssl-home "https://www.openssl.org/"> <!ENTITY openssl-home "https://www.openssl.org/">
<!ENTITY openssl-fin-du "520 MB"> <!ENTITY openssl-fin-du "520 MB">
<!ENTITY openssl-fin-sbu "3.2 SBU"> <!ENTITY openssl-fin-sbu "3.2 SBU">
@ -735,13 +736,13 @@
<!ENTITY util-linux-fin-du "283 MB"> <!ENTITY util-linux-fin-du "283 MB">
<!ENTITY util-linux-fin-sbu "0.5 SBU"> <!ENTITY util-linux-fin-sbu "0.5 SBU">
<!ENTITY vim-version "9.0.1671"> <!ENTITY vim-version "9.0.1677">
<!-- <!ENTITY vim-majmin "90"> --> <!-- <!ENTITY vim-majmin "90"> -->
<!ENTITY vim-docdir "vim/vim90"> <!ENTITY vim-docdir "vim/vim90">
<!ENTITY vim-size "16,669 KB"> <!ENTITY vim-size "16,670 KB">
<!--<!ENTITY vim-url "https://github.com/vim/vim/archive/v&vim-version;/vim-&vim-version;.tar.gz">--> <!--<!ENTITY vim-url "https://github.com/vim/vim/archive/v&vim-version;/vim-&vim-version;.tar.gz">-->
<!ENTITY vim-url "&anduin-sources;/vim-&vim-version;.tar.gz"> <!ENTITY vim-url "&anduin-sources;/vim-&vim-version;.tar.gz">
<!ENTITY vim-md5 "243fce49db0dd93af7c2b12163f47fcf"> <!ENTITY vim-md5 "65e6b09ef0628a2d8eba79f1d1d5a564">
<!ENTITY vim-home "https://www.vim.org"> <!ENTITY vim-home "https://www.vim.org">
<!ENTITY vim-fin-du "235 MB"> <!ENTITY vim-fin-du "235 MB">
<!ENTITY vim-fin-sbu "2.4 SBU"> <!ENTITY vim-fin-sbu "2.4 SBU">

View File

@ -265,6 +265,9 @@ li.chapter h4 a {
margin: .6em 0 .2em 0; margin: .6em 0 .2em 0;
} }
span.blue {
color: #2ac;
}
/* Index */ /* Index */
.item { .item {