gdb: Disable tests
[openwrt/staging/wigyori.git] / package / devel / gdb / Makefile
1 #
2 # Copyright (C) 2006-2016 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=gdb
11 PKG_VERSION:=10.1
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
15 PKG_SOURCE_URL:=@GNU/gdb
16 PKG_HASH:=f82f1eceeec14a3afa2de8d9b0d3c91d5a3820e23e0a01bbb70ef9f0276b62c0
17
18 PKG_BUILD_PARALLEL:=1
19 PKG_INSTALL:=1
20 PKG_LICENSE:=GPL-3.0+
21 PKG_CPE_ID:=cpe:/a:gnu:gdb
22
23 include $(INCLUDE_DIR)/package.mk
24
25 define Package/gdb/Default
26 SECTION:=devel
27 CATEGORY:=Development
28 DEPENDS:=+!USE_MUSL:libthread-db +zlib
29 URL:=https://www.gnu.org/software/gdb/
30 endef
31
32 define Package/gdb
33 $(call Package/gdb/Default)
34 TITLE:=GNU Debugger
35 DEPENDS+=+libreadline +libncurses +zlib
36 endef
37
38 define Package/gdb/description
39 GDB, the GNU Project debugger, allows you to see what is going on `inside'
40 another program while it executes -- or what another program was doing at the
41 moment it crashed.
42 endef
43
44 define Package/gdbserver
45 $(call Package/gdb/Default)
46 TITLE:=Remote server for GNU Debugger
47 DEPENDS=@!arc
48 endef
49
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.
53 endef
54
55 # XXX: add --disable-werror to prevent build failure with arm
56 CONFIGURE_ARGS+= \
57 --with-system-readline \
58 --with-system-zlib \
59 --without-expat \
60 --without-lzma \
61 --disable-unit-tests \
62 --disable-ubsan \
63 --disable-sim \
64 --disable-werror \
65 --disable-source-highlight
66
67 CONFIGURE_VARS+= \
68 ac_cv_search_tgetent="$(TARGET_LDFLAGS) -lncurses -lreadline"
69
70 TARGET_LDFLAGS+= \
71 -static-libstdc++ \
72 -Wl,--gc-sections
73
74 define Build/Install
75 $(MAKE) -C $(PKG_BUILD_DIR) \
76 DESTDIR="$(PKG_INSTALL_DIR)" \
77 CPPFLAGS="$(TARGET_CPPFLAGS)" \
78 install-gdb install-gdbserver
79 endef
80
81 define Package/gdb/install
82 $(INSTALL_DIR) $(1)/usr/bin
83 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gdb $(1)/usr/bin/
84 endef
85
86 define Package/gdbserver/install
87 $(INSTALL_DIR) $(1)/usr/bin
88 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gdbserver $(1)/usr/bin/
89 endef
90
91 $(eval $(call BuildPackage,gdb))
92 $(eval $(call BuildPackage,gdbserver))