1
0

Makefile 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  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 $(ADK_TOPDIR)/rules.mk
  4. include ../rules.mk
  5. include Makefile.inc
  6. include ${ADK_TOPDIR}/mk/buildhlp.mk
  7. ifeq (${ADK_MAKE_PARALLEL},y)
  8. GDB_MAKEOPTS+= -j${ADK_MAKE_JOBS}
  9. endif
  10. ifeq ($(ADK_TARGET_SIM),y)
  11. CONFIGURE_ARGS:= --enable-sim --enable-sim-stdio
  12. else
  13. CONFIGURE_ARGS:= --disable-sim
  14. endif
  15. $(WRKBUILD)/.headers:
  16. $(WRKBUILD)/.configured:
  17. $(SED) 's/install_to_$(INSTALL_DEST) //' ${WRKBUILD}/libiberty/Makefile.in
  18. (cd $(WRKBUILD); \
  19. gdb_cv_func_sigsetjmp=yes \
  20. ./configure \
  21. --prefix=$(STAGING_HOST_DIR) \
  22. --build=$(GNU_HOST_NAME) \
  23. --host=$(GNU_HOST_NAME) \
  24. --target=$(GNU_TARGET_NAME) \
  25. --disable-dependency-tracking \
  26. --without-uiout \
  27. --enable-gdbmi \
  28. --disable-gdbtk \
  29. --without-included-gettext \
  30. --disable-libtool-lock \
  31. --disable-nls \
  32. --with-curses \
  33. --enable-threads \
  34. --disable-tui \
  35. --disable-werror \
  36. --disable-install-libiberty \
  37. --without-python \
  38. --without-x \
  39. $(CONFIGURE_ARGS) \
  40. );
  41. touch $@
  42. $(WRKBUILD)/.compiled:
  43. $(MAKE) ${GDB_MAKEOPTS} -C $(WRKBUILD) CFLAGS="-fPIC ${CFLAGS_FOR_BUILD}"
  44. touch $@
  45. $(WRKBUILD)/.installed:
  46. $(INSTALL_BIN) $(WRKBUILD)/gdb/gdb $(TARGET_CROSS)gdb
  47. ifeq ($(ADK_TARGET_SIM),y)
  48. ifeq ($(ADK_TARGET_ARCH_BFIN),y)
  49. $(INSTALL_BIN) $(WRKBUILD)/sim/bfin/run $(TARGET_CROSS)run
  50. endif
  51. ifeq ($(ADK_TARGET_ARCH_H8300),y)
  52. $(INSTALL_BIN) $(WRKBUILD)/sim/h8300/run $(TARGET_CROSS)run
  53. endif
  54. endif
  55. touch $@
  56. include ${ADK_TOPDIR}/mk/toolchain.mk