is there a reason you didn't build it from the official Go sources?
i only needed to make a couple of tweaks (see the patch below) to
build it.  a couple of things to watch out for:

- make sure you have two different GOBIN's; one for your local Linux
box and the other for making the Plan 9 binaries
- be sure to have the right GOBIN in the first part of your PATH for
your target environment

i use drawterm from the build box and then i can execute Plan 9
binaries produced by 8[gl] from /mnt/term/<whatever>

-Skip

$ hg diff
diff -r b002b8e25d25 src/pkg/Makefile
--- a/src/pkg/Makefile  Tue Apr 05 18:07:01 2011 -0400
+++ b/src/pkg/Makefile  Sat Apr 09 11:18:04 2011 -0700
@@ -106,7 +106,6 @@
        image/png\
        index/suffixarray\
        io\
-       io/ioutil\
        json\
        log\
        math\
@@ -139,7 +138,6 @@
        sync/atomic\
        syscall\
        syslog\
-       tabwriter\
        template\
        testing\
        testing/iotest\
@@ -206,6 +204,14 @@
 NOTEST+=net syslog
 endif

+# Disable packages that plan9 doesn't support yet
+ifneq ($(GOOS),plan9)
+DIRS+=\
+       tabwriter\
+       io/ioutil\
+
+endif
+
 # Disable tests that windows cannot run yet.
 ifeq ($(GOOS),windows)
 NOTEST+=os/signal    # no signals
diff -r b002b8e25d25 src/pkg/path/filepath/Makefile
--- a/src/pkg/path/filepath/Makefile    Tue Apr 05 18:07:01 2011 -0400
+++ b/src/pkg/path/filepath/Makefile    Sat Apr 09 11:18:04 2011 -0700
@@ -15,6 +15,9 @@
 GOFILES_darwin=\
        path_unix.go

+GOFILES_plan9=\
+       path_unix.go
+
 GOFILES_linux=\
        path_unix.go

diff -r b002b8e25d25 src/pkg/time/Makefile
--- a/src/pkg/time/Makefile     Tue Apr 05 18:07:01 2011 -0400
+++ b/src/pkg/time/Makefile     Sat Apr 09 11:18:04 2011 -0700
@@ -21,6 +21,9 @@
 GOFILES_linux=\
        zoneinfo_unix.go\

+GOFILES_plan9=\
+       zoneinfo_unix.go\
+
 GOFILES_windows=\
        zoneinfo_windows.go\



On Sat, Apr 9, 2011 at 10:51 AM, Sergey Kish <sergey.k...@gmail.com> wrote:
> Hello,
>
> I'm unable to make go plan9 crosscompiler.
> Can you help me?
>
> # I use patched repo
> hg qclone https://bitbucket.org/paulzhol/golang-plan9-runtime-patches go
> cd go
> hg qpush -a
>
> # build as usual
> export GOROOT=`pwd`
> export GOOS=linux
> export GOBIN="$GOROOT/bin"
> export PATH="$GOBIN:$PATH"
>
> mkdir -p "$GOROOT/bin"
> cd "$GOROOT/src"
> . ./make.bash
>
> # prepare pkgs
> cd $GOROOT/src/pkg
> make clean
> export GOOS=plan9
> make
>
> # and get
> make -C net install
> make[1]: Entering directory `/home/sergeykish/abs/go/src/go-build/src/pkg/net'
> make[1]: *** No rule to make target `fd_plan9.go', needed by `_go_.8'.  Stop.
> make[1]: Leaving directory `/home/sergeykish/abs/go/src/go-build/src/pkg/net'
>
> What now?
>
>

Reply via email to