meson: add feature flag for storage

storage builds and installs binaries, docs, units, etc. Add a
feature flag to make it easier to avoid shipping it.
This commit is contained in:
Luca Boccassi authored and Yu Watanabe committed 2026-10-25 09:34:00 +09:00
1 parent 2ce176286a
commit 48493bc9d3
11 files changed
+22 -8

No files matched your search

+3 -3
View File
@@ -1013,7 +1013,7 @@ manpages = [
['sd_watchdog_enabled', '3', [], ''],
['shutdown', '8', [], ''],
['smbios-type-11', '7', [], ''],
['storagectl', '1', ['mount.storage'], ''],
['storagectl', '1', ['mount.storage'], 'ENABLE_STORAGE'],
['sysctl.d', '5', [], ''],
['sysext.conf',
'5',
@@ -1287,11 +1287,11 @@ manpages = [
['systemd-storage-block@.service',
'8',
['systemd-storage-block', 'systemd-storage-block.socket'],
''],
'ENABLE_STORAGE'],
['systemd-storage-fs@.service',
'8',
['systemd-storage-fs', 'systemd-storage-fs.socket'],
''],
'ENABLE_STORAGE'],
['systemd-storagetm.service', '8', ['systemd-storagetm'], 'ENABLE_STORAGETM'],
['systemd-stub',
'7',
+1 -1
View File
@@ -3,7 +3,7 @@
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
<!-- SPDX-License-Identifier: LGPL-2.1-or-later -->
<refentry id="storagectl"
<refentry id="storagectl" conditional="ENABLE_STORAGE"
xmlns:xi="http://www.w3.org/2001/XInclude">
<refentryinfo>
+1 -1
View File
@@ -3,7 +3,7 @@
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
<!-- SPDX-License-Identifier: LGPL-2.1-or-later -->
<refentry id="systemd-storage-block_.service"
<refentry id="systemd-storage-block_.service" conditional="ENABLE_STORAGE"
xmlns:xi="http://www.w3.org/2001/XInclude">
<refentryinfo>
+1 -1
View File
@@ -3,7 +3,7 @@
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
<!-- SPDX-License-Identifier: LGPL-2.1-or-later -->
<refentry id="systemd-storage-fs_.service"
<refentry id="systemd-storage-fs_.service" conditional="ENABLE_STORAGE"
xmlns:xi="http://www.w3.org/2001/XInclude">
<refentryinfo>
+2
View File
@@ -1797,6 +1797,7 @@ conf.set10('ENABLE_BATTERY_CHECK', get_option('battery-check').allowed())
conf.set10('ENABLE_CLONESETUP', get_option('clonesetup').allowed())
conf.set10('ENABLE_GROWFS', get_option('growfs').allowed())
conf.set10('ENABLE_SLEEP', get_option('sleep').allowed())
conf.set10('ENABLE_STORAGE', get_option('storage').allowed())
have = get_option('integritysetup').require(
conf.get('HAVE_LIBCRYPTSETUP') == 1,
@@ -3486,6 +3487,7 @@ foreach tuple : [
['rfkill'],
['rust', have_rust],
['sleep'],
['storage'],
['sysext'],
['sysinstall'],
['systemd-analyze', conf.get('ENABLE_ANALYZE') == 1],
+2
View File
@@ -253,6 +253,8 @@ option('rfkill', type : 'boolean',
description : 'support for the rfkill tools')
option('sleep', type : 'feature',
description : 'install systemd-sleep and associated files')
option('storage', type : 'feature',
description : 'install systemd-storage-block, systemd-storage-fs, storagectl, and associated files')
option('storagetm', type : 'boolean',
description : 'support for Storage Target Mode')
option('sysext', type : 'boolean',
+1 -1
View File
@@ -48,7 +48,7 @@ foreach item : [
['ptyctl', ''],
['resolvectl', 'ENABLE_RESOLVE'],
['run0', ''],
['storagectl', ''],
['storagectl', 'ENABLE_STORAGE'],
['systemd-analyze', ''],
['systemd-cat', ''],
['systemd-cgls', ''],
+1 -1
View File
@@ -45,7 +45,7 @@ foreach item : [
['_sd_machines', 'ENABLE_MACHINED'],
['_sd_outputmodes', ''],
['_sd_unit_files', ''],
['_storagectl', ''],
['_storagectl', 'ENABLE_STORAGE'],
['_systemd', ''],
['_systemd-analyze', ''],
['_systemd-cryptenroll', 'HAVE_LIBCRYPTSETUP'],
+4
View File
@@ -1,5 +1,9 @@
# SPDX-License-Identifier: LGPL-2.1-or-later
if conf.get('ENABLE_STORAGE') != 1
subdir_done()
endif
executables += [
libexec_template + {
'name' : 'systemd-storage-block',
+4
View File
@@ -1024,17 +1024,21 @@ units = [
},
{
'file' : 'systemd-storage-block.socket',
'conditions' : ['ENABLE_STORAGE'],
'symlinks' : ['sockets.target.wants/']
},
{
'file' : 'systemd-storage-block@.service.in',
'conditions' : ['ENABLE_STORAGE'],
},
{
'file' : 'systemd-storage-fs.socket',
'conditions' : ['ENABLE_STORAGE'],
'symlinks' : ['sockets.target.wants/']
},
{
'file' : 'systemd-storage-fs@.service.in',
'conditions' : ['ENABLE_STORAGE'],
},
{
'file' : 'systemd-storagetm.service.in',
+2
View File
@@ -68,10 +68,12 @@ units = [
},
{
'file' : 'systemd-storage-fs.socket',
'conditions' : ['ENABLE_STORAGE'],
'symlinks' : ['sockets.target.wants/']
},
{
'file' : 'systemd-storage-fs@.service.in',
'conditions' : ['ENABLE_STORAGE'],
},
{ 'file' : 'systemd-tmpfiles-clean.service' },
{ 'file' : 'systemd-tmpfiles-clean.timer' },