3.Installing Quasar dependencies - ahmedqamesh/quasar-mops-server GitHub Wiki
Quasar framework requires some dependencies which are described in details at Quasar dependencies.
In this twiki we shows how can you install all the Quasar dependancies for both:
-
The Linux system CentOS7 Kernel available on armv7hl-32.
-
The Linux system CentOS7 Kernel available on x86_64 or _32.
all what you need to do is to follow the following steps:
- Install side packages
- Build Quasar dependencies based on your kernel architecture.
-
Installing yum Libraries
yum is the primary tool for getting, installing, deleting, querying, and managing Red Hat Enterprise Linux RPM software packages from official Red Hat software repositories, as well as other third-party repositories.
-
Update the environment:
In order to make sure that we are working with the most up to date environment possible in terms of our packages, we can run the following commandyum update -y
- Installing Pip Package Once you’ve confirmed that Python is correctly installed, you can proceed with installing Pip.
- Download get-pip.py to a folder on your computer [Alternatively,
you can use curl "https://bootstrap.pypa.io/get-pip.py" -o "get-pip.py"
]. - Open a command prompt and navigate to the folder containing get-pip.py.
- Run the following command:Pip is now installed! To install a new package
python get-pip.py
pip install [package name]
-
Installing Python Packages
pip install lxml http-parser tqdm kafe seaborn aenum verboselogs qtawesome coloredlogs termcolor progressbar-latest pyvisa pyvisa-py pyqtgraph
Before building the libraries, one needs to check the exact kernel architecture of the device using uname -m
or to find the processor model in vi /proc/cpuinfo
Note that: The processor part of the used ZedBoard with Linux system CentOS7 Kernel 4.14.0-xilinx on an armv7hl-32:
-
Get Eclipse, preferably the C/C++ Developers version (e.g. https://www.eclipse.org/downloads/) Once installed, install Eclipse add-ons for XML editors.
-
Issue this to install software from the official CC7 RPM repos:
sudo yum install gcc-c++ gdb python-devel python3-devel boost-devel boost-regex boost-program-options boost-signals jre cmake graphviz valgrind doxygen rpm-build subversion xsd openssl-devel libxml2-devel xerces-c-devel python2-pip libgit2 libgit2-devel bzip2 libxslt-devel libevent-devel kdiff3 python-cffi libffi-devel
-
Installing CMake:
. There are pre-compiled binaries available on the Download page for some UNIX platforms. One may alternatively download and build CMake from source. The Download page provides source releases.(Note: the make install step is optional, cmake will run from the build directory.)wget https://github.com/Kitware/CMake/releases/download/v3.18.0-rc2/cmake-3.18.0-rc2.tar.gz tar xvfz cmake-3.18.0-rc2.tar.gz ./bootstrap --prefix=/path/to/build/directory sudo gmake make install
-
Recommended Python libraries
- While pip alone is sufficient to install from pre-built binary archives, up to date copies of the setuptools and wheel projects are useful to ensure you can also install from source archives:
python -m pip install --upgrade pip setuptools wheel
- Other requirements for quasar:WARNING: the version of pygit2 should match the version of libgit2-devel! At the time of writing it was 0.26.4.
sudo pip install enum34 pygit2==0.26.4 colorama Jinja2 lxml
- Install Artistic Style Libraries:
- Download astyle program
- Unzip the downloaded file:
tar xvfz astyle_3.1_linux.tar.gz
- To build the console release version:
mkdir as-gcc-exe cd as-gcc-exe cmake ../ make
- To build the shared debug version:
mkdir --parents as-gcc-so cd as-gcc-so cmake -DBUILD_SHARED_LIBS=1 -DCMAKE_BUILD_TYPE=Debug ../ make
- To build the Java release version using the Clang compiler:
mkdir as-clang-java cd as-clang-java CXX=clang++ CC=clang cmake -DBUILD_JAVA_LIBS=1 ../ make
- Download UaExpert for an universal test&dev tool for OPC-UA.
-
repeat the first 5 steps used in the first section (For CentOS Users (x86_64 or _32)). Some libraries will be missing during installation and we need to install in differently [All the needed libraries for armv7hl-32 are available on armhfp/epel].
-
Issue this to install software from the official CC7 RPM repos:
sudo yum install -y libxml2 libxml2-devel libxml2-python libxslt libxslt-devel
- Install KDiff3 program:
- Download KDiff3 program
- Unzip the downloaded file:
tar xvfz kdiff3-0.9.98.tar.gz
- from the KDiff3 source directory run:
./configure kde4
or./configure qt4
.
-
Install XSD Libraries:
Simply run the attached file/packages/xsd-4.0.0-25.el7.armv7hl.sh
-
Install libssh Libraries:
libssh is a C library that is needed to write a program that uses the SSH protocol.
wget https://www.libssh2.org/download/libssh2-1.9.0.tar.gz
tar xzf libssh2-1.9.0.tar.gz
cd libssh2-1.9.0
mkdir bin
cd bin
cmake ..
cmake --build .
Or
./configure
make
make install
- Install libgit2 Libraries:
libgit2 is a portable, pure C implementation of the Git core methods provided as a re-entrant linkable library with a solid API, allowing you to write native speed custom Git applications in any language which supports C bindings.
-
Download
wget https://github.com/libgit2/libgit2/archive/v0.26.0.tar.gz tar xzf v0.26.0.tar.gz
-
Build the libraries
cd libgit2-0.26.0 mkdir libgit_build cd libgit_build cmake .. cmake --build .
-
Install:
mkdir libgit_install export LIBGIT2=/root/Installation/libgit2-0.26.0/libgit_install cmake .. -DCMAKE_INSTALL_PREFIX=$LIBGIT2 cmake --build . --target install
-
check the installation:
whereis libgit2 libgit2: /usr/lib/libgit2.so /usr/local/lib/libgit2.so
-
set the enviroment:
env LIBGIT_BUILD=/root/Installation/libgit2-0.26.0/libgit_build
This should give
XDG_SESSION_ID=1
HOSTNAME=localhost
TERM=vt220
SHELL=/bin/bash
HISTSIZE=1000
QT_GRAPHICSSYSTEM_CHECKED=1
USER=root
LS_COLORS=
MAIL=/var/spool/mail/root
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/bin:/root/bin
PWD=/root/Installation/libgit2
LANG=en_US.UTF-8
HISTCONTROL=ignoredups
SHLVL=1
HOME=/root
LOGNAME=root
LESSOPEN=||/usr/bin/lesspipe.sh %s
XDG_RUNTIME_DIR=/run/user/0
_=/bin/env
OLDPWD=/root/Installation/libgit2/libgit_build
- Install pygit2:
Pygit2 is a set of Python bindings to the libgit2 shared library, libgit2 implements the core of Git. The version number of pygit2 is composed of three numbers separated by dots « major.minor.micro », where the first two numbers « major.minor » match the first two numbers of the libgit2 version. [Here we will use libgit2-0.26.0 with pygit2-0.26.0]
export LDFLAGS="-Wl,-rpath='$LIBGIT2/lib',--enable-new-dtags $LDFLAGS"
pip install pygit2==0.26.0