Commit 9b07c787 authored by Ghislain MARY's avatar Ghislain MARY

Fix CMake config-file package.

parent edc3520e
......@@ -28,10 +28,28 @@
# BCG729_LIBRARIES - The libraries needed to use bcg729
# BCG729_CPPFLAGS - The compilation flags needed to use bcg729
include("${CMAKE_CURRENT_LIST_DIR}/Bcg729Targets.cmake")
if(NOT LINPHONE_BUILDER_GROUP_EXTERNAL_SOURCE_PATH_BUILDERS)
include("${CMAKE_CURRENT_LIST_DIR}/Bcg729Targets.cmake")
endif()
if(@ENABLE_SHARED@)
set(BCG729_TARGETNAME bcg729)
set(BCG729_LIBRARIES ${BCG729_TARGETNAME})
else()
set(BCG729_TARGETNAME bcg729-static)
get_target_property(BCG729_LIBRARIES ${BCG729_TARGETNAME} LOCATION)
get_target_property(BCG729_LINK_LIBRARIES ${BCG729_TARGETNAME} INTERFACE_LINK_LIBRARIES)
if(BCG729_LINK_LIBRARIES)
list(APPEND BCG729_LIBRARIES ${BCG729_LIBRARIES})
endif()
endif()
get_target_property(BCG729_INCLUDE_DIRS ${BCG729_TARGETNAME} INTERFACE_INCLUDE_DIRECTORIES)
if(LINPHONE_BUILDER_GROUP_EXTERNAL_SOURCE_PATH_BUILDERS)
list(INSERT BCG729_INCLUDE_DIRS 0 "${EP_bcg729_INCLUDE_DIR}")
else()
list(INSERT BCG729_INCLUDE_DIRS 0 "@CMAKE_INSTALL_FULL_INCLUDEDIR@")
endif()
list(REMOVE_DUPLICATES BCG729_INCLUDE_DIRS)
get_filename_component(BCG729_CMAKE_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
set(BCG729_INCLUDE_DIRS "${BCG729_CMAKE_DIR}/../../../include")
set(BCG729_LIBRARIES bcg729)
set(BCG729_CPPFLAGS @BCG729_CPPFLAGS@)
set(BCG729_FOUND 1)
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