perf tools: Fix build on non-glibc systems due to libio.h absence
authorCody P Schafer <cody@linux.vnet.ibm.com>
Thu, 14 Mar 2013 22:27:51 +0000 (15:27 -0700)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Fri, 15 Mar 2013 16:05:13 +0000 (13:05 -0300)
Including libio.h causes build failures on uClibc systems (which lack
libio.h).

It appears that libio.h was only included to pull in a definition for
NULL, so it has been replaced by stddef.h.

On powerpc, libio.h was conditionally included, but could be removed
completely as it is unneeded. Also, the included of stdlib.h was changed
to stddef.h (as again, only NULL is needed).

Signed-off-by: Cody P Schafer <cody@linux.vnet.ibm.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/r/1363300074-26288-1-git-send-email-cody@linux.vnet.ibm.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/arch/arm/util/dwarf-regs.c
tools/perf/arch/powerpc/util/dwarf-regs.c
tools/perf/arch/s390/util/dwarf-regs.c
tools/perf/arch/sh/util/dwarf-regs.c
tools/perf/arch/sparc/util/dwarf-regs.c
tools/perf/arch/x86/util/dwarf-regs.c

index e8d5c551c69c08d4a17e89a370d0e4caedacb101..33ec5b339da87fca6c49757e58816f076c738ba6 100644 (file)
@@ -8,10 +8,7 @@
  * published by the Free Software Foundation.
  */
 
-#include <stdlib.h>
-#ifndef __UCLIBC__
-#include <libio.h>
-#endif
+#include <stddef.h>
 #include <dwarf-regs.h>
 
 struct pt_regs_dwarfnum {
index 7cdd61d0e27cd5fecd30c315fbc49724c5696a07..733151cdf46e08397fae0f293c73222cc54ef21e 100644 (file)
@@ -9,10 +9,7 @@
  * 2 of the License, or (at your option) any later version.
  */
 
-#include <stdlib.h>
-#ifndef __UCLIBC__
-#include <libio.h>
-#endif
+#include <stddef.h>
 #include <dwarf-regs.h>
 
 
index e19653e025fa66177ce4520262fb5435e22b19df..0469df02ee62725f352a8a6c337b86ae162ec0c7 100644 (file)
@@ -6,7 +6,7 @@
  *
  */
 
-#include <libio.h>
+#include <stddef.h>
 #include <dwarf-regs.h>
 
 #define NUM_GPRS 16
index a11edb007a6ce9ad03426a0c33597a9787299dc5..0d0897f57a1027eeb88a8c34a3acd2a9974014cf 100644 (file)
@@ -19,7 +19,7 @@
  *
  */
 
-#include <libio.h>
+#include <stddef.h>
 #include <dwarf-regs.h>
 
 /*
index 0ab88483720c4ef796da3dff29f0c0b7119fc004..92eda412fed34348c09b8471085cc8d88e8d4c2d 100644 (file)
@@ -9,7 +9,7 @@
  * 2 of the License, or (at your option) any later version.
  */
 
-#include <libio.h>
+#include <stddef.h>
 #include <dwarf-regs.h>
 
 #define SPARC_MAX_REGS 96
index a794d3081928d60ac68a14cb865d4aaed1ec39b0..be22dd463232ed734e7a880838035db5e8f86574 100644 (file)
@@ -20,7 +20,7 @@
  *
  */
 
-#include <libio.h>
+#include <stddef.h>
 #include <dwarf-regs.h>
 
 /*