Joakim Bech | 20b4276 | 2017-04-07 12:39:16 +0200 | [diff] [blame] | 1 | # Travis configuration file for downloading and building OP-TEE according to the |
| 2 | # instructions in build.git |
| 3 | language: bash |
| 4 | |
| 5 | notifications: |
| 6 | email: |
| 7 | recipients: |
| 8 | - joakim.bech@linaro.org |
| 9 | on_success: change |
| 10 | on_failure: always |
| 11 | |
| 12 | dist: trusty |
| 13 | sudo: required |
| 14 | group: beta |
| 15 | |
| 16 | cache: |
| 17 | directories: |
| 18 | - $HOME/.ccache |
| 19 | |
| 20 | git: |
| 21 | depth: 10 |
| 22 | |
| 23 | after_script: |
| 24 | - ccache -s |
| 25 | |
| 26 | before_install: |
| 27 | - ccache -s |
| 28 | - sudo dpkg --add-architecture i386 |
| 29 | - sudo apt-get update -qq |
| 30 | # Package list taken from README.md |
| 31 | - sudo apt-get install -qq -y android-tools-adb android-tools-fastboot autoconf automake bc bison build-essential cscope curl device-tree-compiler flex ftp-upload gdisk iasl libattr1-dev libc6:i386 libcap-dev libfdt-dev libftdi-dev libglib2.0-dev libhidapi-dev libncurses5-dev libpixman-1-dev libssl-dev libstdc++6:i386 libtool libz1:i386 make mtools netcat python-crypto python-serial python-wand unzip uuid-dev xdg-utils xterm xz-utils zlib1g-dev |
| 32 | |
| 33 | install: true |
| 34 | |
| 35 | env: |
| 36 | - $REPO_PROJ=default |
| 37 | - $REPO_PROJ=fvp |
| 38 | - $REPO_PROJ=hikey |
| 39 | - $REPO_PROJ=juno |
| 40 | - $REPO_PROJ=mt8173-evb |
| 41 | - $REPO_PROJ=qemu_v8 |
| 42 | - $REPO_PROJ=rpi3 |
| 43 | #- $REPO_PROJ=dra7xx # Cannot build this since it requires TI_SECURE_DEV_PKG |
| 44 | |
| 45 | before_script: |
Joakim Bech | 5d2df84 | 2017-07-25 19:43:35 +0200 | [diff] [blame] | 46 | - mkdir -p $HOME/bin |
Joakim Bech | 20b4276 | 2017-04-07 12:39:16 +0200 | [diff] [blame] | 47 | - cd $HOME/bin && wget https://storage.googleapis.com/git-repo-downloads/repo && chmod +x repo |
| 48 | - export PATH=$HOME/bin:$PATH |
| 49 | - mkdir -p $HOME/$REPO_PROJ |
| 50 | |
| 51 | script: |
| 52 | # Special case for FVP, since we check for the Foundation_Platformpkg folder |
| 53 | # in the makefile. |
| 54 | - if [ $REPO_PROJ == "fvp" ]; then mkdir -p $HOME/$REPO_PROJ/Foundation_Platformpkg; fi |
| 55 | # Use the manifest from the branch itself we're pushing to. |
Joakim Bech | a4e36e9 | 2017-05-31 14:24:51 +0200 | [diff] [blame] | 56 | - | |
| 57 | if [ "$TRAVIS_EVENT_TYPE" == "pull_request" ]; then |
| 58 | slug=$TRAVIS_PULL_REQUEST_SLUG |
| 59 | branch=$TRAVIS_PULL_REQUEST_BRANCH |
| 60 | else |
| 61 | slug=$TRAVIS_REPO_SLUG |
| 62 | branch=$TRAVIS_BRANCH |
| 63 | fi |
| 64 | echo "Getting ${REPO_PROJ}_stable.xml from https://github.com/$slug using branch $branch" |
| 65 | cd $HOME/$REPO_PROJ && repo init -u https://github.com/$slug -b $branch -m ${REPO_PROJ}_stable.xml </dev/null && repo sync -j2 --no-clone-bundle --no-tags --quiet |
Joakim Bech | 20b4276 | 2017-04-07 12:39:16 +0200 | [diff] [blame] | 66 | # Fetch a local copy of dtc+libfdt to avoid issues with a possibly outdated libfdt-dev |
| 67 | - if [ $REPO_PROJ == "qemu_v8" ]; then cd $HOME/$REPO_PROJ/qemu && git submodule update --init dtc; fi |
| 68 | # Dump the content of the manifest (for debug purpose) |
| 69 | - cat $HOME/$REPO_PROJ/.repo/manifests/${REPO_PROJ}_stable.xml |
| 70 | - cd $HOME/$REPO_PROJ/build && make -f toolchain.mk toolchains -j3 && make all -j`nproc` |