The following commit has been merged in the master branch:
commit ef1c0d61cf894cfad4954267c89ffe910995b87f
Author: Guillem Jover <[email protected]>
Date: Thu Sep 24 12:38:47 2009 +0200
build: Add new DPKG_CHECK_DECL m4 macro
Used to check if something is declared in a header.
diff --git a/m4/types.m4 b/m4/types.m4
index dde3f83..f4034a2 100644
--- a/m4/types.m4
+++ b/m4/types.m4
@@ -1,3 +1,5 @@
+# Copyright © 2009 Guillem Jover <[email protected]>
+
# DPKG_TYPE_PTRDIFF_T
# -------------------
# Check for the ptrdiff_t type, defining to int if not defined
@@ -21,6 +23,17 @@ AC_CHECK_DECLS([sys_siglist],,,
])dnl
])# DPKG_DECL_SYS_SIGLIST
+# DPKG_CHECK_DECL([DECL], [HEADER])
+# -----------------
+# Define HAVE_DECL to 1 if declared in HEADER
+AC_DEFUN([DPKG_CHECK_DECL],
+[
+ AC_CHECK_DECL($1,
+ [AC_DEFINE([HAVE_]$1, 1,
+ [Define to 1 if ']$1[' is declared in <$2>])],,
+ [[#include <$2>]])
+])# DPKG_CHECK_DECL
+
# DPKG_CHECK_DEFINE([DEFINE], [HEADER])
# -------------------------------------
# Defines HAVE_DEFINE to 1 if declared in HEADER, 0 otherwise
--
dpkg's main repository
--
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]