2023-12-05 16:19:59 +00:00
|
|
|
TESTS_TAG := v1.4.0-beta.4
|
2019-10-02 01:04:56 +00:00
|
|
|
TESTS = general minimal mainnet
|
2019-10-22 03:35:35 +00:00
|
|
|
TARBALLS = $(patsubst %,%-$(TESTS_TAG).tar.gz,$(TESTS))
|
2019-10-02 01:04:56 +00:00
|
|
|
|
2021-09-25 05:58:35 +00:00
|
|
|
REPO_NAME := consensus-spec-tests
|
2019-10-02 01:04:56 +00:00
|
|
|
OUTPUT_DIR := ./$(REPO_NAME)
|
|
|
|
BASE_URL := https://github.com/ethereum/$(REPO_NAME)/releases/download/$(TESTS_TAG)
|
|
|
|
|
2022-10-12 23:40:42 +00:00
|
|
|
BLS_TEST_REPO_NAME := bls12-381-tests
|
|
|
|
BLS_TEST_TAG := v0.1.1
|
|
|
|
BLS_TEST = bls_tests_yaml
|
|
|
|
BLS_TARBALL = $(patsubst %,%-$(BLS_TEST_TAG).tar.gz,$(BLS_TEST))
|
|
|
|
BLS_OUTPUT_DIR := $(OUTPUT_DIR)/$(BLS_TEST_REPO_NAME)
|
|
|
|
BLS_BASE_URL := https://github.com/ethereum/$(BLS_TEST_REPO_NAME)/releases/download/$(BLS_TEST_TAG)
|
|
|
|
|
2023-07-17 00:14:16 +00:00
|
|
|
CURL := $(if $(LIGHTHOUSE_GITHUB_TOKEN),curl -L --header "Authorization: $(LIGHTHOUSE_GITHUB_TOKEN)",curl -L)
|
2022-12-20 01:34:52 +00:00
|
|
|
|
2022-10-12 23:40:42 +00:00
|
|
|
all:
|
|
|
|
make $(OUTPUT_DIR)
|
|
|
|
make $(BLS_OUTPUT_DIR)
|
|
|
|
|
2019-10-22 03:35:35 +00:00
|
|
|
$(OUTPUT_DIR): $(TARBALLS)
|
2019-10-02 01:04:56 +00:00
|
|
|
mkdir $(OUTPUT_DIR)
|
2019-10-22 03:35:35 +00:00
|
|
|
for test_tarball in $^; do \
|
|
|
|
tar -xzf $$test_tarball -C $(OUTPUT_DIR);\
|
2019-10-02 01:04:56 +00:00
|
|
|
done
|
|
|
|
|
2022-10-12 23:40:42 +00:00
|
|
|
$(BLS_OUTPUT_DIR):
|
|
|
|
mkdir $(BLS_OUTPUT_DIR)
|
2023-07-17 00:14:16 +00:00
|
|
|
$(CURL) $(BLS_BASE_URL)/$(BLS_TEST).tar.gz -o $(BLS_TARBALL)
|
2022-10-12 23:40:42 +00:00
|
|
|
tar -xzf $(BLS_TARBALL) -C $(BLS_OUTPUT_DIR)
|
|
|
|
|
2019-10-22 03:35:35 +00:00
|
|
|
%-$(TESTS_TAG).tar.gz:
|
2023-07-17 00:14:16 +00:00
|
|
|
$(CURL) $(BASE_URL)/$*.tar.gz -o $@
|
2019-10-22 03:35:35 +00:00
|
|
|
|
|
|
|
clean-test-files:
|
2022-10-12 23:40:42 +00:00
|
|
|
rm -rf $(OUTPUT_DIR) $(BLS_OUTPUT_DIR)
|
2019-10-22 03:35:35 +00:00
|
|
|
|
|
|
|
clean-archives:
|
2022-10-12 23:40:42 +00:00
|
|
|
rm -f $(TARBALLS) $(BLS_TARBALL)
|
2019-10-22 03:35:35 +00:00
|
|
|
|
|
|
|
clean: clean-test-files clean-archives
|
|
|
|
|
|
|
|
.PHONY: clean clean-archives clean-test-files
|