fixed: use shallow clones on jenkins

This commit is contained in:
Arne Morten Kvarving 2016-04-06 10:15:46 +02:00
parent b7fc614356
commit 4becc05314

View File

@ -7,7 +7,7 @@ function build_opm_autodiff {
cd $WORKSPACE/deps/ert
git init .
git remote add origin https://github.com/Ensembles/ert
git fetch origin $ERT_REVISION:branch_to_build
git fetch --depth 1 origin $ERT_REVISION:branch_to_build
test $? -eq 0 || exit 1
git checkout branch_to_build
popd
@ -25,7 +25,7 @@ function build_opm_autodiff {
cd $WORKSPACE/deps/opm-common
git init .
git remote add origin https://github.com/OPM/opm-common
git fetch origin $OPM_COMMON_REVISION:branch_to_build
git fetch --depth 1 origin $OPM_COMMON_REVISION:branch_to_build
test $? -eq 0 || exit 1
git checkout branch_to_build
popd
@ -35,27 +35,34 @@ function build_opm_autodiff {
mkdir serial/build-opm-common
cd serial/build-opm-common
build_module "-DCMAKE_INSTALL_PREFIX=$WORKSPACE/serial/install" 0 $WORKSPACE/deps/opm-common
test $? -eq 0 || exit 1
popd
# Build opm-parser
clone_and_build_module opm-parser "-DCMAKE_PREFIX_PATH=$WORKSPACE/serial/install -DCMAKE_INSTALL_PREFIX=$WORKSPACE/serial/install" $OPM_PARSER_REVISION $WORKSPACE/serial
test $? -eq 0 || exit 1
# Build opm-material
clone_and_build_module opm-material "-DCMAKE_PREFIX_PATH=$WORKSPACE/serial/install -DCMAKE_INSTALL_PREFIX=$WORKSPACE/serial/install" $OPM_MATERIAL_REVISION $WORKSPACE/serial
test $? -eq 0 || exit 1
# Build opm-core
clone_and_build_module opm-core "-DCMAKE_PREFIX_PATH=$WORKSPACE/serial/install -DCMAKE_INSTALL_PREFIX=$WORKSPACE/serial/install" $OPM_CORE_REVISION $WORKSPACE/serial
test $? -eq 0 || exit 1
# Build dune-cornerpoint
clone_and_build_module dune-cornerpoint "-DCMAKE_PREFIX_PATH=$WORKSPACE/serial/install -DCMAKE_INSTALL_PREFIX=$WORKSPACE/serial/install" $DUNE_CORNERPOINT_REVISION $WORKSPACE/serial
test $? -eq 0 || exit 1
# Build opm-output
clone_and_build_module opm-output "-DCMAKE_PREFIX_PATH=$WORKSPACE/serial/install -DCMAKE_INSTALL_PREFIX=$WORKSPACE/serial/install" $OPM_OUTPUT_REVISION $WORKSPACE/serial
test $? -eq 0 || exit 1
# Build opm-autodiff
pushd .
mkdir serial/build-opm-autodiff
cd serial/build-opm-autodiff
build_module "-DCMAKE_PREFIX_PATH=$WORKSPACE/serial/install" 1 $WORKSPACE
test $? -eq 0 || exit 1
popd
}