3 include $(TOPDIR
)/rules.mk
6 GDB_SITE
:=http
://ftp.gnu.org
/gnu
/gdb
8 GDB_SOURCE
:=$(GDB_NAME
)-$(GDB_VERSION
).
tar.bz2
11 GDB_DIR
:=$(TOOL_BUILD_DIR
)/$(GDB_NAME
)-$(GDB_VERSION
)
13 $(DL_DIR
)/$(GDB_SOURCE
):
14 $(WGET
) -P
$(DL_DIR
) $(GDB_SITE
)/$(GDB_SOURCE
)
16 $(GDB_DIR
)/.patched
: $(DL_DIR
)/$(GDB_SOURCE
)
17 $(GDB_CAT
) $(DL_DIR
)/$(GDB_SOURCE
) |
tar -C
$(TOOL_BUILD_DIR
) $(TAR_OPTIONS
) -
18 $(PATCH
) $(GDB_DIR
) .
/patches
19 # Copy a config.sub from gcc. This is only necessary until
20 # gdb's config.sub supports <arch>-linux-uclibc tuples.
21 # Should probably integrate this into the patch.
22 touch
$(GDB_DIR
)/.patched
26 GDB_CLIENT_DIR
:=$(TOOL_BUILD_DIR
)/gdbclient-
$(GDB_VERSION
)
28 $(GDB_CLIENT_DIR
)/.configured
: $(GDB_DIR
)/.patched
29 mkdir
-p
$(GDB_CLIENT_DIR
)
30 (cd
$(GDB_CLIENT_DIR
); \
31 gdb_cv_func_sigsetjmp
=yes \
32 $(GDB_DIR
)/configure \
33 --prefix=$(STAGING_DIR
) \
34 --build
=$(GNU_HOST_NAME
) \
35 --host
=$(GNU_HOST_NAME
) \
36 --target
=$(REAL_GNU_TARGET_NAME
) \
38 --without-uiout
--disable-gdbmi \
39 --disable-tui
--disable-gdbtk
--without-x \
40 --without-included-gettext \
43 touch
$(GDB_CLIENT_DIR
)/.configured
45 $(GDB_CLIENT_DIR
)/gdb
/gdb
: $(GDB_CLIENT_DIR
)/.configured
46 $(MAKE
) -C
$(GDB_CLIENT_DIR
)
47 strip $(GDB_CLIENT_DIR
)/gdb
/gdb
49 $(TARGET_CROSS
)gdb
: $(GDB_CLIENT_DIR
)/gdb
/gdb
50 install -c
$(GDB_CLIENT_DIR
)/gdb
/gdb
$(TARGET_CROSS
)gdb
51 cd
$(STAGING_DIR
)/bin
&& \
52 ln
-fs
$(GNU_TARGET_NAME
)-gdb
$(REAL_GNU_TARGET_NAME
)-gdb
54 source
: $(DL_DIR
)/$(GDB_SOURCE
)
55 prepare
: $(GDB_DIR
)/.patched
57 install: $(TARGET_CROSS
)gdb
59 rm -rf
$(GDB_CLIENT_DIR
)