Skip to content

Commit 1b91f0a

Browse files
committed
updated readme
1 parent 29ade17 commit 1b91f0a

File tree

1 file changed

+9
-19
lines changed

1 file changed

+9
-19
lines changed

README.md

+9-19
Original file line numberDiff line numberDiff line change
@@ -23,18 +23,13 @@ A C++20 compatible compiler. Code was only tested on x86_64.
2323

2424
### CMake
2525

26-
add
27-
```cmake
28-
FetchContent_Declare(
29-
dice-hash
30-
GIT_REPOSITORY https://github.com/dice-group/dice-hash.git
31-
GIT_TAG 0.4.4
32-
GIT_SHALLOW TRUE)
33-
34-
FetchContent_MakeAvailable(dice-hash)
26+
### conan
27+
To use it with [conan](https://conan.io/) you need to add the repository:
28+
```shell
29+
conan remote add dice-group https://conan.dice-research.org/artifactory/api/conan/tentris
3530
```
3631

37-
to your CMakeLists.txt
32+
To use it add `dice-hash/0.4.4` to the `[requires]` section of your conan file.
3833

3934
You can now add it to your target with:
4035
```cmake
@@ -43,27 +38,22 @@ target_link_libraries(your_target
4338
)
4439
```
4540

46-
### conan
47-
To use it with [conan](https://conan.io/) you need to add the repository:
48-
```shell
49-
conan remote add dice-group https://conan.dice-research.org/artifactory/api/conan/tentris
50-
```
51-
52-
To use it add `dice-hash/0.4.4` to the `[requires]` section of your conan file.
53-
5441
## build and run tests
5542

5643
```shell
5744
#get it
5845
git clone https://github.com/dice-group/dice-hash.git
5946
cd dice-hash
6047
#build it
48+
wget https://github.com/conan-io/cmake-conan/raw/develop2/conan_provider.cmake -O conan_provider.cmake
6149
mkdir build
6250
cd build
63-
cmake -DBUILD_TESTING -DCMAKE_BUILD_TYPE=Release ..
51+
cmake -DBUILD_TESTING -DCMAKE_BUILD_TYPE=Release .. -DCMAKE_PROJECT_TOP_LEVEL_INCLUDES=conan_provider.cmake
6452
make -j tests_dice_hash
6553
./test/tests_dice_hash
6654
```
55+
Note: This example uses conan as dependency provider, other providers are possible.
56+
See https://cmake.org/cmake/help/latest/guide/using-dependencies/index.html#dependency-providers
6757

6858
## usage
6959
You need to include a single header:

0 commit comments

Comments
 (0)