Skip to content

Commit

Permalink
Automatically detect the host platform in CMakeLists.txt (bytecodeall…
Browse files Browse the repository at this point in the history
…iance#929)

Previously, "linux" was hardcoded in the root CMakeLists.txt, so it was
impossible to build on anything but Linux, even when specifying
WAMR_BUILD_PLATFORM.

Signed-off-by: Piotr Sikora <piotrsikora@google.com>
  • Loading branch information
PiotrSikora authored Jan 4, 2022
1 parent cdf3063 commit 6b733b8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ cmake_minimum_required (VERSION 2.8...3.16)
project (iwasm)
# set (CMAKE_VERBOSE_MAKEFILE 1)

set (WAMR_BUILD_PLATFORM "linux")
string (TOLOWER ${CMAKE_HOST_SYSTEM_NAME} WAMR_BUILD_PLATFORM)

# Reset default linker flags
set (CMAKE_SHARED_LIBRARY_LINK_C_FLAGS "")
Expand Down

0 comments on commit 6b733b8

Please sign in to comment.