CMake Options
Options are set with -D<option>=<value> when configuring. Their current
values, with help text, are shown by cmake -LAH -N <build-dir>, and
cmake-gui or ccmake edit them interactively. Option names are
case-sensitive.
In the tables below, auto means the option is ON by default, but is
switched off at configure time when its dependency is not found; configure
then prints a [!] ... was not found line. An option for a platform the
build is not targeting is always OFF.
General
Option |
Default |
Notes |
|---|---|---|
|
none |
|
|
|
Shared libraries instead of static ones. |
|
|
Build the test applications and register them with CTest. |
|
platform default |
Install destination. |
|
|
Build the C++ components: pjsua2 and the C++ backends (WebRTC AEC3,
libyuv, Lyra, OpenH264, Oboe, WASAPI, DirectShow, Android
MediaCodec). |
|
|
Build pjsua and the sample applications. Never built for iOS. |
|
|
Silence the experimental-status banner. |
PJLIB
Option |
Default |
Notes |
|---|---|---|
|
|
|
|
|
|
|
|
|
|
|
Floating-point support. |
|
auto (Linux) |
Use libuuid for GUID generation. |
PJNATH
Option |
Default |
Notes |
|---|---|---|
|
auto |
UPnP port mapping, with libupnp. See UPnP NAT Traversal. |
PJMEDIA
General
Option |
Default |
Notes |
|---|---|---|
|
|
Video support. |
|
|
SRTP and DTLS-SRTP, with libsrtp. |
|
|
|
|
|
Speex echo canceller. |
|
|
WebRTC echo canceller. Not available on Apple platforms, MinGW or Cygwin. |
|
|
WebRTC AEC3 echo canceller. Same availability as above. |
|
|
libyuv for video format conversion. |
|
auto, with video |
FFMPEG. Needs |
Audio codecs
Option |
Default |
Notes |
|---|---|---|
|
|
|
|
|
|
|
|
|
|
|
Bundled. |
|
|
Bundled. |
|
|
Bundled. |
|
|
Bundled. |
|
auto |
libopus. |
|
auto |
SILK SDK. |
|
auto |
opencore-amrnb. |
|
auto |
opencore-amrwb and vo-amrwbenc. |
|
auto |
bcg729. |
|
auto |
Lyra. |
|
auto (Android) |
MediaCodec audio and video codecs. |
Video codecs
Option |
Default |
Notes |
|---|---|---|
|
auto, with video |
OpenH264. |
|
auto, with video |
libvpx, VP8 and VP9. |
|
auto (Apple), with video |
VideoToolbox H.264. |
Audio devices
PJMEDIA_WITH_AUDIODEV (ON) is the master switch; OFF builds no
audio device support at all.
Option |
Default |
Platform |
|---|---|---|
|
auto |
Linux |
|
auto |
macOS, iOS |
|
|
Windows |
|
|
Windows desktop |
|
auto |
Android; needs |
|
|
Android |
|
|
All; a device that plays and records nothing |
Video devices
PJMEDIA_WITH_VIDEODEV (ON with video) is the master switch.
Option |
Default |
Notes |
|---|---|---|
|
auto |
SDL2 renderer, all platforms. |
|
|
AVI file playback as a capture device. |
|
|
FFMPEG capture. |
|
auto |
Linux capture. |
|
auto |
macOS and iOS capture (AVFoundation). |
|
|
macOS and iOS renderer. |
|
|
macOS renderer. |
|
auto |
OpenGL ES renderer, Android and iOS. |
|
|
Android capture. |
|
|
Windows capture (DirectShow). |
PJSIP
Option |
Default |
Notes |
|---|---|---|
|
|
SIP over TLS. |
|
|
Digest AKAv1/AKAv2 authentication, with the bundled milenage. |
Platform Integration
Option |
Default |
Notes |
|---|---|---|
|
|
Build the pjsua2 JNI bindings, |
|
|
Copy the built libraries into the bundled iOS sample projects. |
|
|
Also copy the generated headers into the source tree, where the sample projects look for them. |
Third-party Libraries
The libraries in third_party/ are built from source
(bundled). Those with a system provider can use an installed copy
instead, found with find_package(). none leaves the library out,
and the features that need it switch themselves off.
Option |
Values |
Library |
|---|---|---|
|
|
libsrtp. The bundled copy uses OpenSSL’s AES-GCM when OpenSSL is
found ( |
|
|
Speex codec. With |
|
|
GSM 06.10. |
|
|
G.722.1. |
|
|
libyuv. Only with |
|
|
libresample. |
|
|
iLBC. |
|
|
WebRTC AEC. Not available on Apple platforms, MinGW or Cygwin, nor
on x86 without |
|
|
WebRTC AEC3. Not available on Apple platforms, MinGW or Cygwin.
Only with |