~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to m4/pandora_cxx_demangle.m4

  • Committer: Brian Aker
  • Date: 2009-12-09 01:09:43 UTC
  • mfrom: (1240.1.8 build)
  • Revision ID: brian@gaz-20091209010943-n5iq2b9ins7mx73j
MergeĀ build

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
dnl  Copyright (C) 2009 Sun Microsystems
 
2
dnl This file is free software; Sun Microsystems
 
3
dnl gives unlimited permission to copy and/or distribute it,
 
4
dnl with or without modifications, as long as this notice is preserved.
 
5
 
 
6
dnl Check for all of the headers and libs that Drizzle needs. We check all
 
7
dnl of these for plugins too, to ensure that all of the appropriate defines
 
8
dnl are set.
 
9
 
 
10
AC_DEFUN([PANDORA_CXX_DEMANGLE],[
 
11
  AC_LANG_PUSH([C++])
 
12
  AC_CHECK_HEADERS(cxxabi.h)
 
13
  AC_CACHE_CHECK([checking for abi::__cxa_demangle], pandora_cv_cxa_demangle,
 
14
  [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <cxxabi.h>]], [[
 
15
    char *foo= 0; int bar= 0;
 
16
    foo= abi::__cxa_demangle(foo, foo, 0, &bar);
 
17
  ]])],[pandora_cv_cxa_demangle=yes],[pandora_cv_cxa_demangle=no])])
 
18
  AC_LANG_POP()
 
19
 
 
20
  AS_IF([test "x$pandora_cv_cxa_demangle" = xyes],[
 
21
    AC_DEFINE(HAVE_ABI_CXA_DEMANGLE, 1,
 
22
              [Define to 1 if you have the `abi::__cxa_demangle' function.])
 
23
  ])
 
24
])