Skip to content

Commit

Permalink
update readme (#105)
Browse files Browse the repository at this point in the history
  • Loading branch information
copperlight authored Nov 23, 2024
1 parent 48cbb7f commit 211b1e6
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 8 deletions.
20 changes: 13 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,17 +24,14 @@ binary.
* The [`udp_numbers.pl`](./tools/udp_numbers.pl) script is used to automate running `metrics_gen`
with different kernel settings for UDP sockets.

## Local Development
## Local & IDE Configuration

```shell
# setup python venv and activate, to gain access to conan cli
./setup-venv.sh
source venv/bin/activate

# link clion default build directory to our build directory
ln -s cmake-build cmake-build-debug

./build.sh # [clean|clean --force|skiptest]
./build.sh # [clean|clean --confirm|skiptest]

# run the binary locally
./cmake-build/bin/spectatord_main --enable_external --no_common_tags
Expand All @@ -49,8 +46,17 @@ echo "c:server.numRequests,nf.app=spectatord_$USER,id=failed" | nc -u -w0 localh
echo "c::1" | nc -u -w0 localhost 1234
```

* CLion > Preferences > Plugins > Marketplace > Conan > Install
* CLion > Preferences > Build, Execution, Deploy > Conan > Conan Executable: $PROJECT_HOME/venv/bin/conan
* Install the Conan plugin for CLion.
* CLion > Settings > Plugins > Marketplace > Conan > Install
* Configure the Conan plugin.
* The easiest way to configure CLion to work with Conan is to build the project first from the command line.
* This will establish the `$PROJECT_HOME/CMakeUserPresets.json` file, which will allow you to choose the custom
CMake configuration created by Conan when creating a new CMake project. Using this custom profile will ensure
that sources are properly indexed and explorable.
* Open the project. The wizard will show three CMake profiles.
* Disable the default Cmake `Debug` profile.
* Enable the CMake `conan-debug` profile.
* CLion > View > Tool Windows > Conan > (gear) > Conan Executable: `$PROJECT_HOME/venv/bin/conan`

## Errata

Expand Down
2 changes: 1 addition & 1 deletion build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ set -e
# usage: ./build.sh [clean|clean --confirm|skiptest]

BUILD_DIR=cmake-build
# Choose: Debug, Release, RelWithDebInfo and MinSizeRel
# Choose: Debug, Release, RelWithDebInfo and MinSizeRel. Use Debug for asan checking locally.
BUILD_TYPE=Debug

BLUE="\033[0;34m"
Expand Down

0 comments on commit 211b1e6

Please sign in to comment.