Русский перевод книги Linux From Scratch
Go to file
Poltern f7e58b2233 gcc: Don't decrease the stack limit
I've had doubts on this "ulimit -s 32768" command for years.  After
reading GCC code (libiberty/stack-limit.c) I'm pretty sure this command
is not doing what we expected.

In a typical Linux distro, the default "soft" stack limit is 8 MiB and
the default "hard" stack limit is infinite.  And GCC will automatically
increase the soft limit to 64 MiB if the original soft limit is smaller
than 64 MiB, and the hard limit is at least 64 MiB.  So with a typical
default configuration, the real stack limit of GCC is 64 MiB.

But our "ulimit -s 32768" command sets both the soft limit and the hard
limit to 32 MiB.  Thus we are actually *decreasing* the real stack
limit.  Fortunately this has not caused any test failures, but it's just
wrong (contradicting with the explanation of the command).

Thus just raise the hard limit to infinite in case the host distro uses
a not so typical configuration where the hard limit is tight, and let
GCC to set up the soft limit to the expected value on its own.  It's
more future-proof than "ulimit -s 65536" in case GCC changes the
expected stack limit in the future.

It should be safe to make the change in freeze because in jhalfs it only
affects the test suite, and even in a manual build the user can skip
this command if not running the GCC test suite.
2024-08-28 10:31:52 +05:00
appendices Package updates. 2024-08-18 22:40:33 +05:00
bootscripts bootscripts: console: Fix fb console detection 2024-08-25 22:14:05 +05:00
chapter01 bootscripts: console: Fix fb console detection 2024-08-25 22:14:05 +05:00
chapter02 Sync book 2024-05-27 16:35:13 +05:00
chapter03 Package updates 2024-08-16 12:55:32 +05:00
chapter04 Add more detail to the About SBUs page 2024-08-27 12:56:29 +05:00
chapter05 Add more detail to the About SBUs page 2024-08-27 12:56:29 +05:00
chapter06 Small fix and reword 2024-08-22 10:01:27 +05:00
chapter07 Package and format updates. 2024-07-12 13:06:06 +05:00
chapter08 gcc: Don't decrease the stack limit 2024-08-28 10:31:52 +05:00
chapter09 Small fix and reword 2024-08-22 10:01:27 +05:00
chapter10 Regenerate kernel configuration with Linux 6.10.5 source 2024-08-18 21:47:06 +05:00
chapter11 Typos fix 2024-04-06 21:07:47 +05:00
images Add images 2022-05-19 02:04:30 +05:00
part3intro Update the paragraph describing ch05 glibc 2024-08-16 12:49:14 +05:00
pdf fixed #3; Automatic insertion of arrows for ru lang 2024-02-26 17:40:43 +05:00
prologue Make capitalization os SysVinit consistent 2024-08-16 12:51:31 +05:00
stylesheets bootscripts: console: Fix fb console detection 2024-08-25 22:14:05 +05:00
udev-lfs bootscripts: console: Fix fb console detection 2024-08-25 22:14:05 +05:00
.gitignore build: Add "make dist" 2023-09-13 23:00:58 +03:00
ABOUT.md Release 12.1 2024-02-29 22:58:36 +05:00
aux-file-data.sh bootscripts: console: Fix fb console detection 2024-08-25 22:14:05 +05:00
gen-changelog.py gen-changelog: Handles holding tickets 2024-01-02 21:11:20 +05:00
general.ent Small fix 2024-04-01 16:09:20 +05:00
git-version.sh bootscripts: console: Fix fb console detection 2024-08-25 22:14:05 +05:00
index.xml Add lang='ru' 2023-09-24 23:04:19 +05:00
INSTALL.md Rename install to install.md 2023-08-13 12:12:31 +05:00
lfs-latest-git.php bootscripts: console: Fix fb console detection 2024-08-25 22:14:05 +05:00
lfs-latest.php Removed stale lfs-latest.php and symlink lfs-latest-git.php to it 2023-09-05 00:38:23 +03:00
LICENSE Initial commit 2022-05-09 00:31:36 +05:00
make-aux-files.sh Fix file mode 2024-02-07 14:55:30 +05:00
Makefile build: Use -r for git ls-tree in make dist 2024-08-18 21:53:18 +05:00
obfuscate.sh Fix file mode 2024-02-07 14:55:30 +05:00
packages.ent bootscripts: console: Fix fb console detection 2024-08-25 22:14:05 +05:00
patches.ent Package updates 2024-08-16 12:55:32 +05:00
pdf-fixups.sh Fix file mode 2024-02-07 14:55:30 +05:00
process-scripts.sh Fix file mode 2024-02-07 14:55:30 +05:00
README.md Added build script with "all" parameter 2023-09-05 11:58:54 +03:00
tidy.conf Generate utf-8 encoded html (needs to be tested) 2023-11-26 21:46:04 +05:00

LFS Book README

В этом документе содержится информация о том, как выполнить преобразование книги из XML формата в другой формат (например, HTML, PDF, PS и TXT). Для начала, если вы ещё этого не сделали, пожалуйста, откройте и прочитайте информацию, представленную в файле INSTALL, чтобы установить необходимое программное обеспечение. Если вы уже выполнили все шаги в файле INSTALL, ознакомьтесь с примерами того, как выполнить преобразование файлов в другие форматы.

Во всех примерах необходимо указание аргумента REV=systemd, если требуется сборка редакции systemd.

XML в XHTML:

make BASEDIR=/path/to/output/location

XML в одностраничный XHTML (nochunks):

make BASEDIR=/path/to/output/location nochunks

XML в TXT:

Следуйте инструкциям для nochunks и затем запустите: lynx -dump /path/to/nochunks > /path/to/output

XML в PDF:

make BASEDIR=/path/to/output/location pdf

Сделать сборку всех версий (TXT по умолчанию не создается):

make BASEDIR=/path/to/output/location all