• Thomas Haller's avatar
    std-aux: add "libnm-std-aux/nm-linux-compat.h" header to avoid build errors · 2a070434
    Thomas Haller authored
    We have a copy of a few linux user space headers in `src/linux-headers`.
    The idea is that we want to use recent kernel API, and not depend on the
    kernel UAPI headers installed on the build system (and not need to
    workaround that).
    
    However, we may not be able to simply compile them, because they too
    have dependencies. For example,
    
      ../src/linux-headers/ethtool.h:1389:2: error: implicit declaration of function '__KERNEL_DIV_ROUND_UP' [-Werror=implicit-function-declaration]
        __u32 queue_mask[__KERNEL_DIV_ROUND_UP(MAX_NUM_QUEUE, 32)];
        ^
    
    As workaround, don't include headers from "linux-headers" directly,
    but only include the new "libnm-std-aux/nm-linux-compat.h" adapter
    header, which tries to solve these incompatibilities.
    
    Fixes: 34d48d25 ('platform: clear all BASE types when setting advertised modes for ethernet autoneg')
    2a070434
After you've reviewed these contribution guidelines, you'll be all set to contribute to this project.