blob: 6e04552034a897eb5383ab88b351f1cd4e7b3254 [file] [log] [blame]
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001SUMMARY = "GNU debugger"
2HOMEPAGE = "http://www.gnu.org/software/gdb/"
Andrew Geissler90fd73c2021-03-05 15:25:55 -06003DESCRIPTION = "GDB, the GNU Project debugger, allows you to see what is going on inside another program while it executes -- or what another program was doing at the moment it crashed."
Patrick Williamsc124f4f2015-09-15 14:41:29 -05004SECTION = "devel"
Brad Bishop1a4b7ee2018-12-16 17:11:34 -08005DEPENDS = "expat zlib ncurses virtual/libiconv ${LTTNGUST} bison-native"
Patrick Williamsc124f4f2015-09-15 14:41:29 -05006
7LTTNGUST = "lttng-ust"
Brad Bishop19323692019-04-05 15:28:33 -04008LTTNGUST_arc = ""
Patrick Williamsc124f4f2015-09-15 14:41:29 -05009LTTNGUST_aarch64 = ""
Brad Bishop6e60e8b2018-02-01 10:27:11 -050010LTTNGUST_mipsarch = ""
Patrick Williamsc124f4f2015-09-15 14:41:29 -050011LTTNGUST_sh4 = ""
Patrick Williamsc124f4f2015-09-15 14:41:29 -050012
Patrick Williamsc124f4f2015-09-15 14:41:29 -050013inherit autotools texinfo
14
Patrick Williamsc0f7c042017-02-23 20:41:17 -060015UPSTREAM_CHECK_GITTAGREGEX = "gdb\-(?P<pver>.+)\-release"
16
Patrick Williamsc124f4f2015-09-15 14:41:29 -050017B = "${WORKDIR}/build-${TARGET_SYS}"
18
Patrick Williamsc124f4f2015-09-15 14:41:29 -050019EXPAT = "--with-expat --with-libexpat-prefix=${STAGING_DIR_HOST}"
20
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080021EXTRA_OECONF = "--disable-gdbtk --disable-x --disable-werror \
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050022 --with-curses --disable-multilib --disable-sim \
Andrew Geissler6ce62a22020-11-30 19:58:47 -060023 --without-guile \
Patrick Williamsc124f4f2015-09-15 14:41:29 -050024 ${GDBPROPREFIX} ${EXPAT} \
25 ${@bb.utils.contains('DISTRO_FEATURES', 'multiarch', '--enable-64-bit-bfd', '', d)} \
26 --disable-rpath \
Patrick Williamsc0f7c042017-02-23 20:41:17 -060027 --disable-gas --disable-binutils \
28 --disable-ld --disable-gold \
29 --disable-gprof \
30"
Patrick Williamsc124f4f2015-09-15 14:41:29 -050031
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050032PACKAGECONFIG ??= "readline"
33# Use --without-system-readline to compile with readline 5.
34PACKAGECONFIG[readline] = "--with-system-readline,--without-system-readline,readline"
Patrick Williamsc0f7c042017-02-23 20:41:17 -060035PACKAGECONFIG[python] = "--with-python=${WORKDIR}/python,--without-python,python3,python3 python3-codecs"
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050036PACKAGECONFIG[babeltrace] = "--with-babeltrace,--without-babeltrace,babeltrace"
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080037# ncurses is already a hard DEPENDS, but would be added here if it weren't
38PACKAGECONFIG[tui] = "--enable-tui,--disable-tui"
Andrew Geissler6ce62a22020-11-30 19:58:47 -060039PACKAGECONFIG[xz] = "--with-lzma,--without-lzma,xz"
Andrew Geissler90fd73c2021-03-05 15:25:55 -060040PACKAGECONFIG[debuginfod] = "--with-debuginfod, --without-debuginfod, elfutils"
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050041
Patrick Williamsc124f4f2015-09-15 14:41:29 -050042GDBPROPREFIX = "--program-prefix=''"
43
Andrew Geissler6ce62a22020-11-30 19:58:47 -060044DISABLE_STATIC = ""
45
Patrick Williamsc124f4f2015-09-15 14:41:29 -050046do_configure () {
47 # override this function to avoid the autoconf/automake/aclocal/autoheader
48 # calls for now
49 (cd ${S} && gnu-configize) || die "failure in running gnu-configize"
50 oe_runconf
51}
52
53# we don't want gdb to provide bfd/iberty/opcodes, which instead will override the
Brad Bishop6e60e8b2018-02-01 10:27:11 -050054# right bits installed by binutils. Same for bfd.info -- also from binutils.
Patrick Williamsc124f4f2015-09-15 14:41:29 -050055do_install_append() {
56 rm -rf ${D}${libdir}
57 rm -rf ${D}${includedir}
58 rm -rf ${D}${datadir}/locale
Brad Bishop6e60e8b2018-02-01 10:27:11 -050059 rm -f ${D}${infodir}/bfd.info
Patrick Williamsc124f4f2015-09-15 14:41:29 -050060}
61
62RRECOMMENDS_gdb_append_linux = " glibc-thread-db "
63RRECOMMENDS_gdb_append_linux-gnueabi = " glibc-thread-db "
64RRECOMMENDS_gdbserver_append_linux = " glibc-thread-db "
65RRECOMMENDS_gdbserver_append_linux-gnueabi = " glibc-thread-db "