[fuchsia] Fix Fuchsia build.

* Needed to clean out the build on the main host. We switched to a
"petal" layout which required a complete rebuild.

* Update SSH interface.  SSH keys have to be set at buildtime via
--args.

* Update fvm.blk location.
This commit is contained in:
Julia Hansbrough 2018-11-12 15:38:24 -08:00 committed by Dmitry Vyukov
parent 4fc13fd6ae
commit 5f5f6d14e8
2 changed files with 5 additions and 3 deletions

View File

@ -29,7 +29,7 @@ Run `syz-manager` with a config along the lines of:
"workdir": "/workdir.fuchsia",
"kernel_obj": "/fuchsia/out/build-zircon/build-x64",
"syzkaller": "/syzkaller",
"image": "/fuchsia/out/x64/images/fvm.blk",
"image": "/fuchsia/out/x64/out/build/images/fvm.blk",
"sshkey": "/fuchsia/out/x64/ssh-keys/id_ed25519",
"reproduce": false,
"cover": false,

View File

@ -21,12 +21,14 @@ func (fu fuchsia) build(targetArch, vmType, kernelDir, outputDir, compiler, user
return fmt.Errorf("unsupported fuchsia arch %v", targetArch)
}
arch := sysTarget.KernelHeaderArch
// TODO check if set-layer required?
if _, err := osutil.RunCmd(time.Hour, kernelDir, "scripts/fx", "clean-build", arch,
"--packages", "garnet/packages/products/sshd"); err != nil {
"--packages", "garnet/packages/products/sshd", "--args",
"'extra_authorized_keys_file=\"//.ssh/authorized_keys\"'"); err != nil {
return err
}
for src, dst := range map[string]string{
"out/" + arch + "/images/fvm.blk": "image",
"out/" + arch + "/obj/build/images/fvm.blk": "image",
"out/" + arch + "/ssh-keys/id_ed25519": "key",
"out/build-zircon/build-" + arch + "/zircon.elf": "obj/zircon.elf",
"out/build-zircon/build-" + arch + "/multiboot.bin": "kernel",