build-system/go: Strip the Go binaries with the native tool.

* guix/build/go-build-system.scm (build): Tell the Go linker to strip some
symbol tables and debugging information.
This commit is contained in:
Leo Famulari 2017-10-21 13:00:27 -04:00
parent 22473f6964
commit 1c37f839fb
No known key found for this signature in database
GPG Key ID: 2646FA30BACA7F08
1 changed files with 3 additions and 0 deletions

View File

@ -179,6 +179,9 @@ respectively."
(zero? (system* "go" "install"
"-v" ; print the name of packages as they are compiled
"-x" ; print each command as it is invoked
;; Respectively, strip the symbol table and debug
;; information, and the DWARF symbol table.
"-ldflags=-s -w"
import-path))
(begin
(display (string-append "Building '" import-path "' failed.\n"