]>
Commit | Line | Data |
---|---|---|
1 | ## | |
2 | ## This file is part of the libsigrok project. | |
3 | ## | |
4 | ## Copyright (C) 2010-2012 Bert Vermeulen <bert@biot.com> | |
5 | ## Copyright (C) 2012 Alexandru Gagniuc <mr.nuke.me@gmail.com> | |
6 | ## | |
7 | ## This program is free software: you can redistribute it and/or modify | |
8 | ## it under the terms of the GNU General Public License as published by | |
9 | ## the Free Software Foundation, either version 3 of the License, or | |
10 | ## (at your option) any later version. | |
11 | ## | |
12 | ## This program is distributed in the hope that it will be useful, | |
13 | ## but WITHOUT ANY WARRANTY; without even the implied warranty of | |
14 | ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
15 | ## GNU General Public License for more details. | |
16 | ## | |
17 | ## You should have received a copy of the GNU General Public License | |
18 | ## along with this program. If not, see <http://www.gnu.org/licenses/>. | |
19 | ## | |
20 | ||
21 | ACLOCAL_AMFLAGS = -I autostuff | |
22 | ||
23 | AM_CPPFLAGS = -DFIRMWARE_DIR='"$(FIRMWARE_DIR)"' | |
24 | ||
25 | lib_LTLIBRARIES = libsigrok.la | |
26 | ||
27 | # Backend files | |
28 | libsigrok_la_SOURCES = \ | |
29 | backend.c \ | |
30 | device.c \ | |
31 | session.c \ | |
32 | session_file.c \ | |
33 | session_driver.c \ | |
34 | hwdriver.c \ | |
35 | strutil.c \ | |
36 | log.c \ | |
37 | version.c \ | |
38 | error.c \ | |
39 | std.c | |
40 | ||
41 | # Input formats | |
42 | libsigrok_la_SOURCES += \ | |
43 | input/binary.c \ | |
44 | input/chronovu_la8.c \ | |
45 | input/csv.c \ | |
46 | input/input.c \ | |
47 | input/vcd.c \ | |
48 | input/wav.c | |
49 | ||
50 | # Output formats | |
51 | libsigrok_la_SOURCES += \ | |
52 | output/output.c \ | |
53 | output/analog.c \ | |
54 | output/ascii.c \ | |
55 | output/bits.c \ | |
56 | output/binary.c \ | |
57 | output/csv.c \ | |
58 | output/chronovu_la8.c \ | |
59 | output/gnuplot.c \ | |
60 | output/hex.c \ | |
61 | output/ols.c \ | |
62 | output/vcd.c | |
63 | ||
64 | # Hardware (common files) | |
65 | libsigrok_la_SOURCES += \ | |
66 | hardware/common/scpi.c \ | |
67 | hardware/common/scpi_tcp.c \ | |
68 | hardware/common/scpi_usbtmc.c | |
69 | if NEED_RPC | |
70 | libsigrok_la_SOURCES += \ | |
71 | hardware/common/scpi_vxi.c \ | |
72 | hardware/common/vxi_clnt.c \ | |
73 | hardware/common/vxi_xdr.c \ | |
74 | hardware/common/vxi.h | |
75 | endif | |
76 | if NEED_SERIAL | |
77 | libsigrok_la_SOURCES += \ | |
78 | hardware/common/serial.c \ | |
79 | hardware/common/scpi_serial.c | |
80 | endif | |
81 | if NEED_USB | |
82 | libsigrok_la_SOURCES += \ | |
83 | hardware/common/ezusb.c \ | |
84 | hardware/common/usb.c \ | |
85 | hardware/common/scpi_usbtmc_libusb.c | |
86 | endif | |
87 | if NEED_VISA | |
88 | libsigrok_la_SOURCES += \ | |
89 | hardware/common/scpi_visa.c | |
90 | endif | |
91 | ||
92 | # Hardware (DMM parsers) | |
93 | libsigrok_la_SOURCES += \ | |
94 | hardware/common/dmm/es519xx.c \ | |
95 | hardware/common/dmm/fs9721.c \ | |
96 | hardware/common/dmm/fs9922.c \ | |
97 | hardware/common/dmm/m2110.c \ | |
98 | hardware/common/dmm/metex14.c \ | |
99 | hardware/common/dmm/rs9lcd.c | |
100 | ||
101 | # Hardware drivers | |
102 | if HW_AGILENT_DMM | |
103 | libsigrok_la_SOURCES += \ | |
104 | hardware/agilent-dmm/api.c \ | |
105 | hardware/agilent-dmm/agilent-dmm.h \ | |
106 | hardware/agilent-dmm/sched.c | |
107 | endif | |
108 | if HW_APPA_55II | |
109 | libsigrok_la_SOURCES += \ | |
110 | hardware/appa-55ii/protocol.h \ | |
111 | hardware/appa-55ii/protocol.c \ | |
112 | hardware/appa-55ii/api.c | |
113 | endif | |
114 | if HW_ASIX_SIGMA | |
115 | libsigrok_la_SOURCES += \ | |
116 | hardware/asix-sigma/asix-sigma.h \ | |
117 | hardware/asix-sigma/asix-sigma.c | |
118 | endif | |
119 | if HW_ATTEN_PPS3XXX | |
120 | libsigrok_la_SOURCES += \ | |
121 | hardware/atten-pps3xxx/protocol.h \ | |
122 | hardware/atten-pps3xxx/protocol.c \ | |
123 | hardware/atten-pps3xxx/api.c | |
124 | endif | |
125 | if HW_BRYMEN_BM86X | |
126 | libsigrok_la_SOURCES += \ | |
127 | hardware/brymen-bm86x/protocol.h \ | |
128 | hardware/brymen-bm86x/protocol.c \ | |
129 | hardware/brymen-bm86x/api.c | |
130 | endif | |
131 | if HW_BRYMEN_DMM | |
132 | libsigrok_la_SOURCES += \ | |
133 | hardware/brymen-dmm/parser.c \ | |
134 | hardware/brymen-dmm/protocol.h \ | |
135 | hardware/brymen-dmm/protocol.c \ | |
136 | hardware/brymen-dmm/api.c | |
137 | endif | |
138 | if HW_CEM_DT_885X | |
139 | libsigrok_la_SOURCES += \ | |
140 | hardware/cem-dt-885x/protocol.h \ | |
141 | hardware/cem-dt-885x/protocol.c \ | |
142 | hardware/cem-dt-885x/api.c | |
143 | endif | |
144 | if HW_CENTER_3XX | |
145 | libsigrok_la_SOURCES += \ | |
146 | hardware/center-3xx/protocol.h \ | |
147 | hardware/center-3xx/protocol.c \ | |
148 | hardware/center-3xx/api.c | |
149 | endif | |
150 | if HW_CHRONOVU_LA | |
151 | libsigrok_la_SOURCES += \ | |
152 | hardware/chronovu-la/protocol.h \ | |
153 | hardware/chronovu-la/protocol.c \ | |
154 | hardware/chronovu-la/api.c | |
155 | endif | |
156 | if HW_COLEAD_SLM | |
157 | libsigrok_la_SOURCES += \ | |
158 | hardware/colead-slm/protocol.h \ | |
159 | hardware/colead-slm/protocol.c \ | |
160 | hardware/colead-slm/api.c | |
161 | endif | |
162 | if HW_CONRAD_DIGI_35_CPU | |
163 | libsigrok_la_SOURCES += \ | |
164 | hardware/conrad-digi-35-cpu/protocol.h \ | |
165 | hardware/conrad-digi-35-cpu/protocol.c \ | |
166 | hardware/conrad-digi-35-cpu/api.c | |
167 | endif | |
168 | if HW_DEMO | |
169 | libsigrok_la_SOURCES += \ | |
170 | hardware/demo/demo.c | |
171 | endif | |
172 | if HW_FLUKE_DMM | |
173 | libsigrok_la_SOURCES += \ | |
174 | hardware/fluke-dmm/fluke-dmm.h \ | |
175 | hardware/fluke-dmm/fluke.c \ | |
176 | hardware/fluke-dmm/api.c | |
177 | endif | |
178 | if HW_FX2LAFW | |
179 | libsigrok_la_SOURCES += \ | |
180 | hardware/fx2lafw/protocol.h \ | |
181 | hardware/fx2lafw/protocol.c \ | |
182 | hardware/fx2lafw/api.c | |
183 | endif | |
184 | if HW_GMC_MH_1X_2X | |
185 | libsigrok_la_SOURCES += \ | |
186 | hardware/gmc-mh-1x-2x/protocol.h \ | |
187 | hardware/gmc-mh-1x-2x/protocol.c \ | |
188 | hardware/gmc-mh-1x-2x/api.c | |
189 | endif | |
190 | if HW_HAMEG_HMO | |
191 | libsigrok_la_SOURCES += \ | |
192 | hardware/hameg-hmo/protocol.h \ | |
193 | hardware/hameg-hmo/protocol.c \ | |
194 | hardware/hameg-hmo/api.c | |
195 | endif | |
196 | if HW_HANTEK_DSO | |
197 | libsigrok_la_SOURCES += \ | |
198 | hardware/hantek-dso/dso.h \ | |
199 | hardware/hantek-dso/dso.c \ | |
200 | hardware/hantek-dso/api.c | |
201 | endif | |
202 | if HW_IKALOGIC_SCANALOGIC2 | |
203 | libsigrok_la_SOURCES += \ | |
204 | hardware/ikalogic-scanalogic2/protocol.h \ | |
205 | hardware/ikalogic-scanalogic2/protocol.c \ | |
206 | hardware/ikalogic-scanalogic2/api.c | |
207 | endif | |
208 | if HW_IKALOGIC_SCANAPLUS | |
209 | libsigrok_la_SOURCES += \ | |
210 | hardware/ikalogic-scanaplus/protocol.h \ | |
211 | hardware/ikalogic-scanaplus/protocol.c \ | |
212 | hardware/ikalogic-scanaplus/api.c | |
213 | endif | |
214 | if HW_KECHENG_KC_330B | |
215 | libsigrok_la_SOURCES += \ | |
216 | hardware/kecheng-kc-330b/protocol.h \ | |
217 | hardware/kecheng-kc-330b/protocol.c \ | |
218 | hardware/kecheng-kc-330b/api.c | |
219 | endif | |
220 | if HW_LASCAR_EL_USB | |
221 | libsigrok_la_SOURCES += \ | |
222 | hardware/lascar-el-usb/protocol.h \ | |
223 | hardware/lascar-el-usb/protocol.c \ | |
224 | hardware/lascar-el-usb/api.c | |
225 | endif | |
226 | if HW_LINK_MSO19 | |
227 | libsigrok_la_SOURCES += \ | |
228 | hardware/link-mso19/protocol.h \ | |
229 | hardware/link-mso19/protocol.c \ | |
230 | hardware/link-mso19/api.c | |
231 | endif | |
232 | if HW_MIC_985XX | |
233 | libsigrok_la_SOURCES += \ | |
234 | hardware/mic-985xx/protocol.h \ | |
235 | hardware/mic-985xx/protocol.c \ | |
236 | hardware/mic-985xx/api.c | |
237 | endif | |
238 | if HW_NORMA_DMM | |
239 | libsigrok_la_SOURCES += \ | |
240 | hardware/norma-dmm/protocol.h \ | |
241 | hardware/norma-dmm/protocol.c \ | |
242 | hardware/norma-dmm/api.c | |
243 | endif | |
244 | if HW_OLS | |
245 | libsigrok_la_SOURCES += \ | |
246 | hardware/openbench-logic-sniffer/protocol.h \ | |
247 | hardware/openbench-logic-sniffer/protocol.c \ | |
248 | hardware/openbench-logic-sniffer/api.c | |
249 | endif | |
250 | if HW_RIGOL_DS | |
251 | libsigrok_la_SOURCES += \ | |
252 | hardware/rigol-ds/protocol.h \ | |
253 | hardware/rigol-ds/protocol.c \ | |
254 | hardware/rigol-ds/api.c | |
255 | endif | |
256 | if HW_SALEAE_LOGIC16 | |
257 | libsigrok_la_SOURCES += \ | |
258 | hardware/saleae-logic16/protocol.h \ | |
259 | hardware/saleae-logic16/protocol.c \ | |
260 | hardware/saleae-logic16/api.c | |
261 | endif | |
262 | if HW_SERIAL_DMM | |
263 | libsigrok_la_SOURCES += \ | |
264 | hardware/serial-dmm/protocol.h \ | |
265 | hardware/serial-dmm/protocol.c \ | |
266 | hardware/serial-dmm/api.c | |
267 | endif | |
268 | if HW_SYSCLK_LWLA | |
269 | libsigrok_la_SOURCES += \ | |
270 | hardware/sysclk-lwla/lwla.h \ | |
271 | hardware/sysclk-lwla/lwla.c \ | |
272 | hardware/sysclk-lwla/protocol.h \ | |
273 | hardware/sysclk-lwla/protocol.c \ | |
274 | hardware/sysclk-lwla/api.c | |
275 | endif | |
276 | if HW_TELEINFO | |
277 | libsigrok_la_SOURCES += \ | |
278 | hardware/teleinfo/protocol.h \ | |
279 | hardware/teleinfo/protocol.c \ | |
280 | hardware/teleinfo/api.c | |
281 | endif | |
282 | if HW_TONDAJ_SL_814 | |
283 | libsigrok_la_SOURCES += \ | |
284 | hardware/tondaj-sl-814/protocol.h \ | |
285 | hardware/tondaj-sl-814/protocol.c \ | |
286 | hardware/tondaj-sl-814/api.c | |
287 | endif | |
288 | if HW_UNI_T_DMM | |
289 | libsigrok_la_SOURCES += \ | |
290 | hardware/uni-t-dmm/protocol.h \ | |
291 | hardware/uni-t-dmm/protocol.c \ | |
292 | hardware/uni-t-dmm/api.c | |
293 | endif | |
294 | if HW_UNI_T_UT32X | |
295 | libsigrok_la_SOURCES += \ | |
296 | hardware/uni-t-ut32x/protocol.h \ | |
297 | hardware/uni-t-ut32x/protocol.c \ | |
298 | hardware/uni-t-ut32x/api.c | |
299 | endif | |
300 | if HW_VICTOR_DMM | |
301 | libsigrok_la_SOURCES += \ | |
302 | hardware/victor-dmm/protocol.h \ | |
303 | hardware/victor-dmm/protocol.c \ | |
304 | hardware/victor-dmm/api.c | |
305 | endif | |
306 | if HW_ZEROPLUS_LOGIC_CUBE | |
307 | libsigrok_la_SOURCES += \ | |
308 | hardware/zeroplus-logic-cube/analyzer.c \ | |
309 | hardware/zeroplus-logic-cube/analyzer.h \ | |
310 | hardware/zeroplus-logic-cube/gl_usb.h \ | |
311 | hardware/zeroplus-logic-cube/gl_usb.c \ | |
312 | hardware/zeroplus-logic-cube/protocol.h \ | |
313 | hardware/zeroplus-logic-cube/protocol.c \ | |
314 | hardware/zeroplus-logic-cube/api.c | |
315 | endif | |
316 | ||
317 | libsigrok_la_LIBADD = $(LIBOBJS) | |
318 | ||
319 | libsigrok_la_LDFLAGS = $(SR_LIB_LDFLAGS) | |
320 | ||
321 | library_includedir = $(includedir)/libsigrok | |
322 | library_include_HEADERS = libsigrok.h proto.h version.h | |
323 | noinst_HEADERS = libsigrok-internal.h | |
324 | ||
325 | pkgconfigdir = $(libdir)/pkgconfig | |
326 | pkgconfig_DATA = libsigrok.pc | |
327 | ||
328 | EXTRA_DIST = \ | |
329 | Doxyfile \ | |
330 | HACKING \ | |
331 | README.devices \ | |
332 | contrib/gnuplot_chronovu_la8.gpi \ | |
333 | contrib/gnuplot_rigol_ds1xx2.gpi \ | |
334 | contrib/gnuplot_usbeesx.gpi \ | |
335 | contrib/gnuplot_usbeedx8.gpi \ | |
336 | contrib/gnuplot_usbeedx16.gpi \ | |
337 | contrib/sigrok-logo-notext.png \ | |
338 | contrib/z60_libsigrok.rules | |
339 | ||
340 | if HAVE_CHECK | |
341 | ||
342 | TESTS = tests/check_main | |
343 | ||
344 | check_PROGRAMS = ${TESTS} | |
345 | ||
346 | tests_check_main_SOURCES = \ | |
347 | libsigrok.h \ | |
348 | tests/lib.c \ | |
349 | tests/lib.h \ | |
350 | tests/check_main.c \ | |
351 | tests/check_core.c \ | |
352 | tests/check_input_all.c \ | |
353 | tests/check_input_binary.c \ | |
354 | tests/check_output_all.c \ | |
355 | tests/check_strutil.c \ | |
356 | tests/check_version.c \ | |
357 | tests/check_driver_all.c | |
358 | ||
359 | tests_check_main_CFLAGS = @check_CFLAGS@ | |
360 | ||
361 | tests_check_main_LDADD = $(top_builddir)/libsigrok.la @check_LIBS@ | |
362 | ||
363 | endif | |
364 | ||
365 | MAINTAINERCLEANFILES = ChangeLog | |
366 | ||
367 | .PHONY: ChangeLog | |
368 | ChangeLog: | |
369 | git --git-dir $(top_srcdir)/.git log > ChangeLog || touch ChangeLog | |
370 | ||
371 | dist-hook: ChangeLog | |
372 |