Browse Source

Improve build docs (#952)

pull/953/head
Hamish Coleman 3 years ago
committed by GitHub
parent
commit
99d56a8a7b
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 3
      CMakeLists.txt
  2. 8
      doc/BuildConfig.md
  3. 2
      scripts/cmake_all.sh

3
CMakeLists.txt

@ -125,6 +125,9 @@ if(N2N_OPTION_USE_PORTMAPPING)
add_subdirectory(${THIRD_PARTY_DIR}/libnatpmp libnatpmp)
link_directories(${PROJECT_BINARY_DIR}/libnatpmp)
# Turns on the generic code for supporting either of the above
ADD_DEFINITIONS("-DHAVE_PORT_FORWARDING")
# TODO:
# - this is the odd one out, is it needed?
include_directories(${PROJECT_BINARY_DIR}/lib_miniupnpc)

8
doc/BuildConfig.md

@ -88,6 +88,9 @@ If the pcap library is available then the `n2n-decode` tool can be compiled.
One of the two UPnP libraries, this one supports the NATPMP protocol.
See also the next option.
This option depends on the library being installed - on Debian and Ubuntu,
this is `apt-get install libnatpmp-dev`
### `--enable-miniupnp`
Enables the other kind of UPnP port mapping protocol.
@ -95,6 +98,11 @@ Enables the other kind of UPnP port mapping protocol.
Turning on either of these two UPnP libraries will enable UPnP support within
the edge.
Both the natpmp and miniupnp depend on the pthread library being enabled.
This option depends on the library being installed - on Debian and Ubuntu,
this is `apt-get install libminiupnpc-dev`
### Disable Multicast Local Peer Detection
For better local peer detection, the edges try to detect local peers by sending REGISTER

2
scripts/cmake_all.sh

@ -31,7 +31,7 @@ cd build
# written in such a horrible language. Since it would be silly to rewrite
# a one-page wrapper script in python, we submit that this check is wrong.
# shellcheck disable=SC2086
cmake $OPTS ..
cmake .. $OPTS
cmake --build . --config Release

Loading…
Cancel
Save