forked from libre-chip/fayalite
		
	
		
			
				
	
	
		
			63 lines
		
	
	
	
		
			2 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
			
		
		
	
	
			63 lines
		
	
	
	
		
			2 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
# SPDX-License-Identifier: LGPL-3.0-or-later
 | 
						|
# See Notices.txt for copyright information
 | 
						|
on: [push, pull_request]
 | 
						|
 | 
						|
jobs:
 | 
						|
  deps:
 | 
						|
    runs-on: debian-12
 | 
						|
    uses: ./.forgejo/workflows/deps.yml
 | 
						|
  test:
 | 
						|
    runs-on: debian-12
 | 
						|
    needs: deps
 | 
						|
    steps:
 | 
						|
      - uses: https://git.libre-chip.org/mirrors/checkout@v3
 | 
						|
        with:
 | 
						|
          fetch-depth: 0
 | 
						|
      - run: |
 | 
						|
          scripts/check-copyright.sh
 | 
						|
      - run: |
 | 
						|
          apt-get update -qq
 | 
						|
          apt-get install -qq \
 | 
						|
            bison \
 | 
						|
            build-essential \
 | 
						|
            ccache \
 | 
						|
            clang \
 | 
						|
            cvc5 \
 | 
						|
            flex \
 | 
						|
            gawk \
 | 
						|
            git \
 | 
						|
            libboost-filesystem-dev \
 | 
						|
            libboost-python-dev \
 | 
						|
            libboost-system-dev \
 | 
						|
            libffi-dev \
 | 
						|
            libreadline-dev \
 | 
						|
            lld \
 | 
						|
            pkg-config \
 | 
						|
            python3 \
 | 
						|
            python3-click \
 | 
						|
            tcl-dev \
 | 
						|
            z3 \
 | 
						|
            zlib1g-dev
 | 
						|
      - run: |
 | 
						|
          curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --default-toolchain 1.89.0
 | 
						|
          source "$HOME/.cargo/env"
 | 
						|
          echo "$PATH" >> "$GITHUB_PATH"
 | 
						|
      - uses: https://git.libre-chip.org/mirrors/cache/restore@v3
 | 
						|
        with:
 | 
						|
          path: deps
 | 
						|
          key: ${{ needs.deps.outputs.cache-primary-key }}
 | 
						|
          fail-on-cache-miss: true
 | 
						|
      - run: |
 | 
						|
          make -C deps/z3/build install
 | 
						|
          make -C deps/sby install
 | 
						|
          make -C deps/yosys install
 | 
						|
          export PATH="$(realpath deps/firtool/bin):$PATH"
 | 
						|
          echo "$PATH" >> "$GITHUB_PATH"
 | 
						|
      - uses: https://git.libre-chip.org/mirrors/rust-cache@v2
 | 
						|
        with:
 | 
						|
          save-if: ${{ github.ref == 'refs/heads/master' }}
 | 
						|
      - run: cargo test
 | 
						|
      - run: cargo build --tests --features=unstable-doc
 | 
						|
      - run: cargo test --doc --features=unstable-doc
 | 
						|
      - run: cargo doc --features=unstable-doc
 | 
						|
      - run: FAYALITE_TEST_HASHER=always_zero cargo test --test=module --features=unstable-doc,unstable-test-hasher
 |