diff options
Diffstat (limited to 'tools/perf/util/cache.h')
-rw-r--r-- | tools/perf/util/cache.h | 28 |
1 files changed, 15 insertions, 13 deletions
diff --git a/tools/perf/util/cache.h b/tools/perf/util/cache.h index 70f318dc1d9a..07aec06e4443 100644 --- a/tools/perf/util/cache.h +++ b/tools/perf/util/cache.h | |||
@@ -33,14 +33,7 @@ extern int pager_use_color; | |||
33 | 33 | ||
34 | extern int use_browser; | 34 | extern int use_browser; |
35 | 35 | ||
36 | #if !defined(NEWT_SUPPORT) && defined(NO_GTK2_SUPPORT) | 36 | #if defined(NEWT_SUPPORT) || defined(GTK2_SUPPORT) |
37 | static inline void setup_browser(bool fallback_to_pager) | ||
38 | { | ||
39 | if (fallback_to_pager) | ||
40 | setup_pager(); | ||
41 | } | ||
42 | static inline void exit_browser(bool wait_for_ok __maybe_unused) {} | ||
43 | #else | ||
44 | void setup_browser(bool fallback_to_pager); | 37 | void setup_browser(bool fallback_to_pager); |
45 | void exit_browser(bool wait_for_ok); | 38 | void exit_browser(bool wait_for_ok); |
46 | 39 | ||
@@ -55,17 +48,26 @@ static inline int ui__init(void) | |||
55 | static inline void ui__exit(bool wait_for_ok __maybe_unused) {} | 48 | static inline void ui__exit(bool wait_for_ok __maybe_unused) {} |
56 | #endif | 49 | #endif |
57 | 50 | ||
58 | #ifdef NO_GTK2_SUPPORT | 51 | #ifdef GTK2_SUPPORT |
52 | int perf_gtk__init(void); | ||
53 | void perf_gtk__exit(bool wait_for_ok); | ||
54 | #else | ||
59 | static inline int perf_gtk__init(void) | 55 | static inline int perf_gtk__init(void) |
60 | { | 56 | { |
61 | return -1; | 57 | return -1; |
62 | } | 58 | } |
63 | static inline void perf_gtk__exit(bool wait_for_ok __maybe_unused) {} | 59 | static inline void perf_gtk__exit(bool wait_for_ok __maybe_unused) {} |
64 | #else | ||
65 | int perf_gtk__init(void); | ||
66 | void perf_gtk__exit(bool wait_for_ok); | ||
67 | #endif | 60 | #endif |
68 | #endif /* !NEWT_SUPPORT && NO_GTK2_SUPPORT */ | 61 | |
62 | #else /* NEWT_SUPPORT || GTK2_SUPPORT */ | ||
63 | |||
64 | static inline void setup_browser(bool fallback_to_pager) | ||
65 | { | ||
66 | if (fallback_to_pager) | ||
67 | setup_pager(); | ||
68 | } | ||
69 | static inline void exit_browser(bool wait_for_ok __maybe_unused) {} | ||
70 | #endif /* NEWT_SUPPORT || GTK2_SUPPORT */ | ||
69 | 71 | ||
70 | char *alias_lookup(const char *alias); | 72 | char *alias_lookup(const char *alias); |
71 | int split_cmdline(char *cmdline, const char ***argv); | 73 | int split_cmdline(char *cmdline, const char ***argv); |