]>
Commit | Line | Data |
---|---|---|
62c82025 | 1 | ## |
50985c20 | 2 | ## This file is part of the libsigrok project. |
62c82025 | 3 | ## |
c73d2ea4 | 4 | ## Copyright (C) 2010-2012 Bert Vermeulen <bert@biot.com> |
d375b3c3 | 5 | ## Copyright (C) 2012 Alexandru Gagniuc <mr.nuke.me@gmail.com> |
62c82025 | 6 | ## |
a1bb33af UH |
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. | |
62c82025 | 11 | ## |
a1bb33af UH |
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. | |
62c82025 | 16 | ## |
a1bb33af UH |
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/>. | |
62c82025 | 19 | ## |
a1bb33af | 20 | |
d8521c93 | 21 | ACLOCAL_AMFLAGS = -I autostuff |
826938d8 | 22 | |
55e55a3f | 23 | AM_CPPFLAGS = -I$(srcdir)/src -DFIRMWARE_DIR='"$(FIRMWARE_DIR)"' |
340f6e7a | 24 | |
8a7b47cd | 25 | lib_LTLIBRARIES = libsigrok.la |
a1bb33af | 26 | |
67bd8055 | 27 | # Backend files |
a695d6c0 | 28 | libsigrok_la_SOURCES = \ |
155b680d BV |
29 | src/backend.c \ |
30 | src/device.c \ | |
31 | src/session.c \ | |
32 | src/session_file.c \ | |
33 | src/session_driver.c \ | |
34 | src/drivers.c \ | |
35 | src/hwdriver.c \ | |
36 | src/trigger.c \ | |
37 | src/soft-trigger.c \ | |
38 | src/strutil.c \ | |
39 | src/log.c \ | |
40 | src/version.c \ | |
41 | src/error.c \ | |
42 | src/std.c | |
960a75e4 | 43 | |
155b680d BV |
44 | # Input modules |
45 | libsigrok_la_SOURCES += \ | |
155b680d | 46 | src/input/input.c \ |
b84cba4d | 47 | src/input/binary.c \ |
02e24c0c | 48 | src/input/chronovu_la8.c \ |
41d214f6 | 49 | src/input/csv.c \ |
7db06394 | 50 | src/input/vcd.c \ |
155b680d | 51 | src/input/wav.c |
67bd8055 | 52 | |
155b680d BV |
53 | # Output modules |
54 | libsigrok_la_SOURCES += \ | |
55 | src/output/output.c \ | |
56 | src/output/analog.c \ | |
57 | src/output/ascii.c \ | |
58 | src/output/bits.c \ | |
59 | src/output/binary.c \ | |
60 | src/output/csv.c \ | |
61 | src/output/chronovu_la8.c \ | |
afaa75b9 | 62 | src/output/wav.c \ |
155b680d BV |
63 | src/output/gnuplot.c \ |
64 | src/output/hex.c \ | |
65 | src/output/ols.c \ | |
66 | src/output/vcd.c | |
67bd8055 | 67 | |
155b680d | 68 | # SCPI support |
67bd8055 | 69 | libsigrok_la_SOURCES += \ |
155b680d BV |
70 | src/scpi/scpi.c \ |
71 | src/scpi/scpi_tcp.c | |
67bd8055 UH |
72 | if NEED_RPC |
73 | libsigrok_la_SOURCES += \ | |
155b680d BV |
74 | src/scpi/scpi_vxi.c \ |
75 | src/scpi/vxi_clnt.c \ | |
76 | src/scpi/vxi_xdr.c \ | |
77 | src/scpi/vxi.h | |
67bd8055 UH |
78 | endif |
79 | if NEED_SERIAL | |
80 | libsigrok_la_SOURCES += \ | |
155b680d BV |
81 | src/serial.c \ |
82 | src/scpi/scpi_serial.c | |
67bd8055 UH |
83 | endif |
84 | if NEED_USB | |
85 | libsigrok_la_SOURCES += \ | |
155b680d BV |
86 | src/ezusb.c \ |
87 | src/usb.c \ | |
88 | src/scpi/scpi_usbtmc_libusb.c | |
67bd8055 UH |
89 | endif |
90 | if NEED_VISA | |
91 | libsigrok_la_SOURCES += \ | |
155b680d | 92 | src/scpi/scpi_visa.c |
67bd8055 | 93 | endif |
bb2a4ed4 ML |
94 | if NEED_GPIB |
95 | libsigrok_la_SOURCES += \ | |
7343ad1e | 96 | src/scpi/scpi_libgpib.c |
bb2a4ed4 | 97 | endif |
67bd8055 | 98 | |
155b680d BV |
99 | # Hardware (DMM chip parsers) |
100 | libsigrok_la_SOURCES += \ | |
101 | src/dmm/es519xx.c \ | |
102 | src/dmm/fs9721.c \ | |
103 | src/dmm/fs9922.c \ | |
104 | src/dmm/m2110.c \ | |
105 | src/dmm/metex14.c \ | |
a24c3f4a JH |
106 | src/dmm/rs9lcd.c \ |
107 | src/dmm/bm25x.c | |
67bd8055 UH |
108 | |
109 | # Hardware drivers | |
110 | if HW_AGILENT_DMM | |
111 | libsigrok_la_SOURCES += \ | |
155b680d BV |
112 | src/hardware/agilent-dmm/api.c \ |
113 | src/hardware/agilent-dmm/agilent-dmm.h \ | |
114 | src/hardware/agilent-dmm/sched.c | |
67bd8055 | 115 | endif |
67bd8055 UH |
116 | if HW_APPA_55II |
117 | libsigrok_la_SOURCES += \ | |
155b680d BV |
118 | src/hardware/appa-55ii/protocol.h \ |
119 | src/hardware/appa-55ii/protocol.c \ | |
120 | src/hardware/appa-55ii/api.c | |
67bd8055 UH |
121 | endif |
122 | if HW_ASIX_SIGMA | |
123 | libsigrok_la_SOURCES += \ | |
155b680d BV |
124 | src/hardware/asix-sigma/asix-sigma.h \ |
125 | src/hardware/asix-sigma/asix-sigma.c | |
67bd8055 UH |
126 | endif |
127 | if HW_ATTEN_PPS3XXX | |
128 | libsigrok_la_SOURCES += \ | |
155b680d BV |
129 | src/hardware/atten-pps3xxx/protocol.h \ |
130 | src/hardware/atten-pps3xxx/protocol.c \ | |
131 | src/hardware/atten-pps3xxx/api.c | |
67bd8055 | 132 | endif |
bb993797 KA |
133 | if HW_BEAGLELOGIC |
134 | libsigrok_la_SOURCES += \ | |
3db4b08b | 135 | src/hardware/beaglelogic/beaglelogic.h \ |
155b680d BV |
136 | src/hardware/beaglelogic/protocol.h \ |
137 | src/hardware/beaglelogic/protocol.c \ | |
138 | src/hardware/beaglelogic/api.c | |
bb993797 | 139 | endif |
67bd8055 UH |
140 | if HW_BRYMEN_BM86X |
141 | libsigrok_la_SOURCES += \ | |
155b680d BV |
142 | src/hardware/brymen-bm86x/protocol.h \ |
143 | src/hardware/brymen-bm86x/protocol.c \ | |
144 | src/hardware/brymen-bm86x/api.c | |
67bd8055 UH |
145 | endif |
146 | if HW_BRYMEN_DMM | |
147 | libsigrok_la_SOURCES += \ | |
155b680d BV |
148 | src/hardware/brymen-dmm/parser.c \ |
149 | src/hardware/brymen-dmm/protocol.h \ | |
150 | src/hardware/brymen-dmm/protocol.c \ | |
151 | src/hardware/brymen-dmm/api.c | |
67bd8055 UH |
152 | endif |
153 | if HW_CEM_DT_885X | |
154 | libsigrok_la_SOURCES += \ | |
155b680d BV |
155 | src/hardware/cem-dt-885x/protocol.h \ |
156 | src/hardware/cem-dt-885x/protocol.c \ | |
157 | src/hardware/cem-dt-885x/api.c | |
67bd8055 UH |
158 | endif |
159 | if HW_CENTER_3XX | |
160 | libsigrok_la_SOURCES += \ | |
155b680d BV |
161 | src/hardware/center-3xx/protocol.h \ |
162 | src/hardware/center-3xx/protocol.c \ | |
163 | src/hardware/center-3xx/api.c | |
67bd8055 | 164 | endif |
7b356712 | 165 | if HW_CHRONOVU_LA |
67bd8055 | 166 | libsigrok_la_SOURCES += \ |
155b680d BV |
167 | src/hardware/chronovu-la/protocol.h \ |
168 | src/hardware/chronovu-la/protocol.c \ | |
169 | src/hardware/chronovu-la/api.c | |
67bd8055 UH |
170 | endif |
171 | if HW_COLEAD_SLM | |
172 | libsigrok_la_SOURCES += \ | |
155b680d BV |
173 | src/hardware/colead-slm/protocol.h \ |
174 | src/hardware/colead-slm/protocol.c \ | |
175 | src/hardware/colead-slm/api.c | |
67bd8055 UH |
176 | endif |
177 | if HW_CONRAD_DIGI_35_CPU | |
178 | libsigrok_la_SOURCES += \ | |
155b680d BV |
179 | src/hardware/conrad-digi-35-cpu/protocol.h \ |
180 | src/hardware/conrad-digi-35-cpu/protocol.c \ | |
181 | src/hardware/conrad-digi-35-cpu/api.c | |
67bd8055 UH |
182 | endif |
183 | if HW_DEMO | |
184 | libsigrok_la_SOURCES += \ | |
155b680d | 185 | src/hardware/demo/demo.c |
67bd8055 UH |
186 | endif |
187 | if HW_FLUKE_DMM | |
188 | libsigrok_la_SOURCES += \ | |
155b680d BV |
189 | src/hardware/fluke-dmm/fluke-dmm.h \ |
190 | src/hardware/fluke-dmm/fluke.c \ | |
191 | src/hardware/fluke-dmm/api.c | |
67bd8055 UH |
192 | endif |
193 | if HW_FX2LAFW | |
194 | libsigrok_la_SOURCES += \ | |
155b680d BV |
195 | src/hardware/fx2lafw/protocol.h \ |
196 | src/hardware/fx2lafw/protocol.c \ | |
197 | src/hardware/fx2lafw/api.c | |
67bd8055 UH |
198 | endif |
199 | if HW_GMC_MH_1X_2X | |
200 | libsigrok_la_SOURCES += \ | |
155b680d BV |
201 | src/hardware/gmc-mh-1x-2x/protocol.h \ |
202 | src/hardware/gmc-mh-1x-2x/protocol.c \ | |
203 | src/hardware/gmc-mh-1x-2x/api.c | |
67bd8055 UH |
204 | endif |
205 | if HW_HAMEG_HMO | |
206 | libsigrok_la_SOURCES += \ | |
155b680d BV |
207 | src/hardware/hameg-hmo/protocol.h \ |
208 | src/hardware/hameg-hmo/protocol.c \ | |
209 | src/hardware/hameg-hmo/api.c | |
67bd8055 UH |
210 | endif |
211 | if HW_HANTEK_DSO | |
212 | libsigrok_la_SOURCES += \ | |
155b680d BV |
213 | src/hardware/hantek-dso/dso.h \ |
214 | src/hardware/hantek-dso/dso.c \ | |
215 | src/hardware/hantek-dso/api.c | |
67bd8055 UH |
216 | endif |
217 | if HW_IKALOGIC_SCANALOGIC2 | |
218 | libsigrok_la_SOURCES += \ | |
155b680d BV |
219 | src/hardware/ikalogic-scanalogic2/protocol.h \ |
220 | src/hardware/ikalogic-scanalogic2/protocol.c \ | |
221 | src/hardware/ikalogic-scanalogic2/api.c | |
67bd8055 UH |
222 | endif |
223 | if HW_IKALOGIC_SCANAPLUS | |
224 | libsigrok_la_SOURCES += \ | |
155b680d BV |
225 | src/hardware/ikalogic-scanaplus/protocol.h \ |
226 | src/hardware/ikalogic-scanaplus/protocol.c \ | |
227 | src/hardware/ikalogic-scanaplus/api.c | |
67bd8055 UH |
228 | endif |
229 | if HW_KECHENG_KC_330B | |
230 | libsigrok_la_SOURCES += \ | |
155b680d BV |
231 | src/hardware/kecheng-kc-330b/protocol.h \ |
232 | src/hardware/kecheng-kc-330b/protocol.c \ | |
233 | src/hardware/kecheng-kc-330b/api.c | |
67bd8055 UH |
234 | endif |
235 | if HW_LASCAR_EL_USB | |
236 | libsigrok_la_SOURCES += \ | |
155b680d BV |
237 | src/hardware/lascar-el-usb/protocol.h \ |
238 | src/hardware/lascar-el-usb/protocol.c \ | |
239 | src/hardware/lascar-el-usb/api.c | |
67bd8055 | 240 | endif |
8f4e922f UH |
241 | if HW_MANSON_HCS_3XXX |
242 | libsigrok_la_SOURCES += \ | |
155b680d BV |
243 | src/hardware/manson-hcs-3xxx/protocol.h \ |
244 | src/hardware/manson-hcs-3xxx/protocol.c \ | |
245 | src/hardware/manson-hcs-3xxx/api.c | |
8f4e922f | 246 | endif |
67bd8055 UH |
247 | if HW_MIC_985XX |
248 | libsigrok_la_SOURCES += \ | |
155b680d BV |
249 | src/hardware/mic-985xx/protocol.h \ |
250 | src/hardware/mic-985xx/protocol.c \ | |
251 | src/hardware/mic-985xx/api.c | |
67bd8055 | 252 | endif |
41b7bd01 MH |
253 | if HW_MOTECH_LPS_30X |
254 | libsigrok_la_SOURCES += \ | |
155b680d BV |
255 | src/hardware/motech-lps-30x/protocol.h \ |
256 | src/hardware/motech-lps-30x/protocol.c \ | |
257 | src/hardware/motech-lps-30x/api.c | |
41b7bd01 | 258 | endif |
67bd8055 UH |
259 | if HW_NORMA_DMM |
260 | libsigrok_la_SOURCES += \ | |
155b680d BV |
261 | src/hardware/norma-dmm/protocol.h \ |
262 | src/hardware/norma-dmm/protocol.c \ | |
263 | src/hardware/norma-dmm/api.c | |
67bd8055 | 264 | endif |
d4b38748 | 265 | if HW_OPENBENCH_LOGIC_SNIFFER |
67bd8055 | 266 | libsigrok_la_SOURCES += \ |
155b680d BV |
267 | src/hardware/openbench-logic-sniffer/protocol.h \ |
268 | src/hardware/openbench-logic-sniffer/protocol.c \ | |
269 | src/hardware/openbench-logic-sniffer/api.c | |
67bd8055 | 270 | endif |
4bd80e12 | 271 | if HW_PIPISTRELLO_OLS |
272 | libsigrok_la_SOURCES += \ | |
273 | src/hardware/pipistrello-ols/protocol.h \ | |
274 | src/hardware/pipistrello-ols/protocol.c \ | |
275 | src/hardware/pipistrello-ols/api.c | |
276 | endif | |
67bd8055 UH |
277 | if HW_RIGOL_DS |
278 | libsigrok_la_SOURCES += \ | |
155b680d BV |
279 | src/hardware/rigol-ds/protocol.h \ |
280 | src/hardware/rigol-ds/protocol.c \ | |
281 | src/hardware/rigol-ds/api.c | |
67bd8055 UH |
282 | endif |
283 | if HW_SALEAE_LOGIC16 | |
284 | libsigrok_la_SOURCES += \ | |
155b680d BV |
285 | src/hardware/saleae-logic16/protocol.h \ |
286 | src/hardware/saleae-logic16/protocol.c \ | |
287 | src/hardware/saleae-logic16/api.c | |
67bd8055 | 288 | endif |
ca1a7cb5 BV |
289 | if HW_SCPI_PPS |
290 | libsigrok_la_SOURCES += \ | |
291 | src/hardware/scpi-pps/protocol.h \ | |
292 | src/hardware/scpi-pps/protocol.c \ | |
d4eabea8 | 293 | src/hardware/scpi-pps/profiles.c \ |
ca1a7cb5 BV |
294 | src/hardware/scpi-pps/api.c |
295 | endif | |
67bd8055 UH |
296 | if HW_SERIAL_DMM |
297 | libsigrok_la_SOURCES += \ | |
155b680d BV |
298 | src/hardware/serial-dmm/protocol.h \ |
299 | src/hardware/serial-dmm/protocol.c \ | |
300 | src/hardware/serial-dmm/api.c | |
67bd8055 UH |
301 | endif |
302 | if HW_SYSCLK_LWLA | |
303 | libsigrok_la_SOURCES += \ | |
155b680d BV |
304 | src/hardware/sysclk-lwla/lwla.h \ |
305 | src/hardware/sysclk-lwla/lwla.c \ | |
306 | src/hardware/sysclk-lwla/protocol.h \ | |
307 | src/hardware/sysclk-lwla/protocol.c \ | |
308 | src/hardware/sysclk-lwla/api.c | |
67bd8055 UH |
309 | endif |
310 | if HW_TELEINFO | |
311 | libsigrok_la_SOURCES += \ | |
155b680d BV |
312 | src/hardware/teleinfo/protocol.h \ |
313 | src/hardware/teleinfo/protocol.c \ | |
314 | src/hardware/teleinfo/api.c | |
67bd8055 | 315 | endif |
0acdd793 BV |
316 | if HW_TESTO |
317 | libsigrok_la_SOURCES += \ | |
155b680d BV |
318 | src/hardware/testo/protocol.h \ |
319 | src/hardware/testo/protocol.c \ | |
320 | src/hardware/testo/api.c | |
0acdd793 | 321 | endif |
67bd8055 UH |
322 | if HW_TONDAJ_SL_814 |
323 | libsigrok_la_SOURCES += \ | |
155b680d BV |
324 | src/hardware/tondaj-sl-814/protocol.h \ |
325 | src/hardware/tondaj-sl-814/protocol.c \ | |
326 | src/hardware/tondaj-sl-814/api.c | |
67bd8055 UH |
327 | endif |
328 | if HW_UNI_T_DMM | |
329 | libsigrok_la_SOURCES += \ | |
155b680d BV |
330 | src/hardware/uni-t-dmm/protocol.h \ |
331 | src/hardware/uni-t-dmm/protocol.c \ | |
332 | src/hardware/uni-t-dmm/api.c | |
67bd8055 UH |
333 | endif |
334 | if HW_UNI_T_UT32X | |
335 | libsigrok_la_SOURCES += \ | |
155b680d BV |
336 | src/hardware/uni-t-ut32x/protocol.h \ |
337 | src/hardware/uni-t-ut32x/protocol.c \ | |
338 | src/hardware/uni-t-ut32x/api.c | |
67bd8055 UH |
339 | endif |
340 | if HW_VICTOR_DMM | |
341 | libsigrok_la_SOURCES += \ | |
155b680d BV |
342 | src/hardware/victor-dmm/protocol.h \ |
343 | src/hardware/victor-dmm/protocol.c \ | |
344 | src/hardware/victor-dmm/api.c | |
67bd8055 | 345 | endif |
10763937 SA |
346 | if HW_YOKOGAWA_DLM |
347 | libsigrok_la_SOURCES += \ | |
348 | src/hardware/yokogawa-dlm/protocol.h \ | |
349 | src/hardware/yokogawa-dlm/protocol.c \ | |
350 | src/hardware/yokogawa-dlm/protocol_wrappers.h \ | |
351 | src/hardware/yokogawa-dlm/protocol_wrappers.c \ | |
352 | src/hardware/yokogawa-dlm/api.c | |
353 | endif | |
67bd8055 UH |
354 | if HW_ZEROPLUS_LOGIC_CUBE |
355 | libsigrok_la_SOURCES += \ | |
155b680d BV |
356 | src/hardware/zeroplus-logic-cube/analyzer.c \ |
357 | src/hardware/zeroplus-logic-cube/analyzer.h \ | |
358 | src/hardware/zeroplus-logic-cube/gl_usb.h \ | |
359 | src/hardware/zeroplus-logic-cube/gl_usb.c \ | |
360 | src/hardware/zeroplus-logic-cube/protocol.h \ | |
361 | src/hardware/zeroplus-logic-cube/protocol.c \ | |
362 | src/hardware/zeroplus-logic-cube/api.c | |
67bd8055 UH |
363 | endif |
364 | ||
365 | libsigrok_la_LIBADD = $(LIBOBJS) | |
a1bb33af | 366 | |
6dddd902 | 367 | libsigrok_la_LDFLAGS = $(SR_LIB_LDFLAGS) |
eeebceea | 368 | |
45c59c8b | 369 | library_includedir = $(includedir)/libsigrok |
63d0fb75 ML |
370 | library_include_HEADERS = \ |
371 | include/libsigrok/libsigrok.h \ | |
372 | include/libsigrok/proto.h \ | |
373 | include/libsigrok/version.h | |
155b680d | 374 | noinst_HEADERS = src/libsigrok-internal.h |
a1bb33af | 375 | |
8a7b47cd UH |
376 | pkgconfigdir = $(libdir)/pkgconfig |
377 | pkgconfig_DATA = libsigrok.pc | |
d658e348 | 378 | |
67bd8055 UH |
379 | EXTRA_DIST = \ |
380 | Doxyfile \ | |
381 | HACKING \ | |
382 | README.devices \ | |
383 | contrib/gnuplot_chronovu_la8.gpi \ | |
384 | contrib/gnuplot_rigol_ds1xx2.gpi \ | |
385 | contrib/gnuplot_usbeesx.gpi \ | |
386 | contrib/gnuplot_usbeedx8.gpi \ | |
387 | contrib/gnuplot_usbeedx16.gpi \ | |
388 | contrib/sigrok-logo-notext.png \ | |
389 | contrib/z60_libsigrok.rules | |
390 | ||
391 | if HAVE_CHECK | |
392 | ||
393 | TESTS = tests/check_main | |
394 | ||
395 | check_PROGRAMS = ${TESTS} | |
396 | ||
397 | tests_check_main_SOURCES = \ | |
6592c369 | 398 | include/libsigrok/libsigrok.h \ |
67bd8055 UH |
399 | tests/lib.c \ |
400 | tests/lib.h \ | |
401 | tests/check_main.c \ | |
402 | tests/check_core.c \ | |
403 | tests/check_input_all.c \ | |
404 | tests/check_input_binary.c \ | |
405 | tests/check_output_all.c \ | |
41723529 | 406 | tests/check_session.c \ |
67bd8055 UH |
407 | tests/check_strutil.c \ |
408 | tests/check_version.c \ | |
409 | tests/check_driver_all.c | |
410 | ||
411 | tests_check_main_CFLAGS = @check_CFLAGS@ | |
412 | ||
413 | tests_check_main_LDADD = $(top_builddir)/libsigrok.la @check_LIBS@ | |
414 | ||
415 | endif | |
dd8b5f56 | 416 | |
580ed400 ML |
417 | BUILD_EXTRA = |
418 | INSTALL_EXTRA = | |
419 | CLEAN_EXTRA = | |
420 | ||
c23c8659 ML |
421 | if BINDINGS_CXX |
422 | ||
423 | lib_LTLIBRARIES += bindings/cxx/libsigrokxx.la | |
424 | ||
425 | bindings_cxx_libsigrokxx_la_SOURCES = bindings/cxx/classes.cpp | |
426 | ||
d1785122 | 427 | bindings_cxx_libsigrokxx_la_LIBADD = libsigrok.la $(glibmm_LIBS) |
c23c8659 ML |
428 | |
429 | bindings_cxx_libsigrokxx_la_LDFLAGS = $(SR_LIB_LDFLAGS) | |
430 | ||
431 | library_include_HEADERS += \ | |
432 | bindings/cxx/include/libsigrok/libsigrok.hpp \ | |
433 | bindings/cxx/include/libsigrok/enums.hpp | |
434 | ||
435 | pkgconfig_DATA += bindings/cxx/libsigrokxx.pc | |
436 | ||
3532ed01 | 437 | doxy/xml/index.xml: include/libsigrok/libsigrok.h |
7f82ec4d | 438 | $(AM_V_GEN)cd $(srcdir) && BUILDDIR=$(abs_builddir)/ doxygen Doxyfile 2>/dev/null |
580ed400 ML |
439 | |
440 | bindings/cxx/enums.cpp: bindings/cxx/enums.timestamp | |
441 | ||
442 | bindings/cxx/include/libsigrok/enums.hpp: bindings/cxx/enums.timestamp | |
c23c8659 | 443 | |
3532ed01 | 444 | bindings/cxx/enums.timestamp: bindings/cxx/enums.py doxy/xml/index.xml \ |
c23c8659 | 445 | bindings/cxx/ConfigKey_methods.cpp bindings/cxx/QuantityFlag_methods.cpp |
3532ed01 | 446 | $(AM_V_GEN)python $< doxy/xml/index.xml |
f2a189f0 | 447 | $(AM_V_at)touch $@ |
c23c8659 | 448 | |
580ed400 ML |
449 | bindings/cxx/classes.lo: bindings/cxx/classes.cpp bindings/cxx/enums.cpp \ |
450 | $(library_include_HEADERS) | |
c23c8659 | 451 | |
580ed400 | 452 | cxx-clean: |
3532ed01 | 453 | rm -rf doxy/ |
bd4fda24 | 454 | rm -rf bindings/cxx/doxy/ |
580ed400 ML |
455 | rm -f bindings/cxx/enums.cpp |
456 | rm -f bindings/cxx/include/libsigrok/enums.hpp | |
457 | rm -f bindings/cxx/enums.timestamp | |
c23c8659 | 458 | |
580ed400 ML |
459 | CLEAN_EXTRA += cxx-clean |
460 | ||
461 | endif | |
f7740954 | 462 | |
bd4fda24 ML |
463 | CPPXMLDOC = bindings/cxx/doxy/xml/index.xml |
464 | ||
465 | $(CPPXMLDOC): bindings/cxx/include/libsigrok/libsigrok.hpp \ | |
466 | bindings/cxx/enums.timestamp | |
33c84e81 | 467 | $(AM_V_GEN)cd $(srcdir)/bindings/cxx && BUILDDIR=$(abs_builddir)/bindings/cxx/ doxygen Doxyfile 2>/dev/null |
bd4fda24 | 468 | |
f7740954 ML |
469 | if BINDINGS_PYTHON |
470 | ||
d1785122 | 471 | PDIR = bindings/python |
bd4fda24 ML |
472 | PDOC = bindings/python/sigrok/core/doc.i |
473 | ||
474 | $(PDOC): bindings/swig/doc.py $(CPPXMLDOC) | |
0e1a7fe9 MC |
475 | $(AM_V_at)test -d $(PDIR)/sigrok/core || mkdir -p $(PDIR)/sigrok/core |
476 | $(AM_V_GEN)python $< python $(CPPXMLDOC) > $@ | |
d1785122 ML |
477 | |
478 | python-build: $(PDIR)/timestamp | |
479 | ||
c26162ff | 480 | python-quietclean: |
0e1a7fe9 | 481 | $(AM_V_at)cd $(PDIR) && python $(abs_srcdir)/$(PDIR)/setup.py --quiet clean --all 3>&1 1>&2 2>&3 \ |
c26162ff | 482 | | grep -v "can.t clean it"; true |
8eb10b62 | 483 | |
580ed400 | 484 | $(PDIR)/timestamp: bindings/cxx/libsigrokxx.la $(PDIR)/sigrok/core/classes.i \ |
bd4fda24 | 485 | bindings/swig/classes.i $(PDOC) $(library_include_HEADERS) |
c26162ff | 486 | $(AM_V_at)$(MAKE) python-quietclean |
0e1a7fe9 | 487 | $(AM_V_GEN)cd $(PDIR) && python $(abs_srcdir)/$(PDIR)/setup.py --quiet build 3>&1 1>&2 2>&3 \ |
c26162ff | 488 | | grep -v "command line option.*Wstrict-prototypes"; true |
f2a189f0 | 489 | $(AM_V_at)touch $(PDIR)/timestamp |
f7740954 ML |
490 | |
491 | python-install: | |
0e1a7fe9 | 492 | cd $(PDIR) && python $(abs_srcdir)/$(PDIR)/setup.py --quiet install --prefix $(prefix) |
f7740954 | 493 | |
c26162ff BV |
494 | python-clean: |
495 | $(AM_V_at)$(MAKE) python-quietclean | |
f2a189f0 | 496 | $(AM_V_at)rm -f $(PDIR)/timestamp |
6a8c1d68 ML |
497 | $(AM_V_at)rm -rf $(PDIR)/doxy/ |
498 | ||
499 | python-doc: | |
0e1a7fe9 | 500 | $(AM_V_at)cd $(srcdir)/$(PDIR) && BUILDDIR=$(abs_builddir)/$(PDIR)/ doxygen Doxyfile 2>/dev/null |
f7740954 ML |
501 | |
502 | BUILD_EXTRA += python-build | |
503 | INSTALL_EXTRA += python-install | |
504 | CLEAN_EXTRA += python-clean | |
505 | ||
506 | endif | |
507 | ||
9fcf4d0b ML |
508 | if BINDINGS_JAVA |
509 | ||
510 | JDIR = bindings/java | |
90bd7656 ML |
511 | JPKG = org/sigrok/core |
512 | JCLS = $(JDIR)/$(JPKG)/classes | |
513 | JINT = $(JDIR)/$(JPKG)/interfaces | |
33c84e81 | 514 | JSRC = $(JCLS)/*.java $(srcdir)/$(JINT)/*.java |
90bd7656 | 515 | JSWG = $(JCLS)/classes.i |
bd4fda24 | 516 | JDOC = $(JCLS)/doc.i |
90bd7656 | 517 | JCXX = $(JCLS)/classes_wrap.cxx |
9fcf4d0b ML |
518 | JLIB = $(JDIR)/libsigrok_java_core_classes.so |
519 | JJAR = $(JDIR)/sigrok-core.jar | |
520 | ||
521 | java-build: $(JJAR) $(JLIB) | |
522 | ||
bd4fda24 | 523 | $(JDOC): bindings/swig/doc.py $(CPPXMLDOC) |
33c84e81 MC |
524 | $(AM_V_at)test -d $(JCLS) || mkdir -p $(JCLS) |
525 | $(AM_V_GEN)python $< java $(CPPXMLDOC) > $@ | |
bd4fda24 ML |
526 | |
527 | $(JCXX): $(JSWG) $(JDOC) bindings/swig/classes.i $(library_include_HEADERS) | |
f1830b22 | 528 | $(AM_V_at)make java-clean |
f2a189f0 | 529 | $(AM_V_GEN)swig -c++ -java -package org.sigrok.core.classes \ |
33c84e81 | 530 | -I$(srcdir)/include -I$(srcdir)/bindings/cxx/include -I$(srcdir) -I$(JCLS) -Ibindings/cxx/include -outdir $(JCLS) -o $@ $< |
9fcf4d0b | 531 | |
90bd7656 | 532 | $(JJAR): $(JCXX) |
33c84e81 | 533 | $(AM_V_GEN)$(JAVAC) -sourcepath $(JDIR) -d $(JDIR) $(JSRC) |
f2a189f0 | 534 | $(AM_V_at)jar cf $(JJAR) -C $(JDIR) $(JPKG) |
9fcf4d0b | 535 | |
90bd7656 | 536 | $(JLIB): $(JCXX) bindings/cxx/libsigrokxx.la $(library_include_HEADERS) |
d1a5f737 | 537 | $(AM_V_GEN)$(CXXCOMPILE) -L.libs -Lbindings/cxx/.libs \ |
90bd7656 ML |
538 | -fno-strict-aliasing -fPIC -shared $(JCLS)/classes_wrap.cxx \ |
539 | -lsigrokxx -o $(JLIB) | |
9fcf4d0b ML |
540 | |
541 | java-install: | |
542 | $(INSTALL) -d $(libdir)/jni | |
543 | $(INSTALL) $(JLIB) -t $(libdir)/jni | |
544 | $(INSTALL) -d $(datadir)/java | |
545 | $(INSTALL) $(JJAR) -t $(datadir)/java | |
546 | ||
547 | java-clean: | |
2fe07d3f BV |
548 | $(AM_V_at)rm -f $(JCXX) |
549 | $(AM_V_at)rm -f $(JCLS)/*.java | |
550 | $(AM_V_at)rm -f $(JCLS)/*.class | |
551 | $(AM_V_at)rm -f $(JINT)/*.class | |
552 | $(AM_V_at)rm -f $(JJAR) | |
553 | $(AM_V_at)rm -f $(JLIB) | |
554 | $(AM_V_at)rm -rf $(JDIR)/doxy/ | |
8a314e90 ML |
555 | |
556 | java-doc: | |
33c84e81 | 557 | $(AM_V_at)cd $(srcdir)/$(JDIR) && BUILDDIR=$(abs_builddir)/$(JDIR)/ doxygen Doxyfile 2>/dev/null |
9fcf4d0b ML |
558 | |
559 | BUILD_EXTRA += java-build | |
560 | INSTALL_EXTRA += java-install | |
561 | CLEAN_EXTRA += java-clean | |
562 | ||
563 | endif | |
564 | ||
f7740954 ML |
565 | all-local: $(BUILD_EXTRA) |
566 | install-exec-local: $(INSTALL_EXTRA) | |
d1785122 | 567 | clean-local: $(CLEAN_EXTRA) |
f7740954 | 568 | |
c0958408 | 569 | MAINTAINERCLEANFILES = ChangeLog |
0fc12d66 UH |
570 | |
571 | .PHONY: ChangeLog | |
572 | ChangeLog: | |
bd58d8f3 | 573 | git --git-dir $(top_srcdir)/.git log > ChangeLog || touch ChangeLog |
0fc12d66 UH |
574 | |
575 | dist-hook: ChangeLog | |
576 |