Project

General

Profile

Preparing a Linux machine for Bilder » History » Version 1

Redmine Admin, 10/30/2015 04:16 PM

1 1 Redmine Admin
# Preparing a Linux machine for Bilder
2
3
## Bilder on Linux
4
5
At least one package (Babel) needs Oracle's java, so we recommend installing it. It is often useful to get a newer gcc that has mmintrinsics.
6
7
## GCC
8
9
Below are the instructions for building gcc-4.9.3.
10
11
### Make sure 32bit glibc-devel is installed
12
13
~~~~~~
14
yum -y install glibc-devel.i686
15
zypper install glibc-devel-32bit  (SLES 11 SP3)
16
~~~~~~
17
18
### Get the source packages
19
20
~~~~~~
21
export GCCVER=4.9.3
22
wget ftp://ftp.gnu.org/gnu/gcc/gcc-${GCCVER}/gcc-${GCCVER}.tar.bz2
23
~~~~~~
24
25
### Build
26
27
Define CONTRIB_DIR to be your tarball installation directory, e.g.,
28
29
~~~~~~
30
export CONTRIB_DIR=/contrib
31
~~~~~~
32
33
Usually CONTRIB_DIR=/contrib, but if one does not have root access, one has to put this in a user area. If one does have root access, one should execute the following commands:
34
35
~~~~~~
36
mkdir /internal /contrib /volatile
37
chmod 775 /internal /contrib /volatile
38
~~~~~~
39
40
Unpack gcc, go into the gcc source directory, and build according to the instructions below.
41
42
**gcc:**
43
44
~~~~~~
45
tar xjf gcc-${GCCVER}.tar.bz2 && cd gcc-${GCCVER}
46
./contrib/download_prerequisites
47
mkdir build && cd build
48
../configure --prefix=$CONTRIB_DIR/gcc-${GCCVER} \
49
  --enable-languages=c,c++,fortran --with-pic
50
env LD_RUN_PATH=$CONTRIB_DIR/gcc-${GCCVER}/lib64 make -j 4
51
make install
52
# Alias as desired.
53
mkdir -p $CONTRIB_DIR/bin && cd $CONTRIB_DIR/bin
54
ln -s $CONTRIB_DIR/gcc-${GCCVER}/bin/{c,g}* .
55
~~~~~~
56
57
### Fix permissions
58
59
~~~~~~
60
chmod -R g+rwX $CONTRIB_DIR/gcc-${GCCVER}
61
chmod -R o+rX $CONTRIB_DIR/gcc-${GCCVER}
62
find $CONTRIB_DIR/gcc-${GCCVER} -type d -exec chmod g+rs '{}' \;
63
~~~~~~
64
65
66
## Java
67
68
Install Oracle's Java.
69
70
Once it is installed, you will need to modify your path to include /usr/java/default/bin before /usr/bin or use the alternatives package:
71
72
~~~~~~
73
for i in java jar javac; do
74
  alternatives --install /usr/bin/$i j$i /usr/java/jdk1.6.0_16/bin/$i 3
75
done
76
alternatives --config java # Pick 3
77
~~~~~~
78
79
On SLES , Install using the tar package from Oracle, then change into the installation directory
80
81
~~~~~~
82
for i in java jar javac; do
83
  /usr/sbin/update-alternatives --install /usr/bin/$i $i <installation directory>/bin/$i 3
84
done
85
~~~~~~
86
87
where <installation directory\> is the absolute path to where Java was just installed  
88
89
## Version control systems
90
91
Make sure git, mercurial, and subversion are all installed.
92
93
## LaTeX
94
95
Install the texlive-latex package. You may need to install other packages over time. For gui usage, see texworks: http://www.tug.org/texworks
96
97
If you cannot install in the system area, you can download
98
99
~~~~~~
100
wget http://mirror.ctan.org/systems/texlive/tlnet/install-tl-unx.tar.gz
101
tar xzf install-tl-unx.tar.gz
102
cd install-tl-20150411 (date might be different)
103
./install-tl -no-gui
104
~~~~~~
105
106
This is now interactive, so set
107
108
* Scheme to basic
109
110
* TEXDIR = $CONTRIB_DIR/texlive
111
112
* Letter size
113
114
and then
115
116
~~~~~~
117
    for i in cmap fancybox fancyvrb epstopdf framed mdwtools multirow parskip \
