2 # Copyright (C) 2006-2016 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR)/rules.mk
11 PKG_VERSION:=arc-2016.03-gdb
14 PKG_SOURCE:=gdb-arc-2016.03-gdb.tar.gz
15 PKG_SOURCE_URL:=https://github.com/foss-for-synopsys-dwc-arc-processors/binutils-gdb/archive/$(PKG_VERSION)
16 PKG_MD5SUM:=775caaf6385c16f20b6f53c0a2b95f79
18 PKG_BUILD_DIR:=$(BUILD_DIR)/binutils-gdb-arc-2016.03-gdb
24 include $(INCLUDE_DIR)/package.mk
26 define Package/gdb-arc/Default
29 DEPENDS:=+!USE_MUSL:libthread-db +PACKAGE_zlib:zlib @arc
30 URL:=http://www.gnu.org/software/gdb/
33 define Package/gdb-arc
34 $(call Package/gdb-arc/Default)
35 TITLE:=GNU Debugger for ARC
36 DEPENDS+=+libreadline +libncurses +zlib
39 define Package/gdb-arc/description
40 GDB, the GNU Project debugger, allows you to see what is going on `inside'
41 another program while it executes -- or what another program was doing at the
45 define Package/gdbserver-arc
46 $(call Package/gdb-arc/Default)
47 TITLE:=Remote server for GNU Debugger
50 define Package/gdbserver-arc/description
51 GDBSERVER is a program that allows you to run GDB on a different machine than the
52 one which is running the program being debugged.
55 # XXX: add --disable-werror to prevent build failure with arm
57 --with-system-readline \
67 ac_cv_search_tgetent="$(TARGET_LDFLAGS) -lncurses -lreadline"
70 +$(MAKE) $(PKG_JOBS) -C $(PKG_BUILD_DIR) \
71 DESTDIR="$(PKG_INSTALL_DIR)" \
72 CPPFLAGS="$(TARGET_CPPFLAGS)" \
77 $(MAKE) -C $(PKG_BUILD_DIR) \
78 DESTDIR="$(PKG_INSTALL_DIR)" \
79 CPPFLAGS="$(TARGET_CPPFLAGS)" \
83 define Package/gdb-arc/install
84 $(INSTALL_DIR) $(1)/usr/bin
85 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gdb $(1)/usr/bin/
88 define Package/gdbserver-arc/install
89 $(INSTALL_DIR) $(1)/usr/bin
90 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gdbserver $(1)/usr/bin/
93 $(eval $(call BuildPackage,gdb-arc))
94 $(eval $(call BuildPackage,gdbserver-arc))