Skip to content

Macro "KERNEL_VERSION" is not defined #39

@ftchawe-aneo

Description

@ftchawe-aneo

Hello,
I am trying to compile the gvNIC driver on a compute intance VM based on an CentOS 7 image.
I am getting compilation errors when trying to build the modules with the command :

make -C /lib/modules/`uname -r`/build M=$(pwd)/build modules modules_install

My kernel release is 3.10.0-1160.25.1.el7.x86_64

The error indicates that the KERNEL_VERSION macro is not defined.

/home/user/compute-virtual-ethernet-linux/build/gve_desc.h:12:27: warning: "KERNEL_VERSION" is not defined [-Wundef] #if LINUX_VERSION_CODE >= KERNEL_VERSION(5,1,0)
/home/user/compute-virtual-ethernet-linux/build/gve_desc.h:12:41: error: missing binary operator before token "(" #if LINUX_VERSION_CODE >= KERNEL_VERSION(5,1,0)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions