Unverified Commit e9ead8a1 authored by dish's avatar dish Committed by GitHub
Browse files

vpp: patch CMakeLists.txt so that the AF_XDP plugin builds (#442342)

parents bd662249 df1a7f02
Loading
Loading
Loading
Loading
+6 −6
Original line number Diff line number Diff line
@@ -38,11 +38,6 @@ let
    ];
  });

  xdp-tools' = xdp-tools.overrideAttrs (old: {
    postInstall = "";
    dontDisableStatic = true;
  });

  # in 25.02 only ID seems to be of interest, so keep it simple
  os-release-fake = writeText "os-release-fake" ''
    ID=nixos
@@ -116,7 +111,12 @@ stdenv.mkDerivation rec {
    # af_xdp plugin
    libelf
    libbpf
    xdp-tools'
    xdp-tools
    zlib
  ];

  patches = lib.optionals enableAfXdp [
    ./use-dynamic-libxdp-libbpf.patch
  ];

  passthru.updateScript = nix-update-script { };
+13 −0
Original line number Diff line number Diff line
--- a/plugins/af_xdp/CMakeLists.txt
+++ b/plugins/af_xdp/CMakeLists.txt
@@ -18,8 +18,8 @@ if (NOT XDP_INCLUDE_DIR)
 endif()

 set_property(GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS TRUE)
-vpp_plugin_find_library(af_xdp XDP_LIB libxdp.a)
-vpp_plugin_find_library(af_xdp BPF_LIB libbpf.a)
+vpp_plugin_find_library(af_xdp XDP_LIB xdp)
+vpp_plugin_find_library(af_xdp BPF_LIB bpf)
 vpp_plugin_find_library(af_xdp ELF_LIB elf)
 vpp_plugin_find_library(af_xdp Z_LIB z)
 if (NOT XDP_LIB OR NOT BPF_LIB OR NOT ELF_LIB OR NOT Z_LIB)