diff --git a/core/shared/utils/bh_list.h b/core/shared/utils/bh_list.h index eaf15f2f..f1021532 100644 --- a/core/shared/utils/bh_list.h +++ b/core/shared/utils/bh_list.h @@ -59,7 +59,7 @@ bh_list_init(bh_list *list); * BH_LIST_ERROR if input is invalid or no memory * available. */ -extern bh_list_status +bh_list_status bh_list_insert(bh_list *list, void *elem); /** diff --git a/doc/build_wamr.md b/doc/build_wamr.md index 555ca2ac..29866405 100644 --- a/doc/build_wamr.md +++ b/doc/build_wamr.md @@ -77,6 +77,10 @@ cmake -DWAMR_BUILD_PLATFORM=linux -DWAMR_BUILD_TARGET=ARM - **WAMR_BUILD_LIB_PTHREAD**=1/0, default to disable if not set > Note: The dependent feature of lib pthread such as the `shared memory` and `thread manager` will be enabled automatically. +#### **Enable lib-pthread-semaphore** +- **WAMR_BUILD_LIB_PTHREAD_SEMAPHORE**=1/0, default to disable if not set +> Note: This feature depends on `lib-pthread`, it will be enabled automatically if this feature is enabled. + #### **Disable boundary check with hardware trap in AOT or JIT mode** - **WAMR_DISABLE_HW_BOUND_CHECK**=1/0, default to enable if not set and supported by platform > Note: by default only platform linux/darwin/android/vxworks 64-bit will enable boundary check with hardware trap in AOT or JIT mode, and the wamrc tool will generate AOT code without boundary check instructions in all 64-bit targets except SGX to improve performance. diff --git a/samples/multi-thread/CMakeLists.txt b/samples/multi-thread/CMakeLists.txt index 63c14eeb..39485e1c 100644 --- a/samples/multi-thread/CMakeLists.txt +++ b/samples/multi-thread/CMakeLists.txt @@ -45,6 +45,7 @@ set(WAMR_BUILD_JIT 0) set(WAMR_BUILD_LIBC_BUILTIN 1) set(WAMR_BUILD_FAST_INTERP 1) set(WAMR_BUILD_LIB_PTHREAD 1) +set(WAMR_BUILD_LIB_PTHREAD_SEMAPHORE 1) # compiling and linking flags set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -pie -fPIE")