~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to m4/pandora_have_libdl.m4

  • Committer: Monty Taylor
  • Date: 2008-09-16 00:00:48 UTC
  • mto: This revision was merged to the branch mainline in revision 391.
  • Revision ID: monty@inaugust.com-20080916000048-3rvrv3gv9l0ad3gs
Fixed copyright headers in drizzled/

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
dnl  Copyright (C) 2009 Sun Microsystems, Inc.
2
 
dnl This file is free software; Sun Microsystems, Inc.
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
 
#--------------------------------------------------------------------
7
 
# Check for libdl
8
 
#--------------------------------------------------------------------
9
 
 
10
 
 
11
 
AC_DEFUN([_PANDORA_SEARCH_LIBDL],[
12
 
 
13
 
  save_LIBS="$LIBS"
14
 
  LIBS=""
15
 
  AC_CHECK_LIB(dl,dlopen)
16
 
  AC_CHECK_FUNCS(dlopen)
17
 
  LIBDL_LIBS="$LIBS"
18
 
  LIBS="${save_LIBS}"
19
 
  AC_SUBST(LIBDL_LIBS)
20
 
 
21
 
  AM_CONDITIONAL(HAVE_LIBDL, [test "x${ac_cv_func_dlopen}" = "xyes"])
22
 
])
23
 
 
24
 
AC_DEFUN([_PANDORA_HAVE_LIBDL],[
25
 
 
26
 
  AC_ARG_ENABLE([libdl],
27
 
    [AS_HELP_STRING([--disable-libdl],
28
 
      [Build with libdl support @<:@default=on@:>@])],
29
 
    [ac_enable_libdl="$enableval"],
30
 
    [ac_enable_libdl="yes"])
31
 
 
32
 
  _PANDORA_SEARCH_LIBDL
33
 
])
34
 
 
35
 
 
36
 
AC_DEFUN([PANDORA_HAVE_LIBDL],[
37
 
  AC_REQUIRE([_PANDORA_HAVE_LIBDL])
38
 
])
39
 
 
40
 
AC_DEFUN([_PANDORA_REQUIRE_LIBDL],[
41
 
  ac_enable_libdl="yes"
42
 
  _PANDORA_SEARCH_LIBDL
43
 
 
44
 
  AS_IF([test "$ac_cv_func_dlopen" != "yes"],[
45
 
    AC_MSG_ERROR([libdl/dlopen() is required for ${PACKAGE}. On Debian this can be found in libc6-dev. On RedHat this can be found in glibc-devel.])
46
 
  ])
47
 
])
48
 
 
49
 
AC_DEFUN([PANDORA_REQUIRE_LIBDL],[
50
 
  AC_REQUIRE([_PANDORA_REQUIRE_LIBDL])
51
 
])