Made installer code pretty
This commit is contained in:
parent
2fb406772d
commit
5cd76355dd
@ -121,12 +121,17 @@ sub install {
|
||||
print "Install FastNetMon dependency list\n";
|
||||
|
||||
if ($distro_type eq 'debian') {
|
||||
my @fastnetmon_deps = ("git", "g++", "gcc", "libboost-all-dev", "libgpm-dev", "libncurses5-dev", "liblog4cpp5-dev", "libnuma-dev", "libgeoip-dev","libpcap-dev", "clang", "cmake");
|
||||
my @fastnetmon_deps = ("git", "g++", "gcc", "libboost-all-dev", "libgpm-dev", "libncurses5-dev",
|
||||
"liblog4cpp5-dev", "libnuma-dev", "libgeoip-dev","libpcap-dev", "clang", "cmake"
|
||||
);
|
||||
|
||||
my $fastnetmon_deps_as_string = join " ", @fastnetmon_deps;
|
||||
`apt-get install -y --force-yes $fastnetmon_deps_as_string`;
|
||||
} elsif ($distro_type eq 'centos') {
|
||||
my @fastnetmon_deps = ('git', 'make', 'gcc', 'gcc-c++', 'boost-devel', 'GeoIP-devel', 'log4cpp-devel', 'ncurses-devel', 'glibc-static', 'ncurses-static', 'boost-thread', 'libpcap-devel', 'gpm-static', 'gpm-devel', 'clang', 'cmake');
|
||||
my @fastnetmon_deps = ('git', 'make', 'gcc', 'gcc-c++', 'boost-devel', 'GeoIP-devel', 'log4cpp-devel',
|
||||
'ncurses-devel', 'glibc-static', 'ncurses-static', 'boost-thread', 'libpcap-devel', 'gpm-static',
|
||||
'gpm-devel', 'clang', 'cmake'
|
||||
);
|
||||
|
||||
my $fastnetmon_deps_as_string = join " ", @fastnetmon_deps;
|
||||
`yum install -y $fastnetmon_deps_as_string`;
|
||||
@ -173,7 +178,6 @@ sub install {
|
||||
`make`;
|
||||
|
||||
my $fastnetmon_dir = "/opt/fastnetmon";
|
||||
|
||||
my $fastnetmon_build_binary_path = "$fastnetmon_code_dir/build/fastnetmon";
|
||||
|
||||
unless (-e $fastnetmon_build_binary_path) {
|
||||
|
Loading…
Reference in New Issue
Block a user