Building instructions (Linux, Ubuntu 16.04)
Open, NormalPublic

Description

Prerequisites:

  • Install CMake and GUI (install cmake and cmake-qt-gui through your package manager)
  • Install Qt 5.6 (download and run the Qt Online Installer for Linux from https://qt.io/)

CMake:

  • Open CMake GUI (Run cmake-gui from terminal)
  • Select OC root folder for source code location and some folder for build output
  • Click "Configure"
  • Dialog opens which will ask for which compiler it should configure the project, select Unix Makefiles and Use default native compilers
  • If CMake complains about not being able to find Qt5 modules then point it to the right module folder, see the screenshot for examples
  • Click "Generate"
  • CMake generates Makefiles for OC in build output folder

Make:

  • Open terminal and navigate into your build folder
  • Run make or make -jX (where X is your number of processor cores)
simonrepp updated the task description. (Show Details)
simonrepp raised the priority of this task from to Needs Triage.
simonrepp added a project: Open Cine.
simonrepp moved this task from Pending tasks to Documentation on the Open Cine board.
simonrepp added a subscriber: simonrepp.
sebix added a subscriber: sebix.Dec 20 2016, 10:24 PM
simonrepp triaged this task as Normal priority.Dec 26 2016, 6:53 PM

Will try to integrate steps into automatic install script for OC development VM.

BAndiT1983 added a comment.EditedFeb 26 2017, 11:23 PM

Current script, space for improvement:

#!/bin/bash

qt_install="qt-opensource-linux-x64-5.8.0.run"

echo "Setup of OpenCine dev environment"
echo "-----------------------------------------"

echo
echo "--- Install required packages ---"
sudo apt-get install git cmake build-essential freeglut3-dev

echo
echo "-----------------------------------------"
echo "--- Download Qt installer ---"
if [ ! -f "$qt_install" ];
then
    wget http://download.qt.io/official_releases/qt/5.8/5.8.0/$qt_install
else
    echo "Qt installer already available"
fi

# Check if a folder starting with "Qt" exists, usual sign for available Qt installation
chmod +x $qt_install
if [ $(find "~/" -maxdepth 1 -type d -name "Qt*") == "0" ] ;
then
    ./$qt_install
else
    echo "Qt already installed."
fi

echo
echo "-----------------------------------------"
echo "--- Clone OpenCine repository ---"
if [ ! -d "../Source/OpenCine" ];
then
    echo "Cloning repository"
    mkdir ~/Source
    git clone https://github.com/apertus-open-source-cinema/opencine.git ~/Source/OpenCine
    cd ~/Source/OpenCine    
else
    echo "Repository exists, updating"
    cd  ~/Source/OpenCine    
    git pull
fi

echo
echo "-----------------------------------------"
echo "--- CMake configuration ---"
cmake -DCMAKE_PREFIX_PATH=~/Qt/5.8/gcc_64/lib/cmake/ ./

echo
echo "-----------------------------------------"
echo "--- Build ---"
make -j4

echo
echo "-----------------------------------------"
echo "--- Finished successfully ---"