Comments (2)
#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.
This has already been fixed.
from libbpfgo.
Related Issues (20)
- bump libbpf to map creation upstream fix HOT 1
- Reduce overhead of polling perf buffers HOT 3
- log callback isn't passing the right output level
- log callback is passing escaped output HOT 3
- v0.4.7-libbpf-1.2.0-b2e29a1 tag is released, but libblf v1.2.0 does not exist HOT 6
- Version `v0.4.8.1-libbpf-1.2.0` is not go module / semver compatible HOT 5
- Missing example/selftest: How to Attach a Socket Filter HOT 9
- How to Attach a BPF_PROG_TYPE_SK_MSG HOT 3
- NewModuleFromBufferArgs should not specify BTF if there isn't one
- Split BPFMap API into managed and unmanaged
- Split bpf module, progs, maps into own files
- Wrap C struct field handling
- Split bpf module and program into own files
- LinkType enum needs to align libbpf values
- attach xdp error
- Check type cast results
- [Error] in running go user space code HOT 1
- OSInfo singleton HOT 3
- LIBBPF_MAJOR_VERSION missing HOT 2
- Compiling a user space application that uses libbpfgo as dependency fails HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from libbpfgo.