mirror of
https://github.com/UltraCoderRU/libwebrtc.git
synced 2026-01-28 03:15:11 +00:00
Add an option to disable the use of internal Clang compiler
This commit is contained in:
parent
ab22b5519e
commit
1e24732035
2 changed files with 7 additions and 4 deletions
|
|
@ -4,6 +4,7 @@ set(CMAKE_CONFIGURATION_TYPES Debug Release CACHE STRING INTERNAL FORCE)
|
|||
|
||||
project(libwebrtc)
|
||||
|
||||
set(USE_CLANG ON CACHE BOOL "Build using internal Clang compiler (set to OFF to build using system GCC/MSVC)")
|
||||
set(GN_EXTRA_ARGS "" CACHE STRING "Extra 'gn gen' arguments to pass when configuring WebRTC")
|
||||
set(NINJA_ARGS "" CACHE STRING "Ninja arguments to pass when compiling WebRTC")
|
||||
option(BUILD_DEB_PACKAGE "Build .deb package" OFF)
|
||||
|
|
|
|||
|
|
@ -1,10 +1,12 @@
|
|||
function(add_webrtc_target SOURCE_DIR BUILD_DIR)
|
||||
|
||||
set(GEN_ARGS_COMMON "target_cpu=\"${TARGET_CPU}\" target_os=\"${TARGET_OS}\" is_component_build=false use_gold=false use_custom_libcxx=false use_custom_libcxx_for_host=false rtc_enable_protobuf=false")
|
||||
set(GEN_ARGS_COMMON "target_cpu=\"${TARGET_CPU}\" target_os=\"${TARGET_OS}\" is_component_build=false use_gold=false use_custom_libcxx=false use_custom_libcxx_for_host=false treat_warnings_as_errors=false rtc_enable_protobuf=false")
|
||||
|
||||
if (MSVC)
|
||||
if (USE_CLANG)
|
||||
set(GEN_ARGS_COMMON "${GEN_ARGS_COMMON} is_clang=true use_lld=true")
|
||||
else()
|
||||
set(GEN_ARGS_COMMON "${GEN_ARGS_COMMON} is_clang=false use_lld=false")
|
||||
endif ()
|
||||
endif()
|
||||
|
||||
set(GEN_ARGS_DEBUG "${GEN_ARGS_COMMON} is_debug=true")
|
||||
set(GEN_ARGS_RELEASE "${GEN_ARGS_COMMON} is_debug=false")
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue