This repository was archived by the owner on Feb 17, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathdebiansetup.sh
More file actions
executable file
·53 lines (45 loc) · 1.6 KB
/
debiansetup.sh
File metadata and controls
executable file
·53 lines (45 loc) · 1.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
#!/bin/bash
# debian-setup.sh
#
# This script takes care of installing all the dependencies required to
# build the obstacle avoidance code. Read the comments below for more
# specific details on what it does.
#
# REQUIREMENTS:
# - This script only works on Debian-based flavors of Linux, e.g. Ubuntu.
# - It's assumed that you're starting from a freshly cloned copy of
# the repository.
# - It's assumed that this script is being run from within the top
# directory of the repository.
# - A working internet connection is needed to install any missing
# packages as well as the git submodules.
#
# If you're having problems cloning git repos, check that ssh-agent
# has your private key loaded. For reference, see e.g.
# https://help.github.com/articles/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent/
#
if [ "$(id -u)" == "0" ]; then
echo "This script cannot be run as root" 1>&2
exit 1
fi
# Update package manager indices to latest available.
sudo apt-get update
# Program dependencies
sudo apt-get install gfortran libopencv-dev libqt4-dev libusb-1.0-0-dev libzmq3-dev -y
# Optional optimized libraries for image processing, use by dlib
sudo apt-get install libopenblas-dev liblapack-dev -y
# CMake is needed to actually build the system
sudo apt-get install cmake -y
# Clone git submodules
git submodule update --init --recursive
cd lib/protofiles
./debian_setup.sh
cd ../..
# Set up build directory
mkdir build
cd build
cmake ..
# Build & run tests. This can take a while on the first build,
# since you'll have to build, among other things, all of dlib.
make runCoreTests
./runCoreTests