mirror of
https://gitlab.kitware.com/vtk/vtk-m
synced 2024-10-05 09:59:12 +00:00
f4386cfb86
Signed-off-by: Vicente Adolfo Bolea Sanchez <vicente.bolea@kitware.com> (cherry picked from commit d4cfe340096c2269197bedaa65ae45d734257ae5)
28 lines
653 B
Bash
Executable File
28 lines
653 B
Bash
Executable File
#!/bin/bash
|
|
|
|
set -xe
|
|
|
|
readonly version="v1.5.2"
|
|
readonly tarball="$version.tar.gz"
|
|
readonly url="https://github.com/google/benchmark/archive/$tarball"
|
|
readonly sha256sum="dccbdab796baa1043f04982147e67bb6e118fe610da2c65f88912d73987e700c"
|
|
readonly install_dir="$HOME/gbench"
|
|
|
|
if ! [[ "$VTKM_SETTINGS" =~ "benchmarks" ]]; then
|
|
exit 0
|
|
fi
|
|
|
|
cd "$HOME"
|
|
|
|
echo "$sha256sum $tarball" > gbenchs.sha256sum
|
|
curl --insecure -OL "$url"
|
|
sha256sum --check gbenchs.sha256sum
|
|
tar xf "$tarball"
|
|
|
|
mkdir build
|
|
mkdir "$install_dir"
|
|
|
|
cmake -GNinja -S benchmark* -B build -DBENCHMARK_DOWNLOAD_DEPENDENCIES=ON
|
|
cmake --build build
|
|
cmake --install build --prefix "$install_dir"
|