wasm-mutator-fuzz: Set compilers earlier (#3585)

CMAKE_C_COMPILER etc should be set before project(),
in which cmake tries to decide which compiler to use.
This commit is contained in:
YAMAMOTO Takashi
2024-07-02 12:27:31 +09:00
committed by GitHub
parent fe4ed6adf2
commit 0d9cea434c

View File

@ -3,10 +3,6 @@
cmake_minimum_required (VERSION 2.8)
project(wasm_mutator)
set (CMAKE_BUILD_TYPE Debug)
if (NOT DEFINED CMAKE_C_COMPILER)
set (CMAKE_C_COMPILER "clang")
endif ()
@ -14,6 +10,10 @@ if (NOT DEFINED CMAKE_CXX_COMPILER)
set (CMAKE_CXX_COMPILER "clang++")
endif ()
project(wasm_mutator)
set (CMAKE_BUILD_TYPE Debug)
string (TOLOWER ${CMAKE_HOST_SYSTEM_NAME} WAMR_BUILD_PLATFORM)
# Reset default linker flags