Makefile 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. # This file is part of the OpenADK project. OpenADK is copyrighted
  2. # material, please see the LICENCE file in the top-level directory.
  3. include $(TOPDIR)/rules.mk
  4. PKG_NAME:= grub
  5. PKG_VERSION:= 2.00
  6. PKG_RELEASE:= 3
  7. PKG_MD5SUM:= e927540b6eda8b024fb0391eeaa4091c
  8. PKG_DESCR:= GRUB2 bootloader (source package)
  9. PKG_SECTION:= boot
  10. PKG_BUILDDEP:= bison-host qemu-host
  11. PKG_URL:= http://www.gnu.org/software/grub
  12. PKG_SITES:= ftp://ftp.gnu.org/gnu/grub/
  13. PKG_ARCH_DEPENDS:= x86 x86_64 mips
  14. PKG_NOPARALLEL:= 1
  15. PKG_CHOICES_GRUB:= PC EFI
  16. PKGCD_PC:= build for PC BIOS
  17. PKGCD_EFI:= build for EFI
  18. include $(TOPDIR)/mk/package.mk
  19. $(eval $(call PKG_template,GRUB,grub,$(PKG_VERSION)-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  20. ifeq ($(ADK_PACKAGE_GRUB_PC),y)
  21. GRUB_ARCH:= i386-pc
  22. CONFIGURE_ARGS+= --with-platform=pc
  23. endif
  24. ifeq ($(ADK_PACKAGE_GRUB_EFI),y)
  25. GRUB_ARCH:= x86_64-efi
  26. CONFIGURE_ARGS+= --with-platform=efi
  27. endif
  28. ifeq ($(ADK_STATIC),y)
  29. TARGET_CFLAGS+= -static
  30. TARGET_LDFLAGS+= -static
  31. endif
  32. CONFIGURE_ARGS+= --disable-grub-mkfont \
  33. --enable-efiemu=no \
  34. --enable-liblzma=no \
  35. --enable-device-mapper=no \
  36. --enable-libzfs=no \
  37. --disable-werror
  38. XAKE_FLAGS+= GCC_HONOUR_COPTS=s
  39. grub-install:
  40. ${INSTALL_DIR} $(IDIR_GRUB)/boot/grub/${GRUB_ARCH}
  41. ${CP} ${WRKINST}/usr/lib/grub/${GRUB_ARCH}/*{mod,lst,img} \
  42. $(IDIR_GRUB)/boot/grub/${GRUB_ARCH}/
  43. ${CP} ./files/core.img.${GRUB_ARCH} \
  44. $(IDIR_GRUB)/boot/grub/core.img
  45. include ${TOPDIR}/mk/pkg-bottom.mk