diff options
author | Denis Vlasenko <vda.linux@googlemail.com> | 2009-04-09 12:35:13 +0000 |
---|---|---|
committer | Denis Vlasenko <vda.linux@googlemail.com> | 2009-04-09 12:35:13 +0000 |
commit | f81e8dbc74186f34faa5ae2b0fe8bdc3f18114ae (patch) | |
tree | 91ee95914c2b9a07817bd6f596fc3df758651147 /networking/libiproute | |
parent | 327fd47f362843fc62fbee6169904c416ca13d11 (diff) | |
download | busybox-w32-f81e8dbc74186f34faa5ae2b0fe8bdc3f18114ae.tar.gz busybox-w32-f81e8dbc74186f34faa5ae2b0fe8bdc3f18114ae.tar.bz2 busybox-w32-f81e8dbc74186f34faa5ae2b0fe8bdc3f18114ae.zip |
*: make "pragma GCC visibility push(hidden)" less ugly
Diffstat (limited to 'networking/libiproute')
-rw-r--r-- | networking/libiproute/ip_common.h | 14 | ||||
-rw-r--r-- | networking/libiproute/libnetlink.h | 15 | ||||
-rw-r--r-- | networking/libiproute/ll_map.h | 14 | ||||
-rw-r--r-- | networking/libiproute/rt_names.h | 14 | ||||
-rw-r--r-- | networking/libiproute/rtm_map.h | 14 | ||||
-rw-r--r-- | networking/libiproute/utils.h | 14 |
6 files changed, 29 insertions, 56 deletions
diff --git a/networking/libiproute/ip_common.h b/networking/libiproute/ip_common.h index 305b491c6..aef325281 100644 --- a/networking/libiproute/ip_common.h +++ b/networking/libiproute/ip_common.h | |||
@@ -1,6 +1,6 @@ | |||
1 | /* vi: set sw=4 ts=4: */ | 1 | /* vi: set sw=4 ts=4: */ |
2 | #ifndef _IP_COMMON_H | 2 | #ifndef IP_COMMON_H |
3 | #define _IP_COMMON_H 1 | 3 | #define IP_COMMON_H 1 |
4 | 4 | ||
5 | #include "libbb.h" | 5 | #include "libbb.h" |
6 | #include <asm/types.h> | 6 | #include <asm/types.h> |
@@ -13,9 +13,7 @@ | |||
13 | #include <linux/if_link.h> | 13 | #include <linux/if_link.h> |
14 | #endif | 14 | #endif |
15 | 15 | ||
16 | #if __GNUC_PREREQ(4,1) | 16 | PUSH_AND_SET_FUNCTION_VISIBILITY_TO_HIDDEN |
17 | # pragma GCC visibility push(hidden) | ||
18 | #endif | ||
19 | 17 | ||
20 | extern char **ip_parse_common_args(char **argv); | 18 | extern char **ip_parse_common_args(char **argv); |
21 | extern int print_neigh(struct sockaddr_nl *who, struct nlmsghdr *n, void *arg); | 19 | extern int print_neigh(struct sockaddr_nl *who, struct nlmsghdr *n, void *arg); |
@@ -34,8 +32,6 @@ extern int do_ipmonitor(char **argv); | |||
34 | extern int do_multiaddr(char **argv); | 32 | extern int do_multiaddr(char **argv); |
35 | extern int do_multiroute(char **argv); | 33 | extern int do_multiroute(char **argv); |
36 | 34 | ||
37 | #if __GNUC_PREREQ(4,1) | 35 | POP_SAVED_FUNCTION_VISIBILITY |
38 | # pragma GCC visibility pop | ||
39 | #endif | ||
40 | 36 | ||
41 | #endif /* ip_common.h */ | 37 | #endif |
diff --git a/networking/libiproute/libnetlink.h b/networking/libiproute/libnetlink.h index 079153b92..e5fee4dd8 100644 --- a/networking/libiproute/libnetlink.h +++ b/networking/libiproute/libnetlink.h | |||
@@ -1,6 +1,6 @@ | |||
1 | /* vi: set sw=4 ts=4: */ | 1 | /* vi: set sw=4 ts=4: */ |
2 | #ifndef __LIBNETLINK_H__ | 2 | #ifndef LIBNETLINK_H |
3 | #define __LIBNETLINK_H__ 1 | 3 | #define LIBNETLINK_H 1 |
4 | 4 | ||
5 | #include <linux/types.h> | 5 | #include <linux/types.h> |
6 | /* We need linux/types.h because older kernels use __u32 etc | 6 | /* We need linux/types.h because older kernels use __u32 etc |
@@ -8,10 +8,7 @@ | |||
8 | #include <linux/netlink.h> | 8 | #include <linux/netlink.h> |
9 | #include <linux/rtnetlink.h> | 9 | #include <linux/rtnetlink.h> |
10 | 10 | ||
11 | 11 | PUSH_AND_SET_FUNCTION_VISIBILITY_TO_HIDDEN | |
12 | #if __GNUC_PREREQ(4,1) | ||
13 | # pragma GCC visibility push(hidden) | ||
14 | #endif | ||
15 | 12 | ||
16 | struct rtnl_handle | 13 | struct rtnl_handle |
17 | { | 14 | { |
@@ -48,8 +45,6 @@ extern int rta_addattr_l(struct rtattr *rta, int maxlen, int type, void *data, i | |||
48 | 45 | ||
49 | extern int parse_rtattr(struct rtattr *tb[], int max, struct rtattr *rta, int len) FAST_FUNC; | 46 | extern int parse_rtattr(struct rtattr *tb[], int max, struct rtattr *rta, int len) FAST_FUNC; |
50 | 47 | ||
51 | #if __GNUC_PREREQ(4,1) | 48 | POP_SAVED_FUNCTION_VISIBILITY |
52 | # pragma GCC visibility pop | ||
53 | #endif | ||
54 | 49 | ||
55 | #endif /* __LIBNETLINK_H__ */ | 50 | #endif |
diff --git a/networking/libiproute/ll_map.h b/networking/libiproute/ll_map.h index 6d64ac15a..3966def10 100644 --- a/networking/libiproute/ll_map.h +++ b/networking/libiproute/ll_map.h | |||
@@ -1,10 +1,8 @@ | |||
1 | /* vi: set sw=4 ts=4: */ | 1 | /* vi: set sw=4 ts=4: */ |
2 | #ifndef __LL_MAP_H__ | 2 | #ifndef LL_MAP_H |
3 | #define __LL_MAP_H__ 1 | 3 | #define LL_MAP_H 1 |
4 | 4 | ||
5 | #if __GNUC_PREREQ(4,1) | 5 | PUSH_AND_SET_FUNCTION_VISIBILITY_TO_HIDDEN |
6 | # pragma GCC visibility push(hidden) | ||
7 | #endif | ||
8 | 6 | ||
9 | int ll_remember_index(const struct sockaddr_nl *who, struct nlmsghdr *n, void *arg); | 7 | int ll_remember_index(const struct sockaddr_nl *who, struct nlmsghdr *n, void *arg); |
10 | int ll_init_map(struct rtnl_handle *rth); | 8 | int ll_init_map(struct rtnl_handle *rth); |
@@ -14,8 +12,6 @@ const char *ll_idx_n2a(int idx, char *buf); | |||
14 | /* int ll_index_to_type(int idx); */ | 12 | /* int ll_index_to_type(int idx); */ |
15 | unsigned ll_index_to_flags(int idx); | 13 | unsigned ll_index_to_flags(int idx); |
16 | 14 | ||
17 | #if __GNUC_PREREQ(4,1) | 15 | POP_SAVED_FUNCTION_VISIBILITY |
18 | # pragma GCC visibility pop | ||
19 | #endif | ||
20 | 16 | ||
21 | #endif /* __LL_MAP_H__ */ | 17 | #endif |
diff --git a/networking/libiproute/rt_names.h b/networking/libiproute/rt_names.h index 3d68b67c8..a2d4fd142 100644 --- a/networking/libiproute/rt_names.h +++ b/networking/libiproute/rt_names.h | |||
@@ -1,10 +1,8 @@ | |||
1 | /* vi: set sw=4 ts=4: */ | 1 | /* vi: set sw=4 ts=4: */ |
2 | #ifndef RT_NAMES_H_ | 2 | #ifndef RT_NAMES_H |
3 | #define RT_NAMES_H_ 1 | 3 | #define RT_NAMES_H 1 |
4 | 4 | ||
5 | #if __GNUC_PREREQ(4,1) | 5 | PUSH_AND_SET_FUNCTION_VISIBILITY_TO_HIDDEN |
6 | # pragma GCC visibility push(hidden) | ||
7 | #endif | ||
8 | 6 | ||
9 | extern const char* rtnl_rtprot_n2a(int id, char *buf, int len); | 7 | extern const char* rtnl_rtprot_n2a(int id, char *buf, int len); |
10 | extern const char* rtnl_rtscope_n2a(int id, char *buf, int len); | 8 | extern const char* rtnl_rtscope_n2a(int id, char *buf, int len); |
@@ -17,19 +15,15 @@ extern int rtnl_rtrealm_a2n(uint32_t *id, char *arg); | |||
17 | extern int rtnl_dsfield_a2n(uint32_t *id, char *arg); | 15 | extern int rtnl_dsfield_a2n(uint32_t *id, char *arg); |
18 | extern int rtnl_rttable_a2n(uint32_t *id, char *arg); | 16 | extern int rtnl_rttable_a2n(uint32_t *id, char *arg); |
19 | 17 | ||
20 | |||
21 | extern const char* ll_type_n2a(int type, char *buf, int len); | 18 | extern const char* ll_type_n2a(int type, char *buf, int len); |
22 | 19 | ||
23 | extern const char* ll_addr_n2a(unsigned char *addr, int alen, int type, | 20 | extern const char* ll_addr_n2a(unsigned char *addr, int alen, int type, |
24 | char *buf, int blen); | 21 | char *buf, int blen); |
25 | extern int ll_addr_a2n(unsigned char *lladdr, int len, char *arg); | 22 | extern int ll_addr_a2n(unsigned char *lladdr, int len, char *arg); |
26 | 23 | ||
27 | |||
28 | extern const char* ll_proto_n2a(unsigned short id, char *buf, int len); | 24 | extern const char* ll_proto_n2a(unsigned short id, char *buf, int len); |
29 | extern int ll_proto_a2n(unsigned short *id, char *buf); | 25 | extern int ll_proto_a2n(unsigned short *id, char *buf); |
30 | 26 | ||
31 | #if __GNUC_PREREQ(4,1) | 27 | POP_SAVED_FUNCTION_VISIBILITY |
32 | # pragma GCC visibility pop | ||
33 | #endif | ||
34 | 28 | ||
35 | #endif | 29 | #endif |
diff --git a/networking/libiproute/rtm_map.h b/networking/libiproute/rtm_map.h index 02fa77e42..ab1b70e45 100644 --- a/networking/libiproute/rtm_map.h +++ b/networking/libiproute/rtm_map.h | |||
@@ -1,18 +1,14 @@ | |||
1 | /* vi: set sw=4 ts=4: */ | 1 | /* vi: set sw=4 ts=4: */ |
2 | #ifndef __RTM_MAP_H__ | 2 | #ifndef RTM_MAP_H |
3 | #define __RTM_MAP_H__ 1 | 3 | #define RTM_MAP_H 1 |
4 | 4 | ||
5 | #if __GNUC_PREREQ(4,1) | 5 | PUSH_AND_SET_FUNCTION_VISIBILITY_TO_HIDDEN |
6 | # pragma GCC visibility push(hidden) | ||
7 | #endif | ||
8 | 6 | ||
9 | const char *rtnl_rtntype_n2a(int id, char *buf, int len); | 7 | const char *rtnl_rtntype_n2a(int id, char *buf, int len); |
10 | int rtnl_rtntype_a2n(int *id, char *arg); | 8 | int rtnl_rtntype_a2n(int *id, char *arg); |
11 | 9 | ||
12 | int get_rt_realms(uint32_t *realms, char *arg); | 10 | int get_rt_realms(uint32_t *realms, char *arg); |
13 | 11 | ||
14 | #if __GNUC_PREREQ(4,1) | 12 | POP_SAVED_FUNCTION_VISIBILITY |
15 | # pragma GCC visibility pop | ||
16 | #endif | ||
17 | 13 | ||
18 | #endif /* __RTM_MAP_H__ */ | 14 | #endif |
diff --git a/networking/libiproute/utils.h b/networking/libiproute/utils.h index 3603c75a7..ed03e785a 100644 --- a/networking/libiproute/utils.h +++ b/networking/libiproute/utils.h | |||
@@ -1,14 +1,12 @@ | |||
1 | /* vi: set sw=4 ts=4: */ | 1 | /* vi: set sw=4 ts=4: */ |
2 | #ifndef __UTILS_H__ | 2 | #ifndef UTILS_H |
3 | #define __UTILS_H__ 1 | 3 | #define UTILS_H 1 |
4 | 4 | ||
5 | #include "libnetlink.h" | 5 | #include "libnetlink.h" |
6 | #include "ll_map.h" | 6 | #include "ll_map.h" |
7 | #include "rtm_map.h" | 7 | #include "rtm_map.h" |
8 | 8 | ||
9 | #if __GNUC_PREREQ(4,1) | 9 | PUSH_AND_SET_FUNCTION_VISIBILITY_TO_HIDDEN |
10 | # pragma GCC visibility push(hidden) | ||
11 | #endif | ||
12 | 10 | ||
13 | extern family_t preferred_family; | 11 | extern family_t preferred_family; |
14 | extern smallint show_stats; /* UNUSED */ | 12 | extern smallint show_stats; /* UNUSED */ |
@@ -87,8 +85,6 @@ int dnet_pton(int af, const char *src, void *addr); | |||
87 | const char *ipx_ntop(int af, const void *addr, char *str, size_t len); | 85 | const char *ipx_ntop(int af, const void *addr, char *str, size_t len); |
88 | int ipx_pton(int af, const char *src, void *addr); | 86 | int ipx_pton(int af, const char *src, void *addr); |
89 | 87 | ||
90 | #if __GNUC_PREREQ(4,1) | 88 | POP_SAVED_FUNCTION_VISIBILITY |
91 | # pragma GCC visibility pop | ||
92 | #endif | ||
93 | 89 | ||
94 | #endif /* __UTILS_H__ */ | 90 | #endif |