forked from SCIInstitute/fluorender
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild_linux.txt
69 lines (56 loc) · 3.25 KB
/
build_linux.txt
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
Building on Linux
1. Install dependencies
1.a. GNU compilers >= 5.0 (at CHPC "module load gcc/5.4.0)
1.b. BOOST (at CHPC "module load boost/1.66.0")
1.c. wxWidgets, download and build, e.g.
$ wget https://github.com/wxWidgets/wxWidgets/releases/download/v3.0.4/wxWidgets-3.0.4.tar.bz2
$ tar xf wxWidgets-3.0.4.tar.bz2
$ mv wxWidgets-3.0.4 3.0.4--5.4.0g
$ cd 3.0.4--5.4.0g/
$ module load gcc/5.4.0
$ ./configure --prefix=/uufs/chpc.utah.edu/sys/installdir/wxWidgets/3.0.4-5.4.0g --with-libpng --with-libjpeg --with-libtiff --with-libxpm --with-libiconv --with-libnotify --with-opengl --with-regex --with-zlib --enable-cxx11 --enable-stl --enable-monolithic
$ make
$ make install
1.d. ffmpeg, download and build
$ wget https://ffmpeg.org/releases/ffmpeg-4.0.2.tar.bz2
$ tar xf ffmpeg-4.0.2.tar.bz2
$ mv ffmpeg-4.0.2 4.0.2
$ cd 4.0.2
$ module load gcc/5.4.0
$ ./configure --prefix=/uufs/chpc.utah.edu/sys/installdir/ffmpeg/4.0.2
$ make
$ make install
2. Download, modify and build fluorender
$ git clone https://github.com/mcuma/fluorender (this includes some Linux
based modifications)
$ cd fluorender
$ mkdir build
$ cd build
$ module load gcc/5.4.0 cmake/3.11.2 wxWidgets/3.0.4 (wxWidgets wx-config
needs to be in the PATH for cmake configure to find it)
$ cmake --debug-trycompile -DCMAKE_INSTALL_PREFIX=./ -DCMAKE_CXX_COMPILER=/uufs/chpc.utah.edu/sys/installdir/gcc/5.4.0-c7/bin/c++ -DCMAKE_C_COMPILER=/uufs/chpc.utah.edu/sys/installdir/gcc/5.4.0-c7/bin/gcc -DBOOST_ROOT=/uufs/chpc.utah.edu/sys/installdir/boost/1.66.0-5.4.0g -DOpenCL_INCLUDE_DIR=/usr/local/cuda/include -DOpenCL_LIBRARY=/usr/lib64/libOpenCL.so.1 -DCMAKE_CXX_FLAGS=-std=c++11 -DFFMPEG_DIR=/uufs/chpc.utah.edu/sys/installdir/ffmpeg/4.0.2 ..
(CXX_COMPILER and C_COMPILER need to be specified otherwise the distro based
compiler is found first by cmake)
after configure is done, need to modify a few files to add FFMPEG paths (which
I can't figure out easily in the CMakeLists.txt):
CMakeFiles/FluoRender.dir/flags.make (make sure to scroll down to CXX_FLAGS, on top is C_FLAGS)
CMakeFiles/VIDEO_OBJ.dir/flags.make
CXX_FLAGS = -fPIC -std=gnu++14 -I/uufs/chpc.utah.edu/sys/installdir/ffmpeg/4.0.2/include
CMakeFiles/FluoRender.dir/link.txt
- need to add -lz (for bzip2) and FFMPEG at the end of the link line:
-L/uufs/chpc.utah.edu/sys/installdir/ffmpeg/4.0.2/lib -lavformat -lavcodec -llzma -lz -lswscale -lswresample -lavutil -lm
$ make
$ make install
Issues
- works with OpenCL shipped with Nvidia driver 390, but segfaults in /lib64/libnvidia-opencl.so.1 with driver 410
- the same crash seems to happen even with 390 when using hardware OpenGL.
- with driver 390, even though the GUI starts, there are several errors:
Error while getting JNI_CreateJavaVM funciton address.
./src/unix/glx11.cpp(565): assert ""xid"" failed in SetCurrent(): window must be shown
Error while getting JNI_CreateJavaVM funciton address.
16:02:08: Debug: Failed to connect to session manager: SESSION_MANAGER environment variable not defined
Error while getting JNI_CreateJavaVM funciton address.
Error compiling vertex shader: 0(3) : error C0000: syntax error, unexpected '(', expecting "::" at token "("
0(10) : error C1503: undefined variable "InVertex"
0(11) : error C1503: undefined variable "InTexCoord"
0(12) : error C1503: undefined variable "InVertex"