Makefile 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  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. include Makefile.inc
  5. include ../rules.mk
  6. include ${TOPDIR}/mk/buildhlp.mk
  7. ifeq ($(ADK_LINUX_64),y)
  8. CONFOPTS+= --enable-64-bit-bfd
  9. endif
  10. ifeq (${ADK_MAKE_PARALLEL},y)
  11. BINUTILS_MAKEOPTS+= -j${ADK_MAKE_JOBS}
  12. endif
  13. $(WRKBUILD)/.headers:
  14. $(WRKBUILD)/.configured:
  15. (cd $(WRKBUILD); \
  16. $(WRKBUILD)/configure \
  17. --prefix=$(STAGING_TOOLS) \
  18. --build=$(GNU_HOST_NAME) \
  19. --host=$(GNU_HOST_NAME) \
  20. --target=$(REAL_GNU_TARGET_NAME) \
  21. --disable-nls \
  22. --with-sysroot=$(TOOLCHAIN_SYSROOT) \
  23. --with-sysroot=$(STAGING_DIR) \
  24. --disable-multilib \
  25. --disable-dependency-tracking \
  26. --disable-libtool-lock \
  27. --disable-werror \
  28. --disable-libssp \
  29. ${CONFOPTS} \
  30. );
  31. touch $@
  32. $(WRKBUILD)/.compiled: $(WRKBUILD)/.configured
  33. $(MAKE) ${BINUTILS_MAKEOPTS} -C $(WRKBUILD) all
  34. touch $@
  35. $(WRKBUILD)/.installed: $(WRKBUILD)/.compiled
  36. $(MAKE) -C $(WRKBUILD) install
  37. # needed on hosts without readelf
  38. $(CP) $(WRKBUILD)/binutils/readelf $(STAGING_TOOLS)/bin
  39. touch $@
  40. include ${TOPDIR}/mk/toolchain.mk