[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
01/05: build-system/go: Strip the Go binaries with the native tool.
From: |
Leo Famulari |
Subject: |
01/05: build-system/go: Strip the Go binaries with the native tool. |
Date: |
Tue, 24 Oct 2017 13:11:50 -0400 (EDT) |
lfam pushed a commit to branch master
in repository guix.
commit 1c37f839fb58283c99bf46be860d66e579d6f555
Author: Leo Famulari <address@hidden>
Date: Sat Oct 21 13:00:27 2017 -0400
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.
---
guix/build/go-build-system.scm | 3 +++
1 file changed, 3 insertions(+)
diff --git a/guix/build/go-build-system.scm b/guix/build/go-build-system.scm
index 7f04e3d..d8ccb98 100644
--- a/guix/build/go-build-system.scm
+++ b/guix/build/go-build-system.scm
@@ -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"