Commit Graph

11546 Commits

Author SHA1 Message Date
Karel Zak dd9bae58ae build-sys: release++ (v2.30)
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-06-02 12:22:29 +02:00
Karel Zak 10a68c54e9 docs: update v2.30-ReleaseNotes
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-06-02 12:20:19 +02:00
Karel Zak df55fbfe9c docs: update AUTHORS file
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-06-02 12:16:08 +02:00
Karel Zak 99791a1984 lib/pager: use xalloc
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-06-02 12:07:36 +02:00
Karel Zak 2a57a232b6 tests: update build-sys test
The libtinfo is enough (and libncurses optional for cal).

Signed-off-by: Karel Zak <kzak@redhat.com>
2017-06-02 12:03:46 +02:00
Karel Zak 12e29c7199 po: merge changes
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-06-02 11:30:19 +02:00
Karel Zak 7dec8dfeca Merge branch 'master' of https://github.com/yurchor/util-linux
* 'master' of https://github.com/yurchor/util-linux:
  Fix minor typos
2017-06-02 11:13:39 +02:00
Yuri Chornoivan 6ef65081c5 po: update uk.po (from translationproject.org) 2017-06-02 11:08:30 +02:00
Mesutcan Kurt cdfe02e35b po: update tr.po (from translationproject.org) 2017-06-02 11:08:30 +02:00
Sebastian Rasmussen 42fd838c91 po: update sv.po (from translationproject.org) 2017-06-02 11:08:30 +02:00
Jakub Bogusz 0062b697f7 po: update pl.po (from translationproject.org) 2017-06-02 11:08:30 +02:00
Takeshi Hamasaki 2affdd5f7d po: update ja.po (from translationproject.org) 2017-06-02 11:08:30 +02:00
Philipp Thomas 08272f4f7e po: update de.po (from translationproject.org) 2017-06-02 11:08:30 +02:00
J William Piggott b3d41ca07c docs: add information about mailing list rejection
Signed-off-by: J William Piggott <elseifthen@gmx.com>
2017-06-01 19:42:21 -04:00
Karel Zak 535a4090b4 lib/pager: don't use pager if command not available
for example:
 # PAGER=foo dmesg -H
 sh: foo: command not found

the same problem is we have with fdisk 'l' command:

 # PAGER=foo fdisk /dev/sda
 Welcome to fdisk (util-linux 2.30-rc2-33-41b71).
 ...
 Command (m for help): l
 sh: foo: command not found

It seems better to don't use pager at all if not available.

Signed-off-by: Karel Zak <kzak@redhat.com>
2017-06-01 14:20:20 +02:00
Karel Zak 8ea1651c38 Merge branch 'travis-test' of https://github.com/rudimeier/util-linux
* 'travis-test' of https://github.com/rudimeier/util-linux:
  tests: check for timeout command
  Revert "tests: use stdbuf when stderr and stdout is randomly ordered"
2017-06-01 12:30:14 +02:00
Karel Zak 0145d84a38 lscpu: make min/max freq arrays usage more robust
The array members may be NULL on some architectures (e.g. AMD). Let's
be paranoid and check for the NULL independently on present/online
masks.

Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=1457744
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-06-01 12:15:23 +02:00
Ruediger Meier 4fb3fe39de tests: check for timeout command
Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2017-06-01 11:24:53 +02:00
Ruediger Meier 22edf0a639 Revert "tests: use stdbuf when stderr and stdout is randomly ordered"
stdbuf does not seem to work reliable. Failed on travis/OSX

This reverts commit 398b3148be.

Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2017-06-01 11:24:00 +02:00
Alexander Kuleshov 8bc5195be9 column: add missed semicolons in case of !HAVE_WIDECHAR
In other case we will get:

  error: expected ‘;’ before ‘}’ token

error.

Signed-off-by: Alexander Kuleshov <kuleshovmail@gmail.com>
2017-06-01 10:56:08 +02:00
Karel Zak 41b71b90ac Merge branch 'travis-test' of https://github.com/rudimeier/util-linux
* 'travis-test' of https://github.com/rudimeier/util-linux:
  misc: fix some warnings
  tests: handle non glibc error message for fallocate
  tests: use stdbuf when stderr and stdout is randomly ordered
  build-sys: fix library order when linking
  tests: avoid diff of diffs
  tests: grep's short option -A is more portable
2017-06-01 10:49:12 +02:00
Ruediger Meier f2ff0adf5d misc: fix some warnings
sys-utils/prlimit.c: In function 'do_prlimit':
sys-utils/prlimit.c:367:16: warning: format '%ju' expects argument of type 'uintmax_t', but argument 2 has type 'rlim_t {aka long long unsigned int}' [-Wformat=]
     printf("<%ju", new->rlim_cur);

