forked from Gnucash/gnucash
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile.am
256 lines (222 loc) · 7.21 KB
/
Makefile.am
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
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
if GNUCASH_ENABLE_GUI
GNUCASH_SUBDIR = gnucash
else
GNUCASH_SUBDIR =
endif
SUBDIRS = . borrowed common libgnucash bindings ${GNUCASH_SUBDIR} doc po data
GNC_CTAGS_FILE = @GNC_CTAGS_FILE@
GNC_ETAGS_FILE = @GNC_ETAGS_FILE@
noinst_DATA = make-gnucash-potfiles
noinst_PROGRAMS = gnc-guile
gnc_guile_SOURCES = util/guile.c
gnc_guile_CFLAGS = ${GUILE_CFLAGS}
gnc_guile_LDADD = ${GUILE_LIBS}
dist_doc_DATA = \
AUTHORS \
COPYING \
ChangeLog \
ChangeLog.2016 \
ChangeLog.2015 \
ChangeLog.2014 \
ChangeLog.2013 \
ChangeLog.2012 \
ChangeLog.2011 \
ChangeLog.2010 \
ChangeLog.2009 \
ChangeLog.2008 \
ChangeLog.2007 \
ChangeLog.2006 \
ChangeLog.2005 \
ChangeLog.2004 \
ChangeLog.2003 \
ChangeLog.2002 \
ChangeLog.2001 \
ChangeLog.2000 \
ChangeLog.1999 \
DOCUMENTERS \
HACKING \
INSTALL \
LICENSE \
NEWS \
README \
README.dependencies
# All the other files that go in the distribution tarfile that aren't
# included some other way...
# Most directories handle their own EXTRA_DIST setting, but for some,
# it's not worth the trouble and for others, there's no Makefile.am
# (i.e. ./intl and ./po -- these handle their own Makefile.in and
# Makefile.in.in files...), so we list their files here.
# Don't list any directories or you'll get *everything*, including the
# CVS dirs.
EXTRA_DIST = \
$(SWIG_DIST_FAIL) \
CMakeLists.txt \
cmake/cmake_uninstall.cmake.in \
cmake/README_CMAKE.txt \
cmake/CMakeLists.txt \
make-gnucash-potfiles.in \
macros/binreloc.m4 \
macros/compiler-flags.m4 \
macros/ax_pkg_swig.m4 \
macros/ax_python_devel.m4 \
macros/ax_swig_python.m4 \
macros/legacy_macros.m4 \
macros/CMakeLists.txt \
po/CMakeLists.txt \
po/check-po.cmake \
po/glossary/CMakeLists.txt \
po/gnucash.pot \
po/POTFILES.in \
po/POTFILES.skip \
po/POTFILES.ignore \
po/README \
po/glossary/bg.po \
po/glossary/ca.po \
po/glossary/da.po \
po/glossary/de.po \
po/glossary/el.po \
po/glossary/es.po \
po/glossary/es_NI-policy.txt \
po/glossary/fr.po \
po/glossary/gnc-glossary.txt \
po/glossary/he.po \
po/glossary/hu.po \
po/glossary/it.po \
po/glossary/nb.po \
po/glossary/nl.po \
po/glossary/pl.po \
po/glossary/pt.po \
po/glossary/pt_BR.po \
po/glossary/ru.po \
po/glossary/rw.po \
po/glossary/sk.po \
po/glossary/sv.po \
po/glossary/txt-to-pot.sh \
po/glossary/vi.po \
po/glossary/zh_CN.po \
po/glossary/zh_TW.po \
intltool-extract.in \
intltool-merge.in \
intltool-update.in \
test-templates/CMakeLists.txt \
test-templates/Makefile.am \
util/gnc-vcs-info \
util/CMakeLists.txt
## We borrow guile's convention and use @-...-@ as the substitution
## brackets here, instead of the usual @...@. This prevents autoconf
## from substituting the values directly into the left-hand sides of
## the sed substitutions.
make-gnucash-potfiles: make-gnucash-potfiles.in Makefile
rm -f [email protected]
sed < $< > [email protected] \
-e 's:@-SRCDIR-@:${srcdir}:g' \
-e 's:@-PERL-@:${PERL}:g'
chmod +x [email protected]
mv [email protected] $@
DISTCLEANFILES = \
intltool-extract intltool-update intltool-merge\
cscope.files cscope.out etags.files \
make-gnucash-potfiles po/.intltool-merge-cache
cscope.files:
find bindings common libgnucash gnucash lib -name '*.[ch]' > cscope.files
if GNUCASH_SEPARATE_BUILDDIR
find ${srcdir}/bindings ${srcdir}/common ${srcdir}/libgnucash ${srcdir}/gnucash ${srcdir}/lib -name '*.[ch]' >> cscope.files
endif
${srcdir}/cscope.out: cscope.files
cscope -b -f ${srcdir}/cscope.out
# make sure etags.files is up to date.
# and use the contents of etags.files to re-make TAGS if needed.
etags:
if GNC_ETAGS_FILE
${MAKE} -f Makefile.TAGS etags.files
${MAKE} -f Makefile.TAGS TAGS
else
@echo "You must ./configure with --enable-etags to use etags."
endif
# make sure etags.files is up to date.
# and use the contents of etags.files to re-make tags if needed.
ctags:
if GNC_CTAGS_FILE
${MAKE} -f Makefile.TAGS etags.files
${MAKE} -f Makefile.TAGS tags
else
@echo "You must ./configure with --enable-ctags to use ctags."
endif
.PHONY: etags ctags
ACLOCAL_AMFLAGS = -I macros
.PHONY: doc
doc:
$(MAKE) -C src/doc doc
distcleancheck_listfiles = \
find -type f -exec sh -c 'test -f ${srcdir}/{} || echo {}' ';'
distuninstallcheck_listfiles = \
find . -type f -print | grep -v ./share/icons/hicolor/icon-theme.cache | grep -v ./share/info/dir
#dist-hook: po/POTFILES.in
# Make "make dist" fail if we have the wrong version of swig
if SWIG_DIST_FAIL
SWIG_DIST_FAIL = swig-dist-fail
swig-dist-fail:
@echo "You cannot build the dist with your version of swig"
@exit 1
endif
distcheck-hook:
@e=''; \
for X in `grep -v \# ${distdir}/po/POTFILES.in | sed 's/\[type:.*\]//'` ; do \
if [ ! -f ${distdir}/$$X ] ; then \
echo $$X " is in POTFILES.in but not in the dist."; \
e='yes'; \
fi; \
done; \
for X in `grep -v '\(^\#\|.scm\$\)' ${distdir}/po/POTFILES.skip` ; do \
if [ -f ${distdir}/$$X ] ; then \
echo $$X " is in POTFILES.skip but also in the dist.";\
e='yes'; \
fi; \
done; \
if test "$$e" = "yes" ; then exit 1; fi;
distclean-local:
libtool: $(LIBTOOL_DEPS)
$(SHELL) ./config.status --recheck
.PHONY: pot
pot: Makefile po/POTFILES.in
rm -f po/$(PACKAGE).pot
${MAKE} -C po $(PACKAGE).pot
$(srcdir)/po/POTFILES.in: make-gnucash-potfiles .potfiles
if test -w $(srcdir)/po/POTFILES.in ; then ./make-gnucash-potfiles > $(srcdir)/po/POTFILES.in ; fi
# Creation rules so that po/gnucash.pot can always be created for
# make dist.
po/gnucash.pot: po/POTFILES.in
${MAKE} -C po gnucash.pot
.potfiles:
SVN = svn
if BUILDING_FROM_VCS
# This rule will generate a ChangeLog of gnucash/trunk commits, plus
# all additional branches that are added in
# ./macros/svn2cl.xsl. (FIXME: Is the dependency on NEWS really a good
# idea? Before a release, NEWS will get updated because of the version
# change, so this should fit just fine.)
ChangeLog: NEWS
cd $(abs_srcdir) ; \
if test x$(VCS_TYPE) = xsvn ; then \
$(SVN) log -v --xml -r HEAD:'{2015-01-01}' http://svn.gnucash.org/repo/gnucash | \
$(XSLTPROC) --stringparam strip-prefix "gnucash/trunk" \
--stringparam include-rev "yes" $(abs_srcdir)/macros/svn2cl.xsl - > $(abs_builddir)/$@ ; \
else \
if test x$(VCS_TYPE) = xgit ; then \
"$(GIT_CMD)" log --format="%ad %aN %n%n%x09* %s%d%n" --date=short --since=2017-01-01 > $(abs_builddir)/$@ ; \
else \
touch $(abs_builddir)/$@ ; \
echo "Note: not in svn or git. ChangeLog not regenerated." ; \
fi ; \
fi ; \
cd $(abs_builddir)
endif
ASTYLE = /usr/bin/astyle
.PHONY: indent
indent:
$(ASTYLE) --indent=spaces=4 --brackets=break --suffix=none `find ${srcdir}/{bindings,common,libgnucash,gnucash} -name '*.[hc]'`
# Use the following line if you've got astyle-1.24, but don't use
# --pad=oper with astyle 1.22 as it will reformat e.g. "return +1;" in
# a very ugly way.
# $(ASTYLE) --indent=spaces=4 --brackets=break --pad-oper -pad-header --suffix=none `find ${srcdir}/{bindings,common,libgnucash,gnucash} -name '*.[hc]'`
@echo "### GnuCash development hint: The above command might have re-indented much more files than what you intended. Please commit only those which you really want to have changed, and revert the changes in the others so that other devevelopers do not have unnecessary merge conflicts. Thanks! ###"