btrfs-progs: drop blocksize argument from readahead_tree_block
[platform/upstream/btrfs-progs.git] / androidcompat.h
1 /*
2  * Compatibility layer for Android.
3  *
4  * Stub calls or alternate functions for pthreads.
5  */
6
7 #ifndef __ANDROID_H__
8 #define __ANDROID_H__
9
10 #ifdef ANDROID
11
12 #define pthread_setcanceltype(type, oldtype)    (0)
13 #define pthread_setcancelstate(state, oldstate) (0)
14
15 #define pthread_cancel(ret)     pthread_kill((ret), SIGUSR1)
16
17 typedef struct blkid_struct_probe *blkid_probe;
18
19 #include <dirent.h>
20 #define direct dirent
21
22 #else   /* !ANDROID */
23
24 #include <sys/dir.h>
25
26 #endif  /* !ANDROID */
27
28 #endif  /* __ANDROID_H__ */