From 3a9b86abd0cfd27cda7da4840f2809a4d098ed63 Mon Sep 17 00:00:00 2001 From: xjd Date: Tue, 6 Feb 2024 12:36:20 +0800 Subject: [PATCH] Add clang CI --- .github/workflows/clang.yml | 17 +++++++++++++++++ Makefile.clang | 2 +- 2 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/clang.yml diff --git a/.github/workflows/clang.yml b/.github/workflows/clang.yml new file mode 100644 index 0000000..1dc79e6 --- /dev/null +++ b/.github/workflows/clang.yml @@ -0,0 +1,17 @@ +name: Rust + +on: [push, pull_request] + +jobs: + build: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v1 + - name: Update submodules + run: git submodule update --init + - name: Build contract + run: make -f Makefile.clang all-via-docker + - name: Run omni_lock tests + run: cd tests/omni_lock_rust && cargo test diff --git a/Makefile.clang b/Makefile.clang index 3c94c1a..fdd2230 100644 --- a/Makefile.clang +++ b/Makefile.clang @@ -85,7 +85,7 @@ omni_lock_mol: build/cobuild.o: c/cobuild.c c/cobuild.h $(CC) -c $(OMNI_LOCK_CFLAGS) -o $@ $< -build/omni_lock.o: c/omni_lock.c c/omni_lock_supply.h c/omni_lock_acp.h c/secp256k1_lock.h build/secp256k1_data_info_20210801.h $(SECP256K1_SRC_20210801) c/ckb_identity.h +build/omni_lock.o: c/omni_lock.c c/omni_lock_supply.h c/omni_lock_acp.h build/secp256k1_data_info_20210801.h $(SECP256K1_SRC_20210801) c/ckb_identity.h $(CC) -c $(OMNI_LOCK_CFLAGS) -o $@ $< build/omni_lock: build/omni_lock.o build/cobuild.o