diff options
Diffstat (limited to 'meta/classes/kernel-module-split.bbclass')
-rw-r--r-- | meta/classes/kernel-module-split.bbclass | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/meta/classes/kernel-module-split.bbclass b/meta/classes/kernel-module-split.bbclass index 1035525dac..73c7f18c78 100644 --- a/meta/classes/kernel-module-split.bbclass +++ b/meta/classes/kernel-module-split.bbclass | |||
@@ -30,7 +30,7 @@ do_install_append() { | |||
30 | 30 | ||
31 | PACKAGESPLITFUNCS_prepend = "split_kernel_module_packages " | 31 | PACKAGESPLITFUNCS_prepend = "split_kernel_module_packages " |
32 | 32 | ||
33 | KERNEL_MODULES_META_PACKAGE ?= "kernel-modules" | 33 | KERNEL_MODULES_META_PACKAGE ?= "${@ d.getVar("KERNEL_PACKAGE_NAME", True) or "kernel" }-modules" |
34 | 34 | ||
35 | KERNEL_MODULE_PACKAGE_PREFIX ?= "" | 35 | KERNEL_MODULE_PACKAGE_PREFIX ?= "" |
36 | KERNEL_MODULE_PACKAGE_SUFFIX ?= "-${KERNEL_VERSION}" | 36 | KERNEL_MODULE_PACKAGE_SUFFIX ?= "-${KERNEL_VERSION}" |
@@ -129,16 +129,19 @@ python split_kernel_module_packages () { | |||
129 | postfix = format.split('%s')[1] | 129 | postfix = format.split('%s')[1] |
130 | d.setVar('RPROVIDES_' + pkg, pkg.replace(postfix, '')) | 130 | d.setVar('RPROVIDES_' + pkg, pkg.replace(postfix, '')) |
131 | 131 | ||
132 | kernel_package_name = d.getVar("KERNEL_PACKAGE_NAME", True) or "kernel" | ||
133 | kernel_version = d.getVar("KERNEL_VERSION", True) | ||
134 | |||
132 | module_regex = '^(.*)\.k?o$' | 135 | module_regex = '^(.*)\.k?o$' |
133 | 136 | ||
134 | module_pattern_prefix = d.getVar('KERNEL_MODULE_PACKAGE_PREFIX') | 137 | module_pattern_prefix = d.getVar('KERNEL_MODULE_PACKAGE_PREFIX') |
135 | module_pattern_suffix = d.getVar('KERNEL_MODULE_PACKAGE_SUFFIX') | 138 | module_pattern_suffix = d.getVar('KERNEL_MODULE_PACKAGE_SUFFIX') |
136 | module_pattern = module_pattern_prefix + 'kernel-module-%s' + module_pattern_suffix | 139 | module_pattern = module_pattern_prefix + kernel_package_name + '-module-%s' + module_pattern_suffix |
137 | 140 | ||
138 | postinst = d.getVar('pkg_postinst_modules') | 141 | postinst = d.getVar('pkg_postinst_modules') |
139 | postrm = d.getVar('pkg_postrm_modules') | 142 | postrm = d.getVar('pkg_postrm_modules') |
140 | 143 | ||
141 | modules = do_split_packages(d, root='${nonarch_base_libdir}/modules', file_regex=module_regex, output_pattern=module_pattern, description='%s kernel module', postinst=postinst, postrm=postrm, recursive=True, hook=frob_metadata, extra_depends='kernel-%s' % (d.getVar("KERNEL_VERSION"))) | 144 | modules = do_split_packages(d, root='${nonarch_base_libdir}/modules', file_regex=module_regex, output_pattern=module_pattern, description='%s kernel module', postinst=postinst, postrm=postrm, recursive=True, hook=frob_metadata, extra_depends='%s-%s' % (kernel_package_name, kernel_version)) |
142 | if modules: | 145 | if modules: |
143 | metapkg = d.getVar('KERNEL_MODULES_META_PACKAGE') | 146 | metapkg = d.getVar('KERNEL_MODULES_META_PACKAGE') |
144 | d.appendVar('RDEPENDS_' + metapkg, ' '+' '.join(modules)) | 147 | d.appendVar('RDEPENDS_' + metapkg, ' '+' '.join(modules)) |