almost all tests work
[soc.git] / .gitlab-ci.yml
1 image: debian:10
2
3 cache:
4 paths:
5 - ccache
6
7 build:
8 stage: build
9 before_script:
10 - apt-get update
11 - >-
12 apt-get -y install
13 build-essential git python3-dev python3-pip
14 python3-setuptools python3-wheel pkg-config tcl-dev
15 libreadline-dev bison flex libffi-dev ccache python3-venv
16 binutils-powerpc64-linux-gnu binutils-powerpc64le-linux-gnu
17 - export PATH="/usr/lib/ccache:$PATH"
18 - export CCACHE_BASEDIR="$PWD"
19 - export CCACHE_DIR="$PWD/ccache"
20 - export CCACHE_COMPILERCHECK=content
21 - ccache --zero-stats || true
22 - ccache --show-stats || true
23 after_script:
24 - export CCACHE_DIR="$PWD/ccache"
25 - ccache --show-stats
26 script:
27 - python3 -m venv .env
28 - . .env/bin/activate
29 - pip install nose
30
31 - git clone --depth 1 https://github.com/YosysHQ/yosys.git yosys
32 - pushd yosys
33 - make config-gcc
34 - make -j$(nproc)
35 - make install
36 - popd
37 - yosys -V
38
39 - git clone --depth 1 https://github.com/nmigen/nmigen.git nmigen
40 - pushd nmigen
41 - python setup.py develop
42 - popd
43
44 - git clone --depth 1 git://git.libre-riscv.org/nmutil.git nmutil
45 - pushd nmutil
46 - python setup.py develop
47 - popd
48
49 - git clone --depth 1 git://git.libre-riscv.org/ieee754fpu.git ieee754fpu
50 - pushd ieee754fpu
51 - python setup.py develop
52 - popd
53
54 - IEEE754FPU_PATH="$(pwd)"/ieee754fpu
55 - git clone --depth 1 --recursive https://github.com/billzorn/sfpy.git sfpy
56 - pushd sfpy
57 - pushd berkeley-softfloat-3
58 - git apply "$IEEE754FPU_PATH"/berkeley-softfloat.patch
59 - popd
60 - pushd SoftPosit
61 - git apply ../softposit_sfpy_build.patch
62 - git apply "$IEEE754FPU_PATH"/SoftPosit.patch
63 - popd
64 - pip install --upgrade -r requirements.txt
65 - make lib -j$(nproc)
66 - make cython -j$(nproc)
67 - make wheel -j$(nproc)
68 - pip install dist/sfpy*.whl
69 - popd
70
71 - python setup.py develop
72 - python src/soc/decoder/pseudo/pywriter.py
73 - nosetests -v --processes=-1