Difference between revisions of "GstKinesisWebRTC/Building GstKinesisWebRTC/Dependencies"

From RidgeRun Developer Connection
Jump to: navigation, search
(Amazon Kinesis Video Streams C WebRTC SDK)
m
 
(3 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
<noinclude>
 
<noinclude>
{{GstKinesisWebRTC/Head|previous=Building GstKinesisWebRTC|next=Building GstKinesisWebRTC/Building and Installing}}
+
{{GstKinesisWebRTC/Head|previous=Building GstKinesisWebRTC|next=Building GstKinesisWebRTC/Building and Installing|metakeywords=GstKinesisWebRTC Dependencies, Websockets, LibkvsCommonLws, OpenSSL, SRTP, Libwebsockets, Amazon Kinesis Video Streams C WebRTC SDK, Amazon Kinesis Video Streams, C WebRTC SDK, WebRTC SDK}}
 
</noinclude>
 
</noinclude>
  
Line 6: Line 6:
  
 
=== GStreamer ===
 
=== GStreamer ===
The project needs gstreamer core, gstramer plugins base and gstreamer app. You can installed with:
+
The project needs gstreamer core, gstramer plugins base and gstreamer app. You can install it with:
 
<syntaxhighlight lang=bash>
 
<syntaxhighlight lang=bash>
 
sudo apt-get install libgstreamer1.0-0 libgstreamer-plugins-base1.0-0 gstreamer1.0-plugins-base-apps
 
sudo apt-get install libgstreamer1.0-0 libgstreamer-plugins-base1.0-0 gstreamer1.0-plugins-base-apps
Line 30: Line 30:
  
 
=== Websockets ===
 
=== Websockets ===
Websockets should be installed manually since the required version is newer than Ubuntu package version. You can follow the next steps:
+
WebSockets should be installed manually since the required version is newer than the Ubuntu package version. You can follow the next steps:
  
 
* Download the code of both Libwebsockets and Amazon Kinesis WebRTC Stream SDK. The latter contains patches that need to be applied to libwebsockets:
 
* Download the code of both Libwebsockets and Amazon Kinesis WebRTC Stream SDK. The latter contains patches that need to be applied to libwebsockets:
Line 100: Line 100:
 
<syntaxhighlight lang=bash>
 
<syntaxhighlight lang=bash>
 
git clone https://github.com/awslabs/amazon-kinesis-video-streams-producer-c.git
 
git clone https://github.com/awslabs/amazon-kinesis-video-streams-producer-c.git
 +
cd amazon-kinesis-video-streams-producer-c
 
git checkout  c7fce9e06021452ff3c42dc70c8360606b22ad53
 
git checkout  c7fce9e06021452ff3c42dc70c8360606b22ad53
 
</syntaxhighlight>
 
</syntaxhighlight>
Line 122: Line 123:
 
=== Amazon Kinesis Video Streams C WebRTC SDK ===
 
=== Amazon Kinesis Video Streams C WebRTC SDK ===
  
The code is stored in a github repository and you have already downloaded it for the Libwebsockets step:
+
The code is stored in a GitHub repository and you have already downloaded it for the Libwebsockets step:
  
 
<syntaxhighlight lang=bash>
 
<syntaxhighlight lang=bash>
Line 129: Line 130:
 
</syntaxhighlight>
 
</syntaxhighlight>
  
This instructions were run for version v.1.7.4
+
This instruction were run for version v.1.7.4
 
To build the code run the following commands:
 
To build the code run the following commands:
  
Line 139: Line 140:
 
sudo make install
 
sudo make install
 
</syntaxhighlight>
 
</syntaxhighlight>
 
 
 
 
 
 
 
  
  

Latest revision as of 09:23, 23 June 2023



Previous: Building GstKinesisWebRTC Index Next: Building GstKinesisWebRTC/Building and Installing






GStreamer

The project needs gstreamer core, gstramer plugins base and gstreamer app. You can install it with:

sudo apt-get install libgstreamer1.0-0 libgstreamer-plugins-base1.0-0 gstreamer1.0-plugins-base-apps

OpenSSL

Can be installed with:

sudo apt install libssl-dev

Quilt

Can be installed with:

sudo apt install quilt

Cmake

Can be installed with:

sudo apt install cmake

Websockets

WebSockets should be installed manually since the required version is newer than the Ubuntu package version. You can follow the next steps:

  • Download the code of both Libwebsockets and Amazon Kinesis WebRTC Stream SDK. The latter contains patches that need to be applied to libwebsockets:
git clone https://github.com/awslabs/amazon-kinesis-video-streams-webrtc-sdk-c.git
cd amazon-kinesis-video-streams-webrtc-sdk-c
git checkout v1.7.3
cd ..
git clone https://github.com/warmcat/libwebsockets.git
cd libwebsockets
git checkout v4.2.2
  • Apply patches included in amazon-kinesis-video-streams-webrtc-sdk-c
mkdir patches
cp ../amazon-kinesis-video-streams-webrtc-sdk-c/CMake/Dependencies/libwebsockets-old-gcc-fix-cast-cmakelists.patch patches/
cp ../amazon-kinesis-video-streams-webrtc-sdk-c/CMake/Dependencies/libwebsockets-leak-pipe-fix.patch patches/
echo libwebsockets-old-gcc-fix-cast-cmakelists.patch >> patches/series
echo libwebsockets-leak-pipe-fix.patch >> patches/series
quilt push -a
  • Configure
mkdir build 
cd  build
cmake .. -DCMAKE_INSTALL_PREFIX=/usr
  • Build
make
  • Install
sudo make install

SRTP

Can be installed with:

sudo apt install libsrtp2-dev

usrsctp

Fox x86 can be installed with:

sudo apt install libusrsctp-dev

But for jetson nano it is not found in the repositories, so you need to build it from code as follows:

git clone https://github.com/sctplab/usrsctp.git
cd  usrsctp/
git checkout 1ade45cbadfd19298d2c47dc538962d4425ad2dd
mkdir build
cd build/
cmake .. -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_C_FLAGS=-fPIC -Dsctp_werror=0
make
sudo make install

LibkvsCommonLws

This is a custom Amazon library part of the project Amazon Kinesis Video Streams C Producer. To build it follow the next instructions:

  • Download the code
git clone https://github.com/awslabs/amazon-kinesis-video-streams-producer-c.git
cd amazon-kinesis-video-streams-producer-c
git checkout  c7fce9e06021452ff3c42dc70c8360606b22ad53
  • Configure
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=/usr .. -DBUILD_DEPENDENCIES=OFF -DBUILD_COMMON_LWS=ON -DBUILD_COMMON_CURL=OFF
  • Build
make
  • Install
sudo make install

Amazon Kinesis Video Streams C WebRTC SDK

The code is stored in a GitHub repository and you have already downloaded it for the Libwebsockets step:

AMAZON_SDK_DIR=<path where the amazon-kinesis-video-streams-webrtc-sdk-c was downloaded>
cd $AMAZON_SDK_DIR

This instruction were run for version v.1.7.4 To build the code run the following commands:

mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=/usr .. -DBUILD_DEPENDENCIES=OFF
make
sudo make install



Previous: Building GstKinesisWebRTC Index Next: Building GstKinesisWebRTC/Building and Installing