Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 1 | SUMMARY = "UBI utils statically compiled against klibc" |
| 2 | DESCRIPTION = "Small sized tools from mtd-utils for use with initramfs." |
| 3 | SECTION = "base" |
| 4 | DEPENDS = "zlib lzo e2fsprogs util-linux" |
| 5 | HOMEPAGE = "http://www.linux-mtd.infradead.org/" |
| 6 | LICENSE = "GPLv2+" |
| 7 | LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3 \ |
| 8 | file://include/common.h;beginline=1;endline=17;md5=ba05b07912a44ea2bf81ce409380049c" |
| 9 | |
| 10 | inherit autotools pkgconfig klibc |
| 11 | |
| 12 | SRCREV = "64f61a9dc71b158c7084006cbce4ea23886f0b47" |
| 13 | SRC_URI = "git://git.infradead.org/mtd-utils.git \ |
| 14 | file://0001-libmissing.h-fix-klibc-build-when-using-glibc-toolch.patch \ |
| 15 | file://0002-Instead-of-doing-preprocessor-magic-just-output-off_.patch \ |
| 16 | file://0003-Makefile.am-only-build-ubi-utils.patch \ |
| 17 | file://0004-mtd-utils-common.h-no-features.h-for-klibc-builds.patch \ |
| 18 | file://0005-common.h-replace-getline-with-fgets.patch \ |
| 19 | " |
| 20 | |
| 21 | S = "${WORKDIR}/git/" |
| 22 | |
| 23 | EXTRA_OECONF += "--disable-tests --without-jffs --without-ubifs" |
| 24 | |
| 25 | PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'xattr', d)}" |
| 26 | PACKAGECONFIG[xattr] = ",,acl," |
| 27 | |
| 28 | EXTRA_OEMAKE = "'CC=${CC}' 'RANLIB=${RANLIB}' 'AR=${AR}' 'CFLAGS=${CFLAGS} ${@bb.utils.contains('PACKAGECONFIG', 'xattr', '', '-DWITHOUT_XATTR', d)} -I${S}/include' 'BUILDDIR=${S}'" |
| 29 | |
| 30 | do_install () { |
| 31 | oe_runmake install DESTDIR=${D} SBINDIR=${sbindir} MANDIR=${mandir} INCLUDEDIR=${includedir} |
| 32 | } |
| 33 | |
| 34 | PACKAGES = "ubi-utils-klibc-dbg ubi-utils-klibc-doc" |
| 35 | |
| 36 | PACKAGES =+ "mtdinfo-klibc ubiattach-klibc ubiblock-klibc ubicrc32-klibc ubidetach-klibc \ |
| 37 | ubiformat-klibc ubimkvol-klibc ubinfo-klibc ubinize-klibc ubirename-klibc \ |
| 38 | ubirmvol-klibc ubirsvol-klibc ubiupdatevol-klibc" |
| 39 | |
| 40 | FILES_mtdinfo-klibc = "${sbindir}/mtdinfo" |
| 41 | FILES_ubiattach-klibc = "${sbindir}/ubiattach" |
| 42 | FILES_ubiblock-klibc = "${sbindir}/ubiblock" |
| 43 | FILES_ubicrc32-klibc = "${sbindir}/ubicrc32" |
| 44 | FILES_ubidetach-klibc = "${sbindir}/ubidetach" |
| 45 | FILES_ubiformat-klibc = "${sbindir}/ubiformat" |
| 46 | FILES_ubimkvol-klibc = "${sbindir}/ubimkvol" |
| 47 | FILES_ubinfo-klibc = "${sbindir}/ubinfo" |
| 48 | FILES_ubinize-klibc = "${sbindir}/ubinize" |
| 49 | FILES_ubirename-klibc = "${sbindir}/ubirename" |
| 50 | FILES_ubirmvol-klibc = "${sbindir}/ubirmvol" |
| 51 | FILES_ubirsvol-klibc = "${sbindir}/ubirsvol" |
| 52 | FILES_ubiupdatevol-klibc = "${sbindir}/ubiupdatevol" |