fix blst build tag (#7443)

* fix blst build tag

* fix fuzz build

* remove buildkite specific bazelrc line

* remove conflicting kafka gotag in CI

* fix again

Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
This commit is contained in:
Preston Van Loon
2020-10-08 11:37:12 -07:00
committed by GitHub
parent a66f434236
commit 4ddacd57c6
12 changed files with 43 additions and 41 deletions

View File

@@ -42,6 +42,7 @@ build:kafka_enabled --define kafka_enabled=true
build:kafka_enabled --define gotags=kafka_enabled build:kafka_enabled --define gotags=kafka_enabled
build:blst_enabled --define blst_enabled=true build:blst_enabled --define blst_enabled=true
build:blst_enabled --define gotags=blst_enabled
# Release flags # Release flags
build:release --workspace_status_command=./scripts/workspace_status.sh build:release --workspace_status_command=./scripts/workspace_status.sh

View File

@@ -34,16 +34,5 @@ build --flaky_test_attempts=5
# Disabled race detection due to unstable test results under constrained environment build kite # Disabled race detection due to unstable test results under constrained environment build kite
# build --features=race # build --features=race
# Enable kafka for CI tests only.
test --config=kafka_enabled
# Disable blst for CI tests.
test --define blst_enabled=true
# Disable flaky test detection for fuzzing. # Disable flaky test detection for fuzzing.
test:fuzz --flaky_test_attempts=1 test:fuzz --flaky_test_attempts=1
# Expose test environment variables in CI
test:fuzzit --test_env=GITHUB_REF
test:fuzzit --test_env=GITHUB_SHA
test:fuzzit --test_env=DOCKER_HOST

View File

@@ -1,4 +1,5 @@
// +build linux,amd64 linux,arm64 // +build linux,amd64 linux,arm64
// +build blst_enabled
package blst package blst

View File

@@ -1,4 +1,5 @@
// +build linux,amd64 linux,arm64 // +build linux,amd64 linux,arm64
// +build blst_enabled
package blst_test package blst_test

View File

@@ -1,4 +1,5 @@
// +build linux,amd64 linux,arm64 // +build linux,amd64 linux,arm64
// +build blst_enabled
package blst package blst

View File

@@ -1,4 +1,5 @@
// +build linux,amd64 linux,arm64 // +build linux,amd64 linux,arm64
// +build blst_enabled
package blst package blst

View File

@@ -1,4 +1,5 @@
// +build linux,amd64 linux,arm64 // +build linux,amd64 linux,arm64
// +build blst_enabled
package blst_test package blst_test

View File

@@ -1,4 +1,5 @@
// +build linux,amd64 linux,arm64 // +build linux,amd64 linux,arm64
// +build blst_enabled
package blst package blst

View File

@@ -1,4 +1,5 @@
// +build linux,amd64 linux,arm64 // +build linux,amd64 linux,arm64
// +build blst_enabled
package blst_test package blst_test

View File

@@ -1,4 +1,5 @@
// +build linux,amd64 linux,arm64 // +build linux,amd64 linux,arm64
// +build blst_enabled
package blst package blst

View File

@@ -1,4 +1,5 @@
// +build linux,amd64 linux,arm64 // +build linux,amd64 linux,arm64
// +build blst_enabled
package blst package blst

View File

@@ -1,25 +1,28 @@
// +build darwin,amd64 windows,amd64 linux,amd64,!blst_enabled linux,arm64,!blst_enabled // +build darwin windows !blst_enabled
package blst package blst
import "github.com/prysmaticlabs/prysm/shared/bls/iface" import "github.com/prysmaticlabs/prysm/shared/bls/iface"
// This stub file exists until build issues can be resolved for darwin and windows.
const err = "blst is only supported on linux with blst_enabled gotag"
// SecretKey -- stub // SecretKey -- stub
type SecretKey struct{} type SecretKey struct{}
// PublicKey -- stub // PublicKey -- stub
func (s SecretKey) PublicKey() iface.PublicKey { func (s SecretKey) PublicKey() iface.PublicKey {
panic("blst is only supported on linux amd64") panic(err)
} }
// Sign -- stub // Sign -- stub
func (s SecretKey) Sign(msg []byte) iface.Signature { func (s SecretKey) Sign(msg []byte) iface.Signature {
panic("blst is only supported on linux amd64") panic(err)
} }
// Marshal -- stub // Marshal -- stub
func (s SecretKey) Marshal() []byte { func (s SecretKey) Marshal() []byte {
panic("blst is only supported on linux amd64") panic(err)
} }
// PublicKey -- stub // PublicKey -- stub
@@ -27,17 +30,17 @@ type PublicKey struct{}
// Marshal -- stub // Marshal -- stub
func (p PublicKey) Marshal() []byte { func (p PublicKey) Marshal() []byte {
panic("blst is only supported on linux amd64") panic(err)
} }
// Copy -- stub // Copy -- stub
func (p PublicKey) Copy() iface.PublicKey { func (p PublicKey) Copy() iface.PublicKey {
panic("blst is only supported on linux amd64") panic(err)
} }
// Aggregate -- stub // Aggregate -- stub
func (p PublicKey) Aggregate(p2 iface.PublicKey) iface.PublicKey { func (p PublicKey) Aggregate(p2 iface.PublicKey) iface.PublicKey {
panic("blst is only supported on linux amd64") panic(err)
} }
// Signature -- stub // Signature -- stub
@@ -45,70 +48,70 @@ type Signature struct{}
// Verify -- stub // Verify -- stub
func (s Signature) Verify(pubKey iface.PublicKey, msg []byte) bool { func (s Signature) Verify(pubKey iface.PublicKey, msg []byte) bool {
panic("blst is only supported on linux amd64") panic(err)
} }
// AggregateVerify -- stub // AggregateVerify -- stub
func (s Signature) AggregateVerify(pubKeys []iface.PublicKey, msgs [][32]byte) bool { func (s Signature) AggregateVerify(_ []iface.PublicKey, _ [][32]byte) bool {
panic("blst is only supported on linux amd64") panic(err)
} }
// FastAggregateVerify -- stub // FastAggregateVerify -- stub
func (s Signature) FastAggregateVerify(pubKeys []iface.PublicKey, msg [32]byte) bool { func (s Signature) FastAggregateVerify(_ []iface.PublicKey, _ [32]byte) bool {
panic("blst is only supported on linux amd64") panic(err)
} }
// Marshal -- stub // Marshal -- stub
func (s Signature) Marshal() []byte { func (s Signature) Marshal() []byte {
panic("blst is only supported on linux amd64") panic(err)
} }
// Copy -- stub // Copy -- stub
func (s Signature) Copy() iface.Signature { func (s Signature) Copy() iface.Signature {
panic("blst is only supported on linux amd64") panic(err)
} }
// SecretKeyFromBytes -- stub // SecretKeyFromBytes -- stub
func SecretKeyFromBytes(privKey []byte) (SecretKey, error) { func SecretKeyFromBytes(_ []byte) (SecretKey, error) {
panic("blst is only supported on linux amd64") panic(err)
} }
// PublicKeyFromBytes -- stub // PublicKeyFromBytes -- stub
func PublicKeyFromBytes(pubKey []byte) (PublicKey, error) { func PublicKeyFromBytes(_ []byte) (PublicKey, error) {
panic("blst is only supported on linux amd64") panic(err)
} }
// SignatureFromBytes -- stub // SignatureFromBytes -- stub
func SignatureFromBytes(sig []byte) (Signature, error) { func SignatureFromBytes(_ []byte) (Signature, error) {
panic("blst is only supported on linux amd64") panic(err)
} }
// AggregatePublicKeys -- stub // AggregatePublicKeys -- stub
func AggregatePublicKeys(pubs [][]byte) (PublicKey, error) { func AggregatePublicKeys(_ [][]byte) (PublicKey, error) {
panic("blst is only supported on linux amd64") panic(err)
} }
// AggregateSignatures -- stub // AggregateSignatures -- stub
func AggregateSignatures(sigs []iface.Signature) iface.Signature { func AggregateSignatures(_ []iface.Signature) iface.Signature {
panic("blst is only supported on linux amd64") panic(err)
} }
// VerifyMultipleSignatures -- stub // VerifyMultipleSignatures -- stub
func VerifyMultipleSignatures(sigs [][]byte, msgs [][32]byte, pubKeys []iface.PublicKey) (bool, error) { func VerifyMultipleSignatures(_ [][]byte, _ [][32]byte, _ []iface.PublicKey) (bool, error) {
panic("blst is only supported on linux amd64") panic(err)
} }
// NewAggregateSignature -- stub // NewAggregateSignature -- stub
func NewAggregateSignature() iface.Signature { func NewAggregateSignature() iface.Signature {
panic("blst is only supported on linux amd64") panic(err)
} }
// RandKey -- stub // RandKey -- stub
func RandKey() iface.SecretKey { func RandKey() iface.SecretKey {
panic("blst is only supported on linux amd64") panic(err)
} }
// VerifyCompressed -- stub // VerifyCompressed -- stub
func VerifyCompressed(signature []byte, pub []byte, msg []byte) bool { func VerifyCompressed(_ []byte, _ []byte, _ []byte) bool {
panic("blst is only supported on linux amd64") panic(err)
} }