Re: AC_FUNC_MMAP test fails on AIX for MAP_FIXED: who's at fault?
Paul Eggert <[email protected]> Mon, 29 Jul 2024 10:10:14 -0700
| Newsgroups | gmane.comp.sysutils.autoconf.general |
|---|---|
| Organization | UCLA Computer Science Department |
| Message-ID | <[email protected]> |
On 2024-07-29 06:36, Zack Weinberg wrote: > However, perhaps we could have a new family of > AC_FUNC_MMAP_* macros that check for specific subsets of mmap functionality > that are generally useful That could be trouble for cross-compiles, no? For cross-compiles AC_FUNC_MMAP currently guesses that mmap works on Linux kernels and fails everywhere else. This is obviously wrong but I guess good enough for programs that use AC_FUNC_MMAP. Not sure I'd like to maintain guesses for a more-sophisticated set of mmap configuration macros. Anyway, if you want to head in this direction I suggest talking to Bruno Haible for advice and looking at Gnulib for prior art, e.g., gl_FUNC_MMAP_ANON sounds like it's the sort of macro that Yury was asking for. A nice property of gl_FUNC_MMAP_ANON is that it doesn't do runtime checks. (Don't know why it's so complicated, though; you'd have to ask Bruno about that.)