- private def set_kernel_version
- boot_dir = "#{SRV_OS}/#{os_dir}/boot"
- if self["kernel_version"]?
self["vmlinuz_path"] = "#{boot_dir}/vmlinuz-#{kernel_version}"
self["modules_path"] = "#{boot_dir}/modules-#{kernel_version}.cgz"
self["headers_path"] = "#{boot_dir}/headers-#{kernel_version}.cgz"
The if/else 'self[] = ...' blocks can be consolidated with help of
suffix = '-' + kernel_version
- else
self["vmlinuz_path"] = "#{boot_dir}/vmlinuz"
self["modules_path"] = "#{boot_dir}/modules.cgz"
self["headers_path"] = "#{boot_dir}/headers.cgz"
Those could be symlinks, better expand them to real path.
Thanks, Fengguang