Commit 50f5fe54 authored by Ghislain MARY's avatar Ghislain MARY

Fix definition of BZRTP_EXPORT.

parent 268eec85
......@@ -95,6 +95,16 @@ if(STRICT_OPTIONS_CPP)
string(REPLACE ";" " " STRICT_OPTIONS_CPP "${STRICT_OPTIONS_CPP}")
endif()
set(BZRTP_CPPFLAGS ${BCTOOLBOX_CPPFLAGS})
if(ENABLE_STATIC)
list(APPEND BZRTP_CPPFLAGS "-DBZRTP_STATIC")
endif()
list(REMOVE_DUPLICATES BZRTP_CPPFLAGS)
if(BZRTP_CPPFLAGS)
add_definitions(${BZRTP_CPPFLAGS})
endif()
add_definitions("-DZRTP_EXPORTS")
include_directories(
include
${CMAKE_CURRENT_BINARY_DIR}
......
......@@ -26,6 +26,7 @@
# BZRTP_FOUND - system has bzrtp
# BZRTP_INCLUDE_DIRS - the bzrtp include directory
# BZRTP_LIBRARIES - The libraries needed to use bzrtp
# BZRTP_CPPFLAGS - The compilation flags needed to use bzrtp
if(NOT LINPHONE_BUILDER_GROUP_EXTERNAL_SOURCE_PATH_BUILDERS)
include("${CMAKE_CURRENT_LIST_DIR}/BZRTPTargets.cmake")
......@@ -50,4 +51,5 @@ if(@ENABLE_SHARED@)
else()
set(BZRTP_LIBRARIES bzrtp-static)
endif()
set(BZRTP_CPPFLAGS @BZRTP_CPPFLAGS@)
set(BZRTP_FOUND 1)
......@@ -27,9 +27,17 @@
#include <stdint.h>
#ifdef _MSC_VER
#define BZRTP_EXPORT __declspec(dllexport)
#ifdef BZRTP_STATIC
#define BZRTP_EXPORT
#else
#ifdef BZRTP_EXPORTS
#define BZRTP_EXPORT __declspec(dllexport)
#else
#define BZRTP_EXPORT __declspec(dllimport)
#endif
#endif
#else
#define BZRTP_EXPORT __attribute__ ((visibility ("default")))
#define BZRTP_EXPORT __attribute__ ((visibility ("default")))
#endif
/**
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment