mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2023-10-10 13:36:59 +02:00
Cross-Compile - Separate flatc scenario for native and cross-compiling
This commit is contained in:
parent
5c807599c5
commit
8dec127673
10
dependencies/CMakeLists.txt
vendored
10
dependencies/CMakeLists.txt
vendored
@ -40,14 +40,14 @@ else ()
|
|||||||
set(FLATBUFFERS_INCLUDE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}/external/flatbuffers/include")
|
set(FLATBUFFERS_INCLUDE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}/external/flatbuffers/include")
|
||||||
set(FLATBUFFERS_INCLUDE_DIRS ${FLATBUFFERS_INCLUDE_DIRS} PARENT_SCOPE)
|
set(FLATBUFFERS_INCLUDE_DIRS ${FLATBUFFERS_INCLUDE_DIRS} PARENT_SCOPE)
|
||||||
|
|
||||||
# define the flatc executable at the parent scope
|
IF (NOT CMAKE_CROSSCOMPILING)
|
||||||
get_property(FLATBUFFERS_FLATC_EXECUTABLE TARGET flatc PROPERTY LOCATION)
|
# define the flatc executable at the parent scope
|
||||||
|
get_property(FLATBUFFERS_FLATC_EXECUTABLE TARGET flatc PROPERTY LOCATION)
|
||||||
IF ( CMAKE_CROSSCOMPILING )
|
else()
|
||||||
#Workaround, set flatc comiplier directory hard, as cmake definitions of flatc do not cater for crosscompile correctly.
|
#Workaround, set flatc comiplier directory hard, as cmake definitions of flatc do not cater for crosscompile correctly.
|
||||||
#Includ of flatc_export.cmake detects that flatc target is defined aand returns before using the definitions written by export
|
#Includ of flatc_export.cmake detects that flatc target is defined aand returns before using the definitions written by export
|
||||||
set ( FLATBUFFERS_FLATC_EXECUTABLE "${CMAKE_BINARY_DIR}/../build-x86x64/bin/flatc")
|
set ( FLATBUFFERS_FLATC_EXECUTABLE "${CMAKE_BINARY_DIR}/../build-x86x64/bin/flatc")
|
||||||
ENDIF()
|
endif()
|
||||||
|
|
||||||
set(FLATBUFFERS_FLATC_EXECUTABLE ${FLATBUFFERS_FLATC_EXECUTABLE} PARENT_SCOPE)
|
set(FLATBUFFERS_FLATC_EXECUTABLE ${FLATBUFFERS_FLATC_EXECUTABLE} PARENT_SCOPE)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user