fix(ci): Deps cache

This commit is contained in:
Michael Carlberg 2017-01-25 15:21:58 +01:00
parent 02ab1b9a81
commit 214b3ddca8
5 changed files with 11 additions and 14 deletions

View File

@ -52,6 +52,8 @@ cache:
- ${TRAVIS_BUILD_DIR}/deps/xcb-util-xrm - ${TRAVIS_BUILD_DIR}/deps/xcb-util-xrm
install: install:
- DEPS_DIR="${TRAVIS_BUILD_DIR}/deps"
- mkdir -p "${DEPS_DIR}" && cd "${DEPS_DIR}"
- source ${TRAVIS_BUILD_DIR}/common/travis/environment.sh - source ${TRAVIS_BUILD_DIR}/common/travis/environment.sh
- source ${TRAVIS_BUILD_DIR}/common/travis/install_xcb_xrm.sh - source ${TRAVIS_BUILD_DIR}/common/travis/install_xcb_xrm.sh
- source ${TRAVIS_BUILD_DIR}/common/travis/install_cmake.sh - source ${TRAVIS_BUILD_DIR}/common/travis/install_cmake.sh

View File

@ -1,10 +1,4 @@
#!/bin/bash #!/bin/bash
export DEPS_DIR="${TRAVIS_BUILD_DIR}/deps"
export LLVM_ROOT="${DEPS_DIR}/llvm-${LLVM_VERSION}"
mkdir -p "${DEPS_DIR}"
mkdir -p "${LLVM_ROOT}"
# Update compiler flags # Update compiler flags
if [ "${CXX:0:7}" = "clang++" ]; then if [ "${CXX:0:7}" = "clang++" ]; then
export CXX="clang++-3.8" export CXX="clang++-3.8"

View File

@ -1,8 +1,7 @@
#!/bin/bash #!/bin/bash
if [ -z "$(ls -A "${DEPS_DIR}/cmake/bin" 2>/dev/null)" ]; then if [ -z "$(ls -A "${DEPS_DIR}/cmake/bin" 2>/dev/null)" ]; then
mkdir -p "${DEPS_DIR}/cmake" mkdir -p "cmake"
cd "${DEPS_DIR}/cmake" || exit 1 travis_retry wget --no-check-certificate -O - "${CMAKE_URL}" | tar --strip-components=1 -xz -C cmake
travis_retry wget --no-check-certificate -O - "${CMAKE_URL}" | tar --strip-components=1 -xz
fi fi
export PATH="${DEPS_DIR}/cmake/bin:${PATH}" export PATH="${DEPS_DIR}/cmake/bin:${PATH}"

View File

@ -1,5 +1,7 @@
#!/bin/bash #!/bin/bash
if [ "${CXX:0:7}" = "clang++" ]; then if [ "${CXX:0:7}" = "clang++" ]; then
LLVM_ROOT="${DEPS_DIR}/llvm-${LLVM_VERSION}"
if [ -z "$(ls -A "${LLVM_ROOT}/install/include" 2>/dev/null)" ]; then if [ -z "$(ls -A "${LLVM_ROOT}/install/include" 2>/dev/null)" ]; then
mkdir -p "${LLVM_ROOT}" "${LLVM_ROOT}/build" "${LLVM_ROOT}/projects/libcxx" "${LLVM_ROOT}/projects/libcxxabi" mkdir -p "${LLVM_ROOT}" "${LLVM_ROOT}/build" "${LLVM_ROOT}/projects/libcxx" "${LLVM_ROOT}/projects/libcxxabi"

View File

@ -1,9 +1,9 @@
#!/bin/bash #!/bin/bash
if [ -z "$(ls -A "${DEPS_DIR}/xcb-util-xrm" 2>/dev/null)" ]; then if [ -z "$(ls -A "${DEPS_DIR}/xcb-util-xrm" 2>/dev/null)" ]; then
cd "${DEPS_DIR}" || exit 1
git clone --recursive https://github.com/Airblader/xcb-util-xrm git clone --recursive https://github.com/Airblader/xcb-util-xrm
cd xcb-util-xrm || exit 1 cd xcb-util-xrm && {
./autogen.sh --prefix=/usr --libdir=/usr/lib ./autogen.sh --prefix=/usr --libdir=/usr/lib
make make
sudo make install sudo make install
}
fi fi