diff options
author | Justin Jagieniak <justin@jagieniak.net> | 2021-04-14 10:17:16 +0200 |
---|---|---|
committer | Daniel Black <daniel@mariadb.org> | 2021-04-15 10:07:50 +1000 |
commit | 1715fef107b2b0fab2b1e2dbac062b3ac7a9c6b2 (patch) | |
tree | 8ba25346b5a2da7330db85769fa2dc3aa844bfbf /CMakeLists.txt | |
parent | d1f2001ee6a184cf34005a1aa81c2179308cf537 (diff) | |
download | mariadb-git-1715fef107b2b0fab2b1e2dbac062b3ac7a9c6b2.tar.gz |
Fix cross-compile to consider CMAKE_CROSSCOMPILING_EMULATORbb-10.5-danielblack-pr1805-cross-compile
When CMAKE_CROSSCOMPILING_EMULATOR is defined, a cross-compile
can be made, however with native (emulated) execution possible.
This commit takes those points in the build system that
execute built targets natively and allow these to be executed
in a crosscompile if CMAKE_CROSSCOMPILING_EMULATOR is defined.
Closes #1805
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 7452509d0d9..4763c48ec13 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -393,7 +393,7 @@ CHECK_PCRE() CHECK_SYSTEMD() -IF(CMAKE_CROSSCOMPILING) +IF(CMAKE_CROSSCOMPILING AND NOT DEFINED CMAKE_CROSSCOMPILING_EMULATOR) SET(IMPORT_EXECUTABLES "IMPORTFILE-NOTFOUND" CACHE FILEPATH "Path to import_executables.cmake from a native build") INCLUDE(${IMPORT_EXECUTABLES}) ENDIF() @@ -475,7 +475,7 @@ ADD_SUBDIRECTORY(scripts) ADD_SUBDIRECTORY(support-files) ADD_SUBDIRECTORY(extra/aws_sdk) -IF(NOT CMAKE_CROSSCOMPILING) +IF(NOT CMAKE_CROSSCOMPILING OR DEFINED CMAKE_CROSSCOMPILING_EMULATOR) SET(EXPORTED comp_err comp_sql factorial) IF(NOT WITHOUT_SERVER) SET(EXPORTED ${EXPORTED} gen_lex_hash gen_lex_token) |