`
xifengtaizi
  • 浏览: 11414 次
  • 性别: Icon_minigender_2
  • 来自: 上海
最近访客 更多访客>>
社区版块
存档分类
最新评论

build.ksh

    博客分类:
  • UNIX
 
阅读更多
#! /bin/sh
#####################################################################################
getPkg()
{
    RESP=""
    while [ -z "${RESP}" ]
    do
        echo "Please select one package to build. The following are the valid packages:
       
            a) aa
            b) bb

       
        Package (default: gEntlSrv): \c"
        read RESP                         
        case "${RESP:=aa}" in
            "a"|"aa")
                MODULE="ss"
                ENV_ID=69751 ;;
            "b"|"bb")
                MODULE="rr"
                ENV_ID=70031 ;;      
            *)      
            echo "
            $RESP: invalid response, please try again!
            Use the option letter or action keyword."
            RESP=""
        ;;
        esac
    done
}

getBranch()
{
    echo "Please enter the branch you want to checkout from CVS.
        Branch name (default: Main trunk): \c"
    read RESP
    if [ -n "${RESP}" ]
    then
        BRANCH="-r $RESP"
    fi
}


getWorkDir()
{
    echo "Please enter your workdir.
        Working dir : \c"
    read RESP
    if [ -n "${RESP}" ]
    then
        WORKING_DIR=$RESP
    fi
}

#####################################################################################
USERID=`whoami`
CVS=/xenv/cvs/X/1.11.22/bin/cvs
export cvs
CVSROOT=":pserver:username@servername:port/RepositoryName"
export CVSROOT
CURR_DIR=$1
echo $CURR_DIR
WORKING_DIR=`pwd`
COMMON="aa/common"

# check args
if [ $# -gt 1 ];then
    MODULE=$1
    ENV_ID=$2
elif [ $# -gt 2  ];then
    MODULE=$1
    ENV_ID=$2
    BRANCH="-r $3"
    echo $BRANCH
else
    getPkg
    getBranch
    getWorkDir
fi
CURRENTDIR=`pwd`
#WORKING_DIR=$CURRENTDIR/$WORKING_DIR
if [ ! -d $WORKING_DIR ];then
    mkdir $WORKING_DIR
fi

cd $WORKING_DIR
echo "working dir is "$WORKING_DIR
echo "Removing old files..."
rm -rf $COMMON
rm -rf $MODULE

echo "Checking out $MODULE..."
echo "branch is $BRANCH"
${CVS} -Q checkout -P $BRANCH $COMMON
${CVS} -Q checkout -P $BRANCH $MODULE

cd $MODULE
#if [ $ENV_ID = 86701 ];then
#  mv build.properties build.properties.bak
#  cat build.properties.bak | sed 's_\${env.aaa\}_bb_g' > build.properties
#  rm build.properties.bak
#fi
ksh prepareSource.ksh
find . -name CVS -exec /bin/rm -rf {} \;;find . -name *.#* -exec /bin/rm -rf {} \;

echo "Building ..."
/xenv/stexenv -r $ENV_ID . << ZZ
make package -f *.mk
ZZ

echo "dstream pakcage location ->"
ls ${WORKING_DIR}/${MODULE}/*.dstream

# print EAR file location if it is a BE package
if [ -d ${WORKING_DIR}/${MODULE}/install/applications ]
then
    EAR_LOCATION=`ls ${WORKING_DIR}/${MODULE}/install/applications/*.ear`
fi

if [ -n $EAR_LOCATION ]
then
    echo "\n\n\n############################################################################\n"
    echo "EAR file location -> "
    echo $EAR_LOCATION
    echo "\n############################################################################\n\n\n"
fi

cd $WORKING_DIR
分享到:
评论

相关推荐

    11g安装guide.doc

    Linux version 3.10.0-862.el7.x86_64 (mockbuild@x86-034.build.eng.bos.redhat.com) (gcc version 4.8.5 20150623 (Red Hat 4.8.5-28) (GCC) ) #1 SMP Wed Mar 21 18:14:51 EDT 2018 查看内核版本 [root@...

    Expert Shell Scripting

    Expert Shell Scripting ...Use scripts to build complete Linux systems. Script X Window without getting lost in configuration files. Ignore Python, and script in bash and ksh instead.

    oracle 19c 19.3.0.0 for RHEL7.6

    - **命令**: `yum install -y binutils compat-lib* gcc* glibc* ksh* libgcc* libstdc* libaio* make* sysstat* elfutils*` - **作用**: 确保安装了Oracle数据库所需的所有依赖库。 **5. 单独上传至系统,并安装...

    gdb调试工具

    For example (assuming sh/bash/ksh): CC=gcc ./configure make A similar example using csh: setenv CC gcc ./configure make Much of the code and documentation enclosed is copyright by the Free ...

    ubuntu 10.04上搭建oracle 11g个人总结

    这些软件包包括 rpm、libaio1、ksh、libtool 和 build-essential。使用以下命令安装这些软件包: sudo apt-get install rpm libaio1 ksh libtool build-essential 此外,还需要安装 libstdc++5,否则 Oracle 11g ...

    oracle 11201 for rhel6.9

    [root@localhost ~]# yum install -y binutils* compat-lib* gcc* glibc* ksh* libgcc* libstdc* libaio* make* sysstat* ``` ##### 4. 创建用户组与用户 为了满足Oracle 11g的安全需求,需创建特定的用户组与用户...

    LINUX系统下TSM6.3服务器部署(LanFree).pdf

    # yum install -y rpm-build # yum install -y kernel-devel glibc-devel gcc # rpm -ivh libstdc++-4.4.7-3.el6.i686.rpm # rpm -ivh compat-libstdc++-33-3.2.3-69.el6.i686.rpm ``` ##### 解压安装包 - 将`...

    ubuntu 8.0.4 server 安装oracle10.2成功

    sudo apt-get install build-essential libaio1 gawk ksh libmotif3 alien libtool rpm lsb-rpm sudo apt-get install gcc lesstif2 libc6 libc6-dev libstdc++5 xorg unzip sudo apt-get install xauth libxp6 ...

    基于Linux系统下的TSM和DB2数据库的还原性测试01-TSM服务器安装.pdf

    # yum install -y rpm-build # yum install -y kernel-devel glibc-devel gcc # rpm -ivh libstdc++-4.4.7-3.el6.i686.rpm # rpm -ivh compat-libstdc++-33-3.2.3-69.el6.i686.rpm ``` 2. **解压安装包** - ...

    debian 5+xdmcp+oracle 10g.txt

    apt-get install libxp-dev sysstat ksh csh libaio-dev binutils libc6 gcc make libaio1 libstdc++5 gawk tcsh libmotif3 alien rcconf ``` #### 四、Oracle 用户与组创建 ##### 1. 创建 Oracle 相关组 ```bash ...

    Sybase11.0.x的安装和配置_SCOUnix5.pdf

    接下来,切换到`sybase`用户并编辑`.profile`(如果是sh或ksh shell)或`.cshrc`(如果是csh shell),添加必要的环境变量。例如,在`.profile`中设置`SYBASE`、`DSQUERY`、`PATH`和`LD_LIBRARY_PATH`,确保Sybase的...

    ubuntu10.04_安装oracle_11g_r2.doc

    sudo apt-get install build-essential libaio1 gawk ksh libmotif3 alien libtool lsb-rpm ``` 注意:`lsb-rpm` 包可能需要手动添加到软件源中,这是因为某些版本的 Ubuntu 默认不会包含该包。如果遇到版权或合法...

    Install-Abaqus-2019-on-Ubuntu-18.04-LTS:使用说明书在Ubuntu 18.04 LTS上安装Abaqus 2019

    sudo chmod -R 777 /opt/Abaqus/*使用DSYInsAppliGUI将libpng12.so.0复制到所有文件夹: //linux_a64/code/bin/安装先决条件: sudo apt install ksh gcc g++ gfortran libstdc++5 build-essential make libjpeg62...

    804下安装Oracle.docx

    - `apt-get install build-essential libaio1 gawk ksh libmotif3 alien libtool lsb rpm` #### Step 6: 修改/bin/sh的默认链接 - **目的**:避免安装过程中因默认shell为dash而导致的问题。 - **步骤**: - 进入...

    UB32位下成功安装ORACLE11G

    sudo apt-get install build-essential libaio1 gawk ksh libmotif3 alien libtool lsb-rpm ``` - 这些库包括编译器、链接器以及其他可能被 Oracle 安装过程中使用的工具。 **2. 创建用户组及用户:** - 创建...

    Abaqus18_on_Ubuntu18.04LTS.pdf

    - 库文件:libstdc++5、build-essential、make、libjpeg62、libmotif-dev、libglu1-mesa,这些库文件分别支持标准C++库、构建重要软件所必需的工具、Make程序、JPEG格式图片处理、Motif图形用户界面以及OpenGL。...

    虚拟机下安装oracle11gr2完整版

    - 采用VMware Server Version 2.0.2 Build 203138作为虚拟化平台。 - 数据库版本为Oracle 11.2.0.1,包括Grid Infrastructure。 - 操作系统选用Oracle Linux Server 6.2,简化后续额外文件需求。 - 规划虚拟机...

Global site tag (gtag.js) - Google Analytics