~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to m4/pandora_visibility.m4

Merge Monty - fix bug 709948 Can't run drizzle on OSX when building with visibility flag

Show diffs side-by-side

added added

removed removed

Lines of Context:
23
23
AC_DEFUN([PANDORA_CHECK_VISIBILITY],
24
24
[
25
25
  AC_REQUIRE([AC_PROG_CC])
 
26
  AC_REQUIRE([PANDORA_PLATFORM])
26
27
  CFLAG_VISIBILITY=
27
28
  HAVE_VISIBILITY=0
28
29
  AS_IF([test -n "$GCC"],[
35
36
         extern __attribute__((__visibility__("default"))) int exportedvar;
36
37
         extern __attribute__((__visibility__("hidden"))) int hiddenfunc (void);
37
38
         extern __attribute__((__visibility__("default"))) int exportedfunc (void);],
38
 
        [],
39
 
        [gl_cv_cc_visibility=yes],
40
 
        [gl_cv_cc_visibility=no])
 
39
        [],[
 
40
        case "$host_os" in
 
41
          *darwin*)
 
42
            gl_cv_cc_visibility=no
 
43
            ;;
 
44
          *)
 
45
            gl_cv_cc_visibility=yes
 
46
            ;;
 
47
        esac
 
48
        ],[gl_cv_cc_visibility=no])
41
49
      CFLAGS="$gl_save_CFLAGS"])
42
50
    AC_MSG_RESULT([$gl_cv_cc_visibility])
43
51
    if test $gl_cv_cc_visibility = yes; then