Add support for building "release" builds that don't contain pprof which are substantially smaller. To build a "debug" build, use "-tags debug" with "go build"

This commit is contained in:
Neil Alexander 2018-05-27 23:22:50 +01:00
parent e9b1006dda
commit a9e61d0d37
No known key found for this signature in database
GPG key ID: A02A2019A2BB0944
3 changed files with 31 additions and 6 deletions

12
src/yggdrasil/release.go Normal file
View file

@ -0,0 +1,12 @@
// +build !debug
package yggdrasil
import "errors"
import "log"
// Starts the function profiler. This is only supported when built with
// '-tags build'.
func StartProfiler(_ *log.Logger) error {
return errors.New("Release builds do not support -pprof, build using '-tags debug'")
}