forked from ppc64le/build-scripts
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathnetty_codec_dns_rhel_7.6.sh
77 lines (68 loc) · 2.46 KB
/
netty_codec_dns_rhel_7.6.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
# ----------------------------------------------------------------------------
#
# Package : netty-codec-dns
# Version : 4.1.48.Final
# Source repo : https://github.com/netty/netty
# Tested on : RHEL 7.6
# Script License : Apache License Version 2.0
# Maintainer : Pratham Murkute <[email protected]>
#
# Disclaimer: This script has been tested in root mode on given
# ========== platform using the mentioned version of the package.
# It may not work as expected with newer versions of the
# package and/or distribution. In such case, please
# contact "Maintainer" of this script.
#
# ----------------------------------------------------------------------------
#!/bin/bash
# install tools and dependent packages
#yum -y update
yum install -y git wget curl unzip nano vim make build-essential
#yum install -y gcc ant
# setup java environment
yum install -y java java-devel
which java
ls /usr/lib/jvm/
export JAVA_HOME=/usr/lib/jvm/java-1.8.0-ibm-1.8.0.6.5-1jpp.1.el7.ppc64le
# update the path env. variable
export PATH=$PATH:$JAVA_HOME/bin
# install maven
MAVEN_VERSION=3.6.3
wget http://mirrors.estointernet.in/apache/maven/maven-3/$MAVEN_VERSION/binaries/apache-maven-$MAVEN_VERSION-bin.tar.gz
ls /usr/local
tar -C /usr/local/ -xzf apache-maven-$MAVEN_VERSION-bin.tar.gz
mv /usr/local/apache-maven-$MAVEN_VERSION /usr/local/maven
ls /usr/local
rm apache-maven-$MAVEN_VERSION-bin.tar.gz
export M2_HOME=/usr/local/maven
# update the path env. variable
export PATH=$PATH:$M2_HOME/bin
# create folder for saving logs
mkdir -p /logs
# variables
PKG_NAME="netty-codec-dns"
PKG_VERSION=4.1.41
PKG_VERSION_LATEST=4.1.48
LOGS_DIRECTORY=/logs
LOCAL_DIRECTORY=/root
REPOSITORY="https://github.com/netty/netty.git"
# clone, build and test specified version
#cd $LOCAL_DIRECTORY
#git clone $REPOSITORY $PKG_NAME-$PKG_VERSION
#cd $PKG_NAME-$PKG_VERSION/
#git checkout -b $PKG_VERSION tags/netty-$PKG_VERSION.Final
#cd codec-dns/
#mvn install | tee $LOGS_DIRECTORY/$PKG_NAME-$PKG_VERSION.txt
# clone, build and test latest version
cd $LOCAL_DIRECTORY
git clone $REPOSITORY $PKG_NAME-$PKG_VERSION_LATEST
cd $PKG_NAME-$PKG_VERSION_LATEST/
git checkout -b $PKG_VERSION_LATEST tags/netty-$PKG_VERSION_LATEST.Final
cd codec-dns/
mvn install | tee $LOGS_DIRECTORY/$PKG_NAME-$PKG_VERSION_LATEST.txt
# clone, build and test master
#cd $LOCAL_DIRECTORY
#git clone $REPOSITORY $PKG_NAME-master
#cd $PKG_NAME-master/
#cd codec-dns/
#mvn install | tee $LOGS_DIRECTORY/$PKG_NAME.txt