Difference between revisions of "Xdp-tools modifications"

From epsciwiki
Jump to navigation Jump to search
 
Line 1: Line 1:
 
<font size="+2">
 
<font size="+2">
 
=== Modifications made to the xdp-tools repo in order to get everything to build and install properly ===
 
=== Modifications made to the xdp-tools repo in order to get everything to build and install properly ===
 +
 +
: Be warned that changes in this code are often checked in which break the build (due to, Ahem!, things like putting headers in different directories and not changing the makefile, Ahem!).
 +
 +
  
 
: modified '''''configure''''' file to change include directory
 
: modified '''''configure''''' file to change include directory

Latest revision as of 15:03, 16 November 2023

Modifications made to the xdp-tools repo in order to get everything to build and install properly

Be warned that changes in this code are often checked in which break the build (due to, Ahem!, things like putting headers in different directories and not changing the makefile, Ahem!).


modified configure file to change include directory
from
     LIBBPF_INCLUDE_DIR='$(LIB_DIR)/libbpf/src/root/usr/include'
to 
     LIBBPF_INCLUDE_DIR='$(LIB_DIR)/libbpf/src/root/include'
modified lib/Makefile to enable installation of libbpf (get all indents right!)
all: $(SUBDIRS) libxdp   ------>  all: $(SUBDIRS) libxdp libbpf
 
install: libxdp_install  ------>  install: libxdp_install libbpf_install

libbpf: $(OBJECT_LIBBPF) ------>

.PHONY: libbpf_install
libbpf_install: libbpf
       install -m 0755 -d $(DESTDIR)$(HDRDIR)
       $(MAKE) -C libbpf/src install

.PHONY: libbpf
 libbpf: $(OBJECT_LIBBPF)
       @echo; echo "  $@"; $(MAKE) -C $@/src
modified lib/libxdp/Makefile by adding these lines to the "install" target to enable installation of header files
$(Q)install -d -m 0755 $(DESTDIR)$(HDRDIR)/xdp
$(Q)install -m 0644 $(LIB_HEADERS) $(DESTDIR)$(HDRDIR)/xdp