-
Notifications
You must be signed in to change notification settings - Fork 53
/
Copy pathMakefile
40 lines (30 loc) · 870 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
all: build
#######################
## BUILD
.PHONY: build
build-evm:
cd evm && forge build
.PHONY: clean-evm
clean-evm:
cd evm && forge clean
.PHONY: build-evm-prod
build-evm-prod: clean-evm
cd evm && docker build --target foundry-export -f Dockerfile -o out .
.PHONY: gen-evm-bindings
gen-evm-bindings: build-evm-prod
cd ci_tests && rm -rf evm_binding && npm ci && npm run gen-evm-bindings
#######################
## TESTS
.PHONY: check-format
check-format:
cd evm && forge fmt --check
.PHONY: fix-format
fix-format:
cd evm && forge fmt
.PHONY: test
test-evm:
cd evm && forge test -vvv
# Verify that the contracts do not include PUSH0 opcodes
test-push0:
forge build --extra-output evm.bytecode.opcodes
@if grep -qr --include \*.json PUSH0 ./out; then echo "Contract uses PUSH0 instruction" 1>&2; exit 1; else echo "PUSH0 Verification Succeeded"; fi