Linux: Suppress -Wordered-compare-function-pointers in tracepoint code
[zfs.git] / config / always-sed.m4
blob3d7ae285ba1b3327fc7acb96816cb8ffc30f5601
1 dnl #
2 dnl # Set the flags used for sed in-place edits.
3 dnl #
4 AC_DEFUN([ZFS_AC_CONFIG_ALWAYS_SED], [
5         AC_REQUIRE([AC_PROG_SED])dnl
6         AC_CACHE_CHECK([for sed --in-place], [ac_cv_inplace], [
7                 tmpfile=$(mktemp conftest.XXXXXX)
8                 echo foo >$tmpfile
9                 AS_IF([$SED --in-place 's#foo#bar#' $tmpfile 2>/dev/null],
10                       [ac_cv_inplace="--in-place"],
11                       [$SED -i '' 's#foo#bar#' $tmpfile 2>/dev/null],
12                       [ac_cv_inplace="-i ''"],
13                       [AC_MSG_ERROR([$SED does not support in-place])])
14         ])
15         AC_SUBST([ac_inplace], [$ac_cv_inplace])