Skip to content

Commit c7d27c6

Browse files
committed
Allow compilation with no slasher backend
1 parent 0866b73 commit c7d27c6

File tree

6 files changed

+16
-7
lines changed

6 files changed

+16
-7
lines changed

Makefile

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,15 +35,24 @@ PROFILE ?= release
3535
# they run for different forks.
3636
FORKS=phase0 altair merge
3737

38+
# Extra flags for Cargo
39+
CARGO_INSTALL_EXTRA_FLAGS?=
40+
3841
# Builds the Lighthouse binary in release (optimized).
3942
#
4043
# Binaries will most likely be found in `./target/release`
4144
install:
42-
cargo install --path lighthouse --force --locked --features "$(FEATURES)" --profile "$(PROFILE)"
45+
cargo install --path lighthouse --force --locked \
46+
--features "$(FEATURES)" \
47+
--profile "$(PROFILE)" \
48+
$(CARGO_INSTALL_EXTRA_FLAGS)
4349

4450
# Builds the lcli binary in release (optimized).
4551
install-lcli:
46-
cargo install --path lcli --force --locked --features "$(FEATURES)" --profile "$(PROFILE)"
52+
cargo install --path lcli --force --locked \
53+
--features "$(FEATURES)" \
54+
--profile "$(PROFILE)" \
55+
$(CARGO_INSTALL_EXTRA_FLAGS)
4756

4857
# The following commands use `cross` to build a cross-compile.
4958
#

beacon_node/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ clap_utils = { path = "../common/clap_utils" }
3636
hyper = "0.14.4"
3737
lighthouse_version = { path = "../common/lighthouse_version" }
3838
hex = "0.4.2"
39-
slasher = { path = "../slasher" }
39+
slasher = { path = "../slasher", default-features = false }
4040
monitoring_api = { path = "../common/monitoring_api" }
4141
sensitive_url = { path = "../common/sensitive_url" }
4242
http_api = { path = "http_api" }

beacon_node/beacon_chain/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ fork_choice = { path = "../../consensus/fork_choice" }
5353
task_executor = { path = "../../common/task_executor" }
5454
derivative = "2.1.1"
5555
itertools = "0.10.0"
56-
slasher = { path = "../../slasher" }
56+
slasher = { path = "../../slasher", default-features = false }
5757
eth2 = { path = "../../common/eth2" }
5858
strum = { version = "0.24.0", features = ["derive"] }
5959
logging = { path = "../../common/logging" }

beacon_node/client/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ time = "0.3.5"
3535
directory = {path = "../../common/directory"}
3636
http_api = { path = "../http_api" }
3737
http_metrics = { path = "../http_metrics" }
38-
slasher = { path = "../../slasher" }
38+
slasher = { path = "../../slasher", default-features = false }
3939
slasher_service = { path = "../../slasher/service" }
4040
monitoring_api = {path = "../../common/monitoring_api"}
4141
execution_layer = { path = "../execution_layer" }

lighthouse/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ malloc_utils = { path = "../common/malloc_utils" }
5555
directory = { path = "../common/directory" }
5656
unused_port = { path = "../common/unused_port" }
5757
database_manager = { path = "../database_manager" }
58-
slasher = { path = "../slasher" }
58+
slasher = { path = "../slasher", default-features = false }
5959

6060
[dev-dependencies]
6161
tempfile = "3.1.0"

slasher/service/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ beacon_chain = { path = "../../beacon_node/beacon_chain" }
99
directory = { path = "../../common/directory" }
1010
lighthouse_network = { path = "../../beacon_node/lighthouse_network" }
1111
network = { path = "../../beacon_node/network" }
12-
slasher = { path = ".." }
12+
slasher = { path = "..", default-features = false }
1313
slog = "2.5.2"
1414
slot_clock = { path = "../../common/slot_clock" }
1515
state_processing = { path = "../../consensus/state_processing" }

0 commit comments

Comments
 (0)