mirror of
https://gitlab.com/pulsechaincom/prysm-pulse.git
synced 2024-12-23 11:57:18 +00:00
4322185d80
* payload use * incl * cloners * regen pb * gen ssz * use proper payload * broken imports * build * state * builds * proper engine * builds * fmt * baz * ssz * baz * fmt * regen ssz * receipts root * regen pb * ssz * receipts root * ci lint * proto * test pkg * bazel
93 lines
3.0 KiB
Python
93 lines
3.0 KiB
Python
##############################################################################
|
|
# Common
|
|
##############################################################################
|
|
|
|
load("@rules_proto//proto:defs.bzl", "proto_library")
|
|
|
|
##############################################################################
|
|
# Go
|
|
##############################################################################
|
|
# gazelle:ignore
|
|
load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
|
|
load("@io_bazel_rules_go//proto:def.bzl", "go_proto_library")
|
|
load("//proto:ssz_proto_library.bzl", "ssz_proto_files")
|
|
load("//tools:ssz.bzl", "SSZ_DEPS", "ssz_gen_marshal")
|
|
|
|
proto_library(
|
|
name = "proto",
|
|
srcs = [
|
|
"execution_engine.proto",
|
|
],
|
|
visibility = ["//visibility:public"],
|
|
deps = [
|
|
"//proto/eth/ext:proto",
|
|
"@go_googleapis//google/api:annotations_proto",
|
|
],
|
|
)
|
|
|
|
##############################################################################
|
|
# Go
|
|
##############################################################################
|
|
ssz_gen_marshal(
|
|
name = "ssz_generated_files",
|
|
go_proto = ":go_proto",
|
|
objs = [
|
|
"ExecutionPayload",
|
|
],
|
|
)
|
|
|
|
go_proto_library(
|
|
name = "go_proto",
|
|
compilers = [
|
|
"@com_github_prysmaticlabs_protoc_gen_go_cast//:go_cast_grpc",
|
|
],
|
|
importpath = "github.com/prysmaticlabs/prysm/proto/engine/v1",
|
|
proto = ":proto",
|
|
visibility = ["//visibility:public"],
|
|
deps = [
|
|
"//proto/eth/ext:go_default_library",
|
|
"@io_bazel_rules_go//proto/wkt:descriptor_go_proto",
|
|
"@com_github_golang_protobuf//proto:go_default_library",
|
|
"@com_github_prysmaticlabs_eth2_types//:go_default_library",
|
|
"@go_googleapis//google/api:annotations_go_proto",
|
|
"@org_golang_google_protobuf//reflect/protoreflect:go_default_library",
|
|
"@org_golang_google_protobuf//runtime/protoimpl:go_default_library",
|
|
],
|
|
)
|
|
|
|
go_library(
|
|
name = "go_default_library",
|
|
srcs = [
|
|
"json_marshal_unmarshal.go",
|
|
":ssz_generated_files", # keep
|
|
],
|
|
embed = [
|
|
":go_proto",
|
|
],
|
|
importpath = "github.com/prysmaticlabs/prysm/proto/engine/v1",
|
|
visibility = ["//visibility:public"],
|
|
deps = [
|
|
"//proto/eth/ext:go_default_library",
|
|
"@io_bazel_rules_go//proto/wkt:descriptor_go_proto",
|
|
"@com_github_golang_protobuf//proto:go_default_library",
|
|
"@io_bazel_rules_go//proto/wkt:timestamp_go_proto",
|
|
"@go_googleapis//google/api:annotations_go_proto",
|
|
"@org_golang_google_protobuf//encoding/protojson:go_default_library",
|
|
"@org_golang_google_protobuf//reflect/protoreflect:go_default_library",
|
|
"@org_golang_google_protobuf//runtime/protoimpl:go_default_library",
|
|
"@com_github_ferranbt_fastssz//:go_default_library"
|
|
], # keep
|
|
)
|
|
|
|
go_test(
|
|
name = "go_default_test",
|
|
srcs = [
|
|
"json_marshal_unmarshal_test.go",
|
|
],
|
|
deps = [
|
|
":go_default_library",
|
|
"//encoding/bytesutil:go_default_library",
|
|
"//testing/require:go_default_library",
|
|
],
|
|
)
|