quilt.inc 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. SUMMARY = "Tool for working with series of patches"
  2. DESCRIPTION = "Quilt is a tool to manage large sets of patches by keeping \
  3. track of the changes each patch makes. Patches can be applied, un-applied,\
  4. refreshed, etc. The key philosophical concept is that your primary output \
  5. is patches."
  6. HOMEPAGE = "http://savannah.nongnu.org/projects/quilt/"
  7. SECTION = "devel"
  8. LICENSE = "GPLv2"
  9. LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
  10. SRC_URI = "${SAVANNAH_GNU_MIRROR}/quilt/quilt-${PV}.tar.gz \
  11. file://run-ptest \
  12. file://Makefile \
  13. file://test.sh \
  14. file://0001-tests-Allow-different-output-from-mv.patch \
  15. "
  16. SRC_URI_append_class-target = " file://gnu_patch_test_fix_target.patch"
  17. SRC_URI[md5sum] = "6800c2404a2c0598ab2eff92a636ba70"
  18. SRC_URI[sha256sum] = "314b319a6feb13bf9d0f9ffa7ce6683b06919e734a41275087ea457cc9dc6e07"
  19. inherit autotools-brokensep ptest
  20. INHIBIT_AUTOTOOLS_DEPS_class-native = "1"
  21. PATCHTOOL_class-native = "patch"
  22. CLEANBROKEN = "1"
  23. EXTRA_OECONF = "--with-perl='${USRBINPATH}/env perl' --with-patch=patch"
  24. EXTRA_OECONF_append_class-native = " --disable-nls"
  25. EXTRA_AUTORECONF += "--exclude=aclocal"
  26. CACHED_CONFIGUREVARS += "ac_cv_path_BASH=/bin/bash"
  27. # Make sure we don't have "-w" in shebang lines: it breaks using
  28. # "/usr/bin/env perl" as parser
  29. do_configure_prepend () {
  30. find ${S} -name "*.in" -exec sed -i -e "1s,^#\!.*@PERL@ -w$,#\! @PERL@\nuse warnings;," {} \;
  31. }
  32. # Don't setup symlinks to host utilities, we don't need them
  33. do_configure_append () {
  34. sed -e 's,^COMPAT_SYMLINKS.*:=.*,COMPAT_SYMLINKS :=,' -i ${S}/Makefile
  35. }
  36. do_configure_class-native () {
  37. oe_runconf
  38. }
  39. # quilt Makefiles install to BUILD_ROOT instead of DESTDIR
  40. do_install () {
  41. oe_runmake 'BUILD_ROOT=${D}' install
  42. # cleanup unpackaged files
  43. rm -rf ${D}/${datadir}/emacs
  44. }
  45. do_install_append_class-native () {
  46. # Dummy quiltrc file for patch.bbclass
  47. install -d ${D}${sysconfdir}/
  48. touch ${D}${sysconfdir}/quiltrc
  49. }
  50. do_compile_ptest() {
  51. oe_runmake bin/patch-wrapper test/.depend
  52. }
  53. do_install_ptest() {
  54. tar -c --exclude=\*.in bin/ | ( cd ${D}${PTEST_PATH} && tar -xf - )
  55. tar -c --exclude=\*.in compat/ | ( cd ${D}${PTEST_PATH} && tar -xf - )
  56. tar -c --exclude=\*.in quilt/ | ( cd ${D}${PTEST_PATH} && tar -xf - )
  57. tar -c --exclude=mail.test --exclude=delete.test test/ | ( cd ${D}${PTEST_PATH} && tar -xf - && chmod 777 test)
  58. cp ${WORKDIR}/Makefile ${D}${PTEST_PATH}
  59. cp ${WORKDIR}/test.sh ${D}${PTEST_PATH}
  60. }
  61. PACKAGES += "guards guards-doc"
  62. FILES_${PN} = "${sysconfdir} ${datadir}/quilt \
  63. ${bindir}/quilt ${libdir}/quilt"
  64. FILES_guards = "${bindir}/guards"
  65. FILES_${PN}-doc = "${mandir}/man1/quilt.1 ${docdir}/${BPN}"
  66. FILES_guards-doc = "${mandir}/man1/guards.1"
  67. RDEPENDS_${PN} = "bash patch diffstat bzip2 util-linux less"
  68. RDEPENDS_${PN}_class-native = "diffstat-native patch-native bzip2-native"
  69. RDEPENDS_${PN}-ptest = "make file sed gawk diffutils findutils ed perl \
  70. perl-module-filehandle perl-module-getopt-std \
  71. perl-module-posix perl-module-file-temp \
  72. perl-module-text-parsewords perl-module-overloading \
  73. bash util-linux-getopt patch \
  74. "