struct / union in initializer, RFE #901.
[sdcc.git] / sdcc / debugger / mcs51 / Makefile.in
blob084a258179626a52bb6d7f098e837c48a96cec13
5 SHELL = /bin/sh
6 CC = @CC@
7 CPP = @CPP@
8 INSTALL = @INSTALL@
9 STRIP = @STRIP@
10 MAKEDEP = @MAKEDEP@
12 top_builddir = ../../
13 top_srcdir = @srcdir@/../..
14 SLIB = $(top_srcdir)/support/util
15 SDCCLIB = $(top_srcdir)/src
17 VPATH = @srcdir@
18 srcdir = @srcdir@
20 prefix = @prefix@
21 exec_prefix = @exec_prefix@
22 bindir = @bindir@
24 transform = @program_transform_name@
26 STD_INC = @sdcc_include_dir@
27 CPPFLAGS = @CPPFLAGS@ -I. -I$(top_builddir) -I$(top_srcdir) -I$(SLIB) -DHAVE_CONFIG_H
28 CFLAGS = @CFLAGS@ @WALL_FLAG@
29 LDFLAGS = @LDFLAGS@
31 EXEEXT = @EXEEXT@
33 LIBS = @LIBS@ @LIBREADLINE@
34 LIBDIRS =
36 OBJECTS = sdcdb.o symtab.o simi.o \
37 break.o cmd.o
38 SLIBOBJS = NewAlloc.o dbuf.o dbuf_string.o
39 SDCCOBJS = SDCCset.o SDCChasht.o SDCCerr.o
41 SOURCES = $(patsubst %.o,%.c,$(OBJECTS))
42 SLIBSOURCES = $(patsubst %.o,$(SLIB)/%.c,$(SLIBOBJS))
43 SDCCSOURCES = $(patsubst %.o,$(SDCCLIB)/%.c,$(SDCCOBJS))
45 TARGET = $(top_builddir)/bin/sdcdb$(EXEEXT)
48 # Compiling entire program or any subproject
49 # ------------------------------------------
50 all: checkconf $(TARGET)
52 # Compiling and installing everything and runing test
53 # ---------------------------------------------------
54 install: all installdirs
55 $(INSTALL) $(TARGET) $(DESTDIR)$(bindir)/`echo sdcdb|sed '$(transform)'`$(EXEEXT)
56 $(STRIP) $(DESTDIR)$(bindir)/`echo sdcdb|sed '$(transform)'`$(EXEEXT)
57 cp $(srcdir)/sdcdb.el $(DESTDIR)$(bindir)/`echo 'sdcdb'|sed '$(transform)'`.el
58 cp $(srcdir)/sdcdbsrc.el $(DESTDIR)$(bindir)/`echo 'sdcdbsrc'|sed '$(transform)'`.el
61 # Deleting all the installed files
62 # --------------------------------
63 uninstall:
64 rm -f $(DESTDIR)$(bindir)/`echo sdcdb|sed '$(transform)'`$(EXEEXT)
65 rm -f $(DESTDIR)$(bindir)/`echo 'sdcdb'|sed '$(transform)'`.el
66 rm -f $(DESTDIR)$(bindir)/`echo 'sdcdbsrc'|sed '$(transform)'`.el
68 # Performing self-test
69 # --------------------
70 check:
73 # Performing installation test
74 # ----------------------------
75 installcheck:
78 # Creating installation directories
79 # ---------------------------------
80 installdirs:
81 $(INSTALL) -d $(DESTDIR)$(bindir)
84 # Creating dependencies
85 # ---------------------
86 dep: Makefile.dep
88 Makefile.dep: $(SOURCES) $(SLIBSOURCES) $(SDCCSOURCES) $(srcdir)/*.h $(top_builddir)/*.h $(top_srcdir)/*.h
89 $(MAKEDEP) $(CPPFLAGS) $(filter %.c,$^) >Makefile.dep
91 ifeq "$(findstring $(MAKECMDGOALS),uninstall installcheck installdirs checkconf \
92 clean distclean mostlyclean realclean)" ""
93 -include Makefile.dep
94 endif
95 include $(srcdir)/clean.mk
97 # My rules
98 # --------
99 $(TARGET): $(OBJECTS) $(SLIBOBJS) $(SDCCOBJS)
100 $(CC) $(LDFLAGS) -o $@ $(OBJECTS) $(SLIBOBJS) $(SDCCOBJS) $(LIBDIRS) $(LIBS)
102 .c.o:
103 $(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<
105 $(SLIBOBJS):%.o:$(SLIB)/%.c
106 $(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<
108 $(SDCCOBJS):%.o:$(SDCCLIB)/%.c
109 $(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<
111 # Remaking configuration
112 # ----------------------
113 checkconf:
114 @if [ -f $(top_builddir)/devel ]; then\
115 $(MAKE) -f conf.mk srcdir="$(srcdir)" top_builddir="$(top_builddir)" freshconf;\
118 # End of cpp/Makefile