Skip to content

Commit

Permalink
fix multiple branch and users for gm, ng and docs builds
Browse files Browse the repository at this point in the history
  • Loading branch information
Xiaoming Wang committed Jun 18, 2015
1 parent 2077c87 commit e01f36c
Show file tree
Hide file tree
Showing 6 changed files with 64 additions and 4 deletions.
32 changes: 30 additions & 2 deletions Linux-Builds/bin/build/build_dc
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,36 @@ cmakeOptions=${scriptName}_cmake_options
. ${curDir}/build_common
. ${curDir}/build_common_${PKG_TYPE}

echo "cmake -DCMAKE_BUILD_TYPE=Release -DCHECK_GIT_TAG=0 -DMAKE_DOCS_ONLY=ON -DUSE_NATIVE_LIBRARIES=ON ${CMAKE_OPTIONS} ../HPCC-Platform"
cmake -DCMAKE_BUILD_TYPE=Release -DCHECK_GIT_TAG=0 -DMAKE_DOCS_ONLY=ON -DUSE_NATIVE_LIBRARIES=ON ${CMAKE_OPTIONS} ../HPCC-Platform || exit 1

cd ..
build_cfg_dir=build-configurator
[ ! -e $build_cfg_dir ] && mkdir -p $build_cfg_dir
BUILD_SCRIPT=build-cfg.sh
cat > $BUILD_SCRIPT <<SCRIPTFILE
#!/bin/sh
cmake ../HPCC-Configurator
SCRIPTFILE

chmod +x $BUILD_SCRIPT

cd $build_cfg_dir
cmake ../HPCC-Configurator
make -j4 || exit 1

cd ..
BUILD_SCRIPT=build.sh
cat > $BUILD_SCRIPT <<SCRIPTFILE
#!/bin/sh
cmake -DCMAKE_BUILD_TYPE=Release -DCHECK_GIT_TAG=0 -DMAKE_DOCS_ONLY=ON -DUSE_NATIVE_LIBRARIES=ON ${CMAKE_OPTIONS} \
-DDOCS_AUTO=ON -DCONFIGURATOR_DIRECTORY=../../../build-configurator/configurator ../HPCC-Platform || exit 1
SCRIPTFILE
chmod +x $BUILD_SCRIPT

cd build
echo "cmake -DCMAKE_BUILD_TYPE=Release -DCHECK_GIT_TAG=0 -DMAKE_DOCS_ONLY=ON -DUSE_NATIVE_LIBRARIES=ON \
${CMAKE_OPTIONS} -DDOCS_AUTO=ON -DCONFIGURATOR_DIRECTORY=../../../build-configurator/configurator ../HPCC-Platform"
cmake -DCMAKE_BUILD_TYPE=Release -DCHECK_GIT_TAG=0 -DMAKE_DOCS_ONLY=ON -DUSE_NATIVE_LIBRARIES=ON ${CMAKE_OPTIONS} \
-DDOCS_AUTO=ON -DCONFIGURATOR_DIRECTORY=../../../build-configurator/configurator ../HPCC-Platform || exit 1

make -j4 || exit 1

Expand Down
2 changes: 2 additions & 0 deletions Linux-Builds/bin/build_hpcc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ usage() {
-b|--branch: HPCC component branch or tag.
It can be multiple branches separated by ','.
For example, LN build -b <Platform branch>,<LN branch>
Docs build -b <Platform branch>,<Configurator branch>
-p|--project: HPCC componet ids seperated by comma.
1: Platform community (rpm only)
2: Platform community with plugin
Expand All @@ -24,6 +25,7 @@ usage() {
-u|--user: github user. Default is hpcc-systems
It can be multiple users for multiple branches separated by ','.
For example, LN build -u <Platform github user>,<LN github user>
LN build -u <Platform github user>,<Configurator github user>
-h|--help: Help message
EOF
Expand Down
28 changes: 28 additions & 0 deletions Linux-Builds/bin/github/github_dc
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,32 @@
[ -z "$1" ] && echo "Miss tag or branch name" && exit 1

curDir=$(dirname $0)
. ${curDir}/github_common

get_user_and_branch $1 ${github_user}

match_branch_suffix $branch2
if [ $? -eq 0 ]
then
TAG_BRANCH_NAME=v$branch2
else
TAG_BRANCH_NAME=$branch2
fi


${curDir}/github_ce $1 OFF
[ $? -ne 0 ] && exit 1

CFG_DIR=HPCC-Configurator
echo ""
echo "get HPCC Configurator repo"
[ -d $CFG_DIR ] && rm -rf $CFG_DIR

#remove this when HPCC-Configurator is moved to HPCC-Sysystems
github_user2=garonsky
CFG_REPO=https://github.com/${github_user2}/HPCC-Configurator.git

git clone $CFG_REPO

cd $CFG_DIR
get_branch_tag $TAG_BRANCH_NAME
2 changes: 2 additions & 0 deletions Linux-Builds/bin/github/github_gc
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ curDir=$(dirname $0)
. ${curDir}/github_common

[ -z "$1" ] && echo "Miss tag or branch name" && exit 1


match_branch_suffix $1
if [ $? -eq 0 ]
then
Expand Down
2 changes: 1 addition & 1 deletion Linux-Builds/bin/github/github_gm
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ ${curDir}/github_ce $1 OFF

GM_DIR=ganglia-monitoring

GM_REPO=https://github.com/${github_user}/ganglia-monitoring.git
GM_REPO=https://github.com/${github_user2}/ganglia-monitoring.git


echo ""
Expand Down
2 changes: 1 addition & 1 deletion Linux-Builds/bin/github/github_nm
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ NM_DIR=nagios-monitoring
echo ""
echo "get HPCC Nagios Monitoring repo"
[ -d $NM_DIR ] && rm -rf $NM_DIR
NM_REPO=https://github.com/${github_user}/nagios-monitoring.git
NM_REPO=https://github.com/${github_user2}/nagios-monitoring.git

git clone $NM_REPO

Expand Down

0 comments on commit e01f36c

Please sign in to comment.