Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make circuits and assignment tables: CI implementation #23

Merged
merged 4 commits into from
Jun 12, 2023

Conversation

NickVolynkin
Copy link
Contributor

@NickVolynkin NickVolynkin commented Jun 6, 2023

Make circuits and assignment tables: CI implementation

Changes in the tutorial will follow this PR (see #4)

ci: build circuit and assignment table

Script ./scripts/build-circuit-ll.sh runs in an environment with zkLLVM.
First, it builds the LLVM-IR form or circuit (.ll) with zkLLVM CLI.
Next, it builds the assignment table .tbl and circuit .crct with
assigner CLI.

Script scripts/docker-run.sh runs the first one in a container based
on a prebuilt image ghcr.io/nilfoundation/zkllvm-template,
that has all required dependencies, in particular, zkLLVM and Boost.
Script uses Podman when it is available, and Docker otherwise.

Using separate scripts (rather than run steps in CI) enables testing
the same workflow locally with a single command.

CI runs on default GitHub's ubuntu-22.04 runners so that devs who fork
this repository would still have CI working in their forks.

Resolves #5

Remove blueprint dependency from crypto3/marshalling/zk

Dependency on crypto3::blueprint in zk/marshalling was causing
the following error:

CMake Error at cmake/modules/share/modules/cmake/CMFuture.cmake:83 (_add_library):
  Target "zkllvm_circuit" links to target "crypto3::blueprint" but the target
  was not found.  Perhaps a find_package() call is missing for an IMPORTED
  target, or an ALIAS target is missing?

Resolves #22

Crypto3: support optional Boost static library usage

Related to NilFoundation/zkLLVM#85

Revert commits related to #14

This reverts commits:

Resolves #24

@NickVolynkin NickVolynkin force-pushed the test-workflows-in-ci branch 24 times, most recently from b97f853 to 21b2ccf Compare June 12, 2023 08:49
This reverts commits:
* dba71d6
* fbf2d5f
* 08eb154

Resolves #24
Dependency on crypto3::blueprint in zk/marshalling was causing
the following error:

```
CMake Error at cmake/modules/share/modules/cmake/CMFuture.cmake:83 (_add_library):
  Target "zkllvm_circuit" links to target "crypto3::blueprint" but the target
  was not found.  Perhaps a find_package() call is missing for an IMPORTED
  target, or an ALIAS target is missing?
```

Resolves #22
@NickVolynkin NickVolynkin force-pushed the test-workflows-in-ci branch 3 times, most recently from 587b616 to 35bccfc Compare June 12, 2023 10:28
@NickVolynkin NickVolynkin force-pushed the test-workflows-in-ci branch 5 times, most recently from c8753f3 to a4ec8a3 Compare June 12, 2023 11:49
@NickVolynkin NickVolynkin changed the title draft: test workflows in ci Make circuits and assignment tables: CI and tutorial Jun 12, 2023
@NickVolynkin NickVolynkin force-pushed the test-workflows-in-ci branch from a4ec8a3 to e97c5fc Compare June 12, 2023 12:46
@NickVolynkin NickVolynkin changed the title Make circuits and assignment tables: CI and tutorial Make circuits and assignment tables: CI implementation Jun 12, 2023
@NickVolynkin NickVolynkin changed the title Make circuits and assignment tables: CI implementation Make circuits and assignment tables: CI and tutorial Jun 12, 2023
@NickVolynkin NickVolynkin requested a review from nkaskov June 12, 2023 13:00
@NickVolynkin NickVolynkin changed the title Make circuits and assignment tables: CI and tutorial Make circuits and assignment tables: CI implementation Jun 12, 2023
@NickVolynkin NickVolynkin marked this pull request as ready for review June 12, 2023 13:00
Script `./scripts/build-circuit-ll.sh` runs in an environment with zkLLVM.
First, it builds the LLVM-IR form or circuit (`.ll`) with zkLLVM CLI.
Next, it builds the assignment table `.tbl` and circuit `.crct` with
assigner CLI.

Script `scripts/docker-run.sh` runs the first one in a container based
on a prebuilt image `ghcr.io/nilfoundation/zkllvm-template`,
that has all required dependencies, in particular, zkLLVM and Boost.
Script uses Podman when it is available, and Docker otherwise.

Using separate scripts (rather than `run` steps in CI) enables testing
the same workflow locally with a single command.

CI runs on default GitHub's `ubuntu-22.04` runners so that devs who fork
this repository would still have CI working in their forks.

Resolves #5
@NickVolynkin NickVolynkin force-pushed the test-workflows-in-ci branch from e97c5fc to a2aa20b Compare June 12, 2023 13:01
@NickVolynkin NickVolynkin merged commit cb2d4cb into master Jun 12, 2023
@NickVolynkin NickVolynkin deleted the test-workflows-in-ci branch June 12, 2023 13:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants