Commit Graph

1823 Commits

Author SHA1 Message Date
Karel Zak 19238be16d docs: fix info about LIBSMARTCOLS_DEBUG_PADDING
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-08-16 12:59:31 +02:00
Érico Nogueira 8ab700b933 logger: use xgetlogin from pwdutils.
It defined its own xgetlogin, which queried geteuid() instead of getuid(),
with a fallback to "<someone>" when lookup fails. This has been the case
since the function was introduced in
019b97024f, so geteuid() has always been
used. Since using geteuid for identification isn't consistent with the
rest of util-linux, switching to xgetlogin(), which uses getuid(),
should be correct.

Signed-off-by: Érico Nogueira <erico.erc@gmail.com>
2021-07-29 21:40:33 +02:00
Karel Zak 22a2bce042 hardlink: remove pcre2posix.h support
It's deprecated for years. Let's rely on old good libc regex.h for now.

Signed-off-by: Karel Zak <kzak@redhat.com>
2021-07-20 11:59:53 +02:00
Karel Zak 5ca73c6eef lsblk: normalize space in SERIAL and MODEL
These strings come from HW and udev does not modify it. It seems good
idea to clean up it before we print it.

Fixes: https://github.com/karelzak/util-linux/issues/1368
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-07-20 11:53:33 +02:00
Karel Zak 9411b6ccf8 wipefs: check errno after strto..()
Addresses: https://github.com/karelzak/util-linux/issues/1356
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-07-20 11:34:53 +02:00
Karel Zak c357816caa lslocks: check errno after strto..()
Addresses: https://github.com/karelzak/util-linux/issues/1356
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-07-20 11:34:53 +02:00
Karel Zak 7a50f117a4 kill: check errno after strto..()
Addresses: https://github.com/karelzak/util-linux/issues/1356
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-07-20 11:34:53 +02:00
Karel Zak 7bee16f27f logger: add __format__ attribute
Reported-by: Jan Pazdziora <jpazdziora@redhat.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-07-20 11:27:34 +02:00
Karel Zak bda3f658e0 findmnt: add __format__ attribute
Reported-by: Jan Pazdziora <jpazdziora@redhat.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-07-20 11:27:34 +02:00
Christian Bartolomäus b81a870767 Fix some brackets in synopses 2021-07-20 11:25:34 +02:00
Karel Zak 9461ae9b90 rename: use readlink() in more robust way
Reported-by: Jan Pazdziora <jpazdziora@redhat.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-07-20 11:24:12 +02:00
Karel Zak aec0e37683 namei: simplify code
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-07-20 11:23:40 +02:00
Karel Zak 5f0cf2484f findmnt: (verify) fix memory leak [asan]
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-07-20 11:12:16 +02:00
Karel Zak a7f7d3474a findmnt: (verify) fix cache related memory leaks on --nocanonicalize [coverity scan]
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-07-20 11:11:49 +02:00
ratijas d3363ef6d7 lsblk: fix formatting in -e option 2021-07-20 11:09:10 +02:00
Karel Zak 9bf924165b lsblk: use ID_MODEL_ENC is possible
Fix: https://github.com/karelzak/util-linux/issues/1098
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-07-20 10:53:55 +02:00
Karel Zak fce7b9501c build-sys: fix {release-version} man pages
* define {release-version} as $VERSION

* do not use {docdir} in adoc; it's built-in ascidoctor variable
  https://docs.asciidoctor.org/asciidoc/latest/attributes/document-attributes-reference/#intrinsic-attributes

Addresses: https://github.com/karelzak/util-linux/issues/1327
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-06-02 12:23:57 +02:00
Christian Hesse e08e3d587c fix whitespace issue in ducumentation
This removes trailing whitespaces and fixes minor issues.
2021-05-10 15:53:50 +02:00
Karel Zak 634636301e hardlink: fix time_t=long assumptions
References: ce3355cc54
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-05-06 10:45:16 +02:00
Karel Zak d8d54e4bfc build-sys: keep adoc files in dist_noinst_DATA
* rename MANPAGES_EXTRA= to ADOCFILES_COMMON=

