OpenWrt – Blame information for rev 2
?pathlinks?
Rev | Author | Line No. | Line |
---|---|---|---|
1 | office | 1 | --- a/tools/include/tools/be_byteshift.h |
2 | +++ b/tools/include/tools/be_byteshift.h |
||
3 | @@ -1,6 +1,10 @@ |
||
4 | #ifndef _TOOLS_BE_BYTESHIFT_H |
||
5 | #define _TOOLS_BE_BYTESHIFT_H |
||
6 | |||
7 | +#ifndef __linux__ |
||
8 | +#include "linux_types.h" |
||
9 | +#endif |
||
10 | + |
||
11 | #include <stdint.h> |
||
12 | |||
13 | static inline uint16_t __get_unaligned_be16(const uint8_t *p) |
||
14 | --- a/tools/include/tools/le_byteshift.h |
||
15 | +++ b/tools/include/tools/le_byteshift.h |
||
16 | @@ -1,6 +1,10 @@ |
||
17 | #ifndef _TOOLS_LE_BYTESHIFT_H |
||
18 | #define _TOOLS_LE_BYTESHIFT_H |
||
19 | |||
20 | +#ifndef __linux__ |
||
21 | +#include "linux_types.h" |
||
22 | +#endif |
||
23 | + |
||
24 | #include <stdint.h> |
||
25 | |||
26 | static inline uint16_t __get_unaligned_le16(const uint8_t *p) |
||
27 | --- /dev/null |
||
28 | +++ b/tools/include/tools/linux_types.h |
||
29 | @@ -0,0 +1,22 @@ |
||
30 | +#ifndef __LINUX_TYPES_H |
||
31 | +#define __LINUX_TYPES_H |
||
32 | + |
||
33 | +#include <stdint.h> |
||
34 | + |
||
35 | +typedef uint8_t __u8; |
||
36 | +typedef uint8_t __be8; |
||
37 | +typedef uint8_t __le8; |
||
38 | + |
||
39 | +typedef uint16_t __u16; |
||
40 | +typedef uint16_t __be16; |
||
41 | +typedef uint16_t __le16; |
||
42 | + |
||
43 | +typedef uint32_t __u32; |
||
44 | +typedef uint32_t __be32; |
||
45 | +typedef uint32_t __le32; |
||
46 | + |
||
47 | +typedef uint64_t __u64; |
||
48 | +typedef uint64_t __be64; |
||
49 | +typedef uint64_t __le64; |
||
50 | + |
||
51 | +#endif |