Skip to content

Commit

Permalink
adding instructions for CMake users
Browse files Browse the repository at this point in the history
  • Loading branch information
talksik committed Jan 27, 2024
1 parent 168350f commit b7e2abd
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion misc/READMORE.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,13 +38,24 @@ There are a few compilation flags for µSockets (see its documentation), but com

You can use the Makefile on Linux and macOS. It is simple to use and builds the examples for you. `WITH_OPENSSL=1 make` builds all examples with SSL enabled. Examples will fail to listen if cert and key cannot be found, so make sure to specify a path that works for you.

### Steps
### Steps for Linux
```sh
git clone --resurse-submodules https://github.com/uNetworking/uWebSockets
make # prepend variables if desired such as `WITH_OPENSSL` as mentioned above
make install
```

_Note for Linux CMake users: make sure to include ZLIB as a dependency as well as `uSockets.a` static library (which was installed during `make install`)._

Here is an example:
```
...
find_library(USOCKETS_LIBRARY uSockets.a PATHS /usr/local/lib REQUIRED)
find_package(ZLIB REQUIRED)
target_link_libraries(${PROJECT_NAME} ${USOCKETS_LIBRARY} ZLIB::ZLIB)
...
```

## User manual

### uWS::App & uWS::SSLApp
Expand Down

0 comments on commit b7e2abd

Please sign in to comment.