Skip to content

Commit 03e1218

Browse files
committed
Remove exclusions from Makefile because they will come from NatSpec docs
The functions to be excluded with be tagged with the @Custom:exclude natspec tag, which are handled by pyabigen.
1 parent 3ba496a commit 03e1218

File tree

1 file changed

+21
-38
lines changed

1 file changed

+21
-38
lines changed

Makefile

Lines changed: 21 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -2,57 +2,40 @@ VERSION := $(shell cat AUTONITY_VERSION)
22
AUTONITY := build/autonity
33
ABIDIR := $(AUTONITY)/params/generated
44
OUTDIR := autonity/contracts
5-
ABIGEN = hatch run generate:pyabigen \
6-
--srcdir $(AUTONITY)/autonity/solidity/contracts \
7-
--version $(VERSION) \
8-
--userdoc $(word 2,$(1)) \
9-
--devdoc $(word 3,$(1)) \
10-
$(word 1,$(1))
115

12-
all: $(OUTDIR)/accountability.py \
13-
$(OUTDIR)/acu.py \
14-
$(OUTDIR)/autonity.py \
15-
$(OUTDIR)/ierc20.py \
16-
$(OUTDIR)/inflation_controller.py \
17-
$(OUTDIR)/liquid.py \
18-
$(OUTDIR)/non_stakable_vesting.py \
19-
$(OUTDIR)/oracle.py \
20-
$(OUTDIR)/stabilization.py \
21-
$(OUTDIR)/supply_control.py \
22-
$(OUTDIR)/upgrade_manager.py
6+
BINDINGS := $(OUTDIR)/accountability.py \
7+
$(OUTDIR)/acu.py \
8+
$(OUTDIR)/autonity.py \
9+
$(OUTDIR)/ierc20.py \
10+
$(OUTDIR)/inflation_controller.py \
11+
$(OUTDIR)/liquid.py \
12+
$(OUTDIR)/non_stakable_vesting.py \
13+
$(OUTDIR)/oracle.py \
14+
$(OUTDIR)/stabilization.py \
15+
$(OUTDIR)/supply_control.py \
16+
$(OUTDIR)/upgrade_manager.py
2317

24-
$(OUTDIR)/accountability.py: $(addprefix $(ABIDIR)/Accountability,.abi .docuser .docdev)
25-
$(call ABIGEN,$^) --exclude distributeRewards,finalize,setEpochPeriod >$@
18+
all: $(BINDINGS)
2619

20+
$(OUTDIR)/accountability.py: $(addprefix $(ABIDIR)/Accountability,.abi .docuser .docdev)
2721
$(OUTDIR)/acu.py: $(addprefix $(ABIDIR)/ACU,.abi .docuser .docdev)
28-
$(call ABIGEN,$^) --exclude setOperator,setOracle,update >$@
29-
3022
$(OUTDIR)/autonity.py: $(addprefix $(ABIDIR)/Autonity,.abi .docuser .docdev)
31-
$(call ABIGEN,$^) --exclude computeCommittee,finalize,finalizeInitialization >$@
32-
3323
$(OUTDIR)/ierc20.py: $(addprefix $(ABIDIR)/IERC20,.abi .docuser .docdev)
34-
$(call ABIGEN,$^) >$@
35-
3624
$(OUTDIR)/inflation_controller.py: $(addprefix $(ABIDIR)/InflationController,.abi .docuser .docdev)
37-
$(call ABIGEN,$^) >$@
38-
3925
$(OUTDIR)/liquid.py: $(addprefix $(ABIDIR)/Liquid,.abi .docuser .docdev)
40-
$(call ABIGEN,$^) --exclude burn,lock,mint,redistribute,setCommissionRate,unlock >$@
41-
4226
$(OUTDIR)/non_stakable_vesting.py: $(addprefix $(ABIDIR)/NonStakableVesting,.abi .docuser .docdev)
43-
$(call ABIGEN,$^) --exclude unlockTokens >$@
44-
4527
$(OUTDIR)/oracle.py: $(addprefix $(ABIDIR)/Oracle,.abi .docuser .docdev)
46-
$(call ABIGEN,$^) --exclude finalize,setOperator,setVoters >$@
47-
4828
$(OUTDIR)/stabilization.py: $(addprefix $(ABIDIR)/Stabilization,.abi .docuser .docdev)
49-
$(call ABIGEN,$^) --exclude setOperator,setOracle >$@
50-
5129
$(OUTDIR)/supply_control.py: $(addprefix $(ABIDIR)/SupplyControl,.abi .docuser .docdev)
52-
$(call ABIGEN,$^) --exclude setOperator >$@
53-
5430
$(OUTDIR)/upgrade_manager.py: $(addprefix $(ABIDIR)/UpgradeManager,.abi .docuser .docdev)
55-
$(call ABIGEN,$^) --exclude setOperator >$@
31+
32+
$(BINDINGS):
33+
hatch run generate:pyabigen \
34+
--srcdir $(AUTONITY)/autonity/solidity/contracts \
35+
--version $(VERSION) \
36+
--userdoc $(word 2,$^) \
37+
--devdoc $(word 3,$^) \
38+
$(word 1,$^) >$@
5639

5740
$(ABIDIR)/%.abi: $(AUTONITY) AUTONITY_VERSION
5841
cd $< && \

0 commit comments

Comments
 (0)