Merge pull request #15 from bitzyz/dev-runtime-fix #60
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build and test cpu | |
| on: | |
| push: | |
| paths-ignore: | |
| - '**.md' | |
| - 'LICENSE' | |
| pull_request: | |
| paths: | |
| - '**.md' | |
| - 'LICENSE' | |
| jobs: | |
| build: | |
| name: Build | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v3 | |
| with: | |
| submodules: recursive | |
| - name: Setup SSH | |
| uses: webfactory/ssh-agent@v0.8.0 | |
| with: | |
| ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }} | |
| - name: Clone InfiniCore | |
| run: | | |
| if [ ! -d InfiniCore ]; then | |
| git clone git@github.com:InfiniTensor/InfiniCore.git && | |
| cd InfiniCore && | |
| git submodule update --init && | |
| git checkout 3c8fb3c05036c95faa2eee42bf8fcc42775edd43 | |
| else | |
| echo "InfiniCore already exists" | |
| fi | |
| - name: Install Xmake | |
| run: | | |
| curl -fsSL https://xmake.io/shget.text | bash | |
| echo "$HOME/.xmake" >> $GITHUB_PATH | |
| - name: Install dependencies | |
| run: cd InfiniCore && xmake require -y | |
| - name: build InfiniCore | |
| run: cd InfiniCore && python scripts/install.py | |
| - name: set INFINI_ROOT environment | |
| run: echo "INFINI_ROOT=~/.infini" >> $GITHUB_ENV && echo "LD_LIBRARY_PATH=$INFINI_ROOT/lib:$LD_LIBRARY_PATH" >> $GITHUB_ENV | |
| - name: Build InfiniTensor | |
| run: make install-python | |
| - name: Test cpu | |
| run: make test | |
| - name: Test python-frontend | |
| run: pip install -r requirements.txt && pytest python/tests/ |