F-Stack / f-stack

F-Stack is an user space network development kit with high performance based on DPDK, FreeBSD TCP/IP stack and coroutine API.
http://www.f-stack.org
Other
3.76k stars 879 forks source link

Compile errors:No such file or directory #766

Closed wufuhuai closed 1 year ago

wufuhuai commented 1 year ago

Hi I followed the README guide, adapting it to my system. However, there was an issue during the compiling of the F-Stack make process.

Makefile:56: *** "no installation of DPDK found, maybe you shuld export environment variable PKG_CONFIG_PATH". Stop.

I searched for some solutions and found that I need to add libdpdk.pc to the environment variable PKG_CONFIG_PATH. I found libdpdk.pc is in /data/f-stack/dpdk/build/meson-private/. I added it to PKG_CONFIG_PATH and make. However, another error occurred.

cc -c -O2 -frename-registers  -funswitch-loops -fweb -Wno-format-truncation -DFF_KNI -Wall -Wno-deprecated-declarations -Werror -include rte_config.h -march=native -I/usr/local/include  -DINET -DINET6 -I. -Werror -Wno-unused-variable  ff_host_interface.c
cc1: fatal error: rte_config.h: No such file or directory
compilation terminated. 
make: *** [Makefile:660: ff_host_interface.o] Error 1

I found that the rte_config.h file is located in the /data/f-stack/dpdk/config/. I added '-I/data/f-stack/dpdk/config/' to the Makefile, but similar missing file(another .h) error appeared again and again.

Compiler environment: F-stack version 1.23 OS Ubuntu 20.04.4 LTS Linux ubuntu 5.15.0-71-generic gcc (Ubuntu 9.4.0-1ubuntu1~20.04.1) 9.4.0

wufuhuai commented 1 year ago

Another linux version is ok OS Ubuntu 20.04.6 LTS Linux ubuntu 5.15.0-71-generic