1
0

Makefile 1.6 KB

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