Skip to content

Commit

Permalink
Add HAVE_PREAD definition to platforms
Browse files Browse the repository at this point in the history
ZipFileRO uses pread() to guarantee atomic reads at an offset, so use
the HAVE_PREAD flag to trigger off of. The only platform that doesn't
implement it directly is Windows.

Change-Id: Ic927611dc45b75ff8f672ed59afee5be1ad07ab4
  • Loading branch information
kruton committed Oct 4, 2010
1 parent 912ff85 commit 6be460d
Show file tree
Hide file tree
Showing 7 changed files with 35 additions and 0 deletions.
5 changes: 5 additions & 0 deletions include/arch/darwin-x86/AndroidConfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -285,4 +285,9 @@
*/
#define HAVE_SCHED_H 1

/*
* Define if pread() exists
*/
#define HAVE_PREAD 1

#endif /*_ANDROID_CONFIG_H*/
5 changes: 5 additions & 0 deletions include/arch/freebsd-x86/AndroidConfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -344,4 +344,9 @@
*/
#define HAVE_SCHED_H 1

/*
* Define if pread() exists
*/
#define HAVE_PREAD 1

#endif /*_ANDROID_CONFIG_H*/
5 changes: 5 additions & 0 deletions include/arch/linux-arm/AndroidConfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -339,4 +339,9 @@
*/
#define HAVE_SCHED_H 1

/*
* Define if pread() exists
*/
#define HAVE_PREAD 1

#endif /* _ANDROID_CONFIG_H */
5 changes: 5 additions & 0 deletions include/arch/linux-sh/AndroidConfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -346,4 +346,9 @@
*/
#define HAVE_UNWIND_CONTEXT_STRUCT

/*
* Define if pread() exists
*/
#define HAVE_PREAD 1

#endif /* _ANDROID_CONFIG_H */
5 changes: 5 additions & 0 deletions include/arch/linux-x86/AndroidConfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -313,4 +313,9 @@
*/
#define HAVE_SCHED_H 1

/*
* Define if pread() exists
*/
#define HAVE_PREAD 1

#endif /*_ANDROID_CONFIG_H*/
5 changes: 5 additions & 0 deletions include/arch/target_linux-x86/AndroidConfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -330,4 +330,9 @@
*/
#define HAVE_SCHED_H 1

/*
* Define if pread() exists
*/
#define HAVE_PREAD 1

#endif /* _ANDROID_CONFIG_H */
5 changes: 5 additions & 0 deletions include/arch/windows/AndroidConfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -318,4 +318,9 @@
*/
/* #define HAVE_SCHED_H */

/*
* Define if pread() exists
*/
/* #define HAVE_PREAD 1 */

#endif /*_ANDROID_CONFIG_H*/

0 comments on commit 6be460d

Please sign in to comment.