Make a package for nvme-cli and include it into the waveshare image.
All checks were successful
buildbot/travis_bionic Build done.
buildbot/multibuild_parent Build done.
buildbot/job/openwrt Build done.

Also move there kmod-nvme.
This commit is contained in:
Lee Miller 2023-06-17 04:02:05 +03:00
parent dc15708ee0
commit aed9b64b71
Signed by: lee.miller
GPG Key ID: 4F97A5EA88F4AB63
2 changed files with 57 additions and 3 deletions

View File

@ -31,6 +31,7 @@ echo "CONFIG_PACKAGE_COLLECTD_ENCRYPTED_NETWORK=y" >> .config
make package/kmod-nvme/compile make package/kmod-nvme/compile
make package/kmod-i2c-mux-pinctrl/compile make package/kmod-i2c-mux-pinctrl/compile
make package/kmod-rtc-pcf85063/compile make package/kmod-rtc-pcf85063/compile
make package/nvme-cli/compile
make package/asterisk-chan-quectel/compile make package/asterisk-chan-quectel/compile
make package/collectd/compile make package/collectd/compile
@ -57,7 +58,7 @@ echo "CONFIG_TARGET_ROOTFS_PARTSIZE=308" >> .config
echo "CONFIG_TARGET_ROOTFS_EXT4FS=n" >> .config echo "CONFIG_TARGET_ROOTFS_EXT4FS=n" >> .config
PACKAGES="kmod-i2c-bcm2835 kmod-i2c-mux kmod-i2c-mux-pinctrl \ PACKAGES="kmod-i2c-bcm2835 kmod-i2c-mux kmod-i2c-mux-pinctrl \
kmod-nf-nathelper-extra kmod-nvme \ kmod-nf-nathelper-extra \
kmod-rtc-ds1307 kmod-rtc-pcf8563 kmod-rtc-pcf85063 \ kmod-rtc-ds1307 kmod-rtc-pcf8563 kmod-rtc-pcf85063 \
kmod-usb-audio kmod-usb-net-rtl8152 \ kmod-usb-audio kmod-usb-net-rtl8152 \
alsa-lib pciutils usbutils \ alsa-lib pciutils usbutils \
@ -131,8 +132,8 @@ sed -i "s|,i2c_csi_dsi||g" ${BOOTSOURCE}/current.txt
make image PROFILE=${PROFILE} \ make image PROFILE=${PROFILE} \
PACKAGES=" \ PACKAGES=" \
${PACKAGES} kmod-ata-ahci smartmontools hdparm fdisk parted \ ${PACKAGES} cryptsetup kmod-ata-ahci smartmontools hdparm fdisk parted \
kmod-hwmon-drivetemp btrfs-progs kmod-fs-btrfs cryptsetup" \ kmod-hwmon-drivetemp btrfs-progs kmod-fs-btrfs kmod-nvme nvme-cli" \
DISABLED_SERVICES="dropbear" FILES="files" || exit 1 DISABLED_SERVICES="dropbear" FILES="files" || exit 1
mv ${IMAGE_PATH}-squashfs-factory.img.gz ${IMAGE_PATH}-squashfs-factory-waveshare.img.gz mv ${IMAGE_PATH}-squashfs-factory.img.gz ${IMAGE_PATH}-squashfs-factory-waveshare.img.gz

53
feed/nvme-cli/Makefile Normal file
View File

@ -0,0 +1,53 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=nvme-cli
PKG_VERSION:=2.4
PKG_RELEASE:=1
PKG_SOURCE:=v$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://github.com/linux-nvme/nvme-cli/archive/refs/tags/
PKG_HASH:=7f80102a933e3bf46f4f2089cad119c827a363478235f66b89ddaad9ca57d019
PKG_MAINTAINER:=Lee Miller <lee.miller@tutanota.com>
PKG_LICENSE:=GPL-2.0
PKG_LICENSE_FILES:=LICENSE
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/meson.mk
define Package/$(PKG_NAME)
SECTION:=utils
CATEGORY:=Utilities
URL:=https://nvmexpress.org/
TITLE:=NVMe management command line interface
DEPENDS += +libopenssl
endef
define Package/$(PKG_NAME)/description
NVM-Express user space tooling for Linux.
endef
MESON_ARGS += --force-fallback-for=libnvme
define Package/$(PKG_NAME)/conffiles
/etc/nvme/discovery.conf
endef
define Package/$(PKG_NAME)/install
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/nvme $(1)/usr/sbin/
$(INSTALL_DIR) $(1)/usr/include
$(CP) $(PKG_INSTALL_DIR)/usr/include/json-c $(1)/usr/include/
$(CP) $(PKG_INSTALL_DIR)/usr/include/nvme $(1)/usr/include/
$(CP) $(PKG_INSTALL_DIR)/usr/include/libnvme*.h $(1)/usr/include/
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libjson-c.so $(1)/usr/lib/
$(CP) $(PKG_INSTALL_DIR)/usr/lib/lib{nvme,nvme-mi}.so* $(1)/usr/lib/
$(INSTALL_DIR) $(1)/etc/nvme
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/etc/nvme/discovery.conf \
$(1)/etc/nvme
$(INSTALL_DIR) $(1)/lib/udev/rules.d
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/udev/rules.d/*.rules \
$(1)/lib/udev/rules.d
endef
$(eval $(call BuildPackage,$(PKG_NAME)))