syslinux_6.04-pre2.bb 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. SUMMARY = "Multi-purpose linux bootloader"
  2. HOMEPAGE = "http://www.syslinux.org/"
  3. LICENSE = "GPLv2+"
  4. LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3 \
  5. file://README;beginline=35;endline=41;md5=558f2c71cb1fb9ba511ccd4858e48e8a"
  6. # If you really want to run syslinux, you need mtools. We just want the
  7. # ldlinux.* stuff for now, so skip mtools-native
  8. DEPENDS = "nasm-native util-linux e2fsprogs"
  9. PV = "6.04-pre2"
  10. SRC_URI = "https://www.zytor.com/pub/syslinux/Testing/6.04/syslinux-${PV}.tar.xz \
  11. file://syslinux-remove-clean-script.patch \
  12. file://0001-linux-syslinux-support-ext2-3-4-device.patch \
  13. file://0002-linux-syslinux-implement-open_ext2_fs.patch \
  14. file://0003-linux-syslinux-implement-install_to_ext2.patch \
  15. file://0004-linux-syslinux-add-ext_file_read-and-ext_file_write.patch \
  16. file://0005-linux-syslinux-implement-handle_adv_on_ext.patch \
  17. file://0006-linux-syslinux-implement-write_to_ext-and-add-syslin.patch \
  18. file://0007-linux-syslinux-implement-ext_construct_sectmap_fs.patch \
  19. file://0008-libinstaller-syslinuxext-implement-syslinux_patch_bo.patch \
  20. file://0009-linux-syslinux-implement-install_bootblock.patch \
  21. file://0010-Workaround-multiple-definition-of-symbol-errors.patch \
  22. file://0001-install-don-t-install-obsolete-file-com32.ld.patch \
  23. "
  24. SRC_URI[md5sum] = "2b31c78f087f99179feb357da312d7ec"
  25. SRC_URI[sha256sum] = "4441a5d593f85bb6e8d578cf6653fb4ec30f9e8f4a2315a3d8f2d0a8b3fadf94"
  26. UPSTREAM_CHECK_URI = "https://www.zytor.com/pub/syslinux/"
  27. UPSTREAM_CHECK_REGEX = "syslinux-(?P<pver>.+)\.tar"
  28. UPSTREAM_VERSION_UNKNOWN = "1"
  29. COMPATIBLE_HOST = '(x86_64|i.86).*-(linux|freebsd.*)'
  30. # Don't let the sanity checker trip on the 32 bit real mode BIOS binaries
  31. INSANE_SKIP_${PN}-misc = "arch"
  32. INSANE_SKIP_${PN}-chain = "arch"
  33. EXTRA_OEMAKE = " \
  34. BINDIR=${bindir} SBINDIR=${sbindir} LIBDIR=${libdir} \
  35. DATADIR=${datadir} MANDIR=${mandir} INCDIR=${includedir} \
  36. "
  37. do_configure() {
  38. # drop win32 targets or build fails
  39. sed -e 's,win32/\S*,,g' -i Makefile
  40. # clean installer executables included in source tarball
  41. oe_runmake clean firmware="efi32" EFIINC="${includedir}"
  42. # NOTE: There is a temporary work around above to specify
  43. # the efi32 as the firmware else the pre-built bios
  44. # files get erased contrary to the doc/distib.txt
  45. # In the future this should be "bios" and not "efi32".
  46. }
  47. do_compile() {
  48. # Make sure the recompile is OK.
  49. # Though the ${B} should always exist, still check it before find and rm.
  50. [ -d "${B}" ] && find ${B} -name '.*.d' -type f -exec rm -f {} \;
  51. # Rebuild only the installer; keep precompiled bootloaders
  52. # as per author's request (doc/distrib.txt)
  53. oe_runmake CC="${CC} ${CFLAGS}" \
  54. LD="${LD}" LDFLAGS="${LDFLAGS}" \
  55. OBJDUMP="${OBJDUMP}" \
  56. OBJCOPY="${OBJCOPY}" \
  57. AR="${AR}" \
  58. STRIP="${STRIP}" \
  59. NM="${NM}" \
  60. RANLIB="${RANLIB}" \
  61. firmware="bios" installer
  62. }
  63. do_install() {
  64. oe_runmake CC="${CC} ${CFLAGS}" LD="${LD}" \
  65. OBJDUMP="${OBJDUMP}" \
  66. OBJCOPY="${OBJCOPY}" \
  67. AR="${AR}" \
  68. STRIP="${STRIP}" \
  69. NM="${NM}" \
  70. RANLIB="${RANLIB}" \
  71. firmware="bios" install INSTALLROOT="${D}"
  72. install -d ${D}${datadir}/syslinux/
  73. install -m 644 ${S}/bios/core/ldlinux.sys ${D}${datadir}/syslinux/
  74. install -m 644 ${S}/bios/core/ldlinux.bss ${D}${datadir}/syslinux/
  75. install -m 755 ${S}/bios/linux/syslinux-nomtools ${D}${bindir}/
  76. }
  77. PACKAGES += "${PN}-nomtools ${PN}-extlinux ${PN}-mbr ${PN}-chain ${PN}-pxelinux ${PN}-isolinux ${PN}-misc"
  78. RDEPENDS_${PN} += "mtools"
  79. RDEPENDS_${PN}-nomtools += "libext2fs"
  80. RDEPENDS_${PN}-misc += "perl"
  81. FILES_${PN} = "${bindir}/syslinux"
  82. FILES_${PN}-nomtools = "${bindir}/syslinux-nomtools"
  83. FILES_${PN}-extlinux = "${sbindir}/extlinux"
  84. FILES_${PN}-mbr = "${datadir}/${BPN}/mbr.bin"
  85. FILES_${PN}-chain = "${datadir}/${BPN}/chain.c32"
  86. FILES_${PN}-isolinux = "${datadir}/${BPN}/isolinux.bin"
  87. FILES_${PN}-pxelinux = "${datadir}/${BPN}/pxelinux.0"
  88. FILES_${PN}-dev += "${datadir}/${BPN}/com32/lib*${SOLIBS} ${datadir}/${BPN}/com32/include ${datadir}/${BPN}/com32/com32.ld"
  89. FILES_${PN}-staticdev += "${datadir}/${BPN}/com32/lib*.a ${libdir}/${BPN}/com32/lib*.a"
  90. FILES_${PN}-misc = "${datadir}/${BPN}/* ${libdir}/${BPN}/* ${bindir}/*"
  91. BBCLASSEXTEND = "native nativesdk"