@@ -353,7 +353,7 @@ AC_CHECK_FUNCS([mach_port_construct])
353353#
354354AC_CHECK_DECLS ( [ CLOCK_UPTIME, CLOCK_MONOTONIC] , [ ] , [ ] ,
355355 [ [ #include <time.h>] ] )
356- AC_CHECK_DECLS ( [ NOTE_NONE, NOTE_REAP, NOTE_REVOKE, NOTE_SIGNAL] , [ ] , [ ] ,
356+ AC_CHECK_DECLS ( [ NOTE_NONE, NOTE_REAP, NOTE_REVOKE, NOTE_SIGNAL, NOTE_LOWAT ] , [ ] , [ ] ,
357357 [ [ #include <sys/event.h>] ] )
358358AC_CHECK_DECLS ( [ FD_COPY] , [ ] , [ ] , [ [ #include <sys/select.h>] ] )
359359AC_CHECK_DECLS ( [ SIGEMT] , [ ] , [ ] , [ [ #include <signal.h>] ] )
@@ -432,6 +432,20 @@ AS_IF([test "x$have_mach" = "xtrue"], [
432432] )
433433AM_CONDITIONAL(HAVE_DARWIN_LD, [ test "x$dispatch_cv_ld_darwin" == "xyes"] )
434434
435+ #
436+ # symlink platform-specific module.modulemap files
437+ #
438+ AS_CASE ( [ $target_os] ,
439+ [ darwin*] , [ dispatch_module_map_os=darwin ] ,
440+ [ dispatch_module_map_os=generic ]
441+ )
442+ AC_CONFIG_COMMANDS ( [ modulemaps] , [
443+ ln -fs $dispatch_module_map_os/module.modulemap $ac_top_srcdir/dispatch/module.modulemap
444+ ln -fs $dispatch_module_map_os/module.modulemap $ac_top_srcdir/private/module.modulemap
445+ ] ,
446+ [ dispatch_module_map_os="$dispatch_module_map_os"]
447+ )
448+
435449#
436450# Temporary: some versions of clang do not mark __builtin_trap() as
437451# __attribute__((__noreturn__)). Detect and add if required.
@@ -449,6 +463,6 @@ AC_CONFIG_FILES([Makefile dispatch/Makefile man/Makefile os/Makefile private/Mak
449463#
450464# Generate testsuite links
451465#
452- AC_CONFIG_LINKS ( [ tests/dispatch:$top_srcdir /private tests/leaks-wrapper:tests/leaks-wrapper.sh] )
466+ AC_CONFIG_LINKS ( [ tests/dispatch:$ac_top_srcdir /private tests/leaks-wrapper:tests/leaks-wrapper.sh] )
453467
454468AC_OUTPUT
0 commit comments