fix suncc visibility support
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@12109 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
parent
00666fde86
commit
900907a205
46
configure.in
46
configure.in
|
@ -184,33 +184,31 @@ if test "x${enable_visibility}" != "xno" ; then
|
||||||
CFLAGS="${save_CFLAGS}"
|
CFLAGS="${save_CFLAGS}"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
# sun)
|
sun)
|
||||||
# save_CFLAGS="${CFLAGS}"
|
save_CFLAGS="${CFLAGS}"
|
||||||
# CFLAGS="${CFLAGS} -xldscope=hidden"
|
CFLAGS="${CFLAGS} -xldscope=hidden"
|
||||||
# AC_MSG_CHECKING([whether the compiler supports -xldscope=hidden])
|
AC_MSG_CHECKING([whether the compiler supports -xldscope=hidden])
|
||||||
# AC_COMPILE_IFELSE(
|
AC_COMPILE_IFELSE(
|
||||||
# [AC_LANG_PROGRAM(
|
[AC_LANG_PROGRAM(
|
||||||
# [int foo __attribute__ ((visibility("default")));],
|
[int foo __attribute__ ((visibility("default")));],
|
||||||
# [;]
|
[;]
|
||||||
# )],
|
)],
|
||||||
#
|
|
||||||
# [AC_MSG_RESULT([yes])
|
[AC_MSG_RESULT([yes])
|
||||||
# APR_ADDTO([SWITCH_AM_CFLAGS], [-xldscope=hidden -DSWITCH_API_VISIBILITY=1 -DHAVE_VISIBILITY=1])
|
APR_ADDTO([SWITCH_AM_CFLAGS], [-xldscope=hidden -DSWITCH_API_VISIBILITY=1 -DHAVE_VISIBILITY=1])
|
||||||
# APR_ADDTO([SWITCH_AM_CXXFLAGS], [-xldscope=hidden -DSWITCH_API_VISIBILITY=1 -DHAVE_VISIBILITY=1])
|
APR_ADDTO([SWITCH_AM_CXXFLAGS], [-xldscope=hidden -DSWITCH_API_VISIBILITY=1 -DHAVE_VISIBILITY=1])
|
||||||
# HAVE_VISIBILITY="yes"],
|
HAVE_VISIBILITY="yes"],
|
||||||
#
|
|
||||||
# [AC_MSG_RESULT([no])]
|
[AC_MSG_RESULT([no])]
|
||||||
# )
|
)
|
||||||
# CFLAGS="${save_CFLAGS}"
|
CFLAGS="${save_CFLAGS}"
|
||||||
# ;;
|
;;
|
||||||
#
|
|
||||||
*)
|
*)
|
||||||
if test "x${enable_visibility}" = "xyes" ; then
|
if test "x${enable_visibility}" = "xyes" ; then
|
||||||
AC_MSG_ERROR([Non-GNU compilers are currently unsupported])
|
AC_MSG_ERROR([Non-GNU / SUN compilers are currently unsupported])
|
||||||
# AC_MSG_ERROR([Non-GNU / SUN compilers are currently unsupported])
|
|
||||||
else
|
else
|
||||||
AC_MSG_WARN([Non-GNU compilers are currently unsupported])
|
AC_MSG_WARN([Non-GNU / SUN compilers are currently unsupported])
|
||||||
# AC_MSG_WARN([Non-GNU / SUN compilers are currently unsupported])
|
|
||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
|
@ -165,7 +165,7 @@ typedef int gid_t;
|
||||||
#define SWITCH_DECLARE_CLASS
|
#define SWITCH_DECLARE_CLASS
|
||||||
#else //not win32
|
#else //not win32
|
||||||
#define O_BINARY 0
|
#define O_BINARY 0
|
||||||
#if (defined(__GNUC__) || defined(__SUNCC__)) && defined(SWITCH_API_VISIBILITY)
|
#if (defined(__GNUC__) || defined(__SUNPRO_CC) || defined (__SUNPRO_C)) && defined(SWITCH_API_VISIBILITY)
|
||||||
#define SWITCH_DECLARE(type) __attribute__((visibility("default"))) type
|
#define SWITCH_DECLARE(type) __attribute__((visibility("default"))) type
|
||||||
#define SWITCH_DECLARE_NONSTD(type) __attribute__((visibility("default"))) type
|
#define SWITCH_DECLARE_NONSTD(type) __attribute__((visibility("default"))) type
|
||||||
#define SWITCH_DECLARE_DATA __attribute__((visibility("default")))
|
#define SWITCH_DECLARE_DATA __attribute__((visibility("default")))
|
||||||
|
|
Loading…
Reference in New Issue