Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame^] | 1 | SUMMARY = "Utilities and libraries for handling compiled object files" |
| 2 | HOMEPAGE = "https://fedorahosted.org/elfutils" |
| 3 | SECTION = "base" |
| 4 | LICENSE = "(GPL-2+ & Elfutils-Exception)" |
| 5 | LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3\ |
| 6 | file://EXCEPTION;md5=570adcb0c1218ab57f2249c67d0ce417" |
| 7 | DEPENDS = "libtool bzip2 zlib virtual/libintl" |
| 8 | |
| 9 | PR = "r11" |
| 10 | |
| 11 | SRC_URI = "https://fedorahosted.org/releases/e/l/${BPN}/${BP}.tar.bz2" |
| 12 | |
| 13 | SRC_URI[md5sum] = "a0bed1130135f17ad27533b0034dba8d" |
| 14 | SRC_URI[sha256sum] = "8aebfa4a745db21cf5429c9541fe482729b62efc7e53e9110151b4169fe887da" |
| 15 | |
| 16 | # pick the patch from debian |
| 17 | # http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.148-1.debian.tar.gz |
| 18 | |
| 19 | SRC_URI += "\ |
| 20 | file://redhat-portability.diff \ |
| 21 | file://redhat-robustify.diff \ |
| 22 | file://hppa_backend.diff \ |
| 23 | file://arm_backend.diff \ |
| 24 | file://mips_backend.diff \ |
| 25 | file://m68k_backend.diff \ |
| 26 | file://testsuite-ignore-elflint.diff \ |
| 27 | file://elf_additions.diff \ |
| 28 | file://elfutils-fsize.patch \ |
| 29 | file://remove-unused.patch \ |
| 30 | file://mempcpy.patch \ |
| 31 | file://fix_for_gcc-4.7.patch \ |
| 32 | file://dso-link-change.patch \ |
| 33 | file://nm-Fix-size-passed-to-snprintf-for-invalid-sh_name-case.patch \ |
| 34 | file://elfutils-ar-c-fix-num-passed-to-memset.patch \ |
| 35 | file://Fix_elf_cvt_gunhash.patch \ |
| 36 | file://elf_begin.c-CVE-2014-9447-fix.patch \ |
| 37 | file://fix-build-gcc-4.8.patch \ |
| 38 | " |
| 39 | # Only apply when building uclibc based target recipe |
| 40 | SRC_URI_append_libc-uclibc = " file://uclibc-support-for-elfutils-0.148.patch" |
| 41 | |
| 42 | # The buildsystem wants to generate 2 .h files from source using a binary it just built, |
| 43 | # which can not pass the cross compiling, so let's work around it by adding 2 .h files |
| 44 | # along with the do_configure_prepend() |
| 45 | |
| 46 | SRC_URI += "\ |
| 47 | file://i386_dis.h \ |
| 48 | file://x86_64_dis.h \ |
| 49 | " |
| 50 | inherit autotools gettext |
| 51 | |
| 52 | EXTRA_OECONF = "--program-prefix=eu- --without-lzma" |
| 53 | EXTRA_OECONF_append_class-native = " --without-bzlib" |
| 54 | EXTRA_OECONF_append_libc-uclibc = " --enable-uclibc" |
| 55 | |
| 56 | do_configure_prepend() { |
| 57 | sed -i '/^i386_dis.h:/,+4 {/.*/d}' ${S}/libcpu/Makefile.am |
| 58 | |
| 59 | cp ${WORKDIR}/*dis.h ${S}/libcpu |
| 60 | } |
| 61 | |
| 62 | # we can not build complete elfutils when using uclibc |
| 63 | # but some recipes e.g. gcc 4.5 depends on libelf so we |
| 64 | # build only libelf for uclibc case |
| 65 | |
| 66 | EXTRA_OEMAKE_libc-uclibc = "-C libelf" |
| 67 | EXTRA_OEMAKE_class-native = "" |
| 68 | EXTRA_OEMAKE_class-nativesdk = "" |
| 69 | |
| 70 | BBCLASSEXTEND = "native nativesdk" |
| 71 | |
| 72 | # Package utilities separately |
| 73 | PACKAGES =+ "${PN}-binutils libelf libasm libdw" |
| 74 | FILES_${PN}-binutils = "\ |
| 75 | ${bindir}/eu-addr2line \ |
| 76 | ${bindir}/eu-ld \ |
| 77 | ${bindir}/eu-nm \ |
| 78 | ${bindir}/eu-readelf \ |
| 79 | ${bindir}/eu-size \ |
| 80 | ${bindir}/eu-strip" |
| 81 | |
| 82 | FILES_libelf = "${libdir}/libelf-${PV}.so ${libdir}/libelf.so.*" |
| 83 | FILES_libasm = "${libdir}/libasm-${PV}.so ${libdir}/libasm.so.*" |
| 84 | FILES_libdw = "${libdir}/libdw-${PV}.so ${libdir}/libdw.so.* ${libdir}/elfutils/lib*" |
| 85 | # Some packages have the version preceeding the .so instead properly |
| 86 | # versioned .so.<version>, so we need to reorder and repackage. |
| 87 | #FILES_${PN} += "${libdir}/*-${PV}.so ${base_libdir}/*-${PV}.so" |
| 88 | #FILES_SOLIBSDEV = "${libdir}/libasm.so ${libdir}/libdw.so ${libdir}/libelf.so" |
| 89 | |
| 90 | # The package contains symlinks that trip up insane |
| 91 | INSANE_SKIP_${MLPREFIX}libdw = "dev-so" |