$NetBSD: patch-configure.ac,v 1.3 2020/02/17 17:24:06 jperkin Exp $ Hunk #0: Don't use non-portable operator ==. Hunk #1: Fix build on FreeBSD/amd64. --- configure.ac.orig 2018-10-13 19:49:38.000000000 +0000 +++ configure.ac @@ -811,7 +811,7 @@ if test "x$EnableDtrace" = "xyes"; then if test -n "$DtraceCmd"; then if test "x$TargetOS_CPP-$TargetVendor_CPP" = "xdarwin-apple" \ -o "x$TargetOS_CPP-$TargetVendor_CPP" = "xfreebsd-portbld" \ - -o "x$TargetOS_CPP-$TargetVendor_CPP" = "xsolaris2-unknown"; then + ; then HaveDtrace=YES fi fi @@ -914,7 +914,7 @@ FP_CHECK_SIZEOF_AND_ALIGNMENT(uint64_t) dnl for use in settings.in TargetWordSize=$ac_cv_sizeof_void_p -if test "x$TargetWordSize" == 8; then +if test "x$TargetWordSize" = 8; then AC_SUBST([Cabal64bit],[True]) else AC_SUBST([Cabal64bit],[False]) @@ -1173,6 +1173,11 @@ if test "$ac_cv_sizeof_void_p" -eq 8 ; t # The flag MAP_NORESERVE is supported for source compatibility reasons, # but is completely ignored by OS mmap use_large_address_space=no + elif test "$ghc_host_os" = "freebsd" ; then + # FreeBSD doesn't support MAP_NORESERVE. The flag + # MAP_NORESERVE is supported for source compatibility + # reasons, but is completely ignored by OS mmap + use_large_address_space=no else AC_CHECK_DECLS([MAP_NORESERVE, MADV_FREE, MADV_DONTNEED],[],[], [