You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
cmake --build . --parallel 8 # or without the number if you feel extra adventurous
124
-
```
118
+
```sh
119
+
mkdir build &&cd build
120
+
```
125
121
126
-
> [!TIP]
127
-
> You can omit the `-o '&:tests=True'` if you don't want to build `clio_tests`.
122
+
2. Install dependencies through conan
128
123
129
-
If successful, `conan install` will find the required packages and `cmake` will do the rest. You should see `clio_server` and `clio_tests` in the `build` directory (the current directory).
124
+
```sh
125
+
# You can also specify profile explicitly by adding `--profile:all <PROFILE_NAME>`
> To generate a Code Coverage report, include `-o '&:coverage=True'` in the `conan install` command above, along with `-o '&:tests=True'` to enable tests.
133
-
> After running the `cmake` commands, execute `make clio_tests-ccov`.
134
-
> The coverage report will be found at `clio_tests-llvm-cov/index.html`.
129
+
If successful, `conan install` will find the required packages and `cmake` will do the rest.
135
130
136
-
<!-- markdownlint-disable-line MD028 -->
131
+
3. Configure and generate build files with CMake
137
132
138
-
> [!NOTE]
139
-
> If you've built Clio before and the build is now failing, it's likely due to updated dependencies. Try deleting the build folder and then rerunning the Conan and CMake commands mentioned above.
133
+
```sh
134
+
# You can also add -GNinja to use Ninja build system instead of Make
4. Now, you can build all targets or specific ones:
142
139
143
-
The API documentation for Clio is generated by [Doxygen](https://www.doxygen.nl/index.html). If you want to generate the API documentation when building Clio, make sure to install Doxygen 1.12.0 on your system.
140
+
```sh
141
+
# builds all targets
142
+
cmake --build . --parallel 8
143
+
# builds only clio_server target
144
+
cmake --build . --parallel 8 --target clio_server
145
+
```
144
146
145
-
To generate the API docs:
147
+
You should see `clio_server` and `clio_tests` in the `build` directory (the current directory).
146
148
147
-
1. First, include `-o '&:docs=True'` in the conan install command. For example:
149
+
> [!NOTE]
150
+
> If you've built Clio before and the build is now failing, it's likely due to updated dependencies. Try deleting the build folder and then rerunning the Conan and CMake commands mentioned above.
|`-Dpackage`| OFF | N/A | Creates a debian package |
160
166
161
-
3. Go to `build/docs/html` to view the generated files.
167
+
### Generating API docs for Clio
162
168
163
-
Open the `index.html` file in your browser to see the documentation pages.
169
+
The API documentation for Clio is generated by [Doxygen](https://www.doxygen.nl/index.html). If you want to generate the API documentation when building Clio, make sure to install Doxygen 1.12.0 on your system.
164
170
165
-

171
+
To generate the API docs, please use CMake option `-Ddocs=ON` as described above and build the `docs` target.
172
+
173
+
To view the generated files, go to `build/docs/html`.
174
+
Open the `index.html` file in your browser to see the documentation pages.
175
+
176
+

166
177
167
178
## Building Clio with Docker
168
179
@@ -171,12 +182,11 @@ It is also possible to build Clio using [Docker](https://www.docker.com/) if you
171
182
```sh
172
183
docker run -it ghcr.io/xrplf/clio-ci:0e8896ad064a5290c4805318b549df16403ca2d7
cmake --build . --parallel 8 # or without the number if you feel extra adventurous
185
+
cd clio
178
186
```
179
187
188
+
And then follow the same steps as in [Building Clio](#building-clio), use `--profile:all gcc` or `--profile:all clang` with `conan install` command to choose the desired compiler.
189
+
180
190
## Developing against `rippled` in standalone mode
181
191
182
192
If you wish to develop against a `rippled` instance running in standalone mode there are a few quirks of both Clio and `rippled` that you need to keep in mind. You must:
@@ -226,13 +236,13 @@ Sometimes, during development, you need to build against a custom version of `li
226
236
227
237
See [Building Clio](#building-clio) for details.
228
238
229
-
## Using `clang-tidy` for static analysis
239
+
## Using `clang-tidy` for static analysis {#clang-tidy}
230
240
231
241
Clang-tidy can be run by CMake when building the project.
232
-
To achieve this, you just need to provide the option `-o '&:lint=True'` for the `conan install` command:
242
+
To achieve this, you just need to provide the option `-Dlint=ON` when generating CMake files:
0 commit comments