ldivmod, uldivmod: fix qdivrem calls
[minix.git] / lib / libelf / libelf_compat.h
blob0343f8e5a72f1021bf3ee507da0dbf42f7a00caa
1 #ifndef LIBELF_COMPAT_H
2 #define LIBELF_COMPAT_H
4 #if defined(NO_MMAP_FILE)
6 #include <stdlib.h>
8 #ifndef PROT_READ
9 #define PROT_READ 0x01 /* pages can be read */
10 #define MAP_PRIVATE 0x0002 /* changes are private */
13 * Error indicator returned by mmap(2)
15 #define MAP_FAILED ((void *) -1) /* mmap() failed */
16 #endif
18 #define mmap libelf_mmap
19 #define munmap libelf_munmap
20 void* libelf_mmap(void *addr, size_t len, int prot, int flags, int fd, off_t offset);
21 int libelf_munmap(void *addr, size_t len);
23 #else /* ! NO_MMAP_FILE */
25 #include <sys/mman.h>
27 #endif /* NO_MMAP_FILE */
29 #endif /* LIBELF_COMPAT_H */