diff options
author | Alex Williams <alex.williams@ni.com> | 2018-08-29 16:01:25 -0700 |
---|---|---|
committer | Martin Braun <martin.braun@ettus.com> | 2018-08-29 18:25:18 -0700 |
commit | 4e084337e685204a0142d1dff9e41b4e03d0b582 (patch) | |
tree | 09253a09485dd8fd063839d82caab4d8de9638a9 /host/cmake/Modules | |
parent | 2084a5a72df45fbcda82839ea35486f8583227bc (diff) | |
download | uhd-4e084337e685204a0142d1dff9e41b4e03d0b582.tar.gz uhd-4e084337e685204a0142d1dff9e41b4e03d0b582.tar.bz2 uhd-4e084337e685204a0142d1dff9e41b4e03d0b582.zip |
cmake: Check for rte_ethdev.h when finding DPDK
Ubuntu splits headers between the arch-specific and noarch directories,
so we were only getting one of them. That caused build failure for DPDK.
This fixes the issue by grabbing a fundamental header from the other
set.
Diffstat (limited to 'host/cmake/Modules')
-rw-r--r-- | host/cmake/Modules/FindDPDK.cmake | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/host/cmake/Modules/FindDPDK.cmake b/host/cmake/Modules/FindDPDK.cmake index 4382a8cce..53ecf1112 100644 --- a/host/cmake/Modules/FindDPDK.cmake +++ b/host/cmake/Modules/FindDPDK.cmake @@ -14,11 +14,19 @@ include(FindPackageHandleStandardArgs) -find_path ( DPDK_INCLUDE_DIR rte_config.h +find_path ( DPDK_INCLUDE_CONFIG_DIR rte_config.h PATHS ENV RTE_INCLUDE PATH_SUFFIXES dpdk ) +find_path ( DPDK_INCLUDE_ETHDEV_DIR rte_ethdev.h + PATHS ENV RTE_INCLUDE + PATH_SUFFIXES dpdk +) + +set(DPDK_INCLUDE_DIR ${DPDK_INCLUDE_CONFIG_DIR} ${DPDK_INCLUDE_ETHDEV_DIR}) +list(REMOVE_DUPLICATES DPDK_INCLUDE_DIR) + find_library(DPDK_LIBRARY PATHS $ENV{RTE_SDK_DIR}/$ENV{RTE_TARGET}/lib ) |