code: func doXgo(cmdline []string) {
  	var (
  		alltools = flag.Bool("alltools", false, `Flag whether we're building all known tools, or only on in particular`)
  	)
  	flag.CommandLine.Parse(cmdline)
  	env := build.Env()
  
  	// Make sure xgo is available for cross compilation
  	gogetxgo := goTool("get", "github.com/karalabe/xgo")
  	build.MustRun(gogetxgo)
  
  	// If all tools building is requested, build everything the builder wants
  	args := append(buildFlags(env), flag.Args()...)
  
  	if *alltools {
  		args = append(args, []string{"--dest", GOBIN}...)
  		for _, res := range allCrossCompiledArchiveFiles {
  			if strings.HasPrefix(res, GOBIN) {
  				// Binary tool found, cross build it explicitly
  				args = append(args, "./"+filepath.Join("cmd", filepath.Base(res)))
  				xgo := xgoTool(args)
  				build.MustRun(xgo)
  				args = args[:len(args)-1]
  			}
  		}
  		return
  	}
  	// Otherwise xxecute the explicit cross compilation
  	path := args[len(args)-1]
  	args = append(args[:len(args)-1], []string{"--dest", GOBIN, path}...)
  
  	xgo := xgoTool(args)
  	build.MustRun(xgo)
  }
docs: // Cross compilation