Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Makefile 102row -lbpf? how do i install it #43

Open
kay6666 opened this issue Jul 12, 2022 · 3 comments
Open

Makefile 102row -lbpf? how do i install it #43

kay6666 opened this issue Jul 12, 2022 · 3 comments

Comments

@kay6666
Copy link

kay6666 commented Jul 12, 2022

102 :$(Q)$(CC) $(CFLAGS) $(INCLUDES) $^ -lelf -lbpf -lz -lssl -lcrypto -Wno-deprecated-declarations -o bin/$@ -ldl

root@iZmj7gheya94tuozzw8m0jZ:~/TripleCross/src# make all
BINARY kit
/usr/bin/ld: cannot find -lbpf: No such file or directory
collect2: error: ld returned 1 exit status
make: *** [Makefile:102: kit] Error 1

I get this error when I make, what is lbpf?
thanks for helping me

@h3xduck
Copy link
Owner

h3xduck commented Jul 18, 2022

Hi, -lbpf is used by gcc for linking against libbpf. You may try installing libbpf in your system:

sudo apt install libbpf-dev

@5stars217
Copy link

Hi @h3xduck.
Thanks for providing this research, it's an excellent write up.

I'm having the same issue as kay6666 on ubunutu 20.04:
~/TripleCross/src$ make all BINARY kit /usr/bin/ld: cannot find -lbpf collect2: error: ld returned 1 exit status make: *** [Makefile:102: kit] Error 1

if I run $ sudo apt update
sudo apt install libbpf-dev
I get
sudo apt install libbpf-dev Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package libbpf-dev

In fact if I search for the package, it doesn't seem to exist anymore?

sudo apt search libbpf-dev Sorting... Done Full Text Search... Done

I also installed aptitude and tried the same thing. No luck.

if libbpf-dev has been merged into some other project, I couldn't find mention of it.

vr

@h3xduck
Copy link
Owner

h3xduck commented Jul 27, 2022

Hi @5stars217, could you try with 21.04? That is the version we are supporting. In 20.04 the package may be called otherwise. In fact you will not only find that build error, but also others such as #42

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants