Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
z4kn4fein committed Aug 21, 2024
1 parent ca8b5ba commit a33fce8
Showing 1 changed file with 12 additions and 11 deletions.
23 changes: 12 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,22 +33,23 @@ provides the ability to **parse**, **compare**, and **increment** semantic versi
FetchContent_MakeAvailable(cpp-semver)
```

> To use the lib as a C++20 module, you have to turn the `SEMVER_BUILD_MODULE` option `ON`:
> ```cmake
> set(SEMVER_BUILD_MODULE ON)
>
> FetchContent_Declare(#[[...]])
> ```
> Then you can import the package:
> ```cpp
> import semver;
> ```
This will produce the target `semver` which you can link against the typical way:

```cmake
target_link_libraries(your_target_name PRIVATE semver)
```

To use the lib as a **C++20 module**, you have to turn the `SEMVER_BUILD_MODULE` option `ON`:
```cmake
set(SEMVER_BUILD_MODULE ON)
FetchContent_Declare(#[[...]])
```
Then you can import the package:
```cpp
import semver;
```

3. With `vcpkg`

If you are using vcpkg for external dependencies, then you can install the package with:
Expand Down

0 comments on commit a33fce8

Please sign in to comment.