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
12 PKG_RELEASE
:=$(AUTORELEASE
)
14 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.xz
15 PKG_SOURCE_URL
:=@GNU
/gdb
16 PKG_HASH
:=0e1793bf8f2b54d53f46dea84ccfd446f48f81b297b28c4f7fc017b818d69fed
21 PKG_CPE_ID
:=cpe
:/a
:gnu
:gdb
23 include $(INCLUDE_DIR
)/package.mk
24 include $(INCLUDE_DIR
)/nls.mk
26 define Package
/gdb
/Default
29 DEPENDS
:=+!USE_MUSL
:libthread-db
$(ICONV_DEPENDS
) $(INTL_DEPENDS
)
30 URL
:=https
://www.gnu.org
/software
/gdb
/
34 $(call Package
/gdb
/Default
)
36 DEPENDS
+=+libreadline
+libncurses
+zlib
+libgmp
39 define Package
/gdb
/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
46 $(call Package/gdb/Default)
47 TITLE:=Remote server for GNU Debugger
50 define Package/gdbserver/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 \
61 --disable-unit-tests \
65 --disable-source-highlight \
69 --with-libgmp-prefix=$(STAGING_DIR)/usr
72 ac_cv_search_tgetent="$(TARGET_LDFLAGS) -lncurses -lreadline"
75 $(INTL_LDFLAGS) $(if $(INTL_FULL),-lintl) \
80 $(MAKE) -C $(PKG_BUILD_DIR) \
81 DESTDIR="$(PKG_INSTALL_DIR)" \
82 CPPFLAGS="$(TARGET_CPPFLAGS)" \
83 install-gdb install-gdbserver
86 define Package/gdb/install
87 $(INSTALL_DIR) $(1)/usr/bin
88 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gdb $(1)/usr/bin/
91 define Package/gdbserver/install
92 $(INSTALL_DIR) $(1)/usr/bin
93 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gdbserver $(1)/usr/bin/
96 $(eval $(call BuildPackage,gdb))
97 $(eval $(call BuildPackage,gdbserver))