Go tool link

From NovaOrdis Knowledge Base
Jump to navigation Jump to search

External

Internal

Overview

The linker is typically invoked as go tool link or as part of the go build command. It reads the Go archive or object for a package main, along with its dependencies, and combines them into an executable binary.

Options

When invoked by go build, all of the following options can be passed from go build command line with the -ldflags option. For syntax, see:

go build -ldflags