Commit 86b821f9 authored by Nigel Tao's avatar Nigel Tao

libcgo: fix NaCl build.

R=r, rsc, nigeltao
CC=golang-dev
https://golang.org/cl/2110046
parent 25c8d4e9
......@@ -16,9 +16,10 @@ OFILES=\
HOST_CFLAGS_386=-m32
HOST_CFLAGS_amd64=-m64
LDFLAGS_linux=-shared -lpthread -lm
LDFLAGS_darwin=-dynamiclib -Wl,-undefined,dynamic_lookup /usr/lib/libpthread.dylib
LDFLAGS_freebsd=-pthread -shared -lm
LDFLAGS_freebsd=-shared -lm -pthread
LDFLAGS_linux=-shared -lm -lpthread
LDFLAGS_nacl=-shared -lm -lpthread
LDFLAGS_windows=-shared -lm -mthreads
%.o: %.c
......
/* unimplemented */
// 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.
#include "libcgo.h"
void
initcgo(void)
{
}
void
libcgo_sys_thread_start(ThreadStart *ts)
{
// unimplemented
*(int*)0 = 0;
}
......@@ -57,7 +57,7 @@ func (file *File) Readdirnames(count int) (names []string, err Error) {
continue
}
bytes := (*[10000]byte)(unsafe.Pointer(&dirent.Name[0]))
var name = string(bytes[0:clen(bytes)])
var name = string(bytes[0:clen(bytes[0:])])
if name == "." || name == ".." { // Useless names
continue
}
......
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