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

compliing the project faild in arm 64 #93

Closed
magnate3 opened this issue Jan 16, 2020 · 8 comments
Closed

compliing the project faild in arm 64 #93

magnate3 opened this issue Jan 16, 2020 · 8 comments

Comments

@magnate3
Copy link

magnate3 commented Jan 16, 2020

I complile the project but fails in arm 64. because of libz.so.
so,I solve the problem by the following steps :
################ download zlib-1.2.8.tar.gz################
################ make & install zlib-1.2.8 ####################

./configure

make && make install
headers will be installed in /usr/local/include/ and libz.so.1.2.8 will be installed in /usr/local/lib/
ls /usr/local/include/

ls /usr/local/lib/

################edit common/common.mk ####################

LDFLAGS ?= -L$(LIBBPF_DIR) -L/usr/local/lib

LIBS = -l:libbpf.a -lelf $(USER_LIBS) -lz -l:libz.so.1.2.8

the solution is here:https://github.com/magnate3/xdp

@tohojo
Copy link
Member

tohojo commented Jan 16, 2020 via email

@magnate3
Copy link
Author

I have installed libz-devel in my os ,but in the process of compling report
undefined reference to 'gzopen()';
undefined reference to 'gzwrite()';
undefined reference to 'gzclose()';

so,I make & install zlib-1.2.8 and finally solve the problem.

@tohojo
Copy link
Member

tohojo commented Jan 16, 2020 via email

@magnate3
Copy link
Author

magnate3 commented Jan 17, 2020

I the following steps
1、 git submodule add https://github.com/libbpf/libbpf/ libbpf
2、 add -lz linker flag.
but reports the bugs such as undefined reference to 'gzopen()' and so on

@tohojo
Copy link
Member

tohojo commented Jan 17, 2020 via email

@magnate3
Copy link
Author

magnate3 commented Jan 19, 2020

thank you very much ,your way can also solve my probleem. cloud you tell me where I can share my notes about the kernel achivements of xdp

@tohojo
Copy link
Member

tohojo commented Jan 20, 2020 via email

@dmitris
Copy link
Contributor

dmitris commented Apr 29, 2022

here's the issue I hit: git clone --recurse-submodules https://github.com/xdp-project/xdp-tutorial as @magnate3 wrote above works fine, but git clone --recurse-submodules --remote-submodules https://github.com/xdp-project/xdp-tutorial gets a wrong version of libbpf and correspondingly the ZLIB compile failure.

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

No branches or pull requests

3 participants