lib/plymouth-ctrl.c: In function 'open_un_socket_and_connect':
lib/plymouth-ctrl.c:88:20: warning: passing argument 2 of 'connect' from incompatible pointer type [-Wincompatible-pointer-types]
  ret = connect(fd, &su, offsetof(struct sockaddr_un, sun_path) + 1 + strlen(su.sun_path+1));
                    ^
In file included from lib/plymouth-ctrl.c:35:0:
/usr/include/sys/socket.h:314:5: note: expected 'const struct sockaddr *' but argument is of type 'struct sockaddr_un *'
 int connect (int, const struct sockaddr *, socklen_t);

login-utils/last.c: In function 'list':
login-utils/last.c:506:54: warning: pointer targets in passing argument 4 of 'dns_lookup' differ in signedness [-Wpointer-sign]
   r = dns_lookup(domain, sizeof(domain), ctl->useip, p->ut_addr_v6);
                                                      ^
login-utils/last.c:291:12: note: expected 'int32_t * {aka int *}' but argument is of type 'unsigned int *'
 static int dns_lookup(char *result, int size, int useip, int32_t *a)
            ^~~~~~~~~~

In file included from sys-utils/hwclock-cmos.c:92:0:
sys-utils/hwclock.h:67:32: warning: 'struct timeval' declared inside parameter list will not be visible outside of this definition or declaration
 extern double time_diff(struct timeval subtrahend, struct timeval subtractor);

misc-utils/test_uuidd.c: In function 'create_nthreads':
misc-utils/test_uuidd.c:187:19: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
        proc->pid, (int) th->tid, th->index));

Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2017-06-01 10:28:18 +02:00
Ruediger Meier 4cb6d04aee tests: handle non glibc error message for fallocate
Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2017-06-01 10:28:14 +02:00
Ruediger Meier 398b3148be tests: use stdbuf when stderr and stdout is randomly ordered
glibc seems to flush stdout before stderr.

Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2017-06-01 10:28:02 +02:00
Ruediger Meier c0d7b11a3f build-sys: fix library order when linking
We got some errors on Alpine Linux where $LTLIBINTL is non-empty:

./.libs/libcommon.a(libcommon_la-blkdev.o): In function `open_blkdev_or_file':
lib/blkdev.c:282: undefined reference to `libintl_gettext
collect2: error: ld returned 1 exit status

Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2017-06-01 03:16:48 +02:00
Ruediger Meier 3936669948 tests: avoid diff of diffs
Certain diff implementations do not produce comparable output.

Noticed on Alpine Linux/busybox.

CC: Sami Kerola <kerolasa@iki.fi>
Reported-by: Assaf Gordon <assafgordon@gmail.com>
Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2017-06-01 03:16:36 +02:00
Ruediger Meier 036af19fc3 tests: grep's short option -A is more portable
Noticed on Alpine Linux/busybox.

Reported-by: Assaf Gordon <assafgordon@gmail.com>
Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2017-06-01 02:58:20 +02:00
J William Piggott 80008bcae9 docs: move source-code-management.txt to README
source-code-management.txt and README had similar content so combine
them in README.

Change Documentation/source-code-management.txt references to README.

Remove Documentation/source-code-management.txt.

Move IRC Channel information to README

Expand information about git branches and tags in README.

Add workflow to README; written by Karel Zak <kzak@redhat.com>

Signed-off-by: J William Piggott <elseifthen@gmx.com>
2017-05-31 11:36:47 -04:00
J William Piggott 0928ca2b59 docs: update howto-contribute.txt
This patch does not change any wording or grammar. It
only shuffles the order of things and adds a table of
contents. For example: it moves coding related bullet
points into the Coding Style Chapter; it groups email
related Chapters together, and so fourth.

Signed-off-by: J William Piggott <elseifthen@gmx.com>
2017-05-31 11:36:47 -04:00
J William Piggott 888d5e0ed6 docs: update howto-contribute.txt
Grammar fixes and some clarification changes.

Signed-off-by: J William Piggott <elseifthen@gmx.com>
2017-05-31 11:36:47 -04:00
J William Piggott ebcb28e53a docs: update v2.30-ReleaseNotes
Signed-off-by: J William Piggott <elseifthen@gmx.com>
2017-05-31 11:36:47 -04:00
Karel Zak 3947ca4ca9 build-sys: ncurses headers cleanup
* assume ncursesw headers in ncursesw/ directory only
* prefer long paths, <term.h> and <ncurses.h> should be last
  possibility
