Skip to content

Commit

Permalink
pkg/build: Add the KCOV build commands
Browse files Browse the repository at this point in the history
  • Loading branch information
R3x authored and dvyukov committed May 23, 2019
1 parent 84b9d38 commit 0dadcd9
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion pkg/build/netbsd.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ include "arch/amd64/conf/GENERIC"
makeoptions KASAN=1
options KASAN
no options SVS
makeoptions KCOV=1
options KCOV
`)

if err := osutil.WriteFile(filepath.Join(confDir, kernelName), conf); err != nil {
Expand Down Expand Up @@ -112,7 +115,9 @@ func (ctx netbsd) copyKernelToDisk(targetArch, vmType, outputDir, kernel string)
if kernel != "/netbsd" {
return fmt.Errorf("kernel is copied into wrong location: %v", kernel)
}
commands := []string{"touch /fastboot"} // /fastboot file prevents disk check on start.
commands := []string{"touch /fastboot",
// /fastboot file prevents disk check on start.
"mknod /dev/kcov c 346 0"}
if vmType == "gce" {
commands = append(commands, []string{
// We expect boot disk to be wd0a for the qemu (that's how qemu exposes -hda disk).
Expand Down

0 comments on commit 0dadcd9

Please sign in to comment.