diff options
Diffstat (limited to 'meta/classes/uboot-extlinux-config.bbclass')
-rw-r--r-- | meta/classes/uboot-extlinux-config.bbclass | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/meta/classes/uboot-extlinux-config.bbclass b/meta/classes/uboot-extlinux-config.bbclass index df91386c00..ec5fffb7bb 100644 --- a/meta/classes/uboot-extlinux-config.bbclass +++ b/meta/classes/uboot-extlinux-config.bbclass | |||
@@ -58,20 +58,20 @@ UBOOT_EXTLINUX_MENU_DESCRIPTION_linux ??= "${DISTRO_NAME}" | |||
58 | UBOOT_EXTLINUX_CONFIG = "${B}/extlinux.conf" | 58 | UBOOT_EXTLINUX_CONFIG = "${B}/extlinux.conf" |
59 | 59 | ||
60 | python create_extlinux_config() { | 60 | python create_extlinux_config() { |
61 | if d.getVar("UBOOT_EXTLINUX", True) != "1": | 61 | if d.getVar("UBOOT_EXTLINUX") != "1": |
62 | return | 62 | return |
63 | 63 | ||
64 | if not d.getVar('WORKDIR', True): | 64 | if not d.getVar('WORKDIR'): |
65 | bb.error("WORKDIR not defined, unable to package") | 65 | bb.error("WORKDIR not defined, unable to package") |
66 | 66 | ||
67 | labels = d.getVar('UBOOT_EXTLINUX_LABELS', True) | 67 | labels = d.getVar('UBOOT_EXTLINUX_LABELS') |
68 | if not labels: | 68 | if not labels: |
69 | bb.fatal("UBOOT_EXTLINUX_LABELS not defined, nothing to do") | 69 | bb.fatal("UBOOT_EXTLINUX_LABELS not defined, nothing to do") |
70 | 70 | ||
71 | if not labels.strip(): | 71 | if not labels.strip(): |
72 | bb.fatal("No labels, nothing to do") | 72 | bb.fatal("No labels, nothing to do") |
73 | 73 | ||
74 | cfile = d.getVar('UBOOT_EXTLINUX_CONFIG', True) | 74 | cfile = d.getVar('UBOOT_EXTLINUX_CONFIG') |
75 | if not cfile: | 75 | if not cfile: |
76 | bb.fatal('Unable to read UBOOT_EXTLINUX_CONFIG') | 76 | bb.fatal('Unable to read UBOOT_EXTLINUX_CONFIG') |
77 | 77 | ||
@@ -85,34 +85,34 @@ python create_extlinux_config() { | |||
85 | for label in labels.split(): | 85 | for label in labels.split(): |
86 | localdata = bb.data.createCopy(d) | 86 | localdata = bb.data.createCopy(d) |
87 | 87 | ||
88 | overrides = localdata.getVar('OVERRIDES', True) | 88 | overrides = localdata.getVar('OVERRIDES') |
89 | if not overrides: | 89 | if not overrides: |
90 | bb.fatal('OVERRIDES not defined') | 90 | bb.fatal('OVERRIDES not defined') |
91 | 91 | ||
92 | localdata.setVar('OVERRIDES', label + ':' + overrides) | 92 | localdata.setVar('OVERRIDES', label + ':' + overrides) |
93 | bb.data.update_data(localdata) | 93 | bb.data.update_data(localdata) |
94 | 94 | ||
95 | extlinux_console = localdata.getVar('UBOOT_EXTLINUX_CONSOLE', True) | 95 | extlinux_console = localdata.getVar('UBOOT_EXTLINUX_CONSOLE') |
96 | 96 | ||
97 | menu_description = localdata.getVar('UBOOT_EXTLINUX_MENU_DESCRIPTION', True) | 97 | menu_description = localdata.getVar('UBOOT_EXTLINUX_MENU_DESCRIPTION') |
98 | if not menu_description: | 98 | if not menu_description: |
99 | menu_description = label | 99 | menu_description = label |
100 | 100 | ||
101 | root = localdata.getVar('UBOOT_EXTLINUX_ROOT', True) | 101 | root = localdata.getVar('UBOOT_EXTLINUX_ROOT') |
102 | if not root: | 102 | if not root: |
103 | bb.fatal('UBOOT_EXTLINUX_ROOT not defined') | 103 | bb.fatal('UBOOT_EXTLINUX_ROOT not defined') |
104 | 104 | ||
105 | kernel_image = localdata.getVar('UBOOT_EXTLINUX_KERNEL_IMAGE', True) | 105 | kernel_image = localdata.getVar('UBOOT_EXTLINUX_KERNEL_IMAGE') |
106 | fdtdir = localdata.getVar('UBOOT_EXTLINUX_FDTDIR', True) | 106 | fdtdir = localdata.getVar('UBOOT_EXTLINUX_FDTDIR') |
107 | if fdtdir: | 107 | if fdtdir: |
108 | cfgfile.write('LABEL %s\n\tKERNEL %s\n\tFDTDIR %s\n' % | 108 | cfgfile.write('LABEL %s\n\tKERNEL %s\n\tFDTDIR %s\n' % |
109 | (menu_description, kernel_image, fdtdir)) | 109 | (menu_description, kernel_image, fdtdir)) |
110 | else: | 110 | else: |
111 | cfgfile.write('LABEL %s\n\tKERNEL %s\n' % (menu_description, kernel_image)) | 111 | cfgfile.write('LABEL %s\n\tKERNEL %s\n' % (menu_description, kernel_image)) |
112 | 112 | ||
113 | kernel_args = localdata.getVar('UBOOT_EXTLINUX_KERNEL_ARGS', True) | 113 | kernel_args = localdata.getVar('UBOOT_EXTLINUX_KERNEL_ARGS') |
114 | 114 | ||
115 | initrd = localdata.getVar('UBOOT_EXTLINUX_INITRD', True) | 115 | initrd = localdata.getVar('UBOOT_EXTLINUX_INITRD') |
116 | if initrd: | 116 | if initrd: |
117 | cfgfile.write('\tINITRD %s\n'% initrd) | 117 | cfgfile.write('\tINITRD %s\n'% initrd) |
118 | 118 | ||