From 8bd10697033e2baf6f3347c6912ec1817a7f46bb Mon Sep 17 00:00:00 2001 From: Pierre-Yves Strub Date: Wed, 25 Sep 2024 17:45:35 +0200 Subject: [PATCH] ci: compile with warning as errors --- .github/workflows/ci.yml | 2 +- Makefile | 3 ++- src/dune | 3 ++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 38bfa21d7..52f5467b4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -34,7 +34,7 @@ jobs: opam pin add -n easycrypt . opam install --deps-only easycrypt - name: Compile EasyCrypt - run: opam exec -- make + run: opam exec -- make PROFILE=ci compile-nix: name: EasyCrypt compilation (nix) diff --git a/Makefile b/Makefile index 06181fc55..62ace7ba2 100644 --- a/Makefile +++ b/Makefile @@ -14,6 +14,7 @@ CHECK += --bin-args=-timeout --bin-args="$(ECTOUT)" CHECK += $(foreach arg,$(ECARGS),--bin-args="$(arg)") CHECK += $(ECEXTRA) config/tests.config NIX ?= nix --extra-experimental-features "nix-command flakes" +PROFILE ?= dev # -------------------------------------------------------------------- UNAME_P = $(shell uname -p) @@ -29,7 +30,7 @@ default: build build: rm -f src/ec.exe ec.native - dune build + $(DUNE) build --profile=$(PROFILE) ln -sf src/ec.exe ec.native ifeq ($(UNAME_P)-$(UNAME_S),arm-Darwin) -codesign -f -s - src/ec.exe diff --git a/src/dune b/src/dune index e6d64c42f..1a5090d1e 100644 --- a/src/dune +++ b/src/dune @@ -1,6 +1,7 @@ (env (dev (flags :standard -rectypes -warn-error -a+31 -w +28+33-9-23-32-58-67-69)) - (release (flags :standard -rectypes -warn-error -a+31 -w +28+33-9-23-32-58-67-69) + (ci (flags :standard -rectypes -warn-error +a -w +28+33-9-23-32-58-67-69)) + (release (flags :standard -rectypes -warn-error -a -w +28+33-9-23-32-58-67-69) (ocamlopt_flags -O3 -unbox-closures))) (include_subdirs unqualified)