Skip to content

Commit

Permalink
Use more informative error when making bpf object fails
Browse files Browse the repository at this point in the history
  • Loading branch information
yanivagman committed Dec 8, 2020
1 parent 800a079 commit a92b1ef
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions main.go
Expand Up @@ -691,7 +691,7 @@ func makeBPFObject(outFile string) error {
}
err = cmd1.Run()
if err != nil {
return err
return fmt.Errorf("Failed to make BPF object (clang): %v. Try using --debug for more info", err)
}

// from Makefile:
Expand All @@ -710,7 +710,7 @@ func makeBPFObject(outFile string) error {
}
err = cmd2.Run()
if err != nil {
return err
return fmt.Errorf("Failed to make BPF object (llc): %v. Try using --debug for more info", err)
}

// from Makefile:
Expand All @@ -727,7 +727,7 @@ func makeBPFObject(outFile string) error {
}
err = cmd3.Run()
if err != nil {
return err
return fmt.Errorf("Failed to make BPF object (llvm-strip): %v. Try using --debug for more info", err)
}
}

Expand Down

0 comments on commit a92b1ef

Please sign in to comment.