Commit 7eeebf49 authored by Russ Cox's avatar Russ Cox

runtime/cgo: adapt files copied from libcgo

Necessary but not sufficient step toward
making those builds work.

R=r
CC=golang-dev
https://golang.org/cl/3411043
parent 70113b43
...@@ -11,14 +11,11 @@ char *environ[] = { 0 }; ...@@ -11,14 +11,11 @@ char *environ[] = { 0 };
char *__progname; char *__progname;
static void static void
inittls(void) xinitcgo(void)
{ {
} }
void void (*initcgo)(void) = xinitcgo;
initcgo(void)
{
}
void void
libcgo_sys_thread_start(ThreadStart *ts) libcgo_sys_thread_start(ThreadStart *ts)
......
...@@ -10,11 +10,13 @@ static void* threadentry(void*); ...@@ -10,11 +10,13 @@ static void* threadentry(void*);
char *environ[] = { 0 }; char *environ[] = { 0 };
char *__progname; char *__progname;
void static void
initcgo(void) xinitcgo(void)
{ {
} }
void (*initcgo)(void) = xinitcgo;
void void
libcgo_sys_thread_start(ThreadStart *ts) libcgo_sys_thread_start(ThreadStart *ts)
{ {
......
...@@ -4,11 +4,13 @@ ...@@ -4,11 +4,13 @@
#include "libcgo.h" #include "libcgo.h"
void static void
initcgo(void) xinitcgo(void)
{ {
} }
void (*initcgo)(void) = xinitcgo;
void void
libcgo_sys_thread_start(ThreadStart *ts) libcgo_sys_thread_start(ThreadStart *ts)
{ {
......
...@@ -12,11 +12,13 @@ static void *threadentry(void*); ...@@ -12,11 +12,13 @@ static void *threadentry(void*);
Allocation granularity on Windows is typically 64 KB. */ Allocation granularity on Windows is typically 64 KB. */
#define STACKSIZE (1*1024*1024) #define STACKSIZE (1*1024*1024)
void static void
initcgo(void) xinitcgo(void)
{ {
} }
void (*initcgo)(void) = xinitcgo;
void void
libcgo_sys_thread_start(ThreadStart *ts) libcgo_sys_thread_start(ThreadStart *ts)
{ {
......
...@@ -12,11 +12,13 @@ static void *threadentry(void*); ...@@ -12,11 +12,13 @@ static void *threadentry(void*);
Allocation granularity on Windows is typically 64 KB. */ Allocation granularity on Windows is typically 64 KB. */
#define STACKSIZE (2*1024*1024) #define STACKSIZE (2*1024*1024)
void static void
initcgo(void) xinitcgo(void)
{ {
} }
void (*initcgo)(void) = xinitcgo;
void void
libcgo_sys_thread_start(ThreadStart *ts) libcgo_sys_thread_start(ThreadStart *ts)
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment