]> git.ipfire.org Git - thirdparty/man-pages.git/log
thirdparty/man-pages.git
40 hours agoshare/mk/: Remove unused variable master
Alejandro Colomar [Thu, 18 Apr 2024 00:30:00 +0000 (02:30 +0200)] 
share/mk/: Remove unused variable

Co-developed-by: Deri James <deri@chuzzlewit.myzen.co.uk>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2 days agoshare/mk/: build-fonts: Use $FONTSDIR/devpdf/, and add the download file
Alejandro Colomar [Tue, 16 Apr 2024 20:04:52 +0000 (22:04 +0200)] 
share/mk/: build-fonts: Use $FONTSDIR/devpdf/, and add the download file

See gropdf(1).

Reported-by: Deri <deri@chuzzlewit.myzen.co.uk>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2 days agosyscalls.2: srcfix
G. Branden Robinson [Mon, 15 Apr 2024 22:39:42 +0000 (17:39 -0500)] 
syscalls.2: srcfix

Tweak input format of table text blocks to make a planned sed-driven
update simpler and more reliable.

Signed-off-by: "G. Branden Robinson" <g.branden.robinson@gmail.com>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2 days agogetpagesize.2: tfix
G. Branden Robinson [Mon, 15 Apr 2024 22:39:29 +0000 (17:39 -0500)] 
getpagesize.2: tfix

Signed-off-by: "G. Branden Robinson" <g.branden.robinson@gmail.com>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 days agoshare/mk/: build-pdf-book: Fix chapter bookmarks
Alejandro Colomar [Tue, 16 Apr 2024 01:35:04 +0000 (03:35 +0200)] 
share/mk/: build-pdf-book: Fix chapter bookmarks

So that they can be folded.

Suggested-by: Deri James <deri@chuzzlewit.myzen.co.uk>
Cc: "G. Branden Robinson" <branden@debian.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 days agoshare/mk/: build-pdf-book: Add support for mdoc(7) pages, with -mandoc
Alejandro Colomar [Tue, 16 Apr 2024 01:23:16 +0000 (03:23 +0200)] 
share/mk/: build-pdf-book: Add support for mdoc(7) pages, with -mandoc

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 days agoshare/mk/: build-pdf-book: Use -rC1, to have strictly increasing page numbers
Alejandro Colomar [Tue, 16 Apr 2024 01:17:16 +0000 (03:17 +0200)] 
share/mk/: build-pdf-book: Use -rC1, to have strictly increasing page numbers

Suggested-by: "G. Branden Robinson" <branden@debian.org>
Suggested-by: Deri James <deri@chuzzlewit.myzen.co.uk>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 days agoshare/mk/: Read files before 'if'
Alejandro Colomar [Tue, 16 Apr 2024 00:02:17 +0000 (02:02 +0200)] 
share/mk/: Read files before 'if'

'if' turns off set -e.  We want to read files before 'if', so that if
they don't exist, the shell will error out.

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 days agoGNUmakefile: Simplify the $SHELL
Alejandro Colomar [Mon, 15 Apr 2024 23:16:08 +0000 (01:16 +0200)] 
GNUmakefile: Simplify the $SHELL

nixpkgs does not provide /usr/bin/env, so they had to work around it by
specifying just env.  Since make(1) accepts program names instead of
paths, we can as well use bash directly, which is simpler.

Link: <https://github.com/NixOS/nixpkgs/pull/300797>
Reported-by: Sergei Trofimovich <slyich@gmail.com>
Cc: Mario Rodas <https://github.com/marsam>
Cc: Eli Schwartz <eschwartz93@gmail.com>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 days agoshare/mk/: install-man: Don't pipe to install(1)
Alejandro Colomar [Mon, 15 Apr 2024 22:29:17 +0000 (00:29 +0200)] 
share/mk/: install-man: Don't pipe to install(1)

install(1) doesn't work well in Darwin.  It seems to be unable to handle
</dev/stdin>.  The problem seems to be that Darwin's stdin misbehaves.

I've only workarounded the install target, and not the dist target,
since it's unlikely that one would run it in such a broken system.  But
since installing the pages is a common operation that everybody needs,
let's work around it here.

Fixes: 30c38a8bf8ae ("*.mk: Pipe to install(1)")
Link: <https://github.com/NixOS/nixpkgs/pull/300797>
Closes: <https://bugzilla.kernel.org/show_bug.cgi?id=218730>
Reported-by: Sergei Trofimovich <slyich@gmail.com>
Reported-by: Mario Rodas <https://github.com/marsam>
Cc: Eli Schwartz <eschwartz93@gmail.com>
Cc: Pádraig Brady <P@draigBrady.com>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 days agoshare/mk/: build-pdf-book: Use the system's man(7) macros
Alejandro Colomar [Mon, 15 Apr 2024 22:26:08 +0000 (00:26 +0200)] 
share/mk/: build-pdf-book: Use the system's man(7) macros

