tasks/system_probe.py
def build_object_files(ctx, parallel_build):
    """build_object_files builds only the eBPF object"""

    # if clang is missing, subsequent calls to ctx.run("clang ...") will fail silently
    print("checking for clang executable...")
    ctx.run("which clang")

    bpf_dir = os.path.join(".", "pkg", "ebpf")
    build_dir = os.path.join(bpf_dir, "bytecode", "build")
    build_runtime_dir = os.path.join(build_dir, "runtime")

    ctx.run(f"mkdir -p {build_dir}")
    ctx.run(f"mkdir -p {build_runtime_dir}")

    bindata_files = []
    build_network_ebpf_files(ctx, build_dir=build_dir, parallel_build=parallel_build)
    bindata_files.extend(build_security_ebpf_files(ctx, build_dir=build_dir, parallel_build=parallel_build))

    generate_runtime_files(ctx)

    go_dir = os.path.join(bpf_dir, "bytecode", "bindata")
    bundle_files(ctx, bindata_files, "pkg/.*/", go_dir, "bindata", BUNDLE_TAG)
build_object_files builds only the eBPF object
build_object_files builds only the eBPF object
build_object_files builds only the eBPF object
def build_object_files(ctx, parallel_build):
    print("checking for clang executable...")
    ctx.run("which clang")
    bpf_dir = os.path.join(".", "pkg", "ebpf")
    build_dir = os.path.join(bpf_dir, "bytecode", "build")
    build_runtime_dir = os.path.join(build_dir, "runtime")
    ctx.run(f"mkdir -p {build_dir}")
    ctx.run(f"mkdir -p {build_runtime_dir}")
    bindata_files = []
    build_network_ebpf_files(ctx, build_dir=build_dir, parallel_build=parallel_build)
    bindata_files.extend(build_security_ebpf_files(ctx, build_dir=build_dir, parallel_build=parallel_build))
    generate_runtime_files(ctx)
    go_dir = os.path.join(bpf_dir, "bytecode", "bindata")
    bundle_files(ctx, bindata_files, "pkg/.*/", go_dir, "bindata", BUNDLE_TAG)
def build_object_files ( ctx , parallel_build ) : print ( "checking for clang executable..." ) ctx . run ( "which clang" ) bpf_dir = os . path . join ( "." , "pkg" , "ebpf" ) build_dir = os . path . join ( bpf_dir , "bytecode" , "build" ) build_runtime_dir = os . path . join ( build_dir , "runtime" ) ctx . run ( f"mkdir -p {build_dir}" ) ctx . run ( f"mkdir -p {build_runtime_dir}" ) bindata_files = [ ] build_network_ebpf_files ( ctx , build_dir = build_dir , parallel_build = parallel_build ) bindata_files . extend ( build_security_ebpf_files ( ctx , build_dir = build_dir , parallel_build = parallel_build ) ) generate_runtime_files ( ctx ) go_dir = os . path . join ( bpf_dir , "bytecode" , "bindata" ) bundle_files ( ctx , bindata_files , "pkg/.*/" , go_dir , "bindata" , BUNDLE_TAG )
build_object_files builds only the eBPF object
build_object_files builds only the eBPF object
"""build_object_files builds only the eBPF object""" # if clang is missing, subsequent calls to ctx.run("clang ...") will fail silently
ctx
parallel_build