Brad Bishop | 1932369 | 2019-04-05 15:28:33 -0400 | [diff] [blame] | 1 | require u-boot-common.inc |
| 2 | |
| 3 | SUMMARY = "U-Boot bootloader fw_printenv/setenv utilities" |
| 4 | DEPENDS += "mtd-utils" |
| 5 | |
Brad Bishop | 64c979e | 2019-11-04 13:55:29 -0500 | [diff] [blame] | 6 | SRC_URI += "file://0001-include-env.h-Ensure-ulong-is-defined.patch" |
| 7 | |
Brad Bishop | 1932369 | 2019-04-05 15:28:33 -0400 | [diff] [blame] | 8 | INSANE_SKIP_${PN} = "already-stripped" |
| 9 | EXTRA_OEMAKE_class-target = 'CROSS_COMPILE=${TARGET_PREFIX} CC="${CC} ${CFLAGS} ${LDFLAGS}" HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" V=1' |
| 10 | EXTRA_OEMAKE_class-cross = 'HOSTCC="${CC} ${CFLAGS} ${LDFLAGS}" V=1' |
| 11 | |
| 12 | inherit uboot-config |
| 13 | |
| 14 | do_compile () { |
| 15 | oe_runmake ${UBOOT_MACHINE} |
| 16 | oe_runmake envtools |
| 17 | } |
| 18 | |
| 19 | do_install () { |
| 20 | install -d ${D}${base_sbindir} |
| 21 | install -d ${D}${sysconfdir} |
| 22 | install -m 755 ${S}/tools/env/fw_printenv ${D}${base_sbindir}/fw_printenv |
| 23 | install -m 755 ${S}/tools/env/fw_printenv ${D}${base_sbindir}/fw_setenv |
| 24 | install -m 0644 ${S}/tools/env/fw_env.config ${D}${sysconfdir}/fw_env.config |
| 25 | } |
| 26 | |
| 27 | do_install_class-cross () { |
| 28 | install -d ${D}${bindir_cross} |
| 29 | install -m 755 ${S}/tools/env/fw_printenv ${D}${bindir_cross}/fw_printenv |
| 30 | install -m 755 ${S}/tools/env/fw_printenv ${D}${bindir_cross}/fw_setenv |
| 31 | } |
| 32 | |
| 33 | SYSROOT_DIRS_append_class-cross = " ${bindir_cross}" |
| 34 | |
| 35 | PACKAGE_ARCH = "${MACHINE_ARCH}" |
| 36 | BBCLASSEXTEND = "cross" |