Skip to content

Commit

Permalink
update workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
kroggen committed Dec 18, 2022
1 parent c094f4e commit 8866795
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 5 deletions.
11 changes: 8 additions & 3 deletions .github/workflows/ccpp.yml → .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
name: C/C++ CI
name: CI

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
workflow_dispatch:

jobs:
build:
Expand Down Expand Up @@ -41,9 +42,13 @@ jobs:
if: ${{ matrix.platform == 'ubuntu-latest' }}
run: sudo ldconfig
- name: test C compilation
run: gcc examples/contract_query/contract_query.c -laergo -o contract_query
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
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
Expand Down
13 changes: 11 additions & 2 deletions .github/workflows/msys2.yml → .github/workflows/windows.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: BuildWin
name: Build for Windows

on:
push:
Expand Down Expand Up @@ -49,10 +49,12 @@ jobs:
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvars64.bat"
set vcpkgdir=C:\vcpkg\installed\x64-windows
cl.exe /I. examples\contract_query\contract_query.c builds-win\x64\libaergo-1.1.lib
cl.exe /I. examples\multiple_tasks\multiple_tasks.c builds-win\x64\libaergo-1.1.lib
- name: test C execution
shell: cmd
run: |
.\contract_query.exe
.\multiple_tasks.exe
- name: test C++ compilation
shell: cmd
run: |
Expand All @@ -63,10 +65,17 @@ jobs:
shell: cmd
run: |
.\contract_query_cpp.exe
- name: Prepare artifacts
shell: cmd
run: |
copy libcurl.dll builds-win\x64\
copy zlib1.dll builds-win\x64\
copy nghttp2.dll builds-win\x64\
copy secp256k1-vrf.dll builds-win\x64\
- name: upload artifacts
uses: actions/upload-artifact@v2
with:
name: libaergo-windows
path: |
builds-win/x64

0 comments on commit 8866795

Please sign in to comment.