nvme-cli won't build
Anybody know what's up here? I've got linux-4.8-rc8 kernel built/installed and the latest nvme-cli pulled, but nvme-cli fails to build.
[root at stevo1 nvme-cli]# make
cc -D_GNU_SOURCE -D__CHECK_ENDIAN__ -std=gnu99 -O2 -g -Wall -Werror -DLIBUDEV_EXISTS -DNVME_VERSION='"0.9.35.gf051"' -c nvme-print.c In file included from nvme.h:22,
from nvme-print.h:4,
from nvme-print.c:6:linux/nvme.h:19:24: error: linux/uuid.h: No such file or directory In file included from nvme.h:22,
from nvme-print.h:4,
from nvme-print.c:6:linux/nvme.h:806: error: expected specifier-qualifier-list before ?uuid_be?
make: *** [nvme-print.o] Error 1
[root at stevo1 nvme-cli]#
Quoted 2 lines · Steve Wise
Anybody know what's up here? I've got linux-4.8-rc8 kernel built/installed and the latest nvme-cli pulled, but nvme-cli fails to build.
Looks like your Linux headers are missing it. It should be fairly easy to avoid the need for it, let me see if I can do that.
The patch below will fix it for you:
linux/nvme.h +1 -2
@@ -16,7 +16,6 @@#define _LINUX_NVME_H#include <linux/types.h> -#include <linux/uuid.h> /* NQN names in commands fields specified one size */ #define NVMF_NQN_FIELD_LEN 256
@@ -803,7 +802,7 @@ struct nvmf_connect_command { };struct nvmf_connect_data { -uuid_be hostid; +__u8 hostid[16 ];__le16 cntlid;char resv4[238 ];char subsysnqn[NVMF_NQN_FIELD_LEN ];
Quoted 2 lines
The patch below will fix it for you:
Thanks, that works!