forked from Tereius/libONVIF
-
Notifications
You must be signed in to change notification settings - Fork 0
/
INSTALL
34 lines (24 loc) · 1.34 KB
/
INSTALL
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
How to build and install libONVIF binaries
===========================================
This projects uses CMake (see www.cmake.org).
You may want to use "CommonLibs" (https://github.com/Tereius/CommonLibs) to build the dependencies (OpenSSL, Qt5).
This is especially useful for Windows hosts which lack a package manager like "apt". "CommonLibs" is an optional
dependency and CMake won't fail if "CommonLibs" is missing.
The minimal project setup for "Unix Makefiles" would be:
cd /opt
git clone https://github.com/Tereius/libONVIF.git
mkdir /opt/build_libonvif
cd /opt/build_libonvif
cmake -G "Unix Makefiles" -DCMAKE_BUILD_TYPE:STRING=Debug /opt/libONVIF
make
make install
If CMake is missing a dependency you have to set the variable (pointing to a path) manually e.g. for OpenSSL:
cmake -G "Unix Makefiles" -DOpenSSL_cryptro_PATH:PATH="/usr/lib/x86_64-linux-gnu/libcrypto.so" -DOpenSSL_ssl_PATH:PATH="usr/lib/x86_64-linux-gnu/libssl.so" -DOpenSSL_include_DIR:PATH="/usr/include" /opt/libONVIF
To print the relevant variables you may want to change use:
cd <src_path>
cmake -LH
For Windows use a CMake generator like "NMake Makefiles" or "Visual Studio [...]" e.g.:
cd <build_path>
cmake -G "NMake Makefiles" -DCMAKE_BUILD_TYPE:STRING=Debug <src_path>
cmake --build ./
cmake --build ./ --target install