speed: fix build for Go 1.4 and lower
Old Go versions miss cipher.NewGCMWithNonceSize, which causes: internal/speed/speed.go:95: undefined: cipher.NewGCMWithNonceSize
This commit is contained in:
parent
1e03e059fa
commit
477071d673
@ -1,3 +1,5 @@
|
|||||||
|
// +build go1.5
|
||||||
|
|
||||||
// Package speed implements the "-speed" command-line option,
|
// Package speed implements the "-speed" command-line option,
|
||||||
// similar to "openssl speed".
|
// similar to "openssl speed".
|
||||||
// It benchmarks the crypto algorithms and libraries used by
|
// It benchmarks the crypto algorithms and libraries used by
|
||||||
|
11
internal/speed/speed_go1.4.go
Normal file
11
internal/speed/speed_go1.4.go
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
// +build !go1.5
|
||||||
|
|
||||||
|
package speed
|
||||||
|
|
||||||
|
import (
|
||||||
|
"fmt"
|
||||||
|
)
|
||||||
|
|
||||||
|
func Run() {
|
||||||
|
fmt.Printf("Compile with Go 1.5 or higher to run the benchmarks\n")
|
||||||
|
}
|
@ -1,3 +1,5 @@
|
|||||||
|
// +build go1.5
|
||||||
|
|
||||||
package speed
|
package speed
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Loading…
Reference in New Issue
Block a user