summaryrefslogtreecommitdiffstats
path: root/gl/m4/absolute-header.m4
diff options
context:
space:
mode:
authorThomas Guyot-Sionnest <dermoth@aei.ca>2009-01-15 09:22:57 (GMT)
committerThomas Guyot-Sionnest <dermoth@aei.ca>2009-01-15 10:19:08 (GMT)
commit71cdb52799220f8d9052643baf1d3e9836a9c755 (patch)
tree27aee97a35d9ab51f0d8f64a46690bd41a5f8c1b /gl/m4/absolute-header.m4
parentf7afa46586645e50498d8b2d0c67884f014dc3a4 (diff)
downloadmonitoring-plugins-71cdb52799220f8d9052643baf1d3e9836a9c755.tar.gz
Sync with gnulib
Diffstat (limited to 'gl/m4/absolute-header.m4')
-rw-r--r--gl/m4/absolute-header.m449
1 files changed, 0 insertions, 49 deletions
diff --git a/gl/m4/absolute-header.m4 b/gl/m4/absolute-header.m4
deleted file mode 100644
index 5b7a2fc..0000000
--- a/gl/m4/absolute-header.m4
+++ /dev/null
@@ -1,49 +0,0 @@
1# absolute-header.m4 serial 7
2dnl Copyright (C) 2006, 2007 Free Software Foundation, Inc.
3dnl This file is free software; the Free Software Foundation
4dnl gives unlimited permission to copy and/or distribute it,
5dnl with or without modifications, as long as this notice is preserved.
6
7dnl From Derek Price.
8
9# gl_ABSOLUTE_HEADER(HEADER1 HEADER2 ...)
10# ---------------------------------------
11# Find the absolute name of a header file, assuming the header exists.
12# If the header were sys/inttypes.h, this macro would define
13# ABSOLUTE_SYS_INTTYPES_H to the `""' quoted absolute name of sys/inttypes.h
14# in config.h
15# (e.g. `#define ABSOLUTE_SYS_INTTYPES_H "///usr/include/sys/inttypes.h"').
16# The three "///" are to pacify Sun C 5.8, which otherwise would say
17# "warning: #include of /usr/include/... may be non-portable".
18# Use `""', not `<>', so that the /// cannot be confused with a C99 comment.
19AC_DEFUN([gl_ABSOLUTE_HEADER],
20[AC_LANG_PREPROC_REQUIRE()dnl
21AC_FOREACH([gl_HEADER_NAME], [$1],
22 [AS_VAR_PUSHDEF([gl_absolute_header],
23 [gl_cv_absolute_]m4_quote(m4_defn([gl_HEADER_NAME])))dnl
24 AC_CACHE_CHECK([absolute name of <]m4_quote(m4_defn([gl_HEADER_NAME]))[>],
25 m4_quote(m4_defn([gl_absolute_header])),
26 [AS_VAR_PUSHDEF([ac_header_exists],
27 [ac_cv_header_]m4_quote(m4_defn([gl_HEADER_NAME])))dnl
28 AC_CHECK_HEADERS_ONCE(m4_quote(m4_defn([gl_HEADER_NAME])))dnl
29 if test AS_VAR_GET(ac_header_exists) = yes; then
30 AC_LANG_CONFTEST([AC_LANG_SOURCE([[#include <]]m4_dquote(m4_defn([gl_HEADER_NAME]))[[>]])])
31dnl eval is necessary to expand ac_cpp.
32dnl Ultrix and Pyramid sh refuse to redirect output of eval, so use subshell.
33 AS_VAR_SET(gl_absolute_header,
34[`(eval "$ac_cpp conftest.$ac_ext") 2>&AS_MESSAGE_LOG_FD |
35sed -n '\#/]m4_quote(m4_defn([gl_HEADER_NAME]))[#{
36 s#.*"\(.*/]m4_quote(m4_defn([gl_HEADER_NAME]))[\)".*#\1#
37 s#^/[^/]#//&#
38 p
39 q
40}'`])
41 fi
42 AS_VAR_POPDEF([ac_header_exists])dnl
43 ])dnl
44 AC_DEFINE_UNQUOTED(AS_TR_CPP([ABSOLUTE_]m4_quote(m4_defn([gl_HEADER_NAME]))),
45 ["AS_VAR_GET(gl_absolute_header)"],
46 [Define this to an absolute name of <]m4_quote(m4_defn([gl_HEADER_NAME]))[>.])
47 AS_VAR_POPDEF([gl_absolute_header])dnl
48])dnl
49])# gl_ABSOLUTE_HEADER