summaryrefslogtreecommitdiff
path: root/m4/getsubopt.m4
blob: 2cb93dcc0af3bc77e9ff5789949ea369d42e71e0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# getsubopt.m4 serial 4
dnl Copyright (C) 2004, 2007, 2009 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
dnl with or without modifications, as long as this notice is preserved.

AC_DEFUN([gl_FUNC_GETSUBOPT],
[
  dnl Persuade glibc <stdlib.h> to declare getsubopt().
  AC_REQUIRE([AC_USE_SYSTEM_EXTENSIONS])

  AC_REQUIRE([gl_STDLIB_H_DEFAULTS])
  AC_CHECK_FUNCS_ONCE([getsubopt])
  if test $ac_cv_func_getsubopt = no; then
    HAVE_GETSUBOPT=0
    AC_LIBOBJ([getsubopt])
    gl_PREREQ_GETSUBOPT
  fi
])

# Prerequisites of lib/getsubopt.c.
AC_DEFUN([gl_PREREQ_GETSUBOPT], [:])