Git Product home page Git Product logo

Comments (2)

rafaeldtinoco avatar rafaeldtinoco commented on June 4, 2024

#28 has been merged and map-update gives us:

$ make -C selftest/map-update run-static
make: Entering directory '/home/rafaeldtinoco/work/sources/ebpf/libbpfgo/selftest/map-update'
make -C /home/rafaeldtinoco/work/sources/ebpf/libbpfgo libbpfgo-static
make -C /home/rafaeldtinoco/work/sources/ebpf/libbpfgo vmlinuxh
make[1]: Entering directory '/home/rafaeldtinoco/work/sources/ebpf/libbpfgo'
make[1]: Entering directory '/home/rafaeldtinoco/work/sources/ebpf/libbpfgo'
mkdir -p ./output
mkdir -p ./output
mkdir -p ./output/libbpf
INFO: generating ./output/vmlinux.h from /sys/kernel/btf/vmlinux
CC="gcc" CFLAGS="-g -O2 -Wall -fpie" LD_FLAGS="" \
   make -C /home/rafaeldtinoco/work/sources/ebpf/libbpfgo/libbpf/src \
	BUILD_STATIC_ONLY=1 \
	OBJDIR=/home/rafaeldtinoco/work/sources/ebpf/libbpfgo/output/libbpf \
	DESTDIR=/home/rafaeldtinoco/work/sources/ebpf/libbpfgo/output \
	INCLUDEDIR= LIBDIR= UAPIDIR= install
make[2]: Entering directory '/home/rafaeldtinoco/work/sources/ebpf/libbpfgo/libbpf/src'
  MKDIR    staticobjs
  INSTALL  bpf.h libbpf.h btf.h libbpf_common.h libbpf_legacy.h xsk.h bpf_helpers.h bpf_helper_defs.h bpf_tracing.h bpf_endian.h bpf_core_read.h skel_internal.h
  CC       bpf.o
  CC       btf.o
  CC       libbpf.o
  CC       libbpf_errno.o
  CC       netlink.o
  CC       nlattr.o
  CC       str_error.o
  CC       libbpf_probes.o
  CC       bpf_prog_linfo.o
  CC       btf_dump.o
  CC       xsk.o
  CC       ringbuf.o
  CC       hashmap.o
  CC       strset.o
  CC       linker.o
  CC       gen_loader.o
  INSTALL  libbpf.pc
make[1]: Leaving directory '/home/rafaeldtinoco/work/sources/ebpf/libbpfgo'
clang -g -O2 -Wall -fpie -target bpf -I../../output -c main.bpf.c -o main.bpf.o
  AR       libbpf.a
  INSTALL  libbpf.a
make[2]: Leaving directory '/home/rafaeldtinoco/work/sources/ebpf/libbpfgo/libbpf/src'
CC=clang \
	CGO_CFLAGS="-I/home/rafaeldtinoco/work/sources/ebpf/libbpfgo/output" \
	CGO_LDFLAGS="-lelf -lz /home/rafaeldtinoco/work/sources/ebpf/libbpfgo/output/libbpf.a" \
	GOOS=linux GOARCH=amd64 \
	go build \
	-tags netgo -ldflags '-w -extldflags "-static"' \
	.
make[1]: Leaving directory '/home/rafaeldtinoco/work/sources/ebpf/libbpfgo'
CC=clang \
	CGO_CFLAGS="-I/home/rafaeldtinoco/work/sources/ebpf/libbpfgo/output" \
	CGO_LDFLAGS="-lelf -lz /home/rafaeldtinoco/work/sources/ebpf/libbpfgo/output/libbpf.a" \
	GOOS=linux GOARCH=amd64 \
	go build \
	-tags netgo -ldflags '-w -extldflags "-static"' \
	-o main-static ./main.go
sudo ./run.sh main-static
[*] SUCCESS: all good
make: Leaving directory '/home/rafaeldtinoco/work/sources/ebpf/libbpfgo/selftest/map-update'

run-dynamic is also good.

from libbpfgo.

rafaeldtinoco avatar rafaeldtinoco commented on June 4, 2024

This has already been fixed.

from libbpfgo.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.