Find all libraries first, set HAS_OWN_DEPOT_TOOLS variable

This commit is contained in:
Axel Isouard 2017-03-17 23:26:47 +01:00
parent 7ad84637f4
commit e60dbd57f6
No known key found for this signature in database
GPG key ID: 4E64BB3EAAF31C29
3 changed files with 12 additions and 13 deletions

View file

@ -10,18 +10,18 @@ set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH}
find_package(Git REQUIRED)
if (DEPOT_TOOLS_PATH)
find_package(DepotTools REQUIRED)
endif (DEPOT_TOOLS_PATH)
if (NOT WIN32)
find_package(PythonInterp 2.7 REQUIRED)
endif (NOT WIN32)
include(FindLibraries)
include(Version)
include(Options)
include(TargetOsAndCpu)
if (HAS_OWN_DEPOT_TOOLS)
find_package(DepotTools REQUIRED)
endif (HAS_OWN_DEPOT_TOOLS)
if (NOT WIN32)
find_package(PythonInterp 2.7 REQUIRED)
endif (NOT WIN32)
add_subdirectory(Targets)
export(PACKAGE LibWebRTC)

View file

@ -1,8 +1,3 @@
if(FIND_DEPOT_TOOLS_INCLUDED)
return()
endif(FIND_DEPOT_TOOLS_INCLUDED)
set(FIND_DEPOT_TOOLS_INCLUDED true)
find_program(GCLIENT_EXECUTABLE
NAMES gclient gclient.bat
DOC "Path to gclient executable"

View file

@ -13,6 +13,10 @@ option(BUILD_SHARED_LIB "Build WebRTC as a shared library" OFF)
set(WEBRTC_REVISION "" CACHE STRING "WebRTC commit hash to checkout")
set(WEBRTC_BRANCH_HEAD "${LIBWEBRTC_WEBRTC_HEAD}" CACHE STRING "WebRTC branch head to checkout")
if (DEPOT_TOOLS_PATH)
set(HAS_OWN_DEPOT_TOOLS 1)
endif (DEPOT_TOOLS_PATH)
if(BUILD_SHARED_LIB)
set(LIBRARY_TYPE SHARED)
else()