Skip to content

Commit

Permalink
build: Add missing shared library linker flags
Browse files Browse the repository at this point in the history
Signed-off-by: Dim-P <[email protected]>
  • Loading branch information
Dim-P committed Nov 13, 2023
1 parent 281aea0 commit c5cea65
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,14 @@ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FLB_FILENAME__=__FILE__")
if(${CMAKE_SYSTEM_PROCESSOR} MATCHES "armv7l")
set(CMAKE_C_LINK_FLAGS "${CMAKE_C_LINK_FLAGS} -latomic")
set(CMAKE_CXX_LINK_FLAGS "${CMAKE_CXX_LINK_FLAGS} -latomic")
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -latomic")
endif()
if(${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD")
set(FLB_SYSTEM_FREEBSD On)
add_definitions(-DFLB_SYSTEM_FREEBSD)
set(CMAKE_C_LINK_FLAGS "${CMAKE_C_LINK_FLAGS} -lutil")
set(CMAKE_CXX_LINK_FLAGS "${CMAKE_CXX_LINK_FLAGS} -lutil")
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -lutil")
endif()

# *BSD is not supported platform for wasm-micro-runtime except for FreeBSD.
Expand Down

0 comments on commit c5cea65

Please sign in to comment.