зеркало из https://github.com/microsoft/caffe.git
Cache protobuf3 build in TravisCI
This commit is contained in:
Родитель
6f15463657
Коммит
994a033a72
|
@ -28,7 +28,10 @@ env:
|
|||
- BUILD_NAME="cudnn-cmake" WITH_CMAKE=true WITH_CUDA=true WITH_CUDNN=true
|
||||
|
||||
cache:
|
||||
timeout: 604800 # 1 week
|
||||
apt: true
|
||||
directories:
|
||||
- ~/protobuf3
|
||||
|
||||
before_install:
|
||||
- source ./scripts/travis/defaults.sh
|
||||
|
|
|
@ -40,9 +40,13 @@ else
|
|||
python3-skimage
|
||||
|
||||
# build Protobuf3 since it's needed for Python3
|
||||
echo "Building protobuf3 from source ..."
|
||||
PROTOBUF3_DIR=~/protobuf3
|
||||
pushd .
|
||||
PROTOBUF3_DIR=~/protobuf3-build
|
||||
if [ -d "$PROTOBUF3_DIR" ] && [ -e "$PROTOBUF3_DIR/src/protoc" ]; then
|
||||
echo "Using cached protobuf3 build ..."
|
||||
cd $PROTOBUF3_DIR
|
||||
else
|
||||
echo "Building protobuf3 from source ..."
|
||||
rm -rf $PROTOBUF3_DIR
|
||||
mkdir $PROTOBUF3_DIR
|
||||
|
||||
|
@ -59,6 +63,7 @@ else
|
|||
./autogen.sh
|
||||
./configure --prefix=/usr
|
||||
make --jobs=$NUM_THREADS
|
||||
fi
|
||||
make install
|
||||
popd
|
||||
fi
|
||||
|
|
Загрузка…
Ссылка в новой задаче