* keep track about individual adoc files by dist_noinst_DATA=
  This variable is not effected by automake conditions, so the files
  are always distributed.

Signed-off-by: Karel Zak <kzak@redhat.com>
2021-05-05 13:35:30 +02:00
Rafael Fontenelle 993556aaa5 Fix misspellings 2021-04-22 20:31:05 -03:00
Karel Zak 2b84ac2dbd Merge branch 'topic/po4a' of https://github.com/mariobl/util-linux
* 'topic/po4a' of https://github.com/mariobl/util-linux:
  mount.a.adoc: Fix markup
  Asciidoc: Add missing macro definition in uclampset.1
  Asciidoc: Fix markup in example man page
  Asciidoc: Fix markup
  Asciidoc: Remove artifact from merge conflict
  Asciidoc: Convert man-common/README to Markdown
  po-man: Fix the example man page
  po-man: Fix typos in po-man/README.md
  po-man: Update the example man page
  po-man: Add po-man/README.md
  po-man: Add (incomplete) de.po for testing purposes
  po-man: Add (incomplete) de.po for testing purposes
  po-man: Adjust paths in po4a.cfg and update .pot file
  po-man: Move Po4a config file and translation template to po-man
2021-04-22 15:23:27 +02:00
Karel Zak e5bde19ae2 build-sys: cleanup Makefiles
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-04-20 14:39:32 +02:00
Karel Zak 01480c61e1 hardlink: fix typo again
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-04-19 15:30:57 +02:00
Karel Zak 35d5db6ebb hardlink: fix typo
Reported-by: Mario Blättermann <mario.blaettermann@gmail.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-04-19 10:10:17 +02:00
Karel Zak 766490185f findmnt: add --shadowed to the man page
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-04-09 15:07:45 +02:00
Karel Zak 27c4353b4e blkid: document --hint
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-04-09 15:07:11 +02:00
Paul Laffitte 02b0bdcc8c
fix typo in findmnt help 2021-04-08 19:09:30 +02:00
Karel Zak 53b37016c3 meson: generate man pages from asciidoc
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-04-06 15:32:46 +02:00
Mario Blättermann 360946bb93 Asciidoc: Fix markup 2021-04-04 15:33:56 +02:00
Karel Zak 625e9c61e8 build-sys: make man pages location independent
We need to evaluate "include::" directive relatively to project
top-level source directory rather than to the current document
location.

Signed-off-by: Karel Zak <kzak@redhat.com>
2021-03-31 11:50:47 +02:00
Karel Zak 97c5380f9c Asciidoc: Incorporate latest changes in findmnt.8
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-03-29 15:10:53 +02:00
Karel Zak 25ce8fb1ed Merge remote-tracking branch 'mariobl/topic/asciidoc'
* mariobl/topic/asciidoc: (71 commits)
  Asciidoc: Update .pot template
  Asciidoc: Reorder example command sequence
  Asciidoc: Update .pot template
  Asciidoc: Better gettext message splitting in nsenter.1.adoc
  Asciidoc: Update .pot template
  Asciidoc: Fix typo and remove invisible spaces which confuse po4a
  Asciidoc: Update .pot template
  Asciidoc: Fix typo
  Asciidoc: Fix artifact from initial import, sixth attempt
  Asciidoc: Update .pot template
  Asciidoc: Fix artifacts from initial import, fifth attempt
  Asciidoc: Fix artifacts from initial import, fourth attempt
  Asciidoc: Update .pot template
  Asciidoc: Fix artifacts from initial import, third attempt
  Asciidoc: Fix artifacts from initial import, second attempt
  Asciidoc: Fix artifacts from initial import
  Asciidoc: Add po4a config file and initial translation template for man pages
  Asciidoc: Small indentation fix in mount.8.adoc
  Asciidoc: Review sys-utils man pages, part 2
  build-sys: fix out-of-tree build
  ...

Signed-off-by: Karel Zak <kzak@redhat.com>
2021-03-29 15:09:27 +02:00
Mario Blättermann 544e64e09e Asciidoc: Fix typo and remove invisible spaces which confuse po4a 2021-03-28 10:47:00 +02:00
Mario Blättermann ff6009fd20 Asciidoc: Fix typo 2021-03-27 00:30:37 +01:00
Karel Zak 4f79d3032e build-sys: split man pages and man page links
The symlinks are generated by asciidoctor and current dist_man_MANS
depends on order (nan page before man link). This solutions is useless
when execute "make -j". The real solution is to keep man pages in
separate variable and use only this variable evaluate what we need to
generate.

