Skip to contentSkip to conversation

fuse3: remove sysv init script and install fuse kernel module explictly

PATCH Superseded [email protected] 2 participants 3 messages May 23, 2024

v2 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 fuse3: remove sysv init script and install fuse kernel module explictly

From: Changqing Li <[email protected]>

For systemd, there is not a fuse.service since systemd provides sys-fs-fuse-connections.mount to mount the fuse control filesystem, so instead, only fuse3.conf is added to modules-load.d to load the required fuse kernel module.

---
 meta-oe/recipes-support/fuse/fuse3/fuse3.conf |  1 +
 meta-oe/recipes-support/fuse/fuse3_3.16.2.bb  | 15 +++++++++++++++
 2 files changed, 16 insertions(+)
 create mode 100644 meta-oe/recipes-support/fuse/fuse3/fuse3.conf
meta-oe/recipes-support/fuse/fuse3/fuse3.conf new file +1 -0
new file mode 100644
index 000000000..a517c488f
@@ -0,0 +1 @@
+fuse
meta-oe/recipes-support/fuse/fuse3_3.16.2.bb +15 -0
index 307544bf3..b799b2c6b 100644
@@ -27,6 +27,7 @@ inherit meson pkgconfig ptest
 
 SRC_URI += " \
     file://run-ptest \
+    file://fuse3.conf \
 "
 
 RDEPENDS:${PN}-ptest += " \
@@ -78,6 +79,20 @@ FILES:fuse3-utils = "${bindir} ${base_sbindir}"
 DEBIAN_NOAUTONAME:fuse3-utils = "1"
 DEBIAN_NOAUTONAME:${PN}-dbg = "1"
 
+SYSTEMD_SERVICE:${PN} = ""
+
 do_install:append() {
     rm -rf ${D}${base_prefix}/dev
+
+    # systemd class remove the sysv_initddir only if systemd_system_unitdir
+    # contains anything, but it's not needed if sysvinit is not in DISTRO_FEATURES
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'false', 'true', d)}; then
+        rm -rf ${D}${sysconfdir}/init.d/
+    fi
+
+    # Install systemd related configuration file
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+        install -d ${D}${sysconfdir}/modules-load.d
+        install -m 0644 ${WORKDIR}/fuse3.conf ${D}${sysconfdir}/modules-load.d
+    fi
 }
Signature · 1 line
2.25.1
#1 lore raw
Quoted 43 lines · Changqing Li via lists.openembedded.org

From: Changqing Li <[email protected]>

For systemd, there is not a fuse.service since systemd provides sys-fs-fuse-connections.mount to mount the fuse control filesystem, so instead, only fuse3.conf is added to modules-load.d to load the required fuse kernel module.

---
 meta-oe/recipes-support/fuse/fuse3/fuse3.conf |  1 +
 meta-oe/recipes-support/fuse/fuse3_3.16.2.bb  | 15 +++++++++++++++
 2 files changed, 16 insertions(+)
 create mode 100644 meta-oe/recipes-support/fuse/fuse3/fuse3.conf
meta-oe/recipes-support/fuse/fuse3/fuse3.conf new file +1 -0
new file mode 100644
index 000000000..a517c488f
@@ -0,0 +1 @@
+fuse
meta-oe/recipes-support/fuse/fuse3_3.16.2.bb +4 -0
index 307544bf3..b799b2c6b 100644
@@ -27,6 +27,7 @@ inherit meson pkgconfig ptest
 
 SRC_URI += " \
     file://run-ptest \
+    file://fuse3.conf \
 "
 
 RDEPENDS:${PN}-ptest += " \
@@ -78,6 +79,20 @@ FILES:fuse3-utils = "${bindir} ${base_sbindir}"
 DEBIAN_NOAUTONAME:fuse3-utils = "1"
 DEBIAN_NOAUTONAME:${PN}-dbg = "1"
 
