]> Cypherpunks repositories - gostls13.git/commitdiff
runtime/cgo: fix netbsd build
authorBenny Siegert <bsiegert@gmail.com>
Sun, 29 Jul 2012 22:51:06 +0000 (18:51 -0400)
committerRuss Cox <rsc@golang.org>
Sun, 29 Jul 2012 22:51:06 +0000 (18:51 -0400)
Copy over freebsd.c to netbsd.c.

Fixes #3823.

R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/6398045

src/pkg/runtime/cgo/netbsd.c [new file with mode: 0644]

diff --git a/src/pkg/runtime/cgo/netbsd.c b/src/pkg/runtime/cgo/netbsd.c
new file mode 100644 (file)
index 0000000..b6403f6
--- /dev/null
@@ -0,0 +1,13 @@
+// Copyright 2010 The Go Authors.  All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Supply environ and __progname, because we don't
+// link against the standard NetBSD crt0.o and the
+// libc dynamic library needs them.
+
+char *environ[1];
+char *__progname;
+
+#pragma dynexport environ environ
+#pragma dynexport __progname __progname