File: Makefile.in

package info (click to toggle)
sdcc 3.4.0%2Bdfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 60,316 kB
  • ctags: 69,276
  • sloc: ansic: 418,778; cpp: 48,792; makefile: 46,787; sh: 28,453; asm: 11,918; perl: 8,387; yacc: 6,640; lisp: 1,630; lex: 746; python: 660; awk: 495; sed: 89
file content (203 lines) | stat: -rw-r--r-- 4,575 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
#
# uCsim Makefile
#
# (c) Drotos Daniel, Talker Bt. 1997,99
#

STARTYEAR	= 1997

SHELL		= /bin/sh

include packages.mk
#PKGS		= cmd.src sim.src gui.src s51.src avr.src z80.src doc

VPATH		= @srcdir@
srcdir		= @srcdir@

top_builddir	= @top_builddir@
top_srcdir	= @top_srcdir@

# Compiling entire program or any subproject
# ------------------------------------------
all: checkconf
	$(MAKE) -f main.mk all
	@for pkg in $(PKGS); do\
	  $(MAKE) -C $$pkg $$pkg ;\
	done
	$(MAKE) -f main.mk main_app

libs: main.mk
	$(MAKE) -f main.mk libs


# Compiling and installing everything and runing test
# ---------------------------------------------------
.PHONY: install INSTALL Install
install:
	$(MAKE) -f main.mk install
	@for pkg in $(PKGS); do\
	  $(MAKE) -C $$pkg install ;\
	done


# Deleting all the installed files
# --------------------------------
uninstall:
	$(MAKE) -f main.mk uninstall
	@for pkg in $(PKGS); do\
	  $(MAKE) -C $$pkg uninstall ;\
	done


# Deleting all files created by building the program
# --------------------------------------------------
clean:
	$(MAKE) -f $(srcdir)/clean.mk clean EXEEXT=$(EXEEXT)
	@for pkg in $(PKGS_ALL); do\
	  $(MAKE) -C $$pkg -f ../$(srcdir)/$$pkg/clean.mk clean EXEEXT=$(EXEEXT) ;\
	done


# Deleting all files created by configuring or building the program
# -----------------------------------------------------------------
distclean: clean
	$(MAKE) -f $(srcdir)/clean.mk distclean
	@for pkg in $(PKGS_ALL); do\
	  $(MAKE) -C $$pkg -f ../$(srcdir)/$$pkg/clean.mk distclean ;\
	done
	rm -rf doc/*~ doc/*.bak Makefile packages.mk libtool


# Like clean but some files may still exist
# -----------------------------------------
mostlyclean: clean
	$(MAKE) -f clean.mk mostlyclean
	@for pkg in $(PKGS_ALL); do\
	  $(MAKE) -C $$pkg -f ../$(srcdir)/$$pkg/clean.mk mostlyclean ;\
	done


# Deleting everything that can reconstructed by this Makefile. It deletes
# everything deleted by distclean plus files created by bison, stc.
# -----------------------------------------------------------------------
realclean: distclean
	$(MAKE) -f clean.mk realclean
	@for pkg in $(PKGS_ALL); do\
	  $(MAKE) -C $$pkg -f ../$(srcdir)/$$pkg/clean.mk realclean ;\
	done


# Creating distribution
# ---------------------
dist: distclean
	@if [ -f devel ]; then\
	  rm -f devel; mkdist; touch devel;\
	else\
	  mkdist;\
	fi


# Performing self-test
# --------------------
check:
	$(MAKE) -f main.mk check
	@for pkg in $(PKGS); do\
	  $(MAKE) -C $$pkg check ;\
	done

test:
	$(MAKE) -f main.mk test
	@for pkg in $(PKGS); do\
	  $(MAKE) -C $$pkg test ;\
	done


# Performing installation test
# ----------------------------
installcheck:


# Creating dependencies
# ---------------------
dep:
	$(MAKE) -f main.mk dep
	@for pkg in $(PKGS); do\
	  $(MAKE) -C $$pkg dep ;\
	done


# My rules
# --------
putcopyright:
	'put(c)' -s $(STARTYEAR) *.cc *.h *.y *.l

start:
	date '+%Y.%m.%d-%H:%M' >.start

newer: distclean
	@if [ -f .start ]; then \
	  tar cvf - \
	    `find . -newer .start -type f -print` |\
	  gzip -9c >ucsim-newer-`cat .start`_`date '+%Y.%m.%d-%H:%M'`_`hostname`.tgz; \
	else \
	  echo ".start file not found.\n"; \
	  exit 1; \
	fi

print-newer:
	@if [ -f .start ]; then \
	  find . -newer .start -type f -print ;\
	else \
	  echo ".start file not found.\n" ;\
	  exit 1 ;\
	fi

new_files:
	diff -rNu $$HOME/clean-source/sdcc/sim/ucsim .|\
	grep '^diff' | grep -v .svn | awk '{print $$4}'

lines:
	@find . \( -name '*.[ch]' -o -name '*.cc' -o -name '*.hh' \) \
	-exec cat {} \; | clines


# Remaking configuration
# ----------------------
configure: configure.in
	@$(top_srcdir)/mkecho $(top_builddir) "RE-CREATING CONFIGURE"
	autoconf configure.in >configure
	chmod 755 configure

config.status: configure
	@$(top_srcdir)/mkecho $(top_builddir) "RE-CHECKING CONFIGURATION (re-creating config.status from configure)"
	@if [ -x ./config.status ]; then \
	  ./config.status -recheck;\
	else\
	  if [ -x ./conf ]; then\
	    ./conf;\
	  else\
	    ./configure;\
	  fi\
	fi

makefiles: config.status
	@$(top_srcdir)/mkecho $(top_builddir) "RE-MAKING MAKEFILES"
	$(SHELL) ./config.status

main.mk: $(srcdir)/main_in.mk config.status
	@$(top_srcdir)/mkecho $(top_builddir) "RE-MAKING MAIN.MK"
	$(SHELL) ./config.status

freshconf: echo_freshconf configure main.mk ddconfig.h

ddconfig.h: ddconfig_in.h config.status
	$(SHELL) ./config.status

echo_freshconf:
	@$(top_srcdir)/mkecho $(top_builddir) "FRESHCONF"

checkconf:
	@$(top_srcdir)/mkecho $(top_builddir) "CHECKCONF"
	@if [ -f devel ]; then $(MAKE) freshconf; fi

# End of Makefile