From 20c3f3c81317a3cb0a442fe556fcb4f7a690efc1 Mon Sep 17 00:00:00 2001 From: Shunsuke Michii Date: Fri, 11 Nov 2016 12:47:11 +0900 Subject: [PATCH 1/2] Remove dpkg install to run without sudo permission. --- .travis.yml | 4 +--- travis-install-libjpeg-turbo.sh | 5 ++--- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/.travis.yml b/.travis.yml index f1a6edc..5c0048f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,5 @@ language: go -sudo: true - go: - 1.6 - 1.7 @@ -9,7 +7,7 @@ go: env: - TURBO_VER="" - - TURBO_VER="1.5.1" CGO_LDFLAGS="-L/opt/libjpeg-turbo/lib64" CGO_CPPFLAGS="-I/opt/libjpeg-turbo/include" LD_LIBRARY_PATH="/opt/libjpeg-turbo/lib64" + - TURBO_VER="1.5.1" CGO_LDFLAGS="-L/tmp/libjpeg-turbo/lib64" CGO_CPPFLAGS="-I/tmp/libjpeg-turbo/include" LD_LIBRARY_PATH="/tmp/libjpeg-turbo/lib64" before_install: - ./travis-install-libjpeg-turbo.sh "$TURBO_VER" diff --git a/travis-install-libjpeg-turbo.sh b/travis-install-libjpeg-turbo.sh index d25c524..5f74c7f 100755 --- a/travis-install-libjpeg-turbo.sh +++ b/travis-install-libjpeg-turbo.sh @@ -3,7 +3,6 @@ if [ "$1" != "" ]; then cd /tmp wget http://downloads.sourceforge.net/project/libjpeg-turbo/$1/libjpeg-turbo-official_$1_amd64.deb - sudo dpkg -i libjpeg-turbo-official_$1_amd64.deb - find /opt/libjpeg-turbo/lib64 - find /opt/libjpeg-turbo/include + sudo dpkg -x libjpeg-turbo-official_$1_amd64.deb /tmp/libjpeg-turbo-official + mv /tmp/libjpeg-turbo-official/opt/libjpeg-turbo /tmp/libjpeg-turbo fi From 853f117dac809886ce5cd7313ee934eb0b939db2 Mon Sep 17 00:00:00 2001 From: Shunsuke Michii Date: Fri, 11 Nov 2016 13:12:23 +0900 Subject: [PATCH 2/2] Remove sudo. --- travis-install-libjpeg-turbo.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/travis-install-libjpeg-turbo.sh b/travis-install-libjpeg-turbo.sh index 5f74c7f..ea914f9 100755 --- a/travis-install-libjpeg-turbo.sh +++ b/travis-install-libjpeg-turbo.sh @@ -3,6 +3,6 @@ if [ "$1" != "" ]; then cd /tmp wget http://downloads.sourceforge.net/project/libjpeg-turbo/$1/libjpeg-turbo-official_$1_amd64.deb - sudo dpkg -x libjpeg-turbo-official_$1_amd64.deb /tmp/libjpeg-turbo-official + dpkg -x libjpeg-turbo-official_$1_amd64.deb /tmp/libjpeg-turbo-official mv /tmp/libjpeg-turbo-official/opt/libjpeg-turbo /tmp/libjpeg-turbo fi