examples: add multicall #2
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: CI | |
| on: | |
| push: | |
| branches: [ master ] | |
| pull_request: | |
| branches: [ master ] | |
| workflow_dispatch: | |
| jobs: | |
| build: | |
| strategy: | |
| matrix: | |
| platform: [ubuntu-latest, macos-latest] | |
| runs-on: ${{ matrix.platform }} | |
| if: "!contains(github.event.head_commit.message, 'skip ci')" | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - name: ubuntu | |
| if: ${{ matrix.platform == 'ubuntu-latest' }} | |
| run: sudo apt install libcurl4-openssl-dev -y | |
| - name: mac | |
| if: ${{ matrix.platform == 'macos-latest' }} | |
| run: brew install automake | |
| - name: install dependencies | |
| run: | | |
| git clone --depth=1 https://github.com/aergoio/secp256k1-vrf | |
| cd secp256k1-vrf | |
| ./autogen.sh | |
| ./configure | |
| make | |
| sudo make install | |
| cd .. | |
| - name: build | |
| run: make debug | |
| - name: install | |
| run: sudo make install | |
| - name: ldconfig | |
| if: ${{ matrix.platform == 'ubuntu-latest' }} | |
| run: sudo ldconfig | |
| - name: test C compilation | |
| run: | | |
| gcc examples/contract_query/contract_query.c -laergo -o contract_query | |
| gcc examples/multiple_tasks/multiple_tasks.c -laergo -o multiple_tasks | |
| - name: test C execution | |
| run: | | |
| ./contract_query | |
| ./multiple_tasks | |
| - name: test C++ compilation | |
| run: g++ examples/contract_query/contract_query.cpp -std=c++17 -laergo -o contract_query_cpp | |
| - name: test C++ execution | |
| run: ./contract_query_cpp |