diff options
author | Fabian Groffen | 2011-01-25 22:44:52 +0100 |
---|---|---|
committer | Karel Zak | 2011-02-14 17:45:24 +0100 |
commit | eb76ca98b0733754d7e9a40f754e89b50af2bf06 (patch) | |
tree | f2becaf31f77a664256273e6ec6772904422ac53 /misc-utils | |
parent | sfdisk: rename warn to my_warn (diff) | |
download | kernel-qcow2-util-linux-eb76ca98b0733754d7e9a40f754e89b50af2bf06.tar.gz kernel-qcow2-util-linux-eb76ca98b0733754d7e9a40f754e89b50af2bf06.tar.xz kernel-qcow2-util-linux-eb76ca98b0733754d7e9a40f754e89b50af2bf06.zip |
build-sys: provide alternatives for err, errx, warn and warnx
Solaris lacks err, errx, warn and warnx. This also means the err.h header
doesn't exist. Removed err.h include from all files, and included err.h from
c.h instead if it exists, otherwise alternatives are provided.
Signed-off-by: Fabian Groffen <grobian@gentoo.org>
Diffstat (limited to 'misc-utils')
-rw-r--r-- | misc-utils/cal.c | 1 | ||||
-rw-r--r-- | misc-utils/findfs.c | 2 | ||||
-rw-r--r-- | misc-utils/findmnt.c | 1 | ||||
-rw-r--r-- | misc-utils/lsblk.c | 2 | ||||
-rw-r--r-- | misc-utils/namei.c | 1 | ||||
-rw-r--r-- | misc-utils/scriptreplay.c | 2 | ||||
-rw-r--r-- | misc-utils/wipefs.c | 2 |
7 files changed, 4 insertions, 7 deletions
diff --git a/misc-utils/cal.c b/misc-utils/cal.c index 896c45339..1e5e2cd8f 100644 --- a/misc-utils/cal.c +++ b/misc-utils/cal.c @@ -63,7 +63,6 @@ #include <string.h> #include <time.h> #include <unistd.h> -#include <err.h> #include <errno.h> #include "c.h" diff --git a/misc-utils/findfs.c b/misc-utils/findfs.c index 18608b470..04651b3a5 100644 --- a/misc-utils/findfs.c +++ b/misc-utils/findfs.c @@ -8,11 +8,11 @@ #include <stdlib.h> #include <string.h> #include <errno.h> -#include <err.h> #include <blkid.h> #include "nls.h" +#include "c.h" static void __attribute__((__noreturn__)) usage(int rc) { diff --git a/misc-utils/findmnt.c b/misc-utils/findmnt.c index f81a0c87f..19a15fb58 100644 --- a/misc-utils/findmnt.c +++ b/misc-utils/findmnt.c @@ -21,7 +21,6 @@ #include <stdio.h> #include <stdlib.h> #include <errno.h> -#include <err.h> #include <unistd.h> #include <getopt.h> #include <string.h> diff --git a/misc-utils/lsblk.c b/misc-utils/lsblk.c index b07bfb49a..2eb6900ac 100644 --- a/misc-utils/lsblk.c +++ b/misc-utils/lsblk.c @@ -31,7 +31,6 @@ #include <dirent.h> #include <fcntl.h> #include <string.h> -#include <err.h> #include <sys/ioctl.h> #include <inttypes.h> #include <stdarg.h> @@ -51,6 +50,7 @@ #include "tt.h" #include "xalloc.h" #include "strutils.h" +#include "c.h" /* column IDs */ enum { diff --git a/misc-utils/namei.c b/misc-utils/namei.c index 1c20b3777..2115fe7c9 100644 --- a/misc-utils/namei.c +++ b/misc-utils/namei.c @@ -30,7 +30,6 @@ #include <sys/types.h> #include <sys/stat.h> #include <sys/param.h> -#include <err.h> #include <pwd.h> #include <grp.h> diff --git a/misc-utils/scriptreplay.c b/misc-utils/scriptreplay.c index e13edf37e..f8ee9e011 100644 --- a/misc-utils/scriptreplay.c +++ b/misc-utils/scriptreplay.c @@ -26,9 +26,9 @@ #include <math.h> #include <sys/select.h> #include <unistd.h> -#include <err.h> #include "nls.h" +#include "c.h" #define SCRIPT_MIN_DELAY 0.0001 /* from original sripreplay.pl */ diff --git a/misc-utils/wipefs.c b/misc-utils/wipefs.c index 079a9bccf..9016f2f40 100644 --- a/misc-utils/wipefs.c +++ b/misc-utils/wipefs.c @@ -27,7 +27,6 @@ #include <stdlib.h> #include <unistd.h> #include <getopt.h> -#include <err.h> #include <string.h> #include <limits.h> @@ -37,6 +36,7 @@ #include "xalloc.h" #include "strutils.h" #include "writeall.h" +#include "c.h" struct wipe_desc { loff_t offset; /* magic string offset */ |