]> git.kernelconcepts.de Git - karo-tx-uboot.git/blob - tools/gdb/Makefile
Merge branch 'u-boot-imx/master' into 'u-boot-arm/master'
[karo-tx-uboot.git] / tools / gdb / Makefile
1 #
2 # (C) Copyright 2006
3 # Wolfgang Denk, DENX Software Engineering, wd@denx.de.
4 #
5 # (C) Copyright 2000
6 # Murray Jensen <Murray.Jensen@csiro.au>
7 #
8 # SPDX-License-Identifier:      GPL-2.0+
9 #
10
11 include $(TOPDIR)/config.mk
12
13 BINS    = gdbsend gdbcont
14
15 COBJS   = gdbsend.o gdbcont.o error.o remote.o serial.o
16
17 HOSTOBJS := $(addprefix $(obj),$(COBJS))
18 HOSTSRCS := $(COBJS:.o=.c)
19 BINS    := $(addprefix $(obj),$(BINS))
20
21 #
22 # Use native tools and options
23 #
24 HOSTCPPFLAGS = -I$(BFD_ROOT_DIR)/include
25
26 ifeq ($(HOSTOS),cygwin)
27
28 all:
29 $(obj).depend:
30
31 else    # ! CYGWIN
32
33 all:    $(obj).depend $(BINS)
34
35 $(obj)gdbsend:  $(obj)gdbsend.o $(obj)error.o $(obj)remote.o $(obj)serial.o
36                 $(HOSTCC) $(HOSTCFLAGS) $(HOSTLDFLAGS) -o $@ $^
37
38 $(obj)gdbcont:  $(obj)gdbcont.o $(obj)error.o $(obj)remote.o $(obj)serial.o
39                 $(HOSTCC) $(HOSTCFLAGS) $(HOSTLDFLAGS) -o $@ $^
40
41 clean:
42         rm -f $(HOSTOBJS)
43
44 distclean:      clean
45         rm -f $(BINS) $(obj)core $(obj)*.bak $(obj).depend
46
47 #########################################################################
48
49 # defines $(obj).depend target
50 include $(SRCTREE)/rules.mk
51
52 sinclude $(obj).depend
53
54 #########################################################################
55
56 endif   # cygwin