Added build for libnvme, optional dep for libblockdev

This commit is contained in:
dslm4515
2023-11-10 21:33:49 -06:00
parent fd91906703
commit dc651258d0
3 changed files with 72 additions and 0 deletions

View File

@ -0,0 +1,46 @@
#! /bin/bash
# libnvme
# Source: https://github.com/linux-nvme/libnvme/archive/refs/tags/v1.6/libnvme-1.6.tar.gz
#
# $BUILD = Directory to temporarily install
# $PKGS = Directory to store built packages
#
# DEPS
# Required: NONE
# Recommended: NONE
# Optional: dbus json-c keyutils swig
patch -Np1 -i ../patches/libnvme-chimera/ioctl-int.patch
patch -Np1 -i ../patches/libnvme-chimera/doc-test.patch
meson setup --prefix=/usr --buildtype=release \
-Dlibdbus=auto BUILD
read -p "Compile?" && ninja -C BUILD -j2 &&
sudo -S DESTDIR=$BUILD ninja -C BUILD install &&
cd $BUILD && sudo -S mkdir -v ${BUILD}/install &&
cat > /tmp/slack-desc << "EOF"
# HOW TO EDIT THIS FILE:
# The "handy ruler" below makes it easier to edit a package description. Line
# up the first '|' above the ':' following the base package name, and the '|'
# on the right side marks the last column you can put a character in. You must
# make exactly 11 lines for the formatting to be correct. It's also
# customary to leave one space after the ':' except on otherwise blank lines.
|-----handy-ruler------------------------------------------------------|
libnvme: libnvme
libnvme:
libnvme: A library which provides type definitions for NVMe specification
libnvme; structures, enumerations, and bit fields, helper functions to
libnvme: construct, dispatch, and decode commands and payloads, and utilities
libnvme: to connect, scan, and manage NVMe devices on a Linux system.
libnvme:
libnvme: https://github.com/linux-nvme/libnvme
libnvme:
EOF
sudo -S mv -v /tmp/slack-desc install/ &&
sudo -S makepkg -l y -c n $PKGS/libnvme-1.6-$PSUFFIX &&
sudo -S rm -rf ${BUILD}/*

View File

@ -0,0 +1,14 @@
needs kernel-doc from linux docs
diff --git a/doc/meson.build b/doc/meson.build
index d716c8b..02e90e2 100644
--- a/doc/meson.build
+++ b/doc/meson.build
@@ -49,7 +49,7 @@ want_docs_build = get_option('docs-build')
kernel_doc = find_program('kernel-doc')
kernel_doc_check = find_program('kernel-doc-check')
-test('kdoc', kernel_doc_check, args: api_paths)
+#test('kdoc', kernel_doc_check, args: api_paths)
if want_docs != 'false'

View File

@ -0,0 +1,12 @@
ffs
--- a/test/ioctl/mock.c
+++ b/test/ioctl/mock.c
@@ -114,7 +114,7 @@
} \
})
-int ioctl(int fd, unsigned long request, ...)
+int ioctl(int fd, int request, ...)
{
struct mock_cmds *mock_cmds;
bool result64;