Home | History | Annotate | Line # | Download | only in gnulib-m4
      1  1.1  christos # canonicalize.m4 serial 2 (gettext-0.13)
      2  1.1  christos dnl Copyright (C) 2003 Free Software Foundation, Inc.
      3  1.1  christos dnl This file is free software; the Free Software Foundation
      4  1.1  christos dnl gives unlimited permission to copy and/or distribute it,
      5  1.1  christos dnl with or without modifications, as long as this notice is preserved.
      6  1.1  christos 
      7  1.1  christos AC_DEFUN([gl_CANONICALIZE],
      8  1.1  christos [
      9  1.1  christos   dnl Do this replacement check manually because the file name is shorter
     10  1.1  christos   dnl than the function name.
     11  1.1  christos   AC_CHECK_FUNCS(canonicalize_file_name)
     12  1.1  christos   if test $ac_cv_func_canonicalize_file_name = no; then
     13  1.1  christos     AC_LIBOBJ(canonicalize)
     14  1.1  christos     AC_DEFINE([realpath], [rpl_realpath],
     15  1.1  christos       [Define to a replacement function name for realpath().])
     16  1.1  christos     gl_PREREQ_CANONICALIZE
     17  1.1  christos   fi
     18  1.1  christos ])
     19  1.1  christos 
     20  1.1  christos # Prerequisites of lib/canonicalize.c.
     21  1.1  christos AC_DEFUN([gl_PREREQ_CANONICALIZE],
     22  1.1  christos [
     23  1.1  christos   AC_CHECK_HEADERS_ONCE(sys/param.h unistd.h)
     24  1.1  christos   AC_CHECK_FUNCS(getcwd readlink)
     25  1.1  christos ])
     26