diff --git a/.travis.yml b/.travis.yml index d9daae7..1f97803 100644 --- a/.travis.yml +++ b/.travis.yml @@ -25,46 +25,48 @@ env: - TOOLCHAIN=xilinx-series-7 OS=centos OS_VERSION=7 - TOOLCHAIN=xilinx-series-7 OS=centos OS_VERSION=8 - - -#before_install: -# - sudo locale-gen "en_US.UTF-8" -# - export LANG="en_US.UTF-8" -# - pip install git+https://github.com/antmicro/tuttest -# - tuttest README.md unnamed0 | bash - - install: + - if [ "$OS" = "ubuntu" ]; then export INSTALL_COMMAND="apt update && apt install -y"; fi + - if [ "$OS" = "centos" ]; then export INSTALL_COMMAND="yum -y install"; fi + - if [ "$OS" = "ubuntu" ]; then export INSTALL_PACKAGES="locales software-properties-common git wget xz-utils make build-essential zlib1g libz-dev libffi-dev ca-certificates"; fi + - if [ "$OS" = "centos" ]; then export INSTALL_PACKAGES="git wget make gcc-c++ zlib-devel xz libffi-devel perl-Pod-Html diffutils byacc"; fi + - export DOCKER_NAME=test + - export IN_DOCKER_EXEC="docker exec -it $DOCKER_NAME" - docker create - --name test + --name $DOCKER_NAME --env LANG="en_US.UTF-8" + --env LANGUAGE="en_US" --env DEBIAN_FRONTEND="noninteractive" - --volume /home/travis + -v /home/travis:/home/travis --workdir $PWD --interactive --tty $OS:$OS_VERSION - - docker start test - - docker ps - - docker exec test ps fax - - docker exec test ls -l - - docker exec test pip install git+https://github.com/antmicro/tuttest - + - docker start $DOCKER_NAME + - $IN_DOCKER_EXEC bash -c "$INSTALL_COMMAND $INSTALL_PACKAGES" + - if [ "$OS" = "ubuntu" ]; then $IN_DOCKER_EXEC locale-gen en_US.UTF-8; fi + - if [ "$OS" = "ubuntu" ]; then $IN_DOCKER_EXEC update-locale; fi + - $IN_DOCKER_EXEC wget https://www.openssl.org/source/openssl-1.1.1c.tar.gz + - $IN_DOCKER_EXEC tar xf openssl-1.1.1c.tar.gz + - $IN_DOCKER_EXEC bash -c 'cd openssl-1.1.1c && ./config --prefix=/usr/local --openssldir=/usr/local/ssl shared zlib && make install > /dev/null' + - if [ "$OS" = "centos" ]; then $IN_DOCKER_EXEC bash -c 'echo "/usr/local/lib64" | tee -a /etc/ld.so.conf'; fi + - $IN_DOCKER_EXEC ldconfig + - if [ "$OS" = "centos" ] && [ "$OS_VERSION" == "8" ]; then $IN_DOCKER_EXEC bash -c "wget https://kerberos.org/dist/krb5/1.17/krb5-1.17.1.tar.gz && tar xf krb5-1.17.1.tar.gz && cd krb5-1.17.1/src && ./configure && make && cp lib/libk5crypto.so.3.1 /lib64/"; fi + - if [ "$OS" = "centos" ] && [ "$OS_VERSION" == "8" ]; then $IN_DOCKER_EXEC bash -c "rm /lib64/libk5crypto.so.3 && ln -s /lib64/libk5crypto.so.3.1 /lib64/libk5crypto.so.3"; fi + - $IN_DOCKER_EXEC ldconfig + - $IN_DOCKER_EXEC wget https://www.python.org/ftp/python/3.7.9/Python-3.7.9.tar.xz --ca-directory=/etc/ssl/certs/ + - $IN_DOCKER_EXEC tar xf Python-3.7.9.tar.xz + - $IN_DOCKER_EXEC bash -c 'cd ./Python-3.7.9/ && ./configure > /dev/null && make install > /dev/null' + - $IN_DOCKER_EXEC ln -s /usr/local/bin/python3.7 /usr/local/bin/python + - $IN_DOCKER_EXEC ln -s /usr/local/bin/pip3 /usr/local/bin/pip + - $IN_DOCKER_EXEC python --version + - $IN_DOCKER_EXEC pip --version + - $IN_DOCKER_EXEC pip install git+https://github.com/antmicro/tuttest + - $IN_DOCKER_EXEC tuttest README.md unnamed0 | tr -d '\r' | bash - + - if [ "$TOOLCHAIN" = "xilinx-series-7" ]; then $IN_DOCKER_EXEC tuttest README.md unnamed1 | tr -d '\r' | bash -; fi + - if [ "$TOOLCHAIN" = "quicklogic" ]; then $IN_DOCKER_EXEC tuttest README.md unnamed2 | tr -d '\r' | bash -; fi script: - - true - -#jobs: -# include: -# - stage: SymbiFlow -# install: -# - tuttest README.md unnamed1 | bash - -# -# script: -# - tuttest README.md unnamed3 | bash - -# - # -# install: -# - tuttest README.md unnamed2 | bash - -# -# script: -# - tuttest README.md unnamed4 | bash - + - if [ "$TOOLCHAIN" = "xilinx-series-7" ]; then $IN_DOCKER_EXEC tuttest README.md unnamed3 | tr -d '\r' | bash -; fi + - if [ "$TOOLCHAIN" = "quicklogic" ]; then $IN_DOCKER_EXEC tuttest README.md unnamed4 | tr -d '\r' | bash -; fi