Last active
November 23, 2021 11:06
-
-
Save krsna1729/8562d9f2ad8050583af9ac55ad269421 to your computer and use it in GitHub Desktop.
dpdk af-xdp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu as builder | |
RUN apt-get update && \ | |
apt-get -y install --no-install-recommends \ | |
ca-certificates \ | |
git \ | |
gcc \ | |
libelf-dev \ | |
libnuma-dev \ | |
make \ | |
pkg-config \ | |
python3-pip \ | |
python3-setuptools && \ | |
rm -rf /var/lib/apt/lists/* | |
RUN pip3 install --no-cache-dir \ | |
meson \ | |
ninja \ | |
pyelftools | |
# Download all code | |
RUN git clone https://github.com/libbpf/libbpf.git /libbpf && \ | |
git clone https://dpdk.org/git/dpdk /dpdk | |
ENV PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig | |
# Compile all code | |
ARG LIBBPF_VER=v0.5.0 | |
RUN cd /libbpf && \ | |
git checkout -b build ${LIBBPF_VER} && \ | |
cp include/uapi/linux/if_xdp.h /usr/include/linux && \ | |
cd src && \ | |
LIBDIR=/usr/lib/x86_64-linux-gnu make install && \ | |
ldconfig | |
ARG DPDK_VER=v21.11-rc3 | |
RUN cd /dpdk && \ | |
git checkout -b build ${DPDK_VER} && \ | |
meson build && \ | |
ninja -C build | |
ENV PATH=${PATH}:/dpdk/build/app | |
# FROM ubuntu | |
# RUN apt-get update && \ | |
# apt-get -y install --no-install-recommends \ | |
# iproute2 \ | |
# libatomic1 \ | |
# libnuma1 | |
# COPY --from=builder /dpdk/build/app/dpdk-testpmd /bin |
Author
krsna1729
commented
Nov 23, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment