-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathMakefile.am
244 lines (203 loc) · 7.12 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
## Process this file with automake to produce Makefile.in
# Unless otherwise specified, the numbers refer to
# https://www.gnu.org/software/automake/manual/automake.html
######################################################################
# https://www.gnu.org/software/gettext/manual/gettext.html
# 13.4.8 aclocal.m4 at top level
ACLOCAL_AMFLAGS = -I m4
######################################################################
# 7 directories
# Generally avoid recursive make as explained in 7.3, but gettext
# insists on a po/ subdirectory.
SUBDIRS = po
######################################################################
# 8 building programs and libraries
# The -pthread compiler and linker option links with libpthread, but
# also selects various architecture-dependent settings.
AM_LDFLAGS = -pthread -Wl,--as-needed
# The glib-compile-resources was generating strings longer than the
# supported by the standard, adding warnings to the build output. The
# flag -Wno-overlength-strings seems right, since we are compiling
# our own generated code.
AM_CFLAGS = -pthread -Wall -Wextra -pedantic -Wno-overlength-strings
bin_PROGRAMS = lingot
lib_LTLIBRARIES = liblingot.la
liblingot_la_SOURCES = \
src/lingot-audio-alsa.c \
src/lingot-audio-jack.c \
src/lingot-audio-oss.c \
src/lingot-audio-pulseaudio.c \
src/lingot-audio.c \
src/lingot-config-scale.c \
src/lingot-config.c \
src/lingot-core.c \
src/lingot-defs-internal.c \
src/lingot-defs-internal.h \
src/lingot-fft.c \
src/lingot-fft.h \
src/lingot-filter.c \
src/lingot-i18n.h \
src/lingot-msg.c \
src/lingot-signal.c \
src/lingot-signal.h
pkginclude_HEADERS = \
src/lingot-audio-alsa.h \
src/lingot-audio-jack.h \
src/lingot-audio-oss.h \
src/lingot-audio-pulseaudio.h \
src/lingot-audio.h \
src/lingot-config-scale.h \
src/lingot-config.h \
src/lingot-core.h \
src/lingot-defs.h \
src/lingot-filter.h \
src/lingot-msg.h
src/lingot-resources.c: src/lingot.gresource.xml
$(GLIB_COMPILE_RESOURCES) $< --target=$@ --sourcedir=$(srcdir)/src --generate-source
# libtool 7.3 updating library version information
# Downstream packagers may have to override the SO version.
lingot_shared_object_version = 0:0:0
# Options to build the library itself (dependencies)
liblingot_dep_cflags = $(ALSA_CFLAGS) $(JACK_CFLAGS) $(LIBFFTW_CFLAGS) $(OSS_CFLAGS) $(PULSEAUDIO_CFLAGS)
liblingot_dep_libs = $(ALSA_LIBS) $(JACK_LIBS) $(LIBFFTW_LIBS) $(OSS_LIBS) $(PULSEAUDIO_LIBS)
# Locally link against the library.
liblingot_rdep_cflags = -I$(srcdir)/src $(liblingot_dep_cflags)
liblingot_rdep_libs = liblingot.la $(liblingot_dep_libs)
liblingot_la_CFLAGS = $(AM_CFLAGS) $(liblingot_dep_cflags)
liblingot_la_LIBADD = $(liblingot_dep_libs)
liblingot_la_LDFLAGS = $(AM_LDFLAGS) \
-version-info $(lingot_shared_object_version) \
-Wl,--no-allow-shlib-undefined \
-Wl,--no-copy-dt-needed-entries \
-Wl,--no-undefined
lingot_SOURCES = \
src/lingot-gui-config-dialog-scale.c \
src/lingot-gui-config-dialog-scale.h \
src/lingot-gui-config-dialog.c \
src/lingot-gui-config-dialog.glade \
src/lingot-gui-config-dialog.h \
src/lingot-gui-gauge.c \
src/lingot-gui-gauge.h \
src/lingot-gui-i18n.h \
src/lingot-gui-mainframe.c \
src/lingot-gui-mainframe.glade \
src/lingot-gui-mainframe.h \
src/lingot-gui-spectrum.c \
src/lingot-gui-spectrum.h \
src/lingot-gui-strobe-disc.c \
src/lingot-gui-strobe-disc.h \
src/lingot-io-config-scale.c \
src/lingot-io-config-scale.h \
src/lingot-io-config.c \
src/lingot-io-config.h \
src/lingot-io-ui-settings.c \
src/lingot-io-ui-settings.h \
src/lingot-strobe.png \
src/lingot.c \
src/lingot.gresource.xml
nodist_lingot_SOURCES = src/lingot-resources.c
lingot_CFLAGS = $(AM_CFLAGS) $(liblingot_rdep_cflags) $(GTK_CFLAGS) $(JSON_CFLAGS)
lingot_LDADD = $(liblingot_rdep_libs) $(GTK_LIBS) $(JSON_LIBS)
######################################################################
# 11 building documentation
dist_man_MANS = lingot.1
######################################################################
# 12 what gets installed
dist_doc_DATA = \
AUTHORS \
COPYING \
ChangeLog \
NEWS \
README \
README.config \
THANKS
iconsdir = $(datadir)/icons/hicolor/scalable/apps
dist_icons_DATA = icons/org.nongnu.lingot.svg
gnomemenudir = $(datadir)/applications
dist_gnomemenu_DATA = org.nongnu.lingot.desktop
appdatadir = $(datadir)/metainfo
dist_appdata_DATA = org.nongnu.lingot.appdata.xml
# Install to architecture-dependent directory. Do not distribute.
pkgexecconfigdir = $(libdir)/pkgconfig
pkgexecconfig_DATA = lingot.pc
# autoconf 4.8.2 Installation Directory Variables
# Substituting from here instead of from configure.ac ensures that the
# user can override prefix on the Make command line.
edit = sed \
-e 's|@PACKAGE_URL[@]|$(PACKAGE_URL)|g' \
-e 's|@PACKAGE_VERSION[@]|$(PACKAGE_VERSION)|g' \
-e 's|@OSS_CFLAGS[@]|$(OSS_CFLAGS)|g' \
-e 's|@pkgincludedir[@]|$(pkgincludedir)|g' \
-e 's|@libdir[@]|$(libdir)|g' \
-e 's|@OSS_LIBS[@]|$(OSS_LIBS)|g'
lingot.pc: Makefile
rm -f $@ $@.tmp
srcdir=''; \
test -f ./$@.in || srcdir=$(srcdir)/; \
$(edit) $${srcdir}$@.in >$@.tmp
mv $@.tmp $@
lingot.pc: $(srcdir)/lingot.pc.in
######################################################################
# 13 what gets cleaned
CLEANFILES = \
lingot.pc \
src/lingot-resources.c
MAINTAINERCLEANFILES = \
ABOUT-NLS \
INSTALL \
Makefile.in \
aclocal.m4 \
ar-lib \
compile \
config.guess \
config.h.in \
config.rpath \
config.sub \
configure \
depcomp \
install-sh \
ltmain.sh \
m4/* \
missing \
po/*.header \
po/*.sed \
po/*.sin \
po/Makevars.template \
po/Rules-quot \
test-driver
######################################################################
# 14 what goes in a distribution
# bootstrap and tests require additional dependencies but may be
# useful to users of the tarball
EXTRA_DIST = \
bootstrap \
lingot.pc.in \
test/resources/lingot-001.conf \
test/resources/lingot-0_9_2b8.conf \
test/resources/lingot-1_0_2b.conf \
test/resources/lingot-1_1_0.conf
######################################################################
# 15 support for test suites
# And also 20 conditionals, because we only want to build and run
# tests if CUnit is available.
# EXTRA_PROGRAMS does not look easyer...
# Automake accepts no indentation here.
# Help the executable finding the shared library.
AM_TESTS_ENVIRONMENT = export LD_LIBRARY_PATH='$(builddir)/.libs';
if CUNIT
# Programs run by 'make check'.
TESTS = lingot_test
# Programs built for 'make check'.
check_PROGRAMS = lingot_test
lingot_test_SOURCES = \
test/src/lingot-test-config-scale.c \
test/src/lingot-test-core.c \
test/src/lingot-test-filter.c \
test/src/lingot-test-io-config.c \
test/src/lingot-test-main.c \
test/src/lingot-test-signal.c \
test/src/lingot-test.c \
test/src/lingot-test.h
lingot_test_CFLAGS = $(AM_CFLAGS) $(liblingot_rdep_cflags) $(CUNIT_CFLAGS) $(JSON_CFLAGS)
lingot_test_LDADD = $(liblingot_rdep_libs) $(CUNIT_LIBS) $(JSON_LIBS)
endif