diff --git a/.github/workflows/clang-sanitizers-linux-nix-check.yml b/.github/workflows/clang-sanitizers-linux-nix-check.yml new file mode 100644 index 000000000..331c001c1 --- /dev/null +++ b/.github/workflows/clang-sanitizers-linux-nix-check.yml @@ -0,0 +1,24 @@ +name: Build and Test on Linux Platforms + +on: + workflow_call: + +jobs: + build-and-test: + name: "Build and test Linux with clang" + runs-on: [self-hosted, Linux, X64, aws_autoscaling] + steps: + # https://github.com/actions/checkout/issues/1552 + - name: Clean up after previous checkout + run: chmod +w -R ${GITHUB_WORKSPACE}; rm -rf ${GITHUB_WORKSPACE}/*; + + - name: Checkout + uses: actions/checkout@v3 + with: + fetch-depth: 0 + + - name: Run checks + run: nix build -L .?#checks.x86_64-linux.all-sanitizers + env: + NIX_CONFIG: | + cores = 4 diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml index 093b840c3..9c35c4036 100644 --- a/.github/workflows/pull-request.yml +++ b/.github/workflows/pull-request.yml @@ -29,6 +29,13 @@ jobs: always() && !cancelled() secrets: inherit + test-linux-sanitizers: + name: Linux Crypto3 Test and sanitize with clang + uses: ./.github/workflows/clang-sanitizers-linux-nix-check.yml + if: | + always() && !cancelled() + secrets: inherit + check-proof-producer: name: Check Proof Producer uses: ./.github/workflows/check-proof-producer.yml diff --git a/flake.nix b/flake.nix index 2cc0f44f1..6666cead4 100644 --- a/flake.nix +++ b/flake.nix @@ -216,6 +216,10 @@ name = "all"; paths = [ crypto3-clang parallel-crypto3-clang evm-assigner-clang transpiler-clang proof-producer-clang ]; }; + all-sanitizers = pkgs.symlinkJoin { + name = "all"; + paths = [ crypto3-clang-sanitize ]; + }; all-gcc = pkgs.symlinkJoin { name = "all"; paths = [ crypto3-gcc parallel-crypto3-gcc evm-assigner-gcc zkevm-framework-gcc transpiler-gcc proof-producer-gcc ];