This is my mman.h
file included from /usr/include/sys/
:
Somehow mmap()
seems to be defined (and can be used with flags 0 and read/write protection), but not MAP_ANON
or MAP_ANONYMOUS
as indicated below:
#include <sys/mman.h>
int a = MAP_ANON; /* compile error */
int b = MAP_ANONYMOUS; /* also compile error */
I'm at a loss of what could be wrong. I'm compiling using this makefile:
EDIT: It turns out the MAP_ANONYMOUS
macro is defined in /usr/include/bits/mman.h
but only if __USE_MISC
is defined...
Any help would be terrific!