updated building documentation (#911)

* Update README.md

update readme.md

* moved detailed content to doc folder

Co-authored-by: Logan oos Even <Logan.00sEven@gmail.com>
This commit is contained in:
skyformat99 2021-12-25 03:33:39 +08:00 committed by GitHub
parent b657881a92
commit bc4789ae0e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 15 additions and 4 deletions

View File

@ -64,9 +64,7 @@ make
make install make install
``` ```
Some parts of the code significantly benefit from compiler optimizations and platform features such as NEON, SSE and AVX. To enable, use `./configure CFLAGS="-O3 -march=native"` for configuration instead of `./configure`. For Windows, MacOS, CMake, optimizations and general building options, please check out [Building documentation](doc/Building.md) for compilation and running.
For Windows, MacOS and general building options, please check out [Building documentation](doc/Building.md) for compilation and running.
**IMPORTANT** It is generally recommended to use the [latest stable release](https://github.com/ntop/n2n/releases). Please note that the current _dev_ branch usually is not guaranteed to be backward compatible neither with the latest stable release nor with previous _dev_ states. On the other hand, if you dare to try bleeding edge features, you are encouraged to compile from _dev_ just keep track of sometimes rapidly occuring changes. Feedback in the _Issues_ section is appreciated. **IMPORTANT** It is generally recommended to use the [latest stable release](https://github.com/ntop/n2n/releases). Please note that the current _dev_ branch usually is not guaranteed to be backward compatible neither with the latest stable release nor with previous _dev_ states. On the other hand, if you dare to try bleeding edge features, you are encouraged to compile from _dev_ just keep track of sometimes rapidly occuring changes. Feedback in the _Issues_ section is appreciated.

View File

@ -48,6 +48,16 @@ In order to build from the command line, open a terminal window change to
the directory where the git checkout of this repository is and run the the directory where the git checkout of this repository is and run the
following commands: following commands:
The `libnatpmp` and `libminiupnp` have been moved to separated repositories.
So the very first time, you should run this command in the n2n directory to
install them:
```bash
git submodule update --init --recursive
```
Building using `cmake` works as follows:
```batch ```batch
cmake -E make_directory build cmake -E make_directory build
cd build cd build
@ -114,7 +124,10 @@ The `tools/n2n-benchmark` tool reports speed-ups of 200% or more! There is no kn
## Hardware Features ## Hardware Features
Some parts of the code can be compiled to benefit from available hardware acceleration. It needs to be decided at compile-time. So, if compiling for a specific platform with known features (maybe the local one), it should be specified to the compiler, for example through the `-march=sandybridge` (you name it) or just `-march=native` for local use. Some parts of the code significantly benefit from compiler optimizations (`-O3`) and platform features
such as NEON, SSE and AVX. It needs to be decided at compile-time. Hence if compiling for a specific
platform with known features (maybe the local one), it should be specified to the compiler for
example through the `-march=sandybridge` (you name it) or just `-march=native` for local use.
So far, the following portions of n2n's code benefit from hardware features: So far, the following portions of n2n's code benefit from hardware features: