.gitlab-ci.yml 1.11 KB
Newer Older
Javad Ebrahimian Amiri's avatar
Javad Ebrahimian Amiri committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40
stages:
  - build

before_script:
  - export MU_ZEBU=$CI_PROJECT_DIR/mu-impl-fast
  - export ZEBU_BUILD=release
  - export CARGO_HOME=.cargo
  - export LD_LIBRARY_PATH=$MU_ZEBU/target/$ZEBU_BUILD/deps/:$LD_LIBRARY_PATH
  - source /home/gitlab-runner/ci/bin/activate

build_mu:
  stage: build
  script:
    - if [ -d "mu-impl-fast" ]; then rm -Rf mu-impl-fast; fi
    - git clone git@gitlab.anu.edu.au:mu/mu-impl-fast.git
    - cd mu-impl-fast
    - export CC=clang
    - export CXX=clang++
    - rustup run 1.30.1-x86_64-unknown-linux-gnu cargo clean
    - time rustup run 1.30.1-x86_64-unknown-linux-gnu cargo test -j6 --release --no-run --color=always
    - cd ..
  artifacts:
    paths:
      - $MU_ZEBU/target/release/deps/libmu.so
      - $MU_ZEBU/target/release/deps/libmu.a
      - $MU_ZEBU/target/release/deps/lib-*

build_muc:
  stage: build
  script:
    - export CC=gcc
    - export CXX=g++
    - export ANTLR_HOME=/home/gitlab-runner/antlr4/runtime/Cpp/run
    - mkdir lib
    - cp -r $ANTLR_HOME/usr/local/lib/* $PWD/lib/
    - cp -r $MU_ZEBU/target/release/deps/* $PWD/lib/
    - time make
  artifacts:
    paths:
      - muc