* fix typos

Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-31 11:01:46 +02:00
Karel Zak c71f5a568f cfdisk: fix compiler warning
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-31 10:58:17 +02:00
Karel Zak 4c12a334dc build-sys: prefer ncurses-config rather than pkg-config
If you have installed:

 ii  libncurses5:i386      5.9+20140913-1+b1  i386   shared libraries for terminal handling
 ii  libncurses5-dev:i386  5.9+20140913-1+b1  i386   developer's libraries for ncurses
 ii  libncursesw5:i386     5.9+20140913-1+b1  i386   shared libraries for terminal handling (wide character support)

then pkg-config blindly follows ncursesw although there are not header
files for this library. It seems better to use pkg-config as fallback
solution only.

Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-31 10:54:21 +02:00
Karel Zak 8a931412e3 build-sys: require kernel headers on Linux
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-31 09:35:32 +02:00
Karel Zak 682fd25dea dmesg: remove unnecessary header
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-31 09:18:10 +02:00
Karel Zak c9ae73c03f lib/colors: fix test compilation
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-31 01:29:25 +02:00
Karel Zak 2ac1bc84d7 text-utils: use proper paths to term.h
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-30 17:15:37 +02:00
Karel Zak 18451b2cf4 cal: ncurses cleanup
* use proper paths to term.h
* keep ncurses support optional
* link with TINFO_LIBS (-ltinfo), or fallback to NCURSES_LIBS (-ltinfo -lncurses)
* don't include unnecessary ncurses.h (term.h is enough)

Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-30 17:14:46 +02:00
Karel Zak 23d4726784 lib/colors: ncurses cleanup
* use proper paths to term.h
* keep ncurses support optional
* link with TINFO_LIBS (-ltinfo), or fallback to NCURSES_LIBS (-ltinfo -lncurses)
* don't include unnecessary ncurses.h (term.h is enough)

Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-30 17:14:12 +02:00
Karel Zak 3cc8a9f42a build-sys: make ncurses detection more robust
It seems Debina 8 is a little bit incompatible with us:

* ncurses-config is packaged in ncurses-bin where is *no* any
  development files! It means the script returns paths to not installed
  files (IMHO packaging bug)

  Fixed, we need to check for header files too.

* term.h is "everywhere" on Fedora:

	<term.h>
	<ncurses/term.h>
	<ncursesw/term.h>

  Debian is more strict and uses <ncurses[w]/term.h> only.

  Fixed, we need #ifdef storm to use the correct path

 * libtinfo-dev does not contains any header files

 Fixed, we have to always require installed ncurses devel stuff to compile,
 but we can link with -ltinfo only (cal, ul, more, ...)

 * we don't use termcap for more(1)

Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-30 17:08:36 +02:00
Karel Zak d25d453464 tests: check for ps --ppid
Reported-by: Assaf Gordon <assafgordon@gmail.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-30 11:19:22 +02:00
Karel Zak bd4f50f044 tests: make /proc optional
Reported-by: Assaf Gordon <assafgordon@gmail.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-30 11:03:28 +02:00
Karel Zak 853a2ea486 lib/loopdev: remove unnecessary header
Reported-by: Assaf Gordon <assafgordon@gmail.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-30 10:47:06 +02:00
Karel Zak b770b48700 test_uuidd: don't use error.h
The header file is not provided by musl-libc.

Reported-by: Assaf Gordon <assafgordon@gmail.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-30 10:26:17 +02:00
Karel Zak b4cb2b48f9 wall: make sure with not referencing a null pointer
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-29 13:25:36 +02:00
Sami Kerola 2e2cfdae79 libfdisk: fix variable shadowing
libfdisk/src/context.c: In function 'fdisk_assign_device':
libfdisk/src/context.c:549:7: warning: declaration of 'rc' shadows a previous local [-Wshadow]
libfdisk/src/context.c:542:10: note: shadowed declaration is here

[kzak@redhat.com: - add rc to debug message]

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-29 12:18:08 +02:00
Sebastian Rasmussen 25c7b43ee2 lib/colors: Fix bug where help text was not being translated.
This affected cfdisk, fdisk, sfdisk, cal, dmesg and hexdump.
2017-05-28 13:30:45 +08:00
Yuri Chornoivan 0508f347c8 Fix minor typos 2017-05-24 00:22:20 +03:00
Karel Zak ae4e2abcb1 libblkid: (docs) add missing 'since' tags
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-05-23 14:27:36 +02:00