Signed-off-by: Karel Zak <kzak@redhat.com>
2021-03-26 11:49:59 +01:00
Karel Zak eac3674f76 build-sys: remove some man pages from PATHFILES
fix warnings:

 Makefile:15936: warning: overriding recipe for target 'misc-utils/uuidd.8'
 Makefile:15928: warning: ignoring old recipe for target 'misc-utils/uuidd.8'
 Makefile:15936: warning: overriding recipe for target 'misc-utils/getopt.1'
 Makefile:15928: warning: ignoring old recipe for target 'misc-utils/getopt.1'

Signed-off-by: Karel Zak <kzak@redhat.com>
2021-03-26 10:15:19 +01:00
Mario Blättermann 925a9b5d72 Asciidoc: Incorporate latest change in findmnt.8 2021-03-23 20:10:02 +01:00
Mario Blättermann 2c646c80d8 Asciidoc: Review misc-utils man pages 2021-03-23 20:07:15 +01:00
Karel Zak 3ab4ef3ca9 findmnt: add --shadowed
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-03-22 15:00:47 +01:00
Karel Zak 667c87c50c findmnt: sort columns
Let's make "Available columns" in --help more readable.

Signed-off-by: Karel Zak <kzak@redhat.com>
2021-03-22 15:00:38 +01:00
Mario Blättermann 295b3979d9 Asciidoc: Add Po4a hint to file headers 2021-03-20 16:42:47 +01:00
Mario Blättermann d315cc4d96 Asciidoc: Re-add empty lines to man pages 2021-03-19 20:52:00 +01:00
Mario Blättermann d7f0a0dfff Asciidoc: Remove already imported misc-utils *roff man pages 2021-03-19 17:16:40 +01:00
Mario Blättermann 6c64d12d13 Asciidoc: Import misc-utils man pages 2021-03-19 17:12:57 +01:00
Karel Zak 7f8b777407 findmnt: add PARENT column
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-03-19 16:39:27 +01:00
Karel Zak bdaed0cde4 meson: update for new hardlink
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-03-17 15:42:26 +01:00
Karel Zak 308a097968 meson: update sources and dependencies
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-03-17 15:07:27 +01:00
Zbigniew Jędrzejewski-Szmek d4c880d5a4 meson: add second build system
To build: meson build && ninja -C build
To run tests: ninja -C build check
To install for packaging: DESTDIR=/var/tmp/inst ninja -C build install
To install for realz: sudo ninja -C build install

v2:
- Optional items are now based on the 'feature' feature in meson.
  Built libraries which are disabled turn into disabler() objects
  and also poison any executables which link to them.

What is there:
- building of the binaries and libs and the python module
- installation of binaries, libs, python module, localization files,
  man pages, pkgconfig files
- running of tests
- most options to configure build equivalently to the
  ./configure settings

Partially implemented:
- disabling of stuff when things missing. In the C code, the defines
  are all used, so that should be fine. In the build system, some
  files should be skipped, but that is probably not always done properly.
  Getting this right might require some testing of various build option
  combinations to get the details right.

Not implemented:
- static builds of fdisk and other binaries
- things marked with XXX or FIXME
- ???

Differences:
- .la files are not created. They are useless and everybody hates them.
- Requires.private in pkgconfig files are not present in the
  autogenerated .pc file. Not sure if they should be there or not. If
  necessary, they can be added by hand.
- man pages and systemd units are installed by the install target. Not
  sure why 'make install' doesn't do that.
- the split between / and /usr is probably wrong. But it's all pointless
  anyway, so maybe we could simplify things but not implementing it at
  all under meson?
2021-03-17 15:07:27 +01:00
Karel Zak 4e9be5a439 findmnt: (man) add more info about --target
Signed-off-by: Karel Zak <kzak@redhat.com>
2021-03-12 11:00:56 +01:00