+SYSTEMD_SERVICE:${PN} = ""
+
 do_install:append() {
     rm -rf ${D}${base_prefix}/dev
+

meta-oe/recipes-support/fuse/fuse3_3.16.2.bb FILES:fuse3-utils = "${bindir} ${base_sbindir}" · line 96

Quoted 10 lines
meta-oe/recipes-support/fuse/fuse3_3.16.2.bb +10 -0
+    # systemd class remove the sysv_initddir only if systemd_system_unitdir
+    # contains anything, but it's not needed if sysvinit is not in DISTRO_FEATURES
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'false', 'true', d)}; then
+        rm -rf ${D}${sysconfdir}/init.d/
+    fi
+
+    # Install systemd related configuration file
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+        install -d ${D}${sysconfdir}/modules-load.d
+        install -m 0644 ${WORKDIR}/fuse3.conf ${D}${sysconfdir}/modules-load.d

This should be UNPACKDIR instead of WORKDIR here.

Quoted 14 lines
meta-oe/recipes-support/fuse/fuse3_3.16.2.bb +1 -1
+    fi
 }
--

2.25.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#110492): https://lists.openembedded.org/g/openembedded-devel/message/110492
Mute This Topic: https://lists.openembedded.org/mt/106255586/1997914
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

#2 lore raw
Quoted 43 lines · Khem Raj

CAUTION: This email comes from a non Wind River email account!
Do not click links or open attachments unless you recognize the sender and know the content is safe.

Quoted 37 lines · Changqing Li via lists.openembedded.org

From: Changqing Li<[email protected]>

For systemd, there is not a fuse.service since systemd provides sys-fs-fuse-connections.mount to mount the fuse control filesystem, so instead, only fuse3.conf is added to modules-load.d to load the required fuse kernel module.

---
  meta-oe/recipes-support/fuse/fuse3/fuse3.conf |  1 +
  meta-oe/recipes-support/fuse/fuse3_3.16.2.bb  | 15 +++++++++++++++
  2 files changed, 16 insertions(+)

create mode 100644 meta-oe/recipes-support/fuse/fuse3/fuse3.conf

meta-oe/recipes-support/fuse/fuse3/fuse3.conf new file +1 -0
new file mode 100644
index 000000000..a517c488f
@@ -0,0 +1 @@
+fuse
meta-oe/recipes-support/fuse/fuse3_3.16.2.bb +1 -0
index 307544bf3..b799b2c6b 100644
@@ -27,6 +27,7 @@ inherit meson pkgconfig ptest
 
  SRC_URI += " \
      file://run-ptest  \
+file://fuse3.conf  \
  "
 
  RDEPENDS:${PN}-ptest += " \
@@ -78,6 +79,20 @@ FILES:fuse3-utils = "${bindir} ${base_sbindir}"
  DEBIAN_NOAUTONAME:fuse3-utils = "1"
  DEBIAN_NOAUTONAME:${PN}-dbg = "1"
 
Quoted 16 lines
Quoted 5 lines
meta-oe/recipes-support/fuse/fuse3_3.16.2.bb +3 -0
+SYSTEMD_SERVICE:${PN} = ""
+
  do_install:append() {
      rm -rf ${D}${base_prefix}/dev
+

meta-oe/recipes-support/fuse/fuse3_3.16.2.bb FILES:fuse3-utils = "${bindir} ${base_sbindir}" · line 96

Quoted 10 lines
meta-oe/recipes-support/fuse/fuse3_3.16.2.bb +10 -0
+    # systemd class remove the sysv_initddir only if systemd_system_unitdir
+    # contains anything, but it's not needed if sysvinit is not in DISTRO_FEATURES
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'false', 'true', d)}; then
+        rm -rf ${D}${sysconfdir}/init.d/
+    fi
+
+    # Install systemd related configuration file
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+        install -d ${D}${sysconfdir}/modules-load.d
+        install -m 0644 ${WORKDIR}/fuse3.conf ${D}${sysconfdir}/modules-load.d

This should be UNPACKDIR instead of WORKDIR here.

Thanks. Will send a V3 and fix this.

Regards

Sandy

Quoted 15 lines
Quoted 15 lines
meta-oe/recipes-support/fuse/fuse3_3.16.2.bb +1 -1
+    fi
  }
--

2.25.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#110492):https://lists.openembedded.org/g/openembedded-devel/message/110492 Mute This Topic:https://lists.openembedded.org/mt/106255586/1997914
Group Owner:[email protected] Unsubscribe:https://lists.openembedded.org/g/openembedded-devel/unsub [[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-