Makefile 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. # Copyright (C) 2006-2009 OpenWrt.org
  2. #
  3. # This is free software, licensed under the GNU General Public License v2.
  4. # See /LICENSE for more information.
  5. #
  6. # $Id$
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=gdb
  9. PKG_VERSION:=6.8
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
  12. PKG_SOURCE_URL:=@GNU/gdb
  13. PKG_MD5SUM:=c9da266b884fb8fa54df786dfaadbc7a
  14. include $(INCLUDE_DIR)/package.mk
  15. define Package/gdb
  16. SECTION:=utils
  17. CATEGORY:=Utilities
  18. DEPENDS:=+libreadline +libncurses
  19. TITLE:=GNU Debugger
  20. endef
  21. define Package/gdbserver
  22. SECTION:=utils
  23. CATEGORY:=Utilities
  24. TITLE:=Remote server for GNU Debugger
  25. endef
  26. define Package/gdb/description
  27. GNU debugger
  28. endef
  29. define Package/gdbserver/description
  30. GDBSERVER is a program that allows you to run GDB on a different machine
  31. than the one which is running the program being debugged.
  32. endef
  33. CONFIGURE_ARGS+= \
  34. --with-system-readline
  35. CONFIGURE_VARS+= \
  36. ac_cv_search_tgetent="$(TARGET_LDFLAGS) -lncurses -lreadline"
  37. define Build/Compile
  38. $(MAKE) -C $(PKG_BUILD_DIR) \
  39. DESTDIR="$(PKG_INSTALL_DIR)" \
  40. CPPFLAGS="$(TARGET_CPPFLAGS)" \
  41. all install-gdb
  42. endef
  43. define Package/gdb/install
  44. $(INSTALL_DIR) $(1)/usr/bin
  45. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gdb $(1)/usr/bin/
  46. endef
  47. define Package/gdbserver/install
  48. $(INSTALL_DIR) $(1)/usr/bin
  49. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gdbserver $(1)/usr/bin/
  50. endef
  51. $(eval $(call BuildPackage,gdb))
  52. $(eval $(call BuildPackage,gdbserver))