cromwell-2.40-r3.ebuild 890 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. # Copyright 1999-2012 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI="4"
  4. inherit eutils mount-boot toolchain-funcs flag-o-matic
  5. DESCRIPTION="Xbox boot loader"
  6. HOMEPAGE="http://www.xbox-linux.org/wiki/Cromwell"
  7. SRC_URI="mirror://gentoo/${P}.tar.bz2
  8. mirror://gentoo/${PF}-cvs-fixes.patch.lzma"
  9. LICENSE="GPL-2"
  10. SLOT="0"
  11. KEYWORDS="-* x86"
  12. IUSE=""
  13. RESTRICT="strip"
  14. src_prepare() {
  15. epatch "${WORKDIR}"/${PF}-cvs-fixes.patch
  16. epatch "${FILESDIR}"/${P}-gcc-4.6.patch #363535
  17. sed -i 's:-Werror:-m32:' Makefile Rules.make || die
  18. sed -i '/^EXTRA_CFLAGS/s:$: -m32:' Rules.make boot_rom/Makefile || die
  19. sed -i \
  20. -e '/^bin.imagebld:/,$s:\<gcc\>:${CC}:' \
  21. Makefile || die
  22. append-flags -m32
  23. }
  24. src_compile() {
  25. emake -j1 CC="$(tc-getCC)" LD="$(tc-getLD)"
  26. }
  27. src_install() {
  28. insinto /boot/${PN}
  29. doins image/cromwell{,_1024}.bin xbe/xromwell.xbe
  30. }