0e1ed8305fa505f3fb5dc02a89e7d6601e4e39ef
[vswitchperf.git] / systems / centos / build_base_machine.sh
1 #!/bin/bash
2 #
3 # Build a base machine for CentOS distro
4 #
5 # Copyright 2015 OPNFV
6 #
7 # Licensed under the Apache License, Version 2.0 (the "License");
8 # you may not use this file except in compliance with the License.
9 # You may obtain a copy of the License at
10 #
11 #     http://www.apache.org/licenses/LICENSE-2.0
12 #
13 # Unless required by applicable law or agreed to in writing, software
14 # distributed under the License is distributed on an "AS IS" BASIS,
15 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 # See the License for the specific language governing permissions and
17 # limitations under the License.
18 #
19 # Contributors:
20 #   Aihua Li, Huawei Technologies.
21 #   Martin Klozik, Intel Corporation.
22
23 # Synchronize package index files
24 yum -y update
25
26 # Install required packages
27 yum -y install $(echo "
28
29 # Make, Compilers and devel
30 make
31 gcc
32 gcc-c++
33 libxml2
34 glibc
35 kernel-devel
36
37 # tools
38 wget
39 git
40 scl-utils
41 vim
42 curl
43 autoconf
44 libtool
45 automake
46 pciutils
47 cifs-utils
48 sysstat
49 sshpass
50
51 # libs
52 libpcap-devel
53 libnet
54 fuse
55 fuse-libs
56 fuse-devel
57 zlib
58 zlib-devel
59 glib2-devel
60 pixman-devel
61 socat
62 numactl
63 numactl-devel
64 libpng-devel
65 freetype-devel
66
67 # install gvim
68 vim-X11
69
70 # install epel release required for git-review
71 epel-release
72 " | grep -v ^#)
73
74 # install SCL for python34
75 sudo yum -y install centos-release-scl-rh
76
77 # install python34 packages and git-review tool
78 yum -y install $(echo "
79 rh-python36
80 rh-python36-python-tkinter
81 git-review
82 " | grep -v ^#)
83 # prevent ovs vanilla from building from source due to kernel incompatibilities
84 sed -i s/'SUBBUILDS = src_vanilla'/'#SUBBUILDS = src_vanilla'/ ../src/Makefile