Signed-off-by: Alejandro Colomar <alx@kernel.org>
5 days agoproc.5: Refer to split-out manual pages for detailed description
Salvatore Bonaccorso [Fri, 12 Apr 2024 18:29:06 +0000 (20:29 +0200)] 
proc.5: Refer to split-out manual pages for detailed description

Back in August 2023 various parts of proc(5) were split out into
separate manpages.  The final cleanup in 92cdcec79df0 ("proc.5: Clean up
after making sashimi of this page") missed to as well refer to the split
out manpages and retained the wording that details are found further
below in the manpages for the various files.

Fixes: 92cdcec79df0 ("proc.5: Clean up after making sashimi of this page")
Signed-off-by: Salvatore Bonaccorso <carnil@debian.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
9 days agoman3/, debian/debhelper.in/glibc-doc.links: Move link pages to their place
Alejandro Colomar [Wed, 10 Apr 2024 00:29:29 +0000 (02:29 +0200)] 
man3/, debian/debhelper.in/glibc-doc.links: Move link pages to their place

Scripted change:

$ cat debian/debhelper.in/glibc-doc.links \
| while read l; do \
echo $l \
| awk '{print $1}' \
| sed 's,usr/share/man/,.so ,' \
| sed 's,\.gz,,' \
> "$(echo $l \
| awk '{print $2}' \
| sed 's,usr/share/man/,,' \
| sed 's,\.gz,,')";
done;
$ rm debian/debhelper.in/glibc-doc.links

Link: <https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1068188>
Link: <https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1068166>
Link: <https://lore.kernel.org/linux-man/703ec07e-dd2b-bbc6-f1bc-f495e53b764f@gmail.com/T/>
Cc: Marcos Fouces <marcos@debian.org>
Cc: Sven Joachim <svenjoac@gmx.de>
Cc: Bas Couwenberg <sebastic@xs4all.nl>
Cc: Andreas Beckmann <anbe@debian.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
9 days agoRevert "debian/debhelper.in/glibc-doc.{links,manpages}, debian/local/manpages/pthread...
Alejandro Colomar [Wed, 10 Apr 2024 00:23:45 +0000 (02:23 +0200)] 
Revert "debian/debhelper.in/glibc-doc.{links,manpages}, debian/local/manpages/pthread_*: drop the man pages for libpthread functions, as they are now included in manpages-dev.  Closes: #1068188."

This reverts commit c75bae912ab3b138687060df3701a888388e3d09.

9 days agoImport pthread_*.3 link pages' git history from debian/glibc.git
Alejandro Colomar [Wed, 10 Apr 2024 00:16:14 +0000 (02:16 +0200)] 
Import pthread_*.3 link pages' git history from debian/glibc.git

These are the link pages, which I forgot to import in 87183bb8e9ec
("Import debian/local/manpages/pthread_*.3 git history from debian/glibc")
They aren't files in the debian repository, but they were generated at
build time, which is the reason I missed them.

Here's the process:

$ git clone git@salsa.debian.org:glibc-team/glibc.git
$ cd glibc/
$ git filter-repo --path debian/debhelper.in/glibc-doc.links
$ git tag | xargs git tag -d
$ git branch | xargs git branch -D
$ git remote add man file:///home/alx/src/linux/man-pages/man-pages/.bare.git
$ git fetch man
$ git rebase man/contrib

Subsequent commits will move the pages to the appropriate place.

Fixes: 87183bb8e9ec ("Import debian/local/manpages/pthread_*.3 git history from debian/glibc")
Link: <https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1068188>
Link: <https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1068166>
Link: <https://lore.kernel.org/linux-man/703ec07e-dd2b-bbc6-f1bc-f495e53b764f@gmail.com/T/>
Cc: Marcos Fouces <marcos@debian.org>
Cc: Sven Joachim <svenjoac@gmx.de>
Cc: Bas Couwenberg <sebastic@xs4all.nl>
Cc: Andreas Beckmann <anbe@debian.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
9 days agodebian/debhelper.in/glibc-doc.{links,manpages}, debian/local/manpages/pthread_*:...
Aurelien Jarno [Tue, 9 Apr 2024 19:44:40 +0000 (21:44 +0200)] 
debian/debhelper.in/glibc-doc.{links,manpages}, debian/local/manpages/pthread_*: drop the man pages for libpthread functions, as they are now included in manpages-dev.  Closes: #1068188.

9 days ago * Remove manpages now provided by manpages-dev (closes: bug#595194):
Aurelien Jarno [Wed, 1 Sep 2010 21:11:16 +0000 (21:11 +0000)] 
  * Remove manpages now provided by manpages-dev (closes: bug#595194):
    - pthread_kill_other_threads_np (3)
    - pthread_sigmask (3)

svn path=/glibc-package/trunk/; revision=4409

9 days ago * Remove manpage that will be provided by manpages-dev. Closes: bug#506515,
Aurelien Jarno [Wed, 7 Jan 2009 15:58:28 +0000 (15:58 +0000)] 
  * Remove manpage that will be provided by manpages-dev.  Closes: bug#506515,
    bug#505784.

svn path=/glibc-package/branches/glibc-2.9/; revision=3223

9 days ago * debian/debhelper.in/glibc-doc.links: add missing manpages links for
Aurelien Jarno [Mon, 23 Apr 2007 09:41:15 +0000 (09:41 +0000)] 
  * debian/debhelper.in/glibc-doc.links: add missing manpages links for
    functions documented with others.  Closes: #413989.

svn path=/glibc-package/trunk/; revision=2114

9 days agoupdate trunk to 2.5-1
Clint Adams [Wed, 11 Apr 2007 03:07:27 +0000 (03:07 +0000)] 
update trunk to 2.5-1

svn path=/glibc-package/trunk/; revision=2040

9 days ago * Backport from experimental (thanks Denis):
Aurelien Jarno [Tue, 15 Aug 2006 20:40:10 +0000 (20:40 +0000)] 
 * Backport from experimental (thanks Denis):
   - Remove the GNU Libc Reference manual from glibc-doc because it is
     not DFSG-free. (Closes: #181494)
     The whole glibc-2.3.6/manual directory is removed from glibc-2.3.6.ds1.tar.bz2.
   - debian/control: Drop Build-Depends: texinfo, texi2html.
   - debian/control: Drop references to the antique libc-doc package.
   - all/cvs-manual-memory.diff: removed.
   - all/cvs-manual-string.diff: removed.

svn path=/glibc-package/trunk/; revision=1742

9 days agoRemove sem_*.3 manual pages from glibc-doc, these manual pages are updated
Denis Barbier [Wed, 10 May 2006 23:32:00 +0000 (23:32 +0000)] 
Remove sem_*.3 manual pages from glibc-doc, these manual pages are updated
and maintained in the manpages-dev package.  (Closes: #365547)

svn path=/glibc-package/trunk/; revision=1475

9 days ago - debian/debhelper.in/glibc-doc.links: add manpages links for sem_*.
GOTO Masanori [Tue, 16 Mar 2004 14:21:45 +0000 (14:21 +0000)] 
   - debian/debhelper.in/glibc-doc.links: add manpages links for sem_*.

svn path=/trunk/; revision=649

9 days ago - debian/debhelper.in/glibc-doc.links: add missing links for
GOTO Masanori [Mon, 17 Nov 2003 09:43:27 +0000 (09:43 +0000)] 
- debian/debhelper.in/glibc-doc.links: add missing links for
      pthread_mutex_*(), pthread_mutexattr_*(), pthread_cond_*(), and
      pthread_condattr_*().

svn path=/trunk/; revision=603

9 days agoFiles missed in merge. Clean *.doc-base.
Daniel Jacobowitz [Tue, 28 Oct 2003 23:07:31 +0000 (23:07 +0000)] 
Files missed in merge.  Clean *.doc-base.

svn path=/trunk/; revision=564

9 days agoshare/mk/: Remove support for installing compressed pages
Alejandro Colomar [Tue, 9 Apr 2024 21:56:44 +0000 (23:56 +0200)] 
share/mk/: Remove support for installing compressed pages

I don't like compressed pages: they make it more difficult/slow to grep
them.  This was added to make it easier for users to install compressed
pages even when installing from source, but probably nobody cares at all
these days about a few KiB per page; drive space got cheap.  Also, some
of the algorithms were added just for benchmarking (for demonstrating
that they were bad in this case), and not for real use.

This reduces a use of compression tools, which seem to be dangerous
these days.

Link: <https://tukaani.org/xz-backdoor/>
Link: <https://cmpct.info/~sam/blog/posts/automatic-manpage-compression/>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
10 days agoS_ISBLK.3, S_ISCHR.3, S_ISDIR.3, S_ISFIFO.3, S_ISLNK.3, S_ISREG.3, S_ISSOCK.3: Add...
Alejandro Colomar [Tue, 9 Apr 2024 12:18:40 +0000 (14:18 +0200)] 
S_ISBLK.3, S_ISCHR.3, S_ISDIR.3, S_ISFIFO.3, S_ISLNK.3, S_ISREG.3, S_ISSOCK.3: Add link pages to inode(7)

These function-like macros are described in inode(7).

Signed-off-by: Alejandro Colomar <alx@kernel.org>
10 days agoshare/mk/: build: Add exceptions
Alejandro Colomar [Mon, 8 Apr 2024 17:25:13 +0000 (19:25 +0200)] 
share/mk/: build: Add exceptions

With the larger font size, these pages have warnings.

Signed-off-by: Alejandro Colomar <alx@kernel.org>
11 days agoshare/mk/: $TROFFFLAGS: Use a larger font size
Alejandro Colomar [Mon, 8 Apr 2024 17:15:35 +0000 (19:15 +0200)] 
share/mk/: $TROFFFLAGS: Use a larger font size

Link: <https://journals.uc.edu/index.php/vl/article/view/5765>
Reported-by: Paul Eggert <eggert@cs.ucla.edu>
Suggested-by: "G. Branden Robinson" <branden@debian.org>
Cc: "Thomas E. Dickey" dickey@his.com
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2 weeks agoinit_module.2: Document MODULE_INIT_COMPRESS_FILE flag
Michael Weiß [Wed, 3 Apr 2024 11:42:23 +0000 (13:42 +0200)] 
init_module.2: Document MODULE_INIT_COMPRESS_FILE flag

finit_module() supports the MODULE_INIT_COMPRESS_FILE flag since
Linux 5.17. See commit b1ae6dc41eaaa ("module: add in-kernel support
for decompressing")

During implementation of a secure module loader in GyroidOS, we
wanted to filter unsafe module parameters. To verify that only the
two documented flags which are disabling sanity checks are unsafe,
we had a look in the current kernel implementation.

We discovered that this new flag MODULE_INIT_COMPRESS_FILE was added.
Having a deeper look at the code, we also discovered that a new error
code EOPNOTSUPP is possible within newer kernels.

The inital commit only supported gzip and xz compression algorithms.
Support for zstd was added in Linux 6.2 by commit 169a58ad824d8
("module/decompress: Support zstd in-kernel decompression")

Signed-off-by: Michael Weiß <michael.weiss@aisec.fraunhofer.de>
Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Cc: Stephen Boyd <swboyd@chromium.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2 weeks agosigwait.3: Note sigprocmask(2) requirement, explicitly link sigtimedwait(2)/NOTES
наб [Wed, 3 Apr 2024 15:06:45 +0000 (17:06 +0200)] 
sigwait.3: Note sigprocmask(2) requirement, explicitly link sigtimedwait(2)/NOTES

This comes from a real user complaint. sigwait(3) is the most obvious
of the family, and it doesn't mention any of the usage details.
Most of these can be crosslinked, but not mentioning the sigprocmask(2)
requirement is malice.

Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2 weeks agogetpagesize.2, syscalls.2: Modernization
Elliott Hughes [Sat, 30 Mar 2024 00:10:26 +0000 (17:10 -0700)] 
getpagesize.2, syscalls.2: Modernization

Remove the HP-UX portability advice, since getpagesize() is a slightly
better option than sysconf() for Linux systems.

Explain why this function exists, and why this man page is in the wrong
section.  (The previous text tried to do both at the same, which was
confusing.) Also explain how the vast majority of architectures that
don't have a syscall (but do support multiple page sizes) actually work.

Also de-emphasize the glibc 2.0 bug, since most people don't need to
worry about compatibility with versions of glibc from 1997.

Finally, change "not on x86" in syscalls.2 to say where there _is_ a
syscall.

Co-developed-by: Elliott Hughes <enh@google.com>
Co-developed-by: Alejandro Colomar <alx@kernel.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2 weeks agogetgrouplist.3: EXAMPLES: Fix error handling for getpwnam(3)
Fedor Lapshin [Fri, 29 Mar 2024 00:21:11 +0000 (03:21 +0300)] 
getgrouplist.3: EXAMPLES: Fix error handling for getpwnam(3)

Signed-off-by: Fedor Lapshin <fe.lap.prog@gmail.com>
Co-developed-by: Alejandro Colomar <alx@kernel.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2 weeks agoshare/mk/: Useful Use of Cat
Alejandro Colomar [Fri, 29 Mar 2024 17:36:40 +0000 (18:36 +0100)] 
share/mk/: Useful Use of Cat

Simplify a pipeline, by using cat(1) to actually catenate stuff.

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: Reorganize files for generating the PDF book
Alejandro Colomar [Mon, 25 Mar 2024 12:59:17 +0000 (13:59 +0100)] 
share/mk/: Reorganize files for generating the PDF book

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: Generate the fonts during the build
Alejandro Colomar [Mon, 25 Mar 2024 12:10:34 +0000 (13:10 +0100)] 
share/mk/: Generate the fonts during the build

Suggested-by: "G. Branden Robinson" <branden@debian.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoetc/clang-tidy/config.yaml: -llvm-header-guard
Alejandro Colomar [Tue, 26 Mar 2024 01:00:26 +0000 (02:00 +0100)] 
etc/clang-tidy/config.yaml: -llvm-header-guard

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoetc/cpplint/cpplint.cfg: -build/header_guard
Alejandro Colomar [Tue, 26 Mar 2024 00:46:05 +0000 (01:46 +0100)] 
etc/cpplint/cpplint.cfg: -build/header_guard

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: $CFLAGS: -Wno-reserved-identifier, -Wno-unused-macros
Alejandro Colomar [Tue, 26 Mar 2024 01:00:03 +0000 (02:00 +0100)] 
share/mk/: $CFLAGS: -Wno-reserved-identifier, -Wno-unused-macros

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: lint-c-iwyu: Add exceptions
Alejandro Colomar [Tue, 26 Mar 2024 00:37:51 +0000 (01:37 +0100)] 
share/mk/: lint-c-iwyu: Add exceptions

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshmop.2: EXAMPLES: ffix
Alejandro Colomar [Tue, 26 Mar 2024 01:06:08 +0000 (02:06 +0100)] 
shmop.2: EXAMPLES: ffix

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoman*/: EXAMPLES: Add include guards
Alejandro Colomar [Tue, 26 Mar 2024 00:46:38 +0000 (01:46 +0100)] 
man*/: EXAMPLES: Add include guards

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoman*/: EXAMPLES: Fix includes
Alejandro Colomar [Tue, 26 Mar 2024 00:35:11 +0000 (01:35 +0100)] 
man*/: EXAMPLES: Fix includes

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: lint-c: Lint headers from EXAMPLES
Alejandro Colomar [Tue, 26 Mar 2024 00:58:34 +0000 (01:58 +0100)] 
share/mk/: lint-c: Lint headers from EXAMPLES

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: Sync with liba2i's build system
Alejandro Colomar [Mon, 25 Mar 2024 11:54:36 +0000 (12:54 +0100)] 
share/mk/: Sync with liba2i's build system

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: build-pdf*, install-pdf*: Rename targets for consistency
Alejandro Colomar [Sun, 24 Mar 2024 12:10:37 +0000 (13:10 +0100)] 
share/mk/: build-pdf*, install-pdf*: Rename targets for consistency

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/, scripts/LinuxManBook/build.sh: Embed script in the makefiles
Alejandro Colomar [Sun, 24 Mar 2024 11:55:15 +0000 (12:55 +0100)] 
share/mk/, scripts/LinuxManBook/build.sh: Embed script in the makefiles

This is done for simplifying, and as a side effect, it also allows
much more control on the script (e.g., TROFFFLAGS).

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: [un]install-pdf: Add target to install the PDF book
Alejandro Colomar [Sun, 24 Mar 2024 11:39:46 +0000 (12:39 +0100)] 
share/mk/: [un]install-pdf: Add target to install the PDF book

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: $EXTRAVERSION: Add variable to append to the version
Alejandro Colomar [Sun, 24 Mar 2024 04:32:17 +0000 (05:32 +0100)] 
share/mk/: $EXTRAVERSION: Add variable to append to the version

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: Derive $DISTNAME from $DISTVERSION
Alejandro Colomar [Sun, 24 Mar 2024 04:30:52 +0000 (05:30 +0100)] 
share/mk/: Derive $DISTNAME from $DISTVERSION

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: Reorganize build system
Alejandro Colomar [Sat, 23 Mar 2024 22:48:30 +0000 (23:48 +0100)] 
share/mk/: Reorganize build system

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: dist: Don't stamp the version on the manual pages
Alejandro Colomar [Fri, 22 Mar 2024 23:59:17 +0000 (00:59 +0100)] 
share/mk/: dist: Don't stamp the version on the manual pages

This will allow downstream packages to set their own version, just by
setting $DISTVERSION.

It will be stamped at `make install` time.

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: $MANPAGEDATECMD: Use a variable for setting the date of manual pages
Alejandro Colomar [Fri, 22 Mar 2024 23:56:47 +0000 (00:56 +0100)] 
share/mk/: $MANPAGEDATECMD: Use a variable for setting the date of manual pages

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: build-*: Specify manual pages' version and date
Alejandro Colomar [Fri, 22 Mar 2024 23:44:50 +0000 (00:44 +0100)] 
share/mk/: build-*: Specify manual pages' version and date

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: Fix includes
Alejandro Colomar [Fri, 22 Mar 2024 23:20:05 +0000 (00:20 +0100)] 
share/mk/: Fix includes

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: build-man: Split rule
Alejandro Colomar [Fri, 22 Mar 2024 22:49:39 +0000 (23:49 +0100)] 
share/mk/: build-man: Split rule

Signed-off-by: Alejandro Colomar <alx@kernel.org>
3 weeks agoshare/mk/: Use more robust regex
Alejandro Colomar [Fri, 22 Mar 2024 20:55:08 +0000 (21:55 +0100)] 
share/mk/: Use more robust regex

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoshare/mk/: build-book, build-man, install-man: Specify version and date
Alejandro Colomar [Wed, 20 Mar 2024 14:56:21 +0000 (15:56 +0100)] 
share/mk/: build-book, build-man, install-man: Specify version and date

Each page has its own date.

Add new 'build-man' target, which stamps the date and version in the
pages (in $builddir, not the source ones).

Build-system internal stuff:
$CURDIR will be used for the build system, while $srcdir will be
used for the project root of the repository.  This helps use
this build system in other projects.

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoscripts/LinuxManBook/prepare.pl: Use more robust pipelines
Alejandro Colomar [Wed, 20 Mar 2024 21:05:08 +0000 (22:05 +0100)] 
scripts/LinuxManBook/prepare.pl: Use more robust pipelines

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoGNUmakefile: help: wfix
Alejandro Colomar [Wed, 20 Mar 2024 14:13:16 +0000 (15:13 +0100)] 
GNUmakefile: help: wfix

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoshare/mk/: Reorganize dependencies
Alejandro Colomar [Tue, 19 Mar 2024 22:09:25 +0000 (23:09 +0100)] 
share/mk/: Reorganize dependencies

Use one directory per each (Debian) package, and one file per command.

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoGNUmakefile: help: Hide variables not meant for users
Alejandro Colomar [Tue, 19 Mar 2024 19:47:15 +0000 (20:47 +0100)] 
GNUmakefile: help: Hide variables not meant for users

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoStart of man-pages-NEXT: Move Changes to Changes.old
Alejandro Colomar [Tue, 19 Mar 2024 18:21:39 +0000 (19:21 +0100)] 
Start of man-pages-NEXT: Move Changes to Changes.old

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agolsm: Released 6.7
Alejandro Colomar [Tue, 19 Mar 2024 18:19:43 +0000 (19:19 +0100)] 
lsm: Released 6.7

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoChanges: Ready for 6.7 man-pages-6.7
Alejandro Colomar [Tue, 19 Mar 2024 18:01:04 +0000 (19:01 +0100)] 
Changes: Ready for 6.7

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoChanges: git(1) already shows contributors
Alejandro Colomar [Tue, 19 Mar 2024 17:42:07 +0000 (18:42 +0100)] 
Changes: git(1) already shows contributors

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoGNUmakefile, INSTALL, RELEASE: Expand 'make help' to document dependencies
Alejandro Colomar [Tue, 19 Mar 2024 17:29:58 +0000 (18:29 +0100)] 
GNUmakefile, INSTALL, RELEASE: Expand 'make help' to document dependencies

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoGNUmakefile: help: Add a simple help
Alejandro Colomar [Tue, 19 Mar 2024 17:14:33 +0000 (18:14 +0100)] 
GNUmakefile: help: Add a simple help

It documents how to actually get the targets and variables with a
pipeline.

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoGNUmakefile: Use a more portable $SHELL
Alejandro Colomar [Tue, 19 Mar 2024 17:13:45 +0000 (18:13 +0100)] 
GNUmakefile: Use a more portable $SHELL

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoGNUmakefile: Remove help
Alejandro Colomar [Tue, 19 Mar 2024 16:54:52 +0000 (17:54 +0100)] 
GNUmakefile: Remove help

It gets out of date easily, and it's always more accurate to actually
read the makefiles, or run a command that parses them for us.
In the case of .PHONY targets, or available variables, here are two
commands that can help:

$ make nothing -p \
| grep '^\.PHONY:' \
| tr ' ' '\n' \
| grep -v '^\.PHONY:' \
| sort;

$ grep -rho '^[^[:space:]].*=' GNUmakefile share/mk/configure/;

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoshare/lint, share/mk/: Move *.grep files
Alejandro Colomar [Tue, 19 Mar 2024 16:23:01 +0000 (17:23 +0100)] 
share/lint, share/mk/: Move *.grep files

They're part of the build system, so put them under <share/mk/>.

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoshare/mk/: Split long line
Alejandro Colomar [Tue, 19 Mar 2024 12:48:41 +0000 (13:48 +0100)] 
share/mk/: Split long line

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoshare/mk/: Rename variables
Alejandro Colomar [Tue, 19 Mar 2024 12:30:30 +0000 (13:30 +0100)] 
share/mk/: Rename variables

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoshare/mk/: We don't use man2html(1) any more
Alejandro Colomar [Tue, 19 Mar 2024 01:25:42 +0000 (02:25 +0100)] 
share/mk/: We don't use man2html(1) any more

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoshare/mk/: $htmlext: Remove unused variable
Alejandro Colomar [Tue, 19 Mar 2024 00:17:21 +0000 (01:17 +0100)] 
share/mk/: $htmlext: Remove unused variable

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoshare/mk/: Print SED rather than CP
Alejandro Colomar [Mon, 18 Mar 2024 23:56:27 +0000 (00:56 +0100)] 
share/mk/: Print SED rather than CP

That's what we use.

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoshare/mk/: wsfix
Alejandro Colomar [Mon, 18 Mar 2024 23:54:15 +0000 (00:54 +0100)] 
share/mk/: wsfix

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoshare/mk/: sort(1) input to tar(1)
Alejandro Colomar [Mon, 18 Mar 2024 16:20:26 +0000 (17:20 +0100)] 
share/mk/: sort(1) input to tar(1)

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoshare/mk/: Consistency fixes in copyright lines
Alejandro Colomar [Mon, 18 Mar 2024 15:50:28 +0000 (16:50 +0100)] 
share/mk/: Consistency fixes in copyright lines

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoshare/mk/: build-html: Skip known errors (in groff-1.23.0)
Alejandro Colomar [Mon, 18 Mar 2024 15:27:49 +0000 (16:27 +0100)] 
share/mk/: build-html: Skip known errors (in groff-1.23.0)

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoLICENSES/: Add LGPL-3.0-or-later and LGPL-3.0-linking-exception
Alejandro Colomar [Mon, 18 Mar 2024 15:20:58 +0000 (16:20 +0100)] 
LICENSES/: Add LGPL-3.0-or-later and LGPL-3.0-linking-exception

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoshare/mk/: Update license
Alejandro Colomar [Mon, 18 Mar 2024 15:19:24 +0000 (16:19 +0100)] 
share/mk/: Update license

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoshare/mk/: Use grohtml(1) instead of man2html(1)
Alejandro Colomar [Mon, 18 Mar 2024 14:35:10 +0000 (15:35 +0100)] 
share/mk/: Use grohtml(1) instead of man2html(1)

man2html(1) crashes on tzfile(5), and the upstream project is defunct.

Link: <https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1067022>
Cc: Paul Eggert <eggert@cs.ucla.edu>
Cc: "G. Branden Robinson" <branden@debian.org>
Cc: Robert Luberda <robert@debian.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoproc_pid_io.5: Move note to CAVEATS
Alejandro Colomar [Mon, 18 Mar 2024 10:00:14 +0000 (11:00 +0100)] 
proc_pid_io.5: Move note to CAVEATS

Cc: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agobpf.2: wfix
Jing Peng [Sun, 17 Mar 2024 23:48:24 +0000 (19:48 -0400)] 
bpf.2: wfix

Signed-off-by: Jing Peng <pj.hades@gmail.com>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoip.7: Some socket options are not supported by SOCK_STREAM
Oliver Crumrine [Sun, 17 Mar 2024 13:55:50 +0000 (09:55 -0400)] 
ip.7: Some socket options are not supported by SOCK_STREAM

It was not made clear in several socket options that they were not
supported by SOCK_STREAM; this patch fixes that.

Socket options not supported by SOCK_STREAM are handled in the
ip_cmsg_recv_offset() function in <net/ipv4/ip_sockglue.c>.  The
function is called for udp sockets, and indirectly by ping and raw
sockets, but not for STREAM sockets, as they don't support these
options.

Link: <https://lore.kernel.org/linux-man/ejhphmjh74ebtk4br3id66f27a4yoh4aukrcz7m6dp7acsu6zr@crtueyadqzmp/T/#mb298ac7f71a348d1e6b423cfa32bfad9c28efa40>
Link: <https://lore.kernel.org/linux-man/ejhphmjh74ebtk4br3id66f27a4yoh4aukrcz7m6dp7acsu6zr@crtueyadqzmp/T/#u>
Signed-off-by: Oliver Crumrine <ozlinuxc@gmail.com>
Cc: Peter Seiderer <ps.report@gmx.net>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoproc_pid_io.5: Dewafflify
наб [Sun, 17 Mar 2024 15:37:52 +0000 (16:37 +0100)] 
proc_pid_io.5: Dewafflify

This page copies verbatim the contents of
Documentation/filesystems/proc.rst, added wholesale in
commit f9c99463b0cd05603d125c915e2886d55a686b82 ("[PATCH] Documentation
for io-accounting / reporting via procfs") in 2007.

As such, it mirrors the sensibilities of the time ‒
writing "successful read returns" as "data pulled from storage. actually
just the data the process gave to read(). this also means from non-regular
files! whether the data was pulled from storage doesn't matter actually
(obligatory cache mention)"
for the modern reader this is just a lot of waffling
(note also that processes give no data to read()!)
‒ and sensibilities of the sheepish implementer in kernel documentation ‒
"an attempt" for a well-defined kernel behaviour, mentioning the
"current implementation", consistent mentions of specific kernel-internal
caching mechanisms, "the big inaccuracy here".

Re-write to be more useful and less misleading as documentation;
the syscall enumeration is accurate for kernel v6.8, but the sysc? stats
are also bumped by kernel_{read,write}(), which is sometimes used by too
many syscalls in too many scenarios to usefully enumerate.

Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoproc_pid_io.5: Stats include children
наб [Sun, 17 Mar 2024 11:01:43 +0000 (12:01 +0100)] 
proc_pid_io.5: Stats include children

This file is like getrusage(2) RUSAGE_SELF + RUSAGE_CHILDREN,
the current wording implies it's like just RUSAGE_SELF.

Compare:
  #include <fcntl.h>
  #include <signal.h>
  #include <string.h>
  #include <sys/wait.h>
  #include <unistd.h>

  void copy() {
    char buf[1024];
    int fd = open("/proc/self/io", 0);
    write(1, buf, read(fd, buf, sizeof(buf)));
    close(fd);
  }

  int main() {
    copy();
    copy();
    if (!fork()) {
    zero:;
      int fd = open("/dev/zero", 0);
      char buf[64 * 1024] = {};
      write(1, buf, 10000);
      for (int i = 0; i < 1000; ++i)
        read(fd, buf, sizeof(buf));
      _exit(0);
    }
    sleep(1);
    copy();
    wait(NULL);
    copy();
    signal(SIGCHLD, SIG_IGN);
    if (!fork())
      goto zero;
    sleep(1);
    copy();
    wait(NULL);
    copy();
  }
yielding
  rchar: 3980
  wchar: 0
  syscr: 9
  syscw: 0
  read_bytes: 2968
  write_bytes: 0
  cancelled_write_bytes: 0

  rchar: 4076
  wchar: 96
  syscr: 10
  syscw: 1
  read_bytes: 2968
  write_bytes: 96
  cancelled_write_bytes: 0

  rchar: 4175
  wchar: 195
  syscr: 11
  syscw: 2
  read_bytes: 2968
  write_bytes: 195
  cancelled_write_bytes: 0

  rchar: 65540276
  wchar: 10296
  syscr: 1012
  syscw: 4
  read_bytes: 2968
  write_bytes: 10296
  cancelled_write_bytes: 0

  rchar: 65540387
  wchar: 10407
  syscr: 1013
  syscw: 5
  read_bytes: 2968
  write_bytes: 10407
  cancelled_write_bytes: 0

  rchar: 65540498
  wchar: 10518
  syscr: 1014
  syscw: 6
  read_bytes: 2968
  write_bytes: 10518
  cancelled_write_bytes: 0

Just s/process/& and its waited-for children/ but re-broken per review.

Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agotzfile.5: ffix
Alejandro Colomar [Sun, 17 Mar 2024 12:47:28 +0000 (13:47 +0100)] 
tzfile.5: ffix

Cc: "G. Branden Robinson" <branden@debian.org>
Cc: Paul Eggert <eggert@cs.ucla.edu>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agotzfile.5: Avoid crashing man2html(1)
Alejandro Colomar [Sun, 17 Mar 2024 11:23:25 +0000 (12:23 +0100)] 
tzfile.5: Avoid crashing man2html(1)

Link: <https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1067022>
Cc: Paul Eggert <eggert@cs.ucla.edu>
Cc: "G. Branden Robinson" <branden@debian.org>
Cc: Robert Luberda <robert@debian.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agotzfile.5, tzselect.8, zdump.8, zic.8: Refresh pages
Alejandro Colomar [Sat, 16 Mar 2024 22:04:46 +0000 (23:04 +0100)] 
tzfile.5, tzselect.8, zdump.8, zic.8: Refresh pages

Refreshed from tzdb-2024a.

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agobpf-helpers.7: Refresh page
Alejandro Colomar [Sat, 16 Mar 2024 21:57:05 +0000 (22:57 +0100)] 
bpf-helpers.7: Refresh page

Scripted change:

$ ~/src/linux/linux/6.8/scripts/bpf_doc.py | rst2man > man7/bpf-helpers.7

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agogetgrouplist.3: Use same type in both sides of comparison
Alejandro Colomar [Sat, 16 Mar 2024 01:01:20 +0000 (02:01 +0100)] 
getgrouplist.3: Use same type in both sides of comparison

This removes a warning.

Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agounix.7: EXAMPLES: server.c: End connection with END
Lili Püspök [Wed, 6 Mar 2024 20:02:47 +0000 (21:02 +0100)] 
unix.7: EXAMPLES: server.c: End connection with END

Client wants to send END while server already closed the connection on
DOWN, so connection is broken instead of the Result = 0 in the sample on
sending a single DOWN.
Now, the server disconnects only on first END. After DOWN, all further
processing of number stops.
Patch does not handle cases of double END sending, multiple clients etc.

Fixes: 15545eb6d7ae ("unix.7: Add example")
Cc: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Lili Püspök <poordirtylili@gmail.com>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
4 weeks agoprintf.3: Return the number of bytes printed, not characters
Jeremy Baxter [Fri, 15 Mar 2024 01:07:14 +0000 (14:07 +1300)] 
printf.3: Return the number of bytes printed, not characters

From <https://pubs.opengroup.org/onlinepubs/9699919799/functions/printf.html>:

    Upon successful completion, the dprintf(), fprintf(), and printf()
    functions shall return the number of bytes transmitted.

Closes: <https://bugzilla.kernel.org/show_bug.cgi?id=218600>
Reported-by: <quirin.blaeser@freenet.de>
Signed-off-by: Jeremy Baxter <jtbx@disroot.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
5 weeks agoutf-8.7: ffix
Alejandro Colomar [Thu, 14 Mar 2024 16:44:12 +0000 (17:44 +0100)] 
utf-8.7: ffix

Signed-off-by: Alejandro Colomar <alx@kernel.org>
5 weeks agoutf-8.7: ffix
Samanta Navarro [Thu, 14 Mar 2024 12:22:42 +0000 (12:22 +0000)] 
utf-8.7: ffix

Signed-off-by: Alejandro Colomar <alx@kernel.org>
5 weeks agoprintf.h.3head: tfix
Samanta Navarro [Thu, 14 Mar 2024 12:21:50 +0000 (12:21 +0000)] 
printf.h.3head: tfix

Signed-off-by: Alejandro Colomar <alx@kernel.org>
5 weeks agogetrusage.2, proc_pid_io.5: Crosslink
наб [Wed, 13 Mar 2024 14:26:54 +0000 (15:26 +0100)] 
getrusage.2, proc_pid_io.5: Crosslink

These serve the same purpose from different perspectives.

Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
5 weeks agogetrusage.2: proc(5) /proc/pid/stat -> proc_pid_stat(5)
наб [Wed, 13 Mar 2024 14:26:52 +0000 (15:26 +0100)] 
getrusage.2: proc(5) /proc/pid/stat -> proc_pid_stat(5)

Fixes: bbc21bc4dbef ("proc.5, proc_pid_stat.5: Split /proc/PID/stat from proc(5)")
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Signed-off-by: Alejandro Colomar <alx@kernel.org>