# Copyright 2009 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.

ROOT= /go
<$ROOT/$objtype/mkfile

GOOS_LIST=\
	darwin\
	freebsd\
	linux\
	openbsd\
	plan9\
	windows\

GOARCH_LIST=\
	386\
	amd64\
	arm\

BIND= `{bind -b $ROOT/$GOARCH/bin /bin}

TARGDIR= $GOROOT/pkg/${GOOS}_$GOARCH/go
TARG= build	# bytes errors fmt go/ast go/doc go/parser go/token io/ioutil log os os/exec path path/filepath regexp runtime sort strconv strings unicode

GOFILES=\
	build.go\
	dir.go\
	path.go\
	syslist.go\

<../../../mkpkg

CLEANFILES=\
	$CLEANFILES\
	syslist.go\
	pkgtest/_obj\
	cmdtest/_obj\
	cgotest/_obj\

syslist.go:
	echo '// Generated automatically by make.' >$target
	echo 'package build' >>$target
	echo 'const goosList = "'^$"GOOS_LIST^'"' >>$target
	echo 'const goarchList = "'^$"GOARCH_LIST^'"' >>$target
