Merged PR 17572: Add Azure pipeline with make install

A new Azure pipeline testing `make install`.
This commit is contained in:
Roman Grundkiewicz 2021-02-08 16:09:28 +00:00
parent 5aeea4e066
commit 80b74b8441

View File

@ -382,3 +382,57 @@ stages:
./spm_encode --version
displayName: Print versions
workingDirectory: build
######################################################################
- job: BuildInstall
displayName: Linux CPU library install
pool:
vmImage: ubuntu-18.04
steps:
- checkout: self
submodules: true
# The following packages are already installed on Azure-hosted runners: build-essential openssl libssl-dev
# No need to install libprotobuf{17,10,9v5} on Ubuntu {20,18,16}.04 because it is installed together with libprotobuf-dev
- bash: sudo apt-get install -y libgoogle-perftools-dev libprotobuf-dev protobuf-compiler
displayName: Install packages
# https://software.intel.com/content/www/us/en/develop/articles/installing-intel-free-libs-and-python-apt-repo.html
- bash: |
wget -qO- "https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS-2019.PUB" | sudo apt-key add -
sudo sh -c "echo deb https://apt.repos.intel.com/mkl all main > /etc/apt/sources.list.d/intel-mkl.list"
sudo apt-get update -o Dir::Etc::sourcelist="/etc/apt/sources.list.d/intel-mkl.list"
sudo apt-get install -y --no-install-recommends intel-mkl-64bit-2020.0-088
displayName: Install MKL
- bash: /usr/bin/gcc-7 --version
displayName: Print GCC version
- bash: |
mkdir -p install
mkdir -p build
cd build
CC=/usr/bin/gcc-7 CXX=/usr/bin/g++-7 \
cmake .. \
-DCMAKE_INSTALL_PREFIX=../install \
-DCMAKE_BUILD_TYPE=slim \
-DCOMPILE_LIBRARY_ONLY=on \
-DCOMPILE_CUDA=off \
-DGENERATE_MARIAN_INSTALL_TARGETS=on \
-DUSE_FBGEMM=on \
-DUSE_SENTENCEPIECE=on
displayName: Configure CMake
- bash: make -j3 install
displayName: Compile & install
workingDirectory: build
- bash: |
test -e lib/libmarian.a
test -e lib/libfbgemm.a
test -e lib/libsentencepiece.a
ls -lah *
displayName: Check targets
workingDirectory: install