perf: remove unneeded include of network header files
PATCH 1/1 perf: remove unneeded include of network header files
perf does not have networking related functionality, and the inclusion of these headers is one of the causes of compile failures for Android:
https://lkml.org/lkml/2012/8/23/316
https://lkml.org/lkml/2012/8/28/293
So, remove them.
v2:
- netdb.h is required by trace-event-perl.c, so leave it in
--- tools/perf/util/util.h | 4 ---- 1 file changed, 4 deletions(-)
tools/perf/util/util.h +0 -4
@@ -69,10 +69,6 @@#include <sys/poll.h> #include <sys/socket.h> #include <sys/ioctl.h> -#include <sys/select.h> -#include <netinet/in.h> -#include <netinet/tcp.h> -#include <arpa/inet.h> #include <netdb.h> #include <inttypes.h> #include "../../../include/linux/magic.h"
Signature · 1 line
1.7.10.1
Em Wed, Sep 05, 2012 at 03:53:06PM -0600, David Ahern escreveu:
Quoted 9 lines
perf does not have networking related functionality, and the inclusion of these headers is one of the causes of compile failures for Android:
https://lkml.org/lkml/2012/8/23/316
https://lkml.org/lkml/2012/8/28/293So, remove them.
v2:
-netdb.his required bytrace-event-perl.c, so leave it in
Nope, I've applied this instead:
commit 12046099160e65cddb639f8b3dda2bd0701c09d6
Author: David Ahern <[email protected]> Date: Wed Aug 29 09:55:32 2012 -0600
perf tools: remove unneeded include of network header files
perf does not have networking related functionality, and the inclusion of these headers is one of the causes of compile failures for Android:
https://lkml.org/lkml/2012/8/23/316
https://lkml.org/lkml/2012/8/28/293
So, remove them.
tools/perf/util/scripting-engines/trace-event-perl.c +4 -4
@@ -25,16 +25,16 @@#include <ctype.h> #include <errno.h> -#include "../../perf.h" #include "../util.h" +#include <EXTERN.h> +#include <perl.h> + +#include "../../perf.h" #include "../thread.h" #include "../event.h" #include "../trace-event.h" #include "../evsel.h" -#include <EXTERN.h> -#include <perl.h> - void boot_Perf__Trace__Context(pTHX_ CV *cv); void boot_DynaLoader(pTHX_ CV *cv);typedef PerlInterpreter *INTERP ;
tools/perf/util/util.h +0 -5
@@ -69,11 +69,6 @@#include <sys/poll.h> #include <sys/socket.h> #include <sys/ioctl.h> -#include <sys/select.h> -#include <netinet/in.h> -#include <netinet/tcp.h> -#include <arpa/inet.h> -#include <netdb.h> #include <inttypes.h> #include "../../../include/linux/magic.h" #include "types.h"