aboutsummaryrefslogtreecommitdiff
path: root/procps
diff options
context:
space:
mode:
authorJohannes Schindelin <johannes.schindelin@gmx.de>2017-02-01 22:29:58 +0100
committerRon Yorston <rmy@pobox.com>2017-07-18 09:51:30 +0100
commit18afed0f98d020608c65293ecb9246dab6c58db3 (patch)
tree376aa1289f3f0e934e8381507c337d68e1e4b89a /procps
parentd416bdac2fff5eed7cfa70499ff61c8b8a9ca7ce (diff)
downloadbusybox-w32-18afed0f98d020608c65293ecb9246dab6c58db3.tar.gz
busybox-w32-18afed0f98d020608c65293ecb9246dab6c58db3.tar.bz2
busybox-w32-18afed0f98d020608c65293ecb9246dab6c58db3.zip
Use %I64* formats with MinGW instead of %ll* formats
The MSVC runtime uses the format specified %I64 for 64-bit data types; It does not understand e.g. %llu for unsigned long longs. However, mingw-w64 provides a compatibility mode in its runtime wrapper which can be activated by defining the constant __USE_MINGW_ANSI_STDIO=1 in which case we must refrain from overriding the %ll* formats. This fixes quite a couple of compile warnings when building with the mingw-w64 compiler. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Diffstat (limited to 'procps')
-rw-r--r--procps/iostat.c2
-rw-r--r--procps/mpstat.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/procps/iostat.c b/procps/iostat.c
index c290c594b..2db343f69 100644
--- a/procps/iostat.c
+++ b/procps/iostat.c
@@ -29,7 +29,7 @@
29#if 1 29#if 1
30typedef unsigned long long cputime_t; 30typedef unsigned long long cputime_t;
31typedef long long icputime_t; 31typedef long long icputime_t;
32# define FMT_DATA "ll" 32# define FMT_DATA LL_FMT
33# define CPUTIME_MAX (~0ULL) 33# define CPUTIME_MAX (~0ULL)
34#else 34#else
35typedef unsigned long cputime_t; 35typedef unsigned long cputime_t;
diff --git a/procps/mpstat.c b/procps/mpstat.c
index 6028903fa..8a79fd8ba 100644
--- a/procps/mpstat.c
+++ b/procps/mpstat.c
@@ -49,7 +49,7 @@
49#if 1 49#if 1
50typedef unsigned long long data_t; 50typedef unsigned long long data_t;
51typedef long long idata_t; 51typedef long long idata_t;
52#define FMT_DATA "ll" 52#define FMT_DATA LL_FMT
53#define DATA_MAX ULLONG_MAX 53#define DATA_MAX ULLONG_MAX
54#else 54#else
55typedef unsigned long data_t; 55typedef unsigned long data_t;