118
pdftex revtex4 titlesec threeparttable url wrapfig courier ec helvetic palatino; do
119
     tlmgr install $i
120
    done
121
~~~~~~
122
123
You may also want to install some of the fonts, avantgar bookman charter cmextra courier euro-ce eurosym marvosym mathpazo ncntrsbk pxfonts rsfs symbol times txfonts utopia wasy zapfchan zapfding.
124
125
## Fedora
126
127
The following packages are needed for Fedora
128
129
~~~~~~
130
   bison
131
   glib2-devel
132
   gstreamer-devel
133
   gstreamer-plugins-base-devel
134
   libxml2-devel
135
   zlib-devel
136
   patch
137
~~~~~~
138
139
If you cannot install in the system area, bilder/extras/gstreamer.sh may
140
be modified to do what you need.
141
142
## Ubuntu
143
144
The following packages are needed for Ubuntu
145
146
~~~~~~
147
   ace-netsvcs
148
   bison
149
   flex
150
   gfortran
151
   graphviz
152
   graphviz-dev
153
   heirloom-mailx
154
   libblas-dev
155
   libfreetype6-dev
156
   libgl1-mesa-dev
157
   libglu1-mesa-dev
158
   liblapack-dev
159
   libntlm0
160
   libpng12-dev
161
   libxext-dev
162
   libxrender-dev
163
   libxtst-dev
164
   libzzip-dev
165
   mailutils
166
   python2.6
167
   python2.6-dev
168
   vim
169
   zlib-dev
170
~~~~~~
171
172
The use of the following commands are helpful. To search for an available package dealing with a keyword, use:
173
174
~~~~~~
175
    $ sudo apt-cache search keyword
176
~~~~~~
177
178
To install a particular package, use:
179
180
~~~~~~
181
    $ sudo apt-get install libblah-dev
182
~~~~~~
183
184
Note: that development packages names typically end with "dev" not "devel" as in other flavors of linux.
185
186
## Suse Linux Enterprise Server (SLES)
187
188
The following packages are needed on SLES
189
190
~~~~~~
191
   bison
192
   blas-devel
193
   blas-devel-static
194
   libblas3
195
   flex
196
   freetype2-devel
197
   gcc
198
   gcc-32bit
199
   gcc-fortran
200
   git
201
   glibc-devel
202
   glibc-devel-32bit
203
   graphviz
204
   graphviz-devel
205
   gstreamer-0_10-devel
206
   gstreamer-0_10-plugins-base-devel
207
   lapack-devel
208
   lapack-devel-static
209
   liblapack3
210
   libapr-util1 (needed to build subversion)
211
   libapr1      (needed to build subversion)
212
   libneon27    (needed to build subversion)
213
   libpng-devel
214
   libssh-devel
215
   libxml2-devel
216
   mailx
217
   mercurial
218
   Mesa-devel
219
   python-devel
220
   xorg-x11-devel
221
   xorg-x11-libXext-devel
222
   xorg-x11-libXrender-devel
223
   xorg-x11-libs
224
   zlib-devel
225
~~~~~~
226
227
To get blas-devel, blas-devel-static and lapack-devel, lapack-devel-static on SLES 11 SP3 , add the Science repository
228
229
~~~~~~
230
   zypper addrepo http://download.opensuse.org/repositories/science/SLE_11_SP3/science.repo
231
   zypper refresh
232
   zypper install blas-devel blas-devel-static lapack-devel lapack-devel-static
233
~~~~~~
234
235
## Vendor-specific version of graphics driver
236
237
If you are preparing a Linux machine for the VisIt Visualization package, the vendor-specific graphics driver for your graphics card should be installed.
238
239
By default, a generic graphics driver is installed.  On Fedora, the generic driver is "nouveau".
240
241
To determine if the nouveau driver is installed on your system, enter the command
242
243
~~~~~~
244
     lsmod | grep nouv
245
~~~~~~
246
247
You will need to download and install the appropriate driver from your graphics card vendor.  This generally uninstalls the nouveau drivers.