btrfs-progs: ci: cache built dependencies
For a slight speed up of the build, cache reiserfs and zstd. A quick cache validity is done, or it can be cleared manually on travis web UI. Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
parent
f0a376df47
commit
efc08d3390
|
@ -25,6 +25,9 @@ compiler:
|
||||||
|
|
||||||
cache:
|
cache:
|
||||||
ccache: true
|
ccache: true
|
||||||
|
directories:
|
||||||
|
- tmp-cached-reiser
|
||||||
|
- tmp-cached-zstd
|
||||||
|
|
||||||
git:
|
git:
|
||||||
depth: 1
|
depth: 1
|
||||||
|
|
|
@ -2,14 +2,28 @@
|
||||||
# download, build and install reiserfs library
|
# download, build and install reiserfs library
|
||||||
|
|
||||||
version=3.6.27
|
version=3.6.27
|
||||||
|
dir=tmp-cached-reiser
|
||||||
|
stamp="$dir/.last-build-reiser"
|
||||||
|
here=`pwd`
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
mkdir tmp-reiser
|
if [ -d "$dir" -a -f "$stamp" ]; then
|
||||||
cd tmp-reiser
|
echo "Using valid cache for $dir, built" `cat "$stamp"`
|
||||||
|
cd "$dir"
|
||||||
|
cd reiserfsprogs-${version}
|
||||||
|
sudo make install
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "No or stale cache for $dir, rebuilding"
|
||||||
|
rm -rf "$dir"
|
||||||
|
mkdir "$dir"
|
||||||
|
cd "$dir"
|
||||||
wget https://www.kernel.org/pub/linux/kernel/people/jeffm/reiserfsprogs/v${version}/reiserfsprogs-${version}.tar.xz
|
wget https://www.kernel.org/pub/linux/kernel/people/jeffm/reiserfsprogs/v${version}/reiserfsprogs-${version}.tar.xz
|
||||||
tar xf reiserfsprogs-${version}.tar.xz
|
tar xf reiserfsprogs-${version}.tar.xz
|
||||||
cd reiserfsprogs-${version}
|
cd reiserfsprogs-${version}
|
||||||
./configure --prefix=/usr
|
./configure --prefix=/usr
|
||||||
make all
|
make all
|
||||||
sudo make install
|
sudo make install
|
||||||
|
date > "$here/$stamp"
|
||||||
|
|
|
@ -2,13 +2,27 @@
|
||||||
# download, build and install the zstd library
|
# download, build and install the zstd library
|
||||||
|
|
||||||
version=1.3.3
|
version=1.3.3
|
||||||
|
dir=tmp-cached-zstd
|
||||||
|
stamp="$dir/.last-build-zstd"
|
||||||
|
here=`pwd`
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
mkdir tmp-zstd
|
if [ -d "$dir" -a -f "$stamp" ]; then
|
||||||
cd tmp-zstd
|
echo "Using valid cache for $dir, built" `cat "$stamp"`
|
||||||
|
cd "$dir"
|
||||||
|
cd zstd-${version}
|
||||||
|
sudo make install PREFIX=/usr
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "No or stale cache for $dir, rebuilding"
|
||||||
|
rm -rf "$dir"
|
||||||
|
mkdir "$dir"
|
||||||
|
cd "$dir"
|
||||||
wget https://github.com/facebook/zstd/archive/v${version}.tar.gz
|
wget https://github.com/facebook/zstd/archive/v${version}.tar.gz
|
||||||
tar xf v${version}.tar.gz
|
tar xf v${version}.tar.gz
|
||||||
cd zstd-${version}
|
cd zstd-${version}
|
||||||
make
|
make
|
||||||
sudo make install PREFIX=/usr
|
sudo make install PREFIX=/usr
|
||||||
|
date > "$here/$stamp"
|
||||||
|
|
Loading…
Reference in New Issue