Building & running server v2.3.0 LTS on Ubuntu 20.04

@didikunz one would think so, right?.. but I don’t have that button. Maybe because the post is too old?

Things changed again :sweat_smile:
Now if you follow the first link, you will be redirected to the Spotify main page.
The second link’s no more available.
But http://opensource.spotify.com now is available again, although it just redirects to https://www.spotify.com/us/opensource which provides a list of links for CEF sources downloading.

Probably because it’s marked as a solution?

Sorry for the off topic input… The forum lets you edit your posts only for a couple of days (maybe weeks), after that the posts get locked and the edit button dissapears.
Same thing happened to me with the launcher thread.

@silencedis the second link still works for me:

https://cef-builds.spotifycdn.com/cef_binary_3.3578.1870.gc974488_linux64_minimal.tar.bz2

In case anyone is interested, here are the steps I’ve followed to build CasparCG server v2.3.0 LTS for Ubuntu 20.04. The build is done inside Docker container so as not to pollute your system.

WARNING: This is work in progress, so some things may not work.

docker run -it --name casparcg nvidia/opengl:1.2-glvnd-devel-ubuntu20.04 /bin/bash

## inside container ##
apt update
apt dist-upgrade

# base
apt install --no-install-recommends git ca-certificates cmake build-essential g++ wget libglew-dev libfreeimage-dev libtbb-dev libsndfile1-dev libopenal-dev libjpeg-dev libfreetype6-dev libxcursor-dev libxinerama-dev libxi-dev libsfml-dev libvpx-dev libwebp-dev liblzma-dev libmp3lame-dev libopus-dev libtheora-dev libx264-dev libx265-dev libbz2-dev libcrypto++-dev librtmp-dev libgmp-dev libxcb-shm0-dev libass-dev libgconf2-dev libnss3 libnspr4 libxtst6 libatspi2.0-dev libatk-bridge2.0-dev libxcomposite1

# boost
apt install --no-install-recommends libboost-system1.67-dev libboost-thread1.67-dev libboost-chrono1.67-dev libboost-filesystem1.67-dev libboost-log1.67-dev libboost-locale1.67-dev libboost-regex1.67-dev libboost-date-time1.67-dev libboost-coroutine1.67-dev

# ffmpeg
apt install --no-install-recommends libavcodec-dev libavformat-dev libavdevice-dev libavutil-dev libswscale-dev libpostproc-dev libswresample-dev

# cef
cd /opt
wget https://cef-builds.spotifycdn.com/cef_binary_3.3578.1870.gc974488_linux64_minimal.tar.bz2 -O cef.tar.bz2
tar -xvjf cef.tar.bz2
mv cef_binary_* cef

mkdir -p /opt/build/cef
cd /opt/build/cef
cmake /opt/cef
make CXX_FLAGS="-Wno-attributes" -j8

cp libcef_dll_wrapper/libcef_dll_wrapper.a /opt/cef/Release/
strip /opt/cef/Release/libcef.so

# server
cd /opt
git clone https://github.com/CasparCG/server.git -b v2.3.0-lts-stable --depth 1 server

sed -i -e "s/Boost 1.66.0/Boost 1.67.0/" server/src/CMakeModules/Bootstrap_Linux.cmake
sed -i -e "s/pthread$/pthread X11/" server/src/shell/CMakeLists.txt

mkdir -p /opt/build/server
cd /opt/build/server
cmake /opt/server/src/
make -j8

exit

## outside container ##
docker cp casparcg:/opt/build/server/staging server
docker rm casparcg

If everything went well, you should have server v2.3.0 LTS built inside the server folder. You might need to install a few missing packages (eg, libsfml-graphics2.5) on your system, if it fails to run.

NB: This version of the server uses native boost and ffmpeg packages.

1 Like

@didikunz @rrebuffo well, I’ve just created a new post with updated link and accepted it as a solution :sunglasses:

So does this run inside a docker or outside of it.

@bifuteki outside.

So i can do this without being in a docker. I dont mind it polluting my system as I want it to only run caspar

@bifuteki was that a question?

Sorry, it was. Will I be able to just install this not in a docker and just have it dedicated to CasparCG only?

@bifuteki correct, docker is only used to build CasparCG Server. At the end it’s extracted from the container and is ready to be run on the host system. At that point you can uninstall docker.

Yep, now it works again :exploding_head:

Hi there
I followed your whole steps to build the ccg server on ubuntu 20.04.
But when I run the ./run.sh command, the terminal answers :
Type “q” to close application.
Aborted (core dumped)
Have you got an idea of my error ?
Thanks

It’s hard to tell without any logs. Please post contents of the terminal, hopefully that will shed some light on it. D-mo

please find out my terminal logs
log.htm (523.5 KB)

Not the build log and please post it in a code block.

Sorry about this.
I finally succeeded to launch CCG, after lots of try.
It was simply in the need of a root permission.
Do you know how to build the media-scanner (that is quite usefull) ?

Here are the scripts for the scanner. I wrote them a while ago and haven’t tested since. Save them into build-scanner and extract-scanner files, make executable and run one after another.

build-scanner

#!/bin/bash
docker build --tag casparcg/scanner - <<EOF
    FROM node:8.9.4

    WORKDIR /opt
    RUN git clone https://github.com/CasparCG/media-scanner.git --depth 1 scanner

    WORKDIR /opt/scanner
    RUN npm install && npm run build-linux
    RUN mv ./dist /scanner
EOF

extract-scanner

#!/bin/bash
id=$(docker create casparcg/scanner)
docker cp $id:/scanner .
docker rm -v $id