Skip to content

Commit 08d3bf4

Browse files
authored
chore: tidy up c binding build and docs (#5243)
Signed-off-by: tison <[email protected]>
1 parent f6e60f6 commit 08d3bf4

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

bindings/c/CMakeLists.txt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,15 @@
1616
# under the License.
1717

1818
cmake_minimum_required(VERSION 3.22)
19+
cmake_policy(SET CMP0135 NEW)
20+
1921
project(opendal-c)
2022

2123
if (NOT CMAKE_BUILD_TYPE)
2224
set(CMAKE_BUILD_TYPE "Debug")
2325
endif()
2426

2527
option(TEST_ENABLE_ASAN "Enable AddressSanitizer for tests" OFF)
26-
set(GOOGLETEST_VERSION 1.15.2)
2728

2829
# force the compiler to support these standards
2930
set(CMAKE_C_STANDARD 11)
@@ -35,6 +36,8 @@ set(CMAKE_CXX_STANDARD_REQUIRED ON)
3536

3637
# fetch google test via GitHub
3738
include(FetchContent)
39+
40+
set(GOOGLETEST_VERSION 1.15.2)
3841
FetchContent_Declare(
3942
googletest
4043
URL https://github.com/google/googletest/archive/refs/tags/v${GOOGLETEST_VERSION}.zip

bindings/c/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
8989
- To **build the library and header file**.
9090

9191
```sh
92-
mkdir build && cd build
92+
mkdir -p build && cd build
9393
cmake ..
9494
make
9595
```

0 commit comments

Comments
 (0)