about summary refs log tree commit diff homepage
path: root/.travis/install-tcmalloc.sh
diff options
context:
space:
mode:
authorAndrea Mattavelli <andreamattavelli@users.noreply.github.com>2017-03-24 08:28:34 +0000
committerGitHub <noreply@github.com>2017-03-24 08:28:34 +0000
commit3a8bc6a43073b98b58c8cf0c20a930cb2c953b5d (patch)
tree2d63ab8ade34cd54cf765a461639c6bbf93d8962 /.travis/install-tcmalloc.sh
parent396db899b5ae4ad011ef413e12b571556ec75f47 (diff)
parent3d6db3261b124bc1705eb647f8c8bea89d936af6 (diff)
downloadklee-3a8bc6a43073b98b58c8cf0c20a930cb2c953b5d.tar.gz
Merge pull request #595 from andreamattavelli/travis_macosx
Travis-CI target for macOS
Diffstat (limited to '.travis/install-tcmalloc.sh')
-rwxr-xr-x.travis/install-tcmalloc.sh23
1 files changed, 15 insertions, 8 deletions
diff --git a/.travis/install-tcmalloc.sh b/.travis/install-tcmalloc.sh
index 5a86380b..a0d825e1 100755
--- a/.travis/install-tcmalloc.sh
+++ b/.travis/install-tcmalloc.sh
@@ -1,12 +1,19 @@
 #!/bin/bash -x
 set -ev
 
-if [ ${USE_TCMALLOC:-0} -eq 1 ] ; then
-	# Get tcmalloc release
-	wget https://github.com/gperftools/gperftools/releases/download/gperftools-2.4/gperftools-2.4.tar.gz
-	tar xfz gperftools-2.4.tar.gz
-	cd gperftools-2.4
-	./configure --disable-dependency-tracking --disable-cpu-profiler --disable-heap-checker --disable-debugalloc  --enable-minimal --prefix=/usr
-	make
-	sudo make install
+if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then
+  if [ ${USE_TCMALLOC:-0} -eq 1 ] ; then
+    # Get tcmalloc release
+    wget https://github.com/gperftools/gperftools/releases/download/gperftools-2.4/gperftools-2.4.tar.gz
+    tar xfz gperftools-2.4.tar.gz
+    cd gperftools-2.4
+    ./configure --disable-dependency-tracking --disable-cpu-profiler --disable-heap-checker --disable-debugalloc  --enable-minimal --prefix=/usr
+    make
+    sudo make install
+  fi
+else # OSX
+  if [ ${USE_TCMALLOC:-0} -eq 1 ] ; then
+    echo "Error: Requested to install TCMalloc on macOS, which is not supported"
+    exit 1
+  fi
 fi