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.)

  • AC_FUNC_MMAP ... Yury V. Zaytsev
    • Re: AC_F... Yury V. Zaytsev
      • Re: ... Bob Friesenhahn
        • ... Paul Eggert
          • ... Bob Friesenhahn
            • ... Zack Weinberg
              • ... Yury V. Zaytsev
              • ... Bob Friesenhahn
                • ... Howard Chu via Discussion list for the autoconf build system
              • ... Paul Eggert
          • ... Yury V. Zaytsev
          • ... Brooks Davis
            • ... Yury V. Zaytsev
              • ... Zack Weinberg
                • ... Howard Chu via Discussion list for the autoconf build system
                • ... Zack Weinberg
                • ... Russ Allbery
                • ... Howard Chu via Discussion list for the autoconf build system
                • ... Russ Allbery
                • ... Paul Eggert

Reply via email to