blob: 99cf3fbcaba7943c7aeaa1db30e83d114881b533 [file] [log] [blame]
Russ Cox33405ec2010-12-15 17:20:26 -05001// Copyright 2010 The Go Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style
3// license that can be found in the LICENSE file.
4
Russ Cox2cd05c32014-11-09 20:20:45 -05005// +build freebsd
6
Russ Cox9f99d532014-11-11 17:05:37 -05007package cgo
Russ Cox75cca052014-09-24 17:50:44 -04008
Russ Coxe98f2d52014-11-12 14:54:04 -05009import _ "unsafe" // for go:linkname
Russ Cox22293bb2014-11-11 23:19:59 -050010
Russ Cox33405ec2010-12-15 17:20:26 -050011// Supply environ and __progname, because we don't
12// link against the standard FreeBSD crt0.o and the
13// libc dynamic library needs them.
14
Russ Cox9f99d532014-11-11 17:05:37 -050015//go:linkname _environ environ
16//go:linkname _progname __progname
Russ Cox33405ec2010-12-15 17:20:26 -050017
Joel Sing37cae802014-11-12 17:18:22 -050018//go:cgo_export_dynamic environ
19//go:cgo_export_dynamic __progname
Russ Coxa9695a52014-11-11 23:28:26 -050020
Russ Cox9f99d532014-11-11 17:05:37 -050021var _environ uintptr
22var _progname uintptr