basic MacOS version
This commit is contained in:
+9
-33
@@ -1,40 +1,16 @@
|
||||
# TODO
|
||||
# This file clearly need rework
|
||||
# Build system to make it works on every platform
|
||||
# Also mb automatically download prebuild libwebrtc binary so the users can directly start coding..
|
||||
# IMPORTANT NOTE
|
||||
# This file is just used because some IDEs need to understand how to do autocompletion.
|
||||
# This file is completely ignored by the library ( See build.rs for the build system )
|
||||
|
||||
cmake_minimum_required(VERSION 3.22)
|
||||
project(livekit-native)
|
||||
project(client_sdk_native)
|
||||
|
||||
set(CMAKE_BUILD_TYPE Release)
|
||||
set(CMAKE_CXX_STANDARD 14)
|
||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||
|
||||
add_definitions(-DWEBRTC_POSIX=1 -DWEBRTC_MAC=1 -DGLIBCXX_USE_CXX11_ABI=0)
|
||||
add_definitions(-DWEBRTC_POSIX -DWEBRTC_MAC)
|
||||
|
||||
find_package(Boost COMPONENTS system REQUIRED)
|
||||
include_directories(${Boost_INCLUDE_DIRS})
|
||||
include_directories(include/)
|
||||
include_directories(libwebrtc/include)
|
||||
|
||||
find_package(Protobuf REQUIRED)
|
||||
include_directories(${Protobuf_INCLUDE_DIRS})
|
||||
|
||||
find_package(spdlog CONFIG REQUIRED)
|
||||
|
||||
include_directories(thirdparty/webrtc/include)
|
||||
|
||||
file(GLOB_RECURSE SRC src/*)
|
||||
add_executable(livekit-native ${SRC} main.cpp)
|
||||
|
||||
# for cocoa
|
||||
find_library(CORE_FOUNDATION Foundation)
|
||||
find_library(APPLICATION_SERVICES ApplicationServices)
|
||||
find_library(CORE_SERVICES CoreServices)
|
||||
|
||||
target_link_libraries(livekit-native PRIVATE
|
||||
spdlog::spdlog
|
||||
${Boost_LIBRARIES}
|
||||
${Protobuf_LIBRARIES}
|
||||
${CORE_FOUNDATION} ${APPLICATION_SERVICES} ${CORE_SERVICES}
|
||||
${CMAKE_CURRENT_LIST_DIR}/thirdparty/webrtc/lib/libboringssl.a
|
||||
${CMAKE_CURRENT_LIST_DIR}/thirdparty/webrtc/lib/libwebrtc.a
|
||||
)
|
||||
# Fake library
|
||||
add_library(client_sdk_native src/peer_connection_factory.cpp)
|
||||
Reference in New Issue
Block a user