-
Notifications
You must be signed in to change notification settings - Fork 116
/
prepare_for_dev_debian_testing.sh
executable file
·95 lines (67 loc) · 3.02 KB
/
prepare_for_dev_debian_testing.sh
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
#!/bin/sh
#
echo "Warning! This script pulls, compiles and installs development version of mandelbulber2
THERE IS NO WARRANTY THAT THE PROGRAM WILL WORK PROPERLY,
because the code can contain partially developed functions
This script will ask about root password to perform installation of system packages and the program
To update the program do not remove already downloaded files. This script will pull only the latest changes."
export CXXFLAGS="-march=native -msse2"
MANDELBULBER_SHARE="/usr/share/mandelbulber2"
set -e # if any of the commands fail the script will exit immediately
echo "
installing all needed packages
"
echo "installing: build-essential qtbase5-dev qtchooser qt5-qmake qtbase5-dev-tools qttools5-dev libqt5gui5 qtmultimedia5-dev \
libpng16-16 libpng-dev libgomp1 libgsl-dev libsndfile1-dev libqt5multimedia5-plugins liblzo2-2 liblzo2-dev"
sudo apt-get -V install build-essential qtbase5-dev qtchooser qt5-qmake qtbase5-dev-tools qttools5-dev libqt5gui5 qtmultimedia5-dev libpng16-16 libpng-dev libgomp1 libgsl-dev libsndfile1-dev libqt5multimedia5-plugins liblzo2-2 liblzo2-dev qtdeclarative5-dev
echo "qtcreator git"
sudo apt-get -V install qtcreator git
echo "installing: opencl-headers ocl-icd-libopencl1"
sudo apt-get -V install opencl-headers ocl-icd-libopencl1 ocl-icd-opencl-dev
echo "
getting fresh source files from git repository
"
if [ ! -d mandelbulber2 ]; then
git clone https://github.com/buddhi1980/mandelbulber2
cd mandelbulber2/mandelbulber2
else
cd mandelbulber2
git pull
cd mandelbulber2
fi
echo "
compiling the program
"
cd qmake
qmake mandelbulber-opencl.pro
make -j4
echo "
installing the program
"
sudo install mandelbulber2 /usr/bin
echo "
creating links to files from formula and deploy
folders in /usr/share/mandelbulber2 directory
if you change anything in that folder you will
not need to reinstall the program
You have to remember to not delete mandelbulber2 folder located here
"
sudo rm -f -r $MANDELBULBER_SHARE
sudo mkdir $MANDELBULBER_SHARE
cd ..
sudo ln -s ${PWD}/formula $MANDELBULBER_SHARE/formula
sudo ln -s ${PWD}/deploy/share/mandelbulber2/data $MANDELBULBER_SHARE/data
sudo ln -s ${PWD}/language $MANDELBULBER_SHARE/language
sudo ln -s ${PWD}/deploy/share/mandelbulber2/materials $MANDELBULBER_SHARE/materials
sudo ln -s ${PWD}/deploy/share/mandelbulber2/examples $MANDELBULBER_SHARE/examples
sudo ln -s ${PWD}/deploy/share/mandelbulber2/icons $MANDELBULBER_SHARE/icons
sudo ln -s ${PWD}/deploy/share/mandelbulber2/textures $MANDELBULBER_SHARE/textures
sudo ln -s ${PWD}/deploy/share/mandelbulber2/toolbar $MANDELBULBER_SHARE/toolbar
sudo ln -s ${PWD}/deploy/doc $MANDELBULBER_SHARE/doc
sudo ln -s ${PWD}/deploy/share/mandelbulber2/sounds $MANDELBULBER_SHARE/sounds
sudo ln -s ${PWD}/opencl $MANDELBULBER_SHARE/opencl
echo "To start development of Mandelbulber you can open
mandelbulber2/mandelbulber2/qmake/mandelbulber-opencl.pro
with QtCreator which is already in your system"
echo "To run the program you need to launch folowing file:
mandelbulber2/mandelbulber2/qmake/mandelbulber2"