-
Notifications
You must be signed in to change notification settings - Fork 18
/
Copy pathMakefile.am
1136 lines (952 loc) · 45.8 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
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
# Description: The Makefile (automake template) for the 42ity project.
# Note: relies on GNU make syntax and features, may fail to work in
# other make programs.
ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
AUTOMAKE_OPTIONS = color-tests parallel-tests
# success of the build depends on the value of the variable GREP_OPTIONS; so ignore it
unexport GREP_OPTIONS
# http://www.gnu.org/software/automake/manual/html_node/Basics-of-Distribution.html
# NOTE: "dist" is not "install": The dist rule in the Makefile can be used to
# generate a gzipped tar file and other flavors of archive for distribution.
# Sometimes there are files that must be distributed, but which are not covered
# in the automatic rules. These files should be listed in the EXTRA_DIST
# variable. You can mention files from subdirectories in EXTRA_DIST.
# You can also mention a directory in EXTRA_DIST; in this case the entire
# directory will be recursively copied into the distribution... you can
# use the dist-hook feature to filter the contents (remove ".svn/" etc).
EXTRA_DIST =
bin_PROGRAMS =
check_PROGRAMS =
check_LTLIBRARIES =
client_SCRIPTS =
noinst_LTLIBRARIES =
pkglib_LTLIBRARIES =
check_SCRIPTS =
noinst_PROGRAMS =
noinst_SCRIPTS =
dist_noinst_DATA =
# http://www.gnu.org/software/automake/manual/html_node/Built-Sources-Example.html
# http://www.gnu.org/software/automake/manual/html_node/Sources.html
# A source file listed in BUILT_SOURCES is made on `make all` or `make check`
# (or even `make install`) before other targets are processed. However, such
# a source file is not compiled unless explicitly requested by mentioning it
# in some other _SOURCES variable.
BUILT_SOURCES =
# http://www.gnu.org/software/automake/manual/html_node/Clean.html
# * If make built it, and it is commonly something that one would want to
# rebuild (for instance, a .o file), then mostlyclean should delete it.
# * Otherwise, if make built it, then clean should delete it.
# * If configure built it, then distclean should delete it.
CLEANFILES =
DISTCLEANFILES =
DISTCLEANDIRS =
# autoconf does not allow pkglib_PROGRAMS for some reason
clientdir = ${pkglibexecdir}
client_PROGRAMS =
helperdir = $(datadir)/@PACKAGE@/scripts
helper_SCRIPTS =
install-data-local: all-docs
# test programs executed by CI scripts
# lower-case var with actual list (so targets can be built by explicit request)
# upper-case var picked up by autotools, populated based on configure settings;
# its relevant "cibindir" is conditionally defined below
cibin_programs =
TESTS =
# Initialize some more variables
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA =
pkginclude_HEADERS =
lib_LTLIBRARIES =
# Named by analogy from configure'd myDOXDIR for doxygen
myDEVDOCDIR = docs/develop
# Locations of child Makefiles (generated by configure from .am via .in files)
SUBDIRS = docs/examples tools database/mysql
# Test data are also part of sources to redistribute
# The COPYING file is symlinked to from the license fixtures
EXTRA_DIST += COPYING
# ----------------------------------------------------------------------
# List of header files. The purpose of this list is not dependency
# tracking (which is automatic), but to ensure these files are
# distributed by "make dist" although not "installed".
dist_noinst_HEADERS =
# Clean up products of configure script
DISTCLEANFILES += \
$(addsuffix /Makefile.in,$(SUBDIRS) .) \
aclocal.m4 config.h.in config.h.in~ config.log \
m4/libtool.m4 \
m4/ltoptions.m4 \
m4/ltsugar.m4 \
m4/ltversion.m4 \
m4/lt~obsolete.m4 \
build-aux/compile* \
build-aux/config* \
build-aux/depcomp* \
build-aux/install* \
build-aux/ltmain* \
build-aux/missing* \
build-aux/test* \
autom4te.cache/output* \
autom4te.cache/traces* \
autom4te.cache/requests \
tests/CI/web/log/*.log
# These are deleted by "distclean-local-dirs" if they exist and are empty
# The "distclean-generic" with "rm DISTCLEANFILES" is a dependency for this
DISTCLEANDIRS += \
autom4te.cache \
build-aux \
config \
tests/CI/web/log
# recommended by daemon(7)
DISTCHECK_CONFIGURE_FLAGS = \
--with-systemdsystemunitdir=$$dc_install_base/$(systemdsystemunitdir) \
--with-systemdsystempresetdir=$$dc_install_base/$(systemdsystempresetdir) \
--with-systemdtmpfilesdir=$$dc_install_base/$(systemdtmpfilesdir)
#----------------------------------------------------------------------
# Tester for the doxygen output sanity
check_SCRIPTS += tools/run-test-doc.sh
# Needed at least for the distcheck (post distribution tests)
EXTRA_DIST += tools/run-test.sh
LOG_COMPILER = $(abs_top_srcdir)/tools/run-test.sh
#Test case examples:
#
#thisTestOnly Matches the test case called, 'thisTestOnly'
#"this test only" Matches the test case called, 'this test only'
#these* Matches all cases starting with 'these'
#exclude:notThis Matches all tests except, 'notThis'
#~notThis Matches all tests except, 'notThis'
#~*private* Matches all tests except those that contain 'private'
#a* ~ab* abc Matches all tests that start with 'a', except those that
# start with 'ab', except 'abc', which is included
#
#Names within square brackets are interpreted as tags. A series of tags form an AND expression wheras a comma-separated sequence forms an OR expression. e.g.:
#
#[one][two],[three]
# setup using AM_LOG_FLAGS see an example
# AM_LOG_FLAGS = ~[db]
# Do we build and install CI programs by default? (see configure)
cibin_programs_list := $(cibin_programs)
cibindir = ${pkgbindir}
if ENABLE_CI_TESTS
cibin_PROGRAMS = $(cibin_programs)
else
# Try to cheat automake into NOT building these programs on simple "make check"
cibin_PROGRAMS =
override cibin_programs =
endif
# These may be built explicitly, so should be removable in any case
CLEANFILES += $(cibin_programs_list)
TESTS += $(check_PROGRAMS)
TESTS += $(check_SCRIPTS)
client_SCRIPTS += tools/db-init
client_SCRIPTS += tools/systemctl tools/update-rc3
EXTRA_DIST += tools/systemctl tools/update-rc3
client_SCRIPTS += \
tools/bios-networking \
tools/fake-th \
tools/mount_usb \
tools/loghost-rsyslog \
tools/compress-logs \
tools/coredumper \
tools/verify-fs \
tools/diagnostic-information \
tools/start-db-services \
tools/fty-hostname-setup \
tools/fty-route \
tools/enable-root-account \
tools/disable-root-account \
tools/runas-_bios-script \
tools/run-user-script \
tools/run-ssh-action
helper_SCRIPTS += \
tools/tntnet-ExecStartPre.sh \
tools/envvars-ExecStartPre.sh \
tools/ssl-ExecStartPre.sh \
tools/generate-release-details.sh \
tools/factory-reset-live.sh \
tools/setup-nut-users-ExecStartPre.sh
EXTRA_DIST += tools/fake-th \
tools/bios-networking \
tools/mount_usb \
tools/diagnostic-information \
tools/generate-release-details.sh \
tools/loghost-rsyslog \
tools/compress-logs \
tools/coredumper \
tools/fty-hostname-setup \
tools/fty-route.in \
tools/enable-root-account.in \
tools/disable-root-account.in \
tools/runas-_bios-script \
tools/run-user-script.in \
tools/run-ssh-action.in
# Recipe needed to fulfill ci-rc-bios.sh logic
fake-th: tools/fake-th
exampleconfdir = $(datarootdir)/@PACKAGE@/examples
EXTRA_DIST += $(exampleconf_DATA)
CLEANFILES += tests/CI/tntnet.xml
# Another script is "@libexecdir@/@PACKAGE@/db-init" as required by the
# bios-db-init.service definition (installed into OS root /lib in CI builds).
# This is an optional target - without this script working (including the
# sudoers setup), the REST API tests involving password changes will fail.
ci_helper_SCRIPTS = tools/db-init tools/systemctl
ci_helperdir = $(clientdir)
# This wrapper now comes with two faces
ci_helper_SCRIPTS += tools/journalctl
tools/journalctl: tools/systemctl
rm -f $@; ln -s ./$(<F) $@
#----------------------------------------------------------------------
# Extra files and sources
#----------------------------------------------------------------------
# add CI tests to dist
EXTRA_DIST += $(top_srcdir)/tests/CI
# This will be removed from the OS image by the preinstallimage-bios.sh script
obsdir = $(datadir)/@PACKAGE@/obs
obs_SCRIPTS = obs/preinstallimage-bios.sh
EXTRA_DIST += $(obs_SCRIPTS)
ipc_meta_setupdir = $(datadir)/@PACKAGE@/setup/
# Note: use srcdir for verbatim scripts, builddir for templated .sh.in products
ipc_meta_setup_SCRIPTS = \
$(top_srcdir)/setup/01-bios-eula.sh \
$(top_srcdir)/setup/02-migrate-users-bios-script.sh \
$(top_srcdir)/setup/10-bios-gpio.sh \
$(top_srcdir)/setup/11-forget-bios-devsvcs-1.sh \
$(top_srcdir)/setup/11-mount-boot-noauto.sh \
$(top_srcdir)/setup/15-dpkg-database.everytime.sh \
$(top_srcdir)/setup/16-machineid-dir.everytime.sh \
$(top_srcdir)/setup/17-proxy-file.everytime.sh \
$(top_srcdir)/setup/20-fty-compat.sh \
$(top_srcdir)/setup/20-ipc-lcd-services.sh \
$(top_builddir)/setup/20-th-names.sh \
$(top_builddir)/setup/20-rcmysql-transient.sh \
$(top_srcdir)/setup/90-mylogin.everytime.sh \
$(top_srcdir)/setup/90-ntp-dhcp-conf.everytime.sh \
$(top_srcdir)/setup/90-nut-ownership.everytime.sh \
$(top_srcdir)/setup/90-sw-manifest.sh \
$(top_srcdir)/setup/91-logrotate-fty.sh \
$(top_srcdir)/setup/999-bios-pre-eula-target.everytime.sh \
$(top_srcdir)/setup/91-mmc-recovery.sh \
$(top_srcdir)/setup/ipc-meta-setup.sh
EXTRA_DIST += \
$(top_srcdir)/setup/01-bios-eula.sh \
$(top_srcdir)/setup/02-migrate-users-bios-script.sh \
$(top_srcdir)/setup/10-bios-gpio.sh \
$(top_srcdir)/setup/11-forget-bios-devsvcs-1.sh \
$(top_srcdir)/setup/11-mount-boot-noauto.sh \
$(top_srcdir)/setup/15-dpkg-database.everytime.sh \
$(top_srcdir)/setup/16-machineid-dir.everytime.sh \
$(top_srcdir)/setup/17-proxy-file.everytime.sh \
$(top_srcdir)/setup/20-fty-compat.sh \
$(top_srcdir)/setup/20-ipc-lcd-services.sh \
$(top_srcdir)/setup/20-th-names.sh.in \
$(top_srcdir)/setup/20-rcmysql-transient.sh.in \
$(top_srcdir)/setup/90-mylogin.everytime.sh \
$(top_srcdir)/setup/90-ntp-dhcp-conf.everytime.sh \
$(top_srcdir)/setup/90-nut-ownership.everytime.sh \
$(top_srcdir)/setup/90-sw-manifest.sh \
$(top_srcdir)/setup/91-logrotate-fty.sh \
$(top_srcdir)/setup/999-bios-pre-eula-target.everytime.sh \
$(top_srcdir)/setup/91-mmc-recovery.sh \
$(top_srcdir)/setup/ipc-meta-setup.sh
# SystemD integrations files; if not enabled - variables remain empty
SYSTEMD_UNITS_LOWLEVEL =
SYSTEMD_UNITS_EXTRA =
SYSTEMD_UNITS_TARGET_BIOS =
SYSTEMD_UNITS =
SYSTEMD_UNITS_NOTPRESET_LOWLEVEL =
SYSTEMD_UNITS_NOTPRESET_TARGET_BIOS =
SYSTEMD_UNITS_NOTPRESET =
SYSTEMD_UNITS_TIMERIMPL_LOWLEVEL =
SYSTEMD_UNITS_TIMERIMPL_TARGET_BIOS =
SYSTEMD_UNITS_TIMERIMPL =
SYSTEMD_TIMERS_LOWLEVEL =
SYSTEMD_TIMERS_TARGET_BIOS =
SYSTEMD_TIMERS =
SYSTEMD_PRESETS =
SYSTEMD_TARGETS =
# Preconfiguration for systemd-tmpfiles service to create needed paths
SYSTEMD_TMPFILES =
# The subdirectory in source (and build) tree where systemd unit files
# and their .in templates reside, starting from workspace (or build) root
# Note: No leading nor trailing slash is expected here!
SYSTEMD_SUBDIR = systemd
# systemd integration enabled?
if HAVE_SYSTEMD
# These units allow to toggle the entirety of 42ity agents and other related
# services on and off (except a few chosen low-level services that remain
# WantedBy=multi-user.target)
SYSTEMD_TARGETS += \
fty-license-accepted.target \
fty-db.target bios-pre-eula.target \
bios-allowed.target bios-shutdown.target \
bios.target bios.service bios-enabler-pre.service
# These units are not part of the common bios.target etc. but are to be
# considered rather a part of the operating environment independent of
# the 42ity high-level target groupings.
SYSTEMD_UNITS_LOWLEVEL += \
bios-reset-button.service \
ifplug-dhcp-autoconf.service \
bios-ssh-last-resort.service \
bios-networking.service \
ipc-meta-setup.service
# These are verbatim (not templated) additional units that wrap third-party
# service instances for us. TODO: should [email protected] move here?
SYSTEMD_UNITS_EXTRA += \
bios-allowed.service bios-shutdown.service \
fty-logrotate.service \
fty-monitor-unlock.service \
# These service-units are PartOf and WantedBy the "bios.target"
# And also "[email protected]" customized by obs/preinstall.sh
# to enable a "[email protected]" instance specifically.
# And also some of the timer units and implementations below
# Note that for packaging practice most are generated from .in templates
SYSTEMD_UNITS_TARGET_BIOS += \
fty-license-accepted.service \
fty-license-accepted.path \
fty-db-engine-pre.service \
fty-db-engine.service \
fty-db-init.service
# Here we list the actual service-definition files that should be compiled
# Enabled as part of 42ity presets
SYSTEMD_UNITS += $(SYSTEMD_UNITS_TARGET_BIOS) $(SYSTEMD_UNITS_LOWLEVEL)
# These units have unit files installed but are not enabled nor disabled
# by default via presets nor timers (may be enabled in OS image generation
# script or during deployment's lifetime).
# Note: Due to conflict with "[email protected]" file from tntnet package,
# we name ours differently here (and override during OS image generation).
SYSTEMD_UNITS_NOTPRESET_LOWLEVEL += \
bios-target-watchdog.service \
fty-hostname-setup.service
SYSTEMD_UNITS_NOTPRESET_TARGET_BIOS += \
fty-envvars.service \
SYSTEMD_UNITS_NOTPRESET += $(SYSTEMD_UNITS_NOTPRESET_LOWLEVEL) $(SYSTEMD_UNITS_NOTPRESET_TARGET_BIOS)
# These unit files are compiled, but are not enabled via 42ity presets
SYSTEMD_UNITS_TIMERIMPL_LOWLEVEL += \
biostimer-loghost-rsyslog-netconsole.service \
biostimer-compress-logs.service \
biostimer-verify-fs.service
SYSTEMD_UNITS_TIMERIMPL += $(SYSTEMD_UNITS_TIMERIMPL_LOWLEVEL) $(SYSTEMD_UNITS_TIMERIMPL_TARGET_BIOS)
# These files need no processing, delivered verbatim
# Enabled as part of 42ity presets
SYSTEMD_TIMERS_LOWLEVEL += \
biostimer-loghost-rsyslog-netconsole.timer \
biostimer-compress-logs.timer \
fty-logrotate.timer \
bios-target-watchdog.timer \
biostimer-verify-fs.timer
SYSTEMD_TIMERS += $(SYSTEMD_TIMERS_LOWLEVEL) $(SYSTEMD_TIMERS_TARGET_BIOS)
# This file is generated to toggle the defined units and targets
# (except those in SYSTEMD_UNITS_NOTPRESET list)
SYSTEMD_PRESETS += 42-bios-systemd.preset
SYSTEMD_TMPFILES += \
logfiles-rights.conf \
fty-core.conf \
fty-db-init.conf
### TODO? Add the build info (git commit, timestamp) to the header comment?
### NOTE: These lines are effectively applied in order, so it is safe although
### sub-efficient to simply enable everything and disable exceptions.
$(SYSTEMD_SUBDIR)/42-bios-systemd.preset: Makefile
@mkdir -p "$(abs_top_builddir)/$(SYSTEMD_SUBDIR)" "`dirname "$@"`" || true
@( echo "### This is a generated file with a list of all BIOS-related services with their default state"; \
for F in $(SYSTEMD_TARGETS) $(SYSTEMD_UNITS) $(SYSTEMD_TIMERS) ; do echo "enable $$F" ; done ) > $@
# The rules to actually "compile" the service definition files
# is part of catch-all %.in recipe above
# $(systemdsystemunitdir) and $(systemdsystempresetdir) may be defined
# externally by automake/autoconf; otherwise they are empty and should
# effectively resolve to the top_builddir
systemdsystemunit_generated = $(addprefix $(SYSTEMD_SUBDIR)/,$(SYSTEMD_UNITS) $(SYSTEMD_UNITS_TIMERIMPL) $(SYSTEMD_UNITS_NOTPRESET))
systemdsystemunit_DATA = $(systemdsystemunit_generated) $(addprefix $(SYSTEMD_SUBDIR)/,$(SYSTEMD_TIMERS) $(SYSTEMD_TARGETS) $(SYSTEMD_UNITS_EXTRA))
systemdsystempreset_generated = $(addprefix $(SYSTEMD_SUBDIR)/,$(SYSTEMD_PRESETS))
systemdsystempreset_DATA = $(systemdsystempreset_generated)
# Nothing generated so far for TMPFILES
systemdtmpfiles_DATA = $(addprefix $(SYSTEMD_SUBDIR)/,$(SYSTEMD_TMPFILES))
# auto-cleanup and dist targets
CLEANFILES += $(systemdsystemunit_generated) $(systemdsystempreset_generated)
EXTRA_DIST += $(addprefix $(top_srcdir)/$(SYSTEMD_SUBDIR)/,$(SYSTEMD_TIMERS) $(SYSTEMD_TARGETS) $(SYSTEMD_TMPFILES) $(SYSTEMD_UNITS_EXTRA) $(addsuffix .in,$(SYSTEMD_UNITS) $(SYSTEMD_UNITS_TIMERIMPL) $(SYSTEMD_UNITS_NOTPRESET)))
endif
# Quick links to build the systemd files (if enabled)
systemd-units: systemd-daemons systemd-timers systemd-presets systemd-targets systemd-tmpfiles
systemd-daemons: $(addprefix $(SYSTEMD_SUBDIR)/,$(SYSTEMD_UNITS) $(SYSTEMD_UNITS_NOTPRESET) $(SYSTEMD_UNITS_EXTRA))
systemd-timers: $(addprefix $(SYSTEMD_SUBDIR)/,$(SYSTEMD_UNITS_TIMERIMPL))
if [ x"$(abs_top_builddir)/" = x"$(abs_top_srcdir)/" ] ; then true; else \
mkdir -p "$(abs_top_builddir)/$(SYSTEMD_SUBDIR)"; \
for F in $(addprefix $(abs_top_srcdir)/$(SYSTEMD_SUBDIR)/,$(SYSTEMD_TIMERS)) ; do \
$(call copy-file,$$F,$(abs_top_builddir)/$(SYSTEMD_SUBDIR)/) || exit $$?; \
done; fi
systemd-presets: $(addprefix $(SYSTEMD_SUBDIR)/,$(SYSTEMD_PRESETS))
systemd-targets: $(addprefix $(SYSTEMD_SUBDIR)/,$(SYSTEMD_TARGETS))
systemd-tmpfiles: $(addprefix $(SYSTEMD_SUBDIR)/,$(SYSTEMD_TMPFILES))
clean-systemd-units:
@if [ x"$(abs_top_builddir)/" != x"$(abs_top_srcdir)/" ] ; then \
if [ -n "$(SYSTEMD_TIMERS)" ]; then \
$(RM) $(addprefix $(abs_top_builddir)/$(SYSTEMD_SUBDIR)/,$(SYSTEMD_TIMERS)) ; fi ; \
if [ -n "$(SYSTEMD_TARGETS)" ]; then \
$(RM) $(addprefix $(abs_top_builddir)/$(SYSTEMD_SUBDIR)/,$(SYSTEMD_TARGETS)) ; fi ; \
fi || true
#----------------------------------------------------------------------
# list of text-based documentation files (rules below)
# Note that the basic filenames in these variables are relative to the
# project sources' root directory, but later in usage and actual targets
# they are prefixed by the build directory (which may or may not be the
# same as the checked-out source directory, both ways SHOULD work).
#----------------------------------------------------------------------
# For legacy/simplicity several types of file list variables are defined
# below to reference the manually maintained and repository-tracked files
# with documentation in text format, including the sources for automated
# conversion from asciidoc to html (i.e. not doxygen, not manpages).
# See comments below for path/extension expectations for different file types.
# Variables below include:
#
# Auto-generated:
# TEXTS - list of *.txt files that are delivered by the project. Generated
# from MAPPED_TXT_DOCS_* lists. Required by "docs-txt" target.
# HTMLS_ASCIIDOC - list of files generated automatically from asciidoc
# into HTML (1:1 relation, same dirname/basename, changes extension);
# the list is generated from MAPPED_TXT_DOCS_ASCIIDOC.
# HTMLS - list of *.html files (except doxygen) that are delivered by the
# project (built via target rules if needed); currently this only
# includes HTMLS_ASCIIDOC. Required by "docs-html" target.
# CLEAN_TEXTS and CLEAN_HTMLS - list of files generated/copied by dynamic
# rules lower in this Makefile, so they can be cleaned up too.
#
# Half-manual, half automation:
# MAPPED_TXT_DOCS_PLAINTEXT and MAPPED_TXT_DOCS_ASCIIDOC - lists of all
# colon-separated couples of source and destination text filenames
# which may involve a copy to another directory, another naming,
# changes of extension, etc. Populated manually and then from the
# other lists (BASE_DOCS_*, TXT_DOCS_*) with simple deterministic
# conversion rules from list to mapping entry. These mappings are
# used to dynamically determine make-recipes and targets for files.
#
# Component lists (populated manually, reprocessed into MAPPED_* lists);
# Note that these lists reference files tracked as part of the project
# sources (not auto-copied, named or generated as in some lists above):
# BASE_DOCS_ASCIIDOC and BASE_DOCS_PLAINTEXT - the text files without
# extension, saved in the root of project sources. These variables
# are used to populate the relevant MAPPED_TXT_DOCS_* lists.
# TXT_DOCS_ASCIIDOC and TXT_DOCS_PLAINTEXT - lists of *.txt files that
# would actually be installed; as seen below, the list starts with
# some files already tracked in the needed location (under docs/).
# These variables are used to populate MAPPED_TXT_DOCS_* lists.
#
# The definition/processing order should be as follows:
# * Populate the manually tracked lists (BASE_DOCS_*, TXT_DOCS_*) and the
# initial entries in MAPPED_TXT_DOCS_* (set those mappings which rename
# text files from tracked source to delivery under "docs/develop/").
# * Define as empty (or very exceptionally pre-populated) the lists in
# HTMLS_ASCIIDOC, HTMLS, TEXTS as well as automated installation targets
# like develdoc_DATA.
# * Run macros to populate the rest of MAPPED_TXT_DOCS_* with trivial
# conversions from BASE_DOCS_* and TXT_DOCS_*.
# * Run macros to define the build targets and recipes for all text files
# (copying) and add to our targets (TEXTS) and other common lists like
# EXTRA_DIST and DISTCLEAN automatically.
# * Run macros to define the build targets and recipes for the HTML files
# created from texts by asciidoc (append to HTMLS_ASCIIDOC).
# * Add the resulting HTMLS_ASCIIDOC to HTMLS.
# * Define the practical targets - to build or clean the whole set of our
# documentation files.
# Documentation files saved in the project source-code root directory
# as text files without extensions in the name (following GNU standards)
# and written in asciidoc markup
# Note these should have paths relative to project root dir.
BASE_DOCS_ASCIIDOC = INSTALL INSTALL-referenceOS-debian8 \
CONTRIBUTING
# Documentation files saved in the project source-code root directory
# as text files without extensions in the name and written in plain
# text with no expected transformation
# Note these should have paths relative to project root dir.
BASE_DOCS_PLAINTEXT = AUTHORS COPYING NEWS ChangeLog
# These two seem to have some markup or similar structuring,
# but it is not asciidoc so consider them plaintext for now.
# Note these should have paths relative to project root dir.
BASE_DOCS_PLAINTEXT += TODO
# The following files are saved into proper subdirectories, have an
# extension in the filename, and contain asciidoc markup.
# Note these should have paths relative to project root dir.
TXT_DOCS_ASCIIDOC = $(myDEVDOCDIR)/README-builder.txt \
$(myDEVDOCDIR)/README-init-os-accounts.txt
# List of text files that are installed as is (none so far, but see
# below for MAPPED_TXT_DOCS_ASCIIDOC and MAPPED_TXT_DOCS_PLAINTEXT)
TXT_DOCS_PLAINTEXT =
#----------------------------------------------------------------------
# List of source texts dispersed in the code with automated targeting
#----------------------------------------------------------------------
# The list below is a colon-separated map of filenames copied from
# sources relative to project root (first token) into different names
# under the builddir and final installation (the second token, here
# copied into "docs/develop"), and also maybe compiled into HTML
# (as in case of the _ASCIIDOC list).
# Filenames here should not have spaces and should have the '.txt' suffix.
MAPPED_TXT_DOCS_PLAINTEXT =
MAPPED_TXT_DOCS_ASCIIDOC =
#################################################################
# Items below are intended for automatic generation and appendage
#################################################################
# Historically some original docs have *.txt names and some don't
# but we solve it by having a target to ensure presence of *.txt
# copies now for all needed files in the same docs directory
# See the MAPPED_TXT_DOCS_ASCIIDOC parsing around this Makefile.
# Here we predefine the HTMLS_ASCIIDOC list as anything that is
# not converted from the MAPPED_TXT_DOCS_ASCIIDOC list, so empty.
HTMLS_ASCIIDOC =
abs_HTMLS_ASCIIDOC =
# Ultimate list of HTMLs from generally many sources (except doxygen,
# since that list of targets is not known in advance). Predefined (and
# empty) here, appended later on. Similarly for ultimate text files.
HTMLS =
TEXTS =
# These variables track the compiled/generated/etc. text/html files
# so they can be removed in *clean requests
CLEAN_HTMLS =
CLEAN_TEXTS =
##################################################
# Define delivery of developer documentation:
##################################################
# Target directory for developer documentation after installation
develdocdir = $(datadir)/@PACKAGE@/develop
# Install the non-doxygen docs here (doxygen has its subdir defined below).
# Text files are "originals" or copies under a different name and are always
# expected to be available (to fail the make otherwise is correct action).
# Note that other HTML component targets must be listed explicitly as they
# might appear in the project later on; as for example HTMLS_ASCIIDOC needs
# a conditional enablement (try install only if generatable at all).
# Like above, this list is initially empty (or maybe explicit later on)
# and is appended by some macros below.
develdoc_DATA =
###----------------------------------------------------------------------
### Magic macros to expand the patterns for text to text file copying
###----------------------------------------------------------------------
# Magic below inspired by this blog post (see description/comments):
# http://blog.jgc.org/2012/01/using-gnu-makes-define-and-eval-to.html
# Copies from "$1" to "$2", making the subdirectories as needed
define copy-file-cp
if test x"$(2)" != x"$(1)" ; then \
{ test -d "`dirname "$(2)"`" || mkdir -p "`dirname "$(2)"`"; } && \
echo " CP '$(1)' -> '$(2)'" >&2 && \
cp -pf "$(1)" "$(2)" || cp -f "$(1)" "$(2)"; \
else \
echo "Not copying '$(1)' -> '$(2)': same file" >&2 E; \
fi
endef
# Another way to skin the cat...
# Note that install program by itself reports the 'SRC' -> 'DST" message
define copy-file-install
$(INSTALL) -D -T -p -v -m 644 "$1" "$2"
endef
# Generalize the two solutions
define copy-file
$(call copy-file-install,$1,$2) || $(call copy-file-cp,$1,$2)
endef
# This macro defines the dependencies and rules to copy the text file
# into the build area. Also adds the filename into lists for install,
# cleanup, ultimately used dependencies, etc.
define depend-copy-file
$(eval override _CP_MAP_SRC_REL := $(firstword $(subst :, ,$(1))) )
$(eval override _CP_MAP_DST_REL := $(word 2,$(subst :, ,$(1))) )
$(eval override _CP_MAP_SRC_ABS := $(addprefix $(abs_top_srcdir)/,$(_CP_MAP_SRC_REL)) )
$(eval override _CP_MAP_DST_ABS := $(addprefix $(abs_top_builddir)/,$(_CP_MAP_DST_REL)) )
# Define the dependency and the rule
$(_CP_MAP_DST_ABS): $(_CP_MAP_SRC_ABS)
@$$(call copy-file,$$<,$$@)
# Fake dependency for subdir/dist builds
$(_CP_MAP_DST_REL): $(_CP_MAP_DST_ABS)
@#echo "DEBUG-MAKEFILE-FAKEDEP: Mapped target '$$@' to source '$$<'"
### Target as a text file
$(eval TEXTS += $(_CP_MAP_DST_REL) )
### Copy for installation:
$(eval develdoc_DATA += $(_CP_MAP_DST_REL) )
### Copy in make dist
$(eval EXTRA_DIST += $(_CP_MAP_SRC_REL) )
endef
define canclean-txt-file
$(eval override _CLEAN_MAP_SRC_REL := $(firstword $(subst :, ,$(1))) )
$(eval override _CLEAN_MAP_DST_REL := $(word 2,$(subst :, ,$(1))) )
### Cleanup in build
$(eval CLEANFILES += $(_CLEAN_MAP_DST_REL) )
$(eval CLEAN_TEXTS += $(_CLEAN_MAP_DST_REL) )
endef
# Convert the simple lists defined above into the common mapping tables
# for unprocessable and for asciidoc-able text files:
$(foreach m,$(BASE_DOCS_ASCIIDOC), \
$(eval MAPPED_TXT_DOCS_ASCIIDOC += ${m}:${myDEVDOCDIR}/${m}.txt ))
$(foreach m,$(BASE_DOCS_PLAINTEXT), \
$(eval MAPPED_TXT_DOCS_PLAINTEXT += ${m}:${myDEVDOCDIR}/${m}.txt ))
# Add to automatic removal ONLY the files which are relocated while mapping
# That is, TXT_DOCS_* which remain in-place should not be removed (i.e. the
# originals during an in-tree build)
$(foreach m,$(MAPPED_TXT_DOCS_PLAINTEXT) $(MAPPED_TXT_DOCS_ASCIIDOC), \
$(eval $(call canclean-txt-file,$(m))))
# Convert the 1:1 simple lists defined above into the common mapping tables
# for unprocessable and for asciidoc-able text files:
$(foreach m,$(TXT_DOCS_ASCIIDOC), \
$(eval MAPPED_TXT_DOCS_ASCIIDOC += ${m}:${m} ))
$(foreach m,$(TXT_DOCS_PLAINTEXT), \
$(eval MAPPED_TXT_DOCS_PLAINTEXT += ${m}:${m} ))
# Finally, run the logic for patterns that define file-copying
# Note that for 1:1 mapped files there may be harmless messages like
# "make: Circular...dependency dropped." during an in-directory build.
$(foreach m,$(MAPPED_TXT_DOCS_PLAINTEXT) $(MAPPED_TXT_DOCS_ASCIIDOC), \
$(eval $(call depend-copy-file,$(m))))
##################################################
# The stuff HTML docs are made of...
# Similar activity for ASCIIDOC-HTML mapping
# The dependencies for the text file via patterns in the standard dir
# were defined above. Now just add the dependency for HTML building
# into the same basename...
# Per dependencies, all the text files should be available in the
# builddir/docs/develop/*.txt and the *.html will appear nearby
define compile-asciidoc-to-html
if HAVE_ASCIIDOC
@test -d "`dirname $(2)`" || mkdir -p "`dirname $(2)`"
@echo " ASCIIDOC '$(1)' -> '$(2)'" >&2
@touch $(2)
$(ASCIIDOC) -b html -o $(2) $(1)
else
@echo "SKIP: Missing 'asciidoc' program, generic HTML documentation generation skipped for '$(1)' -> '$(2)'!" >&2
endif
endef
define depend-txt-html
$(eval override _TH_MAP_DST_REL := $(word 2,$(subst :, ,$(1))) )
$(eval override _TH_HTML_DST_REL := $(_TH_MAP_DST_REL:%.txt=%.html) )
$(eval override _TH_MAP_DST_ABS := $(addprefix $(abs_top_builddir)/,$(_TH_MAP_DST_REL)) )
$(eval override _TH_HTML_DST_ABS := $(addprefix $(abs_top_builddir)/,$(_TH_HTML_DST_REL)) )
# Define the dependency and the rule
$(_TH_HTML_DST_ABS): $(_TH_MAP_DST_ABS)
@#echo "DEBUG-MAKEFILE-FAKEDEP-ABS: Mapped target '$$@' to source '$$<' ; _TH_HTML_DST_REL='$(_TH_HTML_DST_REL)' _TH_HTML_DST_ABS='$(_TH_HTML_DST_ABS)'"
@$$(call compile-asciidoc-to-html,$$<,$$@)
# Fake dependency for subdir/dist builds
$(_TH_HTML_DST_REL): $(_TH_HTML_DST_ABS)
@#echo "DEBUG-MAKEFILE-FAKEDEP-REL: Mapped target '$$@' to source '$$<'"
$(eval CLEAN_HTMLS += $(_TH_HTML_DST_REL) )
$(eval HTMLS_ASCIIDOC += $(_TH_HTML_DST_REL) )
$(eval abs_HTMLS_ASCIIDOC += $(_TH_HTML_DST_ABS) )
endef
# Some HTMLS_ASCIIDOCs may have been defined above, maybe with other recipes
# Convert the remainder of HTMLS_ASCIIDOC from MAPPED_TXT_DOCS_ASCIIDOC
$(foreach m,$(MAPPED_TXT_DOCS_ASCIIDOC), $(eval $(call depend-txt-html,$(m))))
# NOTE: The HTMLS list holds relative pathnames used in other recipes
# But _DATA installs and CLEANups prefer less ambiguity with absolute names
if HAVE_ASCIIDOC
HTMLS += $(HTMLS_ASCIIDOC)
develdoc_DATA += $(addprefix $(abs_top_builddir)/,$(HTMLS_ASCIIDOC))
CLEANFILES += $(addprefix $(abs_top_builddir)/,$(HTMLS_ASCIIDOC))
#develdoc_DATA += $(abs_HTMLS_ASCIIDOC)
#CLEANFILES += $(abs_HTMLS_ASCIIDOC)
#develdoc_DATA += $(HTMLS_ASCIIDOC)
#CLEANFILES += $(HTMLS_ASCIIDOC)
endif
#----------------------------------------------------------------------
# One rule to generate and wipe documentation
#----------------------------------------------------------------------
all-docs: html-docs txt-docs
# man-docs doxygen-docs
# alias for manual typing errors
docs-all: all-docs
clean-docs: clean-html clean-txt
# clean-man clean-doxygen
#----------------------------------------------------------------------
# text to text copying
# Some documents are by GNU standard stored in project root, and we
# want to deliver them to common docs/devel subdirectory in install.
#----------------------------------------------------------------------
# A copy of TXT_DOCS_ASCIIDOC in the build area is needed for unified
# rules of asciidoc to html parsing, defined below; see MAPPED_* above.
txt-docs: $(addprefix $(abs_top_builddir)/,$(TEXTS))
# alias for manual typing errors
docs-txt: txt-docs
clean-txt: clean-txt-built clean-txt-txt_docs
clean-txt-built:
/bin/rm -f $(addprefix $(abs_top_builddir)/,$(CLEAN_TEXTS))
# Only clean up the copies in the builddir, if applicable
# Do not kill the originals in the source tree
clean-txt-txt_docs:
if test x"$(abs_top_srcdir)" != x"$(abs_top_builddir)" -a \
x"$(abs_top_srcdir)" != x -a x"$(abs_top_builddir)" != x ; then \
/bin/rm -f $(addprefix $(abs_top_builddir)/,$(TXT_DOCS_ASCIIDOC) $(TXT_DOCS_PLAINTEXT)); \
else true; fi
#----------------------------------------------------------------------
# asciidoc html generation
#----------------------------------------------------------------------
# Technically we only implement building of HTMLS_ASCIIDOC now.
# If others appear and are not handled, they will fail to make.
# That is a good thing by design - we'll know to add more logic ;)
html-docs: txt-docs $(addprefix $(abs_top_builddir)/,$(HTMLS))
# alias for manual typing errors
docs-html: html-docs
clean-html:
/bin/rm -f $(addprefix $(abs_top_builddir)/,$(CLEAN_HTMLS))
#----------------------------------------------------------------------
# doxygen html generation
# Note that unlike many other targets, doxygen seemingly has to use
# relative paths and be generated in a directory near the source code
#----------------------------------------------------------------------
#if HAVE_DOXYGEN
#EXTRA_DIST += $(top_srcdir)/${myDOXDIR}/html
#BUILT_SOURCES += $(top_srcdir)/${myDOXDIR}/html
#endif
#EXTRA_DIST += $(top_srcdir)/${myDOXDIR}/Doxyfile.in
CLEANFILES += $(top_srcdir)/${myDOXDIR}/doxygen_sqlite3.db \
$(top_srcdir)/${myDOXDIR}/${mydoxylog} \
${myDOXDIR}/doxygen_sqlite3.db \
${myDOXDIR}/Doxyfile \
${myDOXDIR}/${mydoxylog}
#$(top_srcdir)/${myDOXDIR}/html: $(abs_top_srcdir)/${myDOXDIR}/html
#doxygen-docs: $(abs_top_srcdir)/${myDOXDIR}/html
# alias for manual typing errors
#docs-doxygen: doxygen-docs
clean-doxygen:
( test -w $(abs_top_srcdir)/${myDOXDIR}/html && \
/bin/rm -rf $(abs_top_srcdir)/${myDOXDIR}/html ) || /bin/true
# Copy generated contents of "docs/doxygen/" into "/usr/share/core.../doxygen"
#develdocdoxygendir = $(develdocdir)/doxygen
#develdocdoxygen: doxygen-docs
#if HAVE_DOXYGEN
#develdocdoxygen_DATA = ${myDOXDIR}/html/*
#
# Such-named target is required by the _DATA above, so have a rule to build it
#${myDOXDIR}/html/*: doxygen-docs
#$(abs_top_builddir)/${myDOXDIR}/Doxyfile: ${myDOXDIR}/Doxyfile $(abs_top_builddir)/Makefile
#
#$(abs_top_srcdir)/${myDOXDIR}/html: $(abs_top_builddir)/${myDOXDIR}/Doxyfile
# @test -d $(abs_top_srcdir)/${myDOXDIR}/html || \
# { cd $(abs_top_srcdir)/ && \
# echo "INFO: Generating Doxygen docs in '`pwd`' according to '$<'" >&2 && \
# $(DOXYGEN) "$<"; }
# @touch -r "$<" "$@" || true
#else
#develdocdoxygen_DATA =
#
#${myDOXDIR}/html/*: $(abs_top_srcdir)/${myDOXDIR}/html
#
#$(abs_top_srcdir)/${myDOXDIR}/html:
# @echo "SKIP: Missing 'doxygen' program, sourcecode-documentation generation skipped!" >&2
#endif
#----------------------------------------------------------------------
# manpage generation (delegated to sub-make)
#----------------------------------------------------------------------
#EXTRA_DIST += $(top_srcdir)/${myMANDIR}/*.txt
#CLEANFILES += $(abs_top_builddir)/${myMANDIR}/*.?
#man-docs:
# ( cd $(abs_top_builddir)/$(myMANDIR) && $(MAKE) all )
# alias for manual typing errors
#docs-man: man-docs
#clean-man:
# ( cd $(abs_top_builddir)/$(myMANDIR) && \
# { $(MAKE) clean || /bin/true; } && \
# /bin/rm -f *.[123456789] *.xml *.html )
# /bin/rm -f $(abs_top_builddir)/$(myMANDIR)/*.?
#----------------------------------------------------------------------
# hook for make all => generate files too
#----------------------------------------------------------------------
all-local: all-docs .git_details-fty-core .git_details systemd-units
# Try to build everything buildable, e.g. for further warning counters
all-buildproducts: all
# Note: variable cibin_PROGRAMS may be empty if not enabled via configure
# The variable cibin_programs holds the actual list of CI programs instead
if ENABLE_CI_TESTS
cibin_PROGRAMS: $(cibin_PROGRAMS)
else
cibin_PROGRAMS:
endif
cibin_programs: $(cibin_programs_list)
#----------------------------------------------------------------------
# hook for make check custom verifications
#----------------------------------------------------------------------
# Run compile/link tests defined in this Makefile
# Note that check-gitignore should be the last target
# FIXME: "check-pool" temporarily not included into "check-local", see below
check-local: check-gitignore
# If git repo details are not available, or git program does not exist,
# or if everything is properly GitIgnored - then succeed
# If some not-gitignored files are found, then fail
check-gitignore: all-buildproducts
@(if [ x"$(SKIP_MAKE_CHECK_GITIGNORE)" \!= xno ]; then \
echo "SKIP: $@ (by implicit SKIP_MAKE_CHECK_GITIGNORE=yes)"; exit 0 ; \
else \
if which git >/dev/null 2>&1 ; then \
git status -s | egrep '^\?\? ' && \
echo "FAIL: $@" && exit 1; \
echo "PASS: $@"; exit 0 ; \
fi ; \
echo "SKIP: $@ (no git)"; exit 0 ; \
fi )
clean-junit:
/bin/rm -rf $(abs_top_builddir)/tests/junit
clean-local: clean-systemd-units clean-junit
# This may and should complain on non-empty dirs; "distclean-generic"
# with proper list of DISTCLEANFILES should have taken care of that
distclean-local-dirs: distclean-generic
for D in $(addprefix $(abs_top_builddir)/,$(DISTCLEANDIRS)); do \
[ ! -d "$$D" ] || /bin/rmdir "$$D"; done || true
distclean-local-deps: distclean-generic
cd $(abs_top_builddir)/ && { \
find . -type f -name '*.Plo' -exec /bin/rm -f '{}' \; ; \
find . -type f -name '*.Po' -exec /bin/rm -f '{}' \; ; \
find . -type d -name '.deps' -exec /bin/rmdir '{}' \; || true ; \
}
# BUILDER_RETAIN_CONFIGURE=yes may be exported by builder.sh
distclean-local: distclean-local-dirs distclean-local-deps
@if [ x"$(BUILDER_RETAIN_CONFIGURE)" = xyes ]; then \
echo "INFO: Retaining the configure script because I was asked to"; \
else \
echo "INFO: Removing the configure script as part of distclean"; \
/bin/rm -f $(abs_top_builddir)/configure; \
fi >&2 || true
@if [ x"$(abs_top_builddir)/.git_details" != x"$(abs_top_srcdir)/.git_details" ]; then \
/bin/rm -f $(abs_top_builddir)/.git_details \
$(abs_top_builddir)/.git_details-fty-core \
$(abs_top_builddir)/$(TXT_DOCS_ASCIIDOC); \
fi || true
#----------------------------------------------------------------------
# astyle formating
#----------------------------------------------------------------------
if HAVE_ASTYLE
EXTRA_DIST += $(top_srcdir)/tools/astyle.conf \
$(top_srcdir)/tools/astyle-bios
checkstyle:
$(abs_top_srcdir)/tools/astyle-bios \
-c $(abs_top_srcdir)/tools/astyle.conf $(abs_top_srcdir)/src
style:
$(abs_top_srcdir)/tools/astyle-bios \
$(abs_top_srcdir)/tools/astyle.conf $(abs_top_srcdir)/src
endif
#----------------------------------------------------------------------
# some popular testing targets
#----------------------------------------------------------------------
ci-test-restapi: test-restapi
test-restapi: all
$(abs_top_srcdir)/tests/CI/ci-test-restapi.sh
#----------------------------------------------------------------------
# SCM details
#----------------------------------------------------------------------
gitdetaildir = $(datarootdir)/@PACKAGE@
gitdetail_DATA = .git_details-fty-core
EXTRA_DIST += .git_details \
tools/git_details.sh \
tools/JSON.sh