Makefile.am 178 KB
Newer Older
1
include $(GLIB_MAKEFILE)
2
-include $(INTROSPECTION_MAKEFILE)
3
include Makefile.vapigen
4

5 6
@GNOME_CODE_COVERAGE_RULES@

7 8
@NM_LOG_COMPILER@

9 10
###############################################################################

11 12
AUTOMAKE_OPTIONS = subdir-objects

13
noinst_LTLIBRARIES =
14
check_LTLIBRARIES =
15
noinst_PROGRAMS =
16
noinst_LIBRARIES =
17
check_PROGRAMS =
18
noinst_DATA =
19
sbin_PROGRAMS =
20
bin_PROGRAMS =
21
libexec_PROGRAMS =
22
dist_libexec_SCRIPTS =
23
lib_LTLIBRARIES =
24
plugin_LTLIBRARIES =
25
core_plugins =
26
service_DATA =
27
man_MANS =
28
examples_DATA =
29
CLEANFILES =
30
DISTCLEANFILES =
31
EXTRA_DIST =
32
EXTRA_LTLIBRARIES =
33
dist_hook =
34 35
dist_dependencies =
dist_configure_check =
36
install_data_hook =
37
install_exec_hook =
38
uninstall_hook =
39
TESTS =
40
BUILT_SOURCES =
41
GLIB_GENERATED =
42 43
man_pages =
man_pages_autogen =
44
check_programs =
45
check_programs_norun =
46
check_ltlibraries =
47
check_local =
48
VAPIGEN_VAPIS =
49
dbusservice_DATA =
50
dbusactivation_DATA =
51 52 53 54 55 56

INTROSPECTION_GIRS =
INTROSPECTION_SCANNER_ARGS =
INTROSPECTION_COMPILER_ARGS =
# Pass SANITIZER_ENV where a command that uses built libraries is
# executed, to suppress possible errors
57
INTROSPECTION_SCANNER_ENV = $(SANITIZER_ENV) LDFLAGS="$(SANITIZER_LIB_LDFLAGS)"
58 59 60

libnmincludedir = $(includedir)/libnm
libnminclude_HEADERS =
61
nodist_libnminclude_HEADERS =
62 63 64

pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA =
65

66 67 68
pppd_plugindir = $(PPPD_PLUGIN_DIR)
pppd_plugin_LTLIBRARIES =

69 70 71
vapidir = $(datadir)/vala/vapi
vapi_DATA =

72 73
examplesdir = $(docdir)/examples

74 75 76
rundir=$(runstatedir)/NetworkManager
statedir=$(localstatedir)/lib/NetworkManager

77 78
plugindir=$(pkglibdir)/$(NM_DIST_VERSION)

79 80
dbusactivationdir = $(datadir)/dbus-1/system-services

81 82
servicedir = $(datadir)/dbus-1/system-services

83 84
completiondir = $(datadir)/bash-completion/completions

85 86
nmlocaledir = $(datadir)/locale

87 88 89
GLIB_MKENUMS_H_FLAGS = --identifier-prefix NM
GLIB_MKENUMS_C_FLAGS = --identifier-prefix NM

90
SUBDIRS = \
91
	. \
92 93
	po

94
if HAVE_DOCS
95 96

SUBDIRS += \
97 98 99
	docs/libnm \
	docs/api

100 101
endif

102
dflt_cppflags = -std=gnu11
103

104 105
###############################################################################

106
include config-extra.h.mk
107 108 109

DISTCLEANFILES += config-extra.h

110 111 112 113 114 115 116 117 118 119
$(libnm_core_lib_h_pub_mkenums):     config-extra.h
libnm-core/.dirstamp:                config-extra.h
shared/.dirstamp:                    config-extra.h
shared/nm-glib-aux/.dirstamp:        config-extra.h
shared/nm-std-aux/.dirstamp:         config-extra.h
shared/nm-udev-aux/.dirstamp:        config-extra.h
shared/systemd/.dirstamp:            config-extra.h
shared/systemd/src/basic/.dirstamp:  config-extra.h
shared/systemd/src/shared/.dirstamp: config-extra.h
src/dhcp/.dirstamp:                  config-extra.h
120 121

###############################################################################
122

123 124
set_sanitizer_env = \
	[ -n "$(SANITIZER_ENV)" ] && export $(SANITIZER_ENV) ; \
125 126 127
	if echo $(SANITIZER_LIB_CFLAGS) $(SANITIZER_EXEC_CFLAGS) | grep -e -fsanitize=address > /dev/null; then \
		[ -n "$(1)" ] && export LD_PRELOAD="$${LD_PRELOAD}:$$(ldd $(1) | grep libasan\.so\.. -o | head -n 1)"; \
		[ -n "$(2)" ] && export LD_PRELOAD="$${LD_PRELOAD}:$$(ldd $(2) | grep libasan\.so\.. -o | head -n 1)"; \
128 129 130
	fi

check_so_symbols = \
131
	$(call set_sanitizer_env,$(1),$(builddir)/src/NetworkManager); \
132
	LD_BIND_NOW=1 LD_PRELOAD=$${LD_PRELOAD}:$(1) $(builddir)/src/NetworkManager --version >/dev/null
133 134 135

###############################################################################

136 137 138 139 140 141 142 143 144
DISTCHECK_CONFIGURE_FLAGS = \
	--enable-tests=yes \
	--with-valgrind=no \
	--enable-gtk-doc \
	--enable-more-warnings=error \
	--with-udev-dir=$$dc_install_base/lib/udev \
	--with-wext=no \
	--enable-ifcfg-rh \
	--enable-ifupdown \
145 146
	--disable-dependency-tracking \
	$(NULL)
147

148
dist-configure-check:
Lubomir Rintel's avatar
Lubomir Rintel committed
149
	@echo "*** 'make dist' requires '--enable-gtk-doc --enable-introspection'. ***"
150
	@false
151
if !BUILD_DOCS
152 153
dist_configure_check += dist-configure-check
endif
154

155
dist: $(dist_configure_check) $(dist_dependencies)
156

157
DISTCLEANFILES += intltool-extract intltool-merge intltool-update
158 159 160

###############################################################################

161 162 163
polkit_policydir = $(datadir)/polkit-1/actions

dist_polkit_policy_in_in_files = \
164
	data/org.freedesktop.NetworkManager.policy.in.in
165 166 167 168 169 170 171 172 173

polkit_policy_DATA = $(dist_polkit_policy_in_in_files:.policy.in.in=.policy)

@INTLTOOL_POLICY_RULE@

DISTCLEANFILES += $(polkit_policy_DATA)

###############################################################################

174 175 176 177 178 179
EXTRA_DIST += \
	shared/c-stdaux/src/c-stdaux.h \
	$(NULL)

###############################################################################

180 181
noinst_LTLIBRARIES += shared/libcsiphash.la

182 183 184 185 186 187
shared_libcsiphash_la_CFLAGS = \
	$(AM_CFLAGS) \
	-std=c11 \
	-I$(srcdir)/shared/c-stdaux/src \
	$(NULL)

188 189 190 191 192
shared_libcsiphash_la_CPPFLAGS = \
	$(CODE_COVERAGE_CFLAGS) \
	$(SANITIZER_LIB_CFLAGS) \
	$(NULL)

193
shared_libcsiphash_la_LDFLAGS = \
194 195
	$(SANITIZER_LIB_LDFLAGS) \
	$(NULL)
196

197 198
shared_libcsiphash_la_SOURCES = \
	shared/c-siphash/src/c-siphash.c \
199 200
	shared/c-siphash/src/c-siphash.h \
	$(NULL)
201 202 203 204 205

###############################################################################

noinst_LTLIBRARIES += shared/libcrbtree.la

206 207 208
shared_libcrbtree_la_CFLAGS = \
	$(AM_CFLAGS) \
	-std=c11 \
209
	-I$(srcdir)/shared/c-stdaux/src \
210
	$(NULL)
211 212 213 214 215 216

shared_libcrbtree_la_CPPFLAGS = \
	$(CODE_COVERAGE_CFLAGS) \
	$(SANITIZER_LIB_CFLAGS) \
	$(NULL)

217
shared_libcrbtree_la_LDFLAGS = \
218 219
	$(SANITIZER_LIB_LDFLAGS) \
	$(NULL)
220

221 222 223
shared_libcrbtree_la_SOURCES = \
	shared/c-rbtree/src/c-rbtree.c \
	shared/c-rbtree/src/c-rbtree.h \
224 225
	shared/c-rbtree/src/c-rbtree-private.h \
	$(NULL)
226 227 228 229 230

###############################################################################

noinst_LTLIBRARIES += shared/libnacd.la

231 232 233 234 235 236
shared_libnacd_la_CFLAGS = \
	$(AM_CFLAGS) \
	-std=c11 \
	-Wno-pointer-arith \
	-Wno-vla \
	$(NULL)
237 238 239 240 241 242

shared_libnacd_la_CPPFLAGS = \
	-D_GNU_SOURCE \
	-DSO_ATTACH_BPF=50 \
	$(CODE_COVERAGE_CFLAGS) \
	$(SANITIZER_LIB_CFLAGS) \
243
	-I$(srcdir)/shared/c-stdaux/src \
244 245 246 247 248
	-I$(srcdir)/shared/c-list/src \
	-I$(srcdir)/shared/c-siphash/src \
	-I$(srcdir)/shared/c-rbtree/src \
	$(NULL)

249
shared_libnacd_la_LDFLAGS = \
250 251
	$(SANITIZER_LIB_LDFLAGS) \
	$(NULL)
252

253 254 255 256 257 258
shared_libnacd_la_SOURCES = \
	shared/n-acd/src/n-acd.c \
	shared/n-acd/src/n-acd.h \
	shared/n-acd/src/n-acd-private.h \
	shared/n-acd/src/n-acd-probe.c \
	shared/n-acd/src/util/timer.c \
259 260
	shared/n-acd/src/util/timer.h \
	$(NULL)
261 262 263 264 265 266 267 268 269

if WITH_EBPF
shared_libnacd_la_SOURCES += shared/n-acd/src/n-acd-bpf.c
else
shared_libnacd_la_SOURCES += shared/n-acd/src/n-acd-bpf-fallback.c
endif

###############################################################################

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
noinst_LTLIBRARIES += shared/libndhcp4.la

shared_libndhcp4_la_CFLAGS = \
	$(AM_CFLAGS) \
	-std=c11 \
	-Wno-error=declaration-after-statement \
	-Wno-pointer-arith \
	$(NULL)

shared_libndhcp4_la_CPPFLAGS = \
	-D_GNU_SOURCE \
	$(CODE_COVERAGE_CFLAGS) \
	$(SANITIZER_LIB_CFLAGS) \
	-I$(srcdir)/shared/c-stdaux/src \
	-I$(srcdir)/shared/c-list/src \
	-I$(srcdir)/shared/c-siphash/src \
	$(NULL)

shared_libndhcp4_la_LDFLAGS = \
	$(SANITIZER_LIB_LDFLAGS)

shared_libndhcp4_la_SOURCES = \
	shared/n-dhcp4/src/n-dhcp4-c-connection.c \
	shared/n-dhcp4/src/n-dhcp4-c-lease.c \
	shared/n-dhcp4/src/n-dhcp4-c-probe.c \
	shared/n-dhcp4/src/n-dhcp4-client.c \
	shared/n-dhcp4/src/n-dhcp4-incoming.c \
	shared/n-dhcp4/src/n-dhcp4-outgoing.c \
	shared/n-dhcp4/src/n-dhcp4-private.h \
	shared/n-dhcp4/src/n-dhcp4-socket.c \
	shared/n-dhcp4/src/n-dhcp4.h \
	shared/n-dhcp4/src/util/packet.c \
	shared/n-dhcp4/src/util/packet.h \
	shared/n-dhcp4/src/util/socket.c \
	shared/n-dhcp4/src/util/socket.h \
	$(NULL)

###############################################################################

309 310 311 312 313 314 315 316 317 318 319 320 321 322 323
noinst_LTLIBRARIES += shared/nm-std-aux/libnm-std-aux.la

shared_nm_std_aux_libnm_std_aux_la_CPPFLAGS = \
	$(dflt_cppflags) \
	-I$(srcdir)/shared \
	$(CODE_COVERAGE_CFLAGS) \
	$(SANITIZER_LIB_CFLAGS) \
	-DG_LOG_DOMAIN=\""libnm"\" \
	-DNETWORKMANAGER_COMPILATION='0' \
	$(NULL)

shared_nm_std_aux_libnm_std_aux_la_SOURCES = \
	shared/c-list/src/c-list.h \
	shared/nm-std-aux/c-list-util.c \
	shared/nm-std-aux/c-list-util.h \
324
	shared/nm-std-aux/nm-dbus-compat.h \
325 326 327 328 329 330 331 332 333 334
	shared/nm-std-aux/unaligned.h \
	$(NULL)

shared_nm_std_aux_libnm_std_aux_la_LDFLAGS = \
	$(CODE_COVERAGE_LDFLAGS) \
	$(SANITIZER_LIB_LDFLAGS) \
	$(NULL)

###############################################################################

335
shared_nm_glib_aux_cppflags = \
336 337 338 339
	$(dflt_cppflags) \
	-I$(srcdir)/shared \
	$(CODE_COVERAGE_CFLAGS) \
	$(SANITIZER_LIB_CFLAGS) \
340 341 342
	$(GLIB_CFLAGS) \
	-DG_LOG_DOMAIN=\""libnm"\" \
	-DNETWORKMANAGER_COMPILATION='(NM_NETWORKMANAGER_COMPILATION_GLIB|NM_NETWORKMANAGER_COMPILATION_WITH_GLIB_I18N_LIB)' \
343 344
	$(NULL)

345
noinst_LTLIBRARIES += shared/nm-glib-aux/libnm-glib-aux.la
346

347 348
shared_nm_glib_aux_libnm_glib_aux_la_CPPFLAGS = \
	$(shared_nm_glib_aux_cppflags) \
349 350
	$(NULL)

351 352
shared_nm_glib_aux_libnm_glib_aux_la_SOURCES = \
	shared/nm-glib-aux/nm-c-list.h \
353 354
	shared/nm-glib-aux/nm-dbus-aux.c \
	shared/nm-glib-aux/nm-dbus-aux.h \
355 356 357 358 359 360 361 362 363 364 365 366
	shared/nm-glib-aux/nm-dedup-multi.c \
	shared/nm-glib-aux/nm-dedup-multi.h \
	shared/nm-glib-aux/nm-enum-utils.c \
	shared/nm-glib-aux/nm-enum-utils.h \
	shared/nm-glib-aux/nm-errno.c \
	shared/nm-glib-aux/nm-errno.h \
	shared/nm-glib-aux/nm-glib.h \
	shared/nm-glib-aux/nm-hash-utils.c \
	shared/nm-glib-aux/nm-hash-utils.h \
	shared/nm-glib-aux/nm-io-utils.c \
	shared/nm-glib-aux/nm-io-utils.h \
	shared/nm-glib-aux/nm-jansson.h \
367 368
	shared/nm-glib-aux/nm-json-aux.c \
	shared/nm-glib-aux/nm-json-aux.h \
369 370
	shared/nm-glib-aux/nm-keyfile-aux.c \
	shared/nm-glib-aux/nm-keyfile-aux.h \
371 372 373 374 375
	shared/nm-glib-aux/nm-logging-fwd.h \
	shared/nm-glib-aux/nm-macros-internal.h \
	shared/nm-glib-aux/nm-obj.h \
	shared/nm-glib-aux/nm-random-utils.c \
	shared/nm-glib-aux/nm-random-utils.h \
Thomas Haller's avatar
Thomas Haller committed
376 377
	shared/nm-glib-aux/nm-ref-string.c \
	shared/nm-glib-aux/nm-ref-string.h \
378 379 380 381 382 383
	shared/nm-glib-aux/nm-secret-utils.c \
	shared/nm-glib-aux/nm-secret-utils.h \
	shared/nm-glib-aux/nm-shared-utils.c \
	shared/nm-glib-aux/nm-shared-utils.h \
	shared/nm-glib-aux/nm-time-utils.c \
	shared/nm-glib-aux/nm-time-utils.h \
384
	shared/nm-glib-aux/nm-value-type.h \
385 386
	$(NULL)

387
shared_nm_glib_aux_libnm_glib_aux_la_LDFLAGS = \
388 389 390 391
	$(CODE_COVERAGE_LDFLAGS) \
	$(SANITIZER_LIB_LDFLAGS) \
	$(NULL)

392
shared_nm_glib_aux_libnm_glib_aux_la_LIBADD = \
393 394 395 396 397
	$(GLIB_LIBS) \
	$(NULL)

###############################################################################

398
noinst_LTLIBRARIES += shared/nm-udev-aux/libnm-udev-aux.la
399

400
shared_nm_udev_aux_libnm_udev_aux_la_CPPFLAGS = \
401
	$(shared_nm_glib_aux_cppflags) \
402 403 404
	$(LIBUDEV_CFLAGS) \
	$(NULL)

405 406 407
shared_nm_udev_aux_libnm_udev_aux_la_SOURCES = \
	shared/nm-udev-aux/nm-udev-utils.c \
	shared/nm-udev-aux/nm-udev-utils.h \
408 409
	$(NULL)

410
shared_nm_udev_aux_libnm_udev_aux_la_LDFLAGS = \
411 412 413 414
	$(CODE_COVERAGE_LDFLAGS) \
	$(SANITIZER_LIB_LDFLAGS) \
	$(NULL)

415
shared_nm_udev_aux_libnm_udev_aux_la_LIBADD = \
416 417 418 419 420 421
	$(GLIB_LIBS) \
	$(LIBUDEV_LIBS) \
	$(NULL)

###############################################################################

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
noinst_LTLIBRARIES += shared/nm-libnm-core-intern/libnm-libnm-core-intern.la

shared_nm_libnm_core_intern_libnm_libnm_core_intern_la_CPPFLAGS = \
	$(dflt_cppflags) \
	-I$(srcdir)/shared \
	-I$(builddir)/shared \
	-I$(srcdir)/libnm-core \
	-I$(builddir)/libnm-core \
	$(CODE_COVERAGE_CFLAGS) \
	$(GLIB_CFLAGS) \
	$(SANITIZER_LIB_CFLAGS) \
	-DG_LOG_DOMAIN=\""libnm"\" \
	-DNETWORKMANAGER_COMPILATION=NM_NETWORKMANAGER_COMPILATION_LIBNM_CORE \
	$(NULL)

shared_nm_libnm_core_intern_libnm_libnm_core_intern_la_SOURCES = \
	shared/nm-libnm-core-intern/nm-common-macros.h \
	shared/nm-libnm-core-intern/nm-ethtool-utils.c \
	shared/nm-libnm-core-intern/nm-ethtool-utils.h \
	shared/nm-libnm-core-intern/nm-libnm-core-utils.c \
	shared/nm-libnm-core-intern/nm-libnm-core-utils.h \
	$(NULL)

shared_nm_libnm_core_intern_libnm_libnm_core_intern_la_LDFLAGS = \
	$(CODE_COVERAGE_LDFLAGS) \
	$(SANITIZER_LIB_LDFLAGS) \
	$(NULL)

shared_nm_libnm_core_intern_libnm_libnm_core_intern_la_LIBADD = \
	$(GLIB_LIBS) \
	$(NULL)

$(shared_nm_libnm_core_intern_libnm_libnm_core_intern_la_OBJECTS): $(libnm_core_lib_h_pub_mkenums)

###############################################################################

noinst_LTLIBRARIES += shared/nm-libnm-core-aux/libnm-libnm-core-aux.la

shared_nm_libnm_core_aux_libnm_libnm_core_aux_la_CPPFLAGS = \
	$(dflt_cppflags) \
	-I$(srcdir)/shared \
	-I$(builddir)/shared \
	-I$(srcdir)/libnm-core \
	-I$(builddir)/libnm-core \
	$(CODE_COVERAGE_CFLAGS) \
	$(GLIB_CFLAGS) \
	$(SANITIZER_LIB_CFLAGS) \
	-DG_LOG_DOMAIN=\""libnm"\" \
	-DNETWORKMANAGER_COMPILATION='(NM_NETWORKMANAGER_COMPILATION_WITH_GLIB|NM_NETWORKMANAGER_COMPILATION_WITH_GLIB_I18N_LIB)' \
	$(NULL)

shared_nm_libnm_core_aux_libnm_libnm_core_aux_la_SOURCES = \
	shared/nm-libnm-core-aux/nm-dispatcher-api.h \
475 476
	shared/nm-libnm-core-aux/nm-libnm-core-aux.c \
	shared/nm-libnm-core-aux/nm-libnm-core-aux.h \
477 478 479 480 481 482 483 484 485 486 487 488 489 490 491
	$(NULL)

shared_nm_libnm_core_aux_libnm_libnm_core_aux_la_LDFLAGS = \
	$(CODE_COVERAGE_LDFLAGS) \
	$(SANITIZER_LIB_LDFLAGS) \
	$(NULL)

shared_nm_libnm_core_aux_libnm_libnm_core_aux_la_LIBADD = \
	$(GLIB_LIBS) \
	$(NULL)

$(shared_nm_libnm_core_aux_libnm_libnm_core_aux_la_OBJECTS): $(libnm_core_lib_h_pub_mkenums)

###############################################################################

492 493 494 495 496 497
EXTRA_DIST += \
	shared/nm-utils/tests/meson.build \
	$(NULL)

###############################################################################

498 499 500 501 502 503 504 505 506 507
check_programs += shared/nm-utils/tests/test-shared-general

shared_nm_utils_tests_test_shared_general_CPPFLAGS = \
	$(dflt_cppflags) \
	-I$(srcdir)/shared \
	-DNETWORKMANAGER_COMPILATION_TEST \
	-DNETWORKMANAGER_COMPILATION='(NM_NETWORKMANAGER_COMPILATION_GLIB|NM_NETWORKMANAGER_COMPILATION_WITH_GLIB_I18N_PROG)' \
	$(CODE_COVERAGE_CFLAGS) \
	$(GLIB_CFLAGS) \
	$(SANITIZER_LIB_CFLAGS) \
508 509
	$(NULL)

510 511 512 513 514
shared_nm_utils_tests_test_shared_general_LDFLAGS = \
	$(CODE_COVERAGE_LDFLAGS) \
	$(SANITIZER_EXEC_LDFLAGS) \
	$(NULL)

515
shared_nm_utils_tests_test_shared_general_LDADD = \
516
	shared/nm-glib-aux/libnm-glib-aux.la \
517
	shared/systemd/libnm-systemd-logging-stub.la \
518
	shared/nm-std-aux/libnm-std-aux.la \
519
	shared/libcsiphash.la \
520 521 522 523 524
	$(GLIB_LIBS) \
	$(NULL)

###############################################################################

525
noinst_LTLIBRARIES += introspection/libnmdbus.la
526

527
introspection_libnmdbus_la_CPPFLAGS = $(GLIB_CFLAGS)
528

529
introspection_sources = \
530 531 532 533 534 535
	introspection/org.freedesktop.NetworkManager.AccessPoint.c \
	introspection/org.freedesktop.NetworkManager.AccessPoint.h \
	introspection/org.freedesktop.NetworkManager.AgentManager.c \
	introspection/org.freedesktop.NetworkManager.AgentManager.h \
	introspection/org.freedesktop.NetworkManager.Checkpoint.c \
	introspection/org.freedesktop.NetworkManager.Checkpoint.h \
536 537 538 539 540 541
	introspection/org.freedesktop.NetworkManager.Connection.Active.c \
	introspection/org.freedesktop.NetworkManager.Connection.Active.h \
	introspection/org.freedesktop.NetworkManager.DHCP4Config.c \
	introspection/org.freedesktop.NetworkManager.DHCP4Config.h \
	introspection/org.freedesktop.NetworkManager.DHCP6Config.c \
	introspection/org.freedesktop.NetworkManager.DHCP6Config.h \
542 543
	introspection/org.freedesktop.NetworkManager.Device.Adsl.c \
	introspection/org.freedesktop.NetworkManager.Device.Adsl.h \
544 545
	introspection/org.freedesktop.NetworkManager.Device.Bluetooth.c \
	introspection/org.freedesktop.NetworkManager.Device.Bluetooth.h \
546 547 548 549
	introspection/org.freedesktop.NetworkManager.Device.Bond.c \
	introspection/org.freedesktop.NetworkManager.Device.Bond.h \
	introspection/org.freedesktop.NetworkManager.Device.Bridge.c \
	introspection/org.freedesktop.NetworkManager.Device.Bridge.h \
550 551
	introspection/org.freedesktop.NetworkManager.Device.Dummy.c \
	introspection/org.freedesktop.NetworkManager.Device.Dummy.h \
552 553 554 555
	introspection/org.freedesktop.NetworkManager.Device.Generic.c \
	introspection/org.freedesktop.NetworkManager.Device.Generic.h \
	introspection/org.freedesktop.NetworkManager.Device.IPTunnel.c \
	introspection/org.freedesktop.NetworkManager.Device.IPTunnel.h \
556 557
	introspection/org.freedesktop.NetworkManager.Device.Infiniband.c \
	introspection/org.freedesktop.NetworkManager.Device.Infiniband.h \
558 559
	introspection/org.freedesktop.NetworkManager.Device.Lowpan.c \
	introspection/org.freedesktop.NetworkManager.Device.Lowpan.h \
560 561
	introspection/org.freedesktop.NetworkManager.Device.Macsec.c \
	introspection/org.freedesktop.NetworkManager.Device.Macsec.h \
562 563 564 565 566 567
	introspection/org.freedesktop.NetworkManager.Device.Macvlan.c \
	introspection/org.freedesktop.NetworkManager.Device.Macvlan.h \
	introspection/org.freedesktop.NetworkManager.Device.Modem.c \
	introspection/org.freedesktop.NetworkManager.Device.Modem.h \
	introspection/org.freedesktop.NetworkManager.Device.OlpcMesh.c \
	introspection/org.freedesktop.NetworkManager.Device.OlpcMesh.h \
568 569
	introspection/org.freedesktop.NetworkManager.Device.OvsBridge.c \
	introspection/org.freedesktop.NetworkManager.Device.OvsBridge.h \
570 571
	introspection/org.freedesktop.NetworkManager.Device.OvsInterface.c \
	introspection/org.freedesktop.NetworkManager.Device.OvsInterface.h \
572 573
	introspection/org.freedesktop.NetworkManager.Device.OvsPort.c \
	introspection/org.freedesktop.NetworkManager.Device.OvsPort.h \
Beniamino Galvani's avatar
Beniamino Galvani committed
574 575
	introspection/org.freedesktop.NetworkManager.Device.Ppp.c \
	introspection/org.freedesktop.NetworkManager.Device.Ppp.h \
576 577 578 579 580 581 582 583 584 585 586 587
	introspection/org.freedesktop.NetworkManager.Device.Statistics.c \
	introspection/org.freedesktop.NetworkManager.Device.Statistics.h \
	introspection/org.freedesktop.NetworkManager.Device.Team.c \
	introspection/org.freedesktop.NetworkManager.Device.Team.h \
	introspection/org.freedesktop.NetworkManager.Device.Tun.c \
	introspection/org.freedesktop.NetworkManager.Device.Tun.h \
	introspection/org.freedesktop.NetworkManager.Device.Veth.c \
	introspection/org.freedesktop.NetworkManager.Device.Veth.h \
	introspection/org.freedesktop.NetworkManager.Device.Vlan.c \
	introspection/org.freedesktop.NetworkManager.Device.Vlan.h \
	introspection/org.freedesktop.NetworkManager.Device.Vxlan.c \
	introspection/org.freedesktop.NetworkManager.Device.Vxlan.h \
588 589
	introspection/org.freedesktop.NetworkManager.Device.WiMax.c \
	introspection/org.freedesktop.NetworkManager.Device.WiMax.h \
Thomas Haller's avatar
Thomas Haller committed
590 591
	introspection/org.freedesktop.NetworkManager.Device.WifiP2P.c \
	introspection/org.freedesktop.NetworkManager.Device.WifiP2P.h \
592 593
	introspection/org.freedesktop.NetworkManager.Device.WireGuard.c \
	introspection/org.freedesktop.NetworkManager.Device.WireGuard.h \
594 595
	introspection/org.freedesktop.NetworkManager.Device.Wired.c \
	introspection/org.freedesktop.NetworkManager.Device.Wired.h \
596 597
	introspection/org.freedesktop.NetworkManager.Device.Wireless.c \
	introspection/org.freedesktop.NetworkManager.Device.Wireless.h \
598 599
	introspection/org.freedesktop.NetworkManager.Device.Wpan.c \
	introspection/org.freedesktop.NetworkManager.Device.Wpan.h \
600 601
	introspection/org.freedesktop.NetworkManager.Device.c \
	introspection/org.freedesktop.NetworkManager.Device.h \
602 603
	introspection/org.freedesktop.NetworkManager.DnsManager.c \
	introspection/org.freedesktop.NetworkManager.DnsManager.h \
604 605 606 607
	introspection/org.freedesktop.NetworkManager.IP4Config.c \
	introspection/org.freedesktop.NetworkManager.IP4Config.h \
	introspection/org.freedesktop.NetworkManager.IP6Config.c \
	introspection/org.freedesktop.NetworkManager.IP6Config.h \
Thomas Haller's avatar
Thomas Haller committed
608 609
	introspection/org.freedesktop.NetworkManager.WifiP2PPeer.c \
	introspection/org.freedesktop.NetworkManager.WifiP2PPeer.h \
610 611 612 613 614 615 616 617 618 619 620
	introspection/org.freedesktop.NetworkManager.PPP.c \
	introspection/org.freedesktop.NetworkManager.PPP.h \
	introspection/org.freedesktop.NetworkManager.SecretAgent.c \
	introspection/org.freedesktop.NetworkManager.SecretAgent.h \
	introspection/org.freedesktop.NetworkManager.Settings.Connection.c \
	introspection/org.freedesktop.NetworkManager.Settings.Connection.h \
	introspection/org.freedesktop.NetworkManager.Settings.c \
	introspection/org.freedesktop.NetworkManager.Settings.h \
	introspection/org.freedesktop.NetworkManager.VPN.Connection.c \
	introspection/org.freedesktop.NetworkManager.VPN.Connection.h \
	introspection/org.freedesktop.NetworkManager.VPN.Plugin.c \
621 622 623 624
	introspection/org.freedesktop.NetworkManager.VPN.Plugin.h \
	introspection/org.freedesktop.NetworkManager.c \
	introspection/org.freedesktop.NetworkManager.h \
	$(NULL)
625

626 627
nodist_introspection_libnmdbus_la_SOURCES = $(introspection_sources)

628
DBUS_INTERFACE_DOCS = \
629
	docs/api/dbus-org.freedesktop.NetworkManager.AccessPoint.xml \
630
	docs/api/dbus-org.freedesktop.NetworkManager.AgentManager.xml \
631
	docs/api/dbus-org.freedesktop.NetworkManager.Checkpoint.xml \
632 633
	docs/api/dbus-org.freedesktop.NetworkManager.Connection.Active.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.DHCP4Config.xml \
634
	docs/api/dbus-org.freedesktop.NetworkManager.DHCP6Config.xml \
635
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Adsl.xml \
636 637
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Bluetooth.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Bond.xml \
638 639 640 641 642 643
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Bridge.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Dummy.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Generic.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.Device.IPTunnel.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Infiniband.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Lowpan.xml \
644
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Macsec.xml \
645
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Macvlan.xml \
646
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Modem.xml \
647
	docs/api/dbus-org.freedesktop.NetworkManager.Device.OlpcMesh.xml \
648
	docs/api/dbus-org.freedesktop.NetworkManager.Device.OvsBridge.xml \
649
	docs/api/dbus-org.freedesktop.NetworkManager.Device.OvsInterface.xml \
650
	docs/api/dbus-org.freedesktop.NetworkManager.Device.OvsPort.xml \
Beniamino Galvani's avatar
Beniamino Galvani committed
651
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Ppp.xml \
652 653 654
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Statistics.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Team.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Tun.xml \
655
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Veth.xml \
656 657 658
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Vlan.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Vxlan.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.Device.WiMax.xml \
Thomas Haller's avatar
Thomas Haller committed
659
	docs/api/dbus-org.freedesktop.NetworkManager.Device.WifiP2P.xml \
660
	docs/api/dbus-org.freedesktop.NetworkManager.Device.WireGuard.xml \
661 662 663 664
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Wired.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Wireless.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.Device.Wpan.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.Device.xml \
665
	docs/api/dbus-org.freedesktop.NetworkManager.DnsManager.xml \
666 667 668 669 670 671 672 673
	docs/api/dbus-org.freedesktop.NetworkManager.IP4Config.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.IP6Config.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.PPP.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.SecretAgent.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.Settings.Connection.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.Settings.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.VPN.Connection.xml \
	docs/api/dbus-org.freedesktop.NetworkManager.VPN.Plugin.xml \
Thomas Haller's avatar
Thomas Haller committed
674
	docs/api/dbus-org.freedesktop.NetworkManager.WifiP2PPeer.xml \
675 676
	docs/api/dbus-org.freedesktop.NetworkManager.xml \
	$(NULL)
677 678

introspection/%.c: introspection/%.xml
679
	@$(MKDIR_P) introspection/
680 681 682
	$(AM_V_GEN) gdbus-codegen \
		--generate-c-code $(basename $@) \
		--generate-docbook docs/api/dbus \
683 684
		--c-namespace NMDBus \
		--interface-prefix org.freedesktop.NetworkManager \
685
		$<
686

687 688
introspection/%.h: introspection/%.c
	$()
689

690 691
docs/api/dbus-%.xml: introspection/%.c
	$()
692

693
dbusinterfacesdir = $(datadir)/dbus-1/interfaces
694

695
dbusinterfaces_DATA = \
696 697 698
	introspection/org.freedesktop.NetworkManager.AccessPoint.xml \
	introspection/org.freedesktop.NetworkManager.AgentManager.xml \
	introspection/org.freedesktop.NetworkManager.Checkpoint.xml \
Thomas Haller's avatar
Thomas Haller committed
699 700 701
	introspection/org.freedesktop.NetworkManager.Connection.Active.xml \
	introspection/org.freedesktop.NetworkManager.DHCP4Config.xml \
	introspection/org.freedesktop.NetworkManager.DHCP6Config.xml \
702
	introspection/org.freedesktop.NetworkManager.Device.Adsl.xml \
Thomas Haller's avatar
Thomas Haller committed
703
	introspection/org.freedesktop.NetworkManager.Device.Bluetooth.xml \
704 705
	introspection/org.freedesktop.NetworkManager.Device.Bond.xml \
	introspection/org.freedesktop.NetworkManager.Device.Bridge.xml \
706
	introspection/org.freedesktop.NetworkManager.Device.Dummy.xml \
707 708
	introspection/org.freedesktop.NetworkManager.Device.Generic.xml \
	introspection/org.freedesktop.NetworkManager.Device.IPTunnel.xml \
Thomas Haller's avatar
Thomas Haller committed
709
	introspection/org.freedesktop.NetworkManager.Device.Infiniband.xml \
710
	introspection/org.freedesktop.NetworkManager.Device.Lowpan.xml \
711
	introspection/org.freedesktop.NetworkManager.Device.Macsec.xml \
712 713 714
	introspection/org.freedesktop.NetworkManager.Device.Macvlan.xml \
	introspection/org.freedesktop.NetworkManager.Device.Modem.xml \
	introspection/org.freedesktop.NetworkManager.Device.OlpcMesh.xml \
Thomas Haller's avatar
Thomas Haller committed
715
	introspection/org.freedesktop.NetworkManager.Device.OvsBridge.xml \
716
	introspection/org.freedesktop.NetworkManager.Device.OvsInterface.xml \
717
	introspection/org.freedesktop.NetworkManager.Device.OvsPort.xml \
Beniamino Galvani's avatar
Beniamino Galvani committed
718
	introspection/org.freedesktop.NetworkManager.Device.Ppp.xml \
719 720 721 722 723 724
	introspection/org.freedesktop.NetworkManager.Device.Statistics.xml \
	introspection/org.freedesktop.NetworkManager.Device.Team.xml \
	introspection/org.freedesktop.NetworkManager.Device.Tun.xml \
	introspection/org.freedesktop.NetworkManager.Device.Veth.xml \
	introspection/org.freedesktop.NetworkManager.Device.Vlan.xml \
	introspection/org.freedesktop.NetworkManager.Device.Vxlan.xml \
Thomas Haller's avatar
Thomas Haller committed
725 726
	introspection/org.freedesktop.NetworkManager.Device.WiMax.xml \
	introspection/org.freedesktop.NetworkManager.Device.WifiP2P.xml \
727
	introspection/org.freedesktop.NetworkManager.Device.WireGuard.xml \
Thomas Haller's avatar
Thomas Haller committed
728
	introspection/org.freedesktop.NetworkManager.Device.Wired.xml \
729
	introspection/org.freedesktop.NetworkManager.Device.Wireless.xml \
730
	introspection/org.freedesktop.NetworkManager.Device.Wpan.xml \
731
	introspection/org.freedesktop.NetworkManager.Device.xml \
732
	introspection/org.freedesktop.NetworkManager.DnsManager.xml \
733 734 735 736 737 738 739 740
	introspection/org.freedesktop.NetworkManager.IP4Config.xml \
	introspection/org.freedesktop.NetworkManager.IP6Config.xml \
	introspection/org.freedesktop.NetworkManager.PPP.xml \
	introspection/org.freedesktop.NetworkManager.SecretAgent.xml \
	introspection/org.freedesktop.NetworkManager.Settings.Connection.xml \
	introspection/org.freedesktop.NetworkManager.Settings.xml \
	introspection/org.freedesktop.NetworkManager.VPN.Connection.xml \
	introspection/org.freedesktop.NetworkManager.VPN.Plugin.xml \
Thomas Haller's avatar
Thomas Haller committed
741 742 743 744
	introspection/org.freedesktop.NetworkManager.WiMax.Nsp.xml \
	introspection/org.freedesktop.NetworkManager.WifiP2PPeer.xml \
	introspection/org.freedesktop.NetworkManager.xml \
	$(NULL)
745

746 747
CLEANFILES += $(introspection_sources)
CLEANFILES += $(DBUS_INTERFACE_DOCS)
748

749 750 751 752
$(dispatcher_libnm_dispatcher_core_la_OBJECTS): $(introspection_sources)
$(dispatcher_nm_dispatcher_OBJECTS):            $(introspection_sources)
$(libnm_libnm_la_OBJECTS):                      $(introspection_sources)

753
EXTRA_DIST += \
754 755
	$(dbusinterfaces_DATA) \
	introspection/meson.build
756

757
check-docs:
758
	$(srcdir)/tools/check-docs.sh "$(srcdir)" "$(builddir)"
759 760 761

check_local += check-docs

762 763
###############################################################################

764
libnm_core_lib_h_pub_real = \
765 766 767 768 769
	shared/nm-version-macros.h \
	libnm-core/nm-connection.h \
	libnm-core/nm-core-types.h \
	libnm-core/nm-dbus-interface.h \
	libnm-core/nm-errors.h \
Lubomir Rintel's avatar
Lubomir Rintel committed
770
	libnm-core/nm-setting-6lowpan.h \
771 772 773 774 775 776 777 778 779
	libnm-core/nm-setting-8021x.h \
	libnm-core/nm-setting-adsl.h \
	libnm-core/nm-setting-bluetooth.h \
	libnm-core/nm-setting-bond.h \
	libnm-core/nm-setting-bridge-port.h \
	libnm-core/nm-setting-bridge.h \
	libnm-core/nm-setting-cdma.h \
	libnm-core/nm-setting-connection.h \
	libnm-core/nm-setting-dcb.h \
780
	libnm-core/nm-setting-dummy.h \
781
	libnm-core/nm-setting-ethtool.h \
782 783 784 785 786 787 788
	libnm-core/nm-setting-generic.h \
	libnm-core/nm-setting-gsm.h \
	libnm-core/nm-setting-infiniband.h \
	libnm-core/nm-setting-ip-config.h \
	libnm-core/nm-setting-ip-tunnel.h \
	libnm-core/nm-setting-ip4-config.h \
	libnm-core/nm-setting-ip6-config.h \
789
	libnm-core/nm-setting-macsec.h \
790
	libnm-core/nm-setting-macvlan.h \
Beniamino Galvani's avatar
Beniamino Galvani committed
791
	libnm-core/nm-setting-match.h \
792
	libnm-core/nm-setting-olpc-mesh.h \
793
	libnm-core/nm-setting-ovs-bridge.h \
794
	libnm-core/nm-setting-ovs-dpdk.h \
795
	libnm-core/nm-setting-ovs-interface.h \
796
	libnm-core/nm-setting-ovs-patch.h \
797
	libnm-core/nm-setting-ovs-port.h \
798 799 800 801
	libnm-core/nm-setting-ppp.h \
	libnm-core/nm-setting-pppoe.h \
	libnm-core/nm-setting-proxy.h \
	libnm-core/nm-setting-serial.h \
802
	libnm-core/nm-setting-sriov.h \
803
	libnm-core/nm-setting-tc-config.h \
804 805 806
	libnm-core/nm-setting-team-port.h \
	libnm-core/nm-setting-team.h \
	libnm-core/nm-setting-tun.h \
Thomas Haller's avatar
Thomas Haller committed
807
	libnm-core/nm-setting-user.h \
808 809 810
	libnm-core/nm-setting-vlan.h \
	libnm-core/nm-setting-vpn.h \
	libnm-core/nm-setting-vxlan.h \
811
	libnm-core/nm-setting-wifi-p2p.h \
812 813
	libnm-core/nm-setting-wimax.h \
	libnm-core/nm-setting-wired.h \
814
	libnm-core/nm-setting-wireguard.h \
815 816
	libnm-core/nm-setting-wireless-security.h \
	libnm-core/nm-setting-wireless.h \
Lubomir Rintel's avatar
Lubomir Rintel committed
817
	libnm-core/nm-setting-wpan.h \
818 819 820 821 822 823
	libnm-core/nm-setting.h \
	libnm-core/nm-simple-connection.h \
	libnm-core/nm-utils.h \
	libnm-core/nm-version.h \
	libnm-core/nm-vpn-dbus-interface.h \
	libnm-core/nm-vpn-editor-plugin.h \
824 825
	libnm-core/nm-vpn-plugin-info.h \
	$(NULL)
826
libnm_core_lib_h_pub_mkenums = \
827 828
	libnm-core/nm-core-enum-types.h \
	$(NULL)
829
libnm_core_lib_h_priv = \
830
	shared/nm-meta-setting.h \
831 832 833
	libnm-core/nm-connection-private.h \
	libnm-core/nm-core-internal.h \
	libnm-core/nm-core-types-internal.h \
834 835
	libnm-core/nm-crypto-impl.h \
	libnm-core/nm-crypto.h \
836 837 838 839
	libnm-core/nm-keyfile-internal.h \
	libnm-core/nm-keyfile-utils.h \
	libnm-core/nm-property-compare.h \
	libnm-core/nm-setting-private.h \
840 841 842
	libnm-core/nm-team-utils.h \
	libnm-core/nm-utils-private.h \
	$(NULL)
843
libnm_core_lib_c_settings_real = \
Lubomir Rintel's avatar
Lubomir Rintel committed
844
	libnm-core/nm-setting-6lowpan.c \
845 846 847 848 849 850 851 852 853
	libnm-core/nm-setting-8021x.c \
	libnm-core/nm-setting-adsl.c \
	libnm-core/nm-setting-bluetooth.c \
	libnm-core/nm-setting-bond.c \
	libnm-core/nm-setting-bridge-port.c \
	libnm-core/nm-setting-bridge.c \
	libnm-core/nm-setting-cdma.c \
	libnm-core/nm-setting-connection.c \
	libnm-core/nm-setting-dcb.c \
854
	libnm-core/nm-setting-dummy.c \
855
	libnm-core/nm-setting-ethtool.c \
856 857 858 859 860 861 862
	libnm-core/nm-setting-generic.c \
	libnm-core/nm-setting-gsm.c \
	libnm-core/nm-setting-infiniband.c \
	libnm-core/nm-setting-ip-config.c \
	libnm-core/nm-setting-ip-tunnel.c \
	libnm-core/nm-setting-ip4-config.c \
	libnm-core/nm-setting-ip6-config.c \
863
	libnm-core/nm-setting-macsec.c \
864
	libnm-core/nm-setting-macvlan.c \
Beniamino Galvani's avatar
Beniamino Galvani committed
865
	libnm-core/nm-setting-match.c \
866
	libnm-core/nm-setting-olpc-mesh.c \
867
	libnm-core/nm-setting-ovs-bridge.c \
868
	libnm-core/nm-setting-ovs-dpdk.c \
869
	libnm-core/nm-setting-ovs-interface.c \
870
	libnm-core/nm-setting-ovs-patch.c \
871
	libnm-core/nm-setting-ovs-port.c \
872 873 874 875
	libnm-core/nm-setting-ppp.c \
	libnm-core/nm-setting-pppoe.c \
	libnm-core/nm-setting-proxy.c \
	libnm-core/nm-setting-serial.c \
876
	libnm-core/nm-setting-sriov.c \
877
	libnm-core/nm-setting-tc-config.c \
878 879 880
	libnm-core/nm-setting-team-port.c \
	libnm-core/nm-setting-team.c \
	libnm-core/nm-setting-tun.c \
Thomas Haller's avatar
Thomas Haller committed
881
	libnm-core/nm-setting-user.c \
882 883 884
	libnm-core/nm-setting-vlan.c \
	libnm-core/nm-setting-vpn.c \
	libnm-core/nm-setting-vxlan.c \
885
	libnm-core/nm-setting-wifi-p2p.c \
886 887
	libnm-core/nm-setting-wimax.c \
	libnm-core/nm-setting-wired.c \
888
	libnm-core/nm-setting-wireguard.c \
889
	libnm-core/nm-setting-wireless-security.c \
Lubomir Rintel's avatar
Lubomir Rintel committed
890
	libnm-core/nm-setting-wireless.c \
891 892
	libnm-core/nm-setting-wpan.c \
	$(NULL)
893 894 895 896
libnm_core_lib_c_real = \
	$(libnm_core_lib_c_settings_real) \
	shared/nm-meta-setting.c \
	libnm-core/nm-connection.c \
897
	libnm-core/nm-crypto.c \
898 899 900
	libnm-core/nm-dbus-utils.c \
	libnm-core/nm-errors.c \
	libnm-core/nm-keyfile-utils.c \
901
	libnm-core/nm-keyfile.c \
902
	libnm-core/nm-property-compare.c \
903 904
	libnm-core/nm-setting.c \
	libnm-core/nm-simple-connection.c \
905
	libnm-core/nm-team-utils.c \
906 907
	libnm-core/nm-utils.c \
	libnm-core/nm-vpn-editor-plugin.c \
908 909
	libnm-core/nm-vpn-plugin-info.c \
	$(NULL)
910 911 912

if WITH_JSON_VALIDATION
libnm_core_lib_h_priv += \
913
	libnm-core/nm-json.h
914
libnm_core_lib_c_real += \
915
	libnm-core/nm-json.c
916 917
endif

918
libnm_core_lib_c_mkenums = \
919 920 921 922
	libnm-core/nm-core-enum-types.c

libnminclude_HEADERS += \
	$(libnm_core_lib_h_pub_real)
923

924
nodist_libnminclude_HEADERS += \
925
	$(libnm_core_lib_h_pub_mkenums)
926 927 928

###############################################################################

929
dflt_cppflags_libnm_core = \
930
	$(dflt_cppflags) \
931 932 933 934
	-I$(srcdir)/shared \
	-I$(builddir)/shared \
	-I$(srcdir)/libnm-core \
	-I$(builddir)/libnm-core \
935
	$(CODE_COVERAGE_CFLAGS) \
936
	$(GLIB_CFLAGS) \
937
	$(LIBUDEV_CFLAGS) \
938 939
	$(SANITIZER_LIB_CFLAGS) \
	$(NULL)
940

941 942 943
noinst_LTLIBRARIES += libnm-core/libnm-core.la

GLIB_GENERATED += \
944 945
	$(libnm_core_lib_h_pub_mkenums) \
	$(libnm_core_lib_c_mkenums)
946
nm_core_enum_types_sources = $(libnm_core_lib_h_pub_real)
947

948 949
nm_core_enum_types_MKENUMS_C_FLAGS = --identifier-prefix NM --fhead '\#include "nm-default.h"\n'

950 951
libnm-core/nm-core-enum-types.h.stamp:                                      libnm-core/.dirstamp
libnm-core/nm-core-enum-types.c.stamp:                                      libnm-core/.dirstamp
952

953 954 955 956 957 958 959 960 961 962 963
$(dispatcher_libnm_dispatcher_core_la_OBJECTS):                             $(libnm_core_lib_h_pub_mkenums)
$(dispatcher_nm_dispatcher_OBJECTS):                                        $(libnm_core_lib_h_pub_mkenums)
$(libnm_core_libnm_core_la_OBJECTS):                                        $(libnm_core_lib_h_pub_mkenums)
$(libnm_libnm_la_OBJECTS):                                                  $(libnm_core_lib_h_pub_mkenums)
$(libnm_tests_libnm_vpn_plugin_utils_test_la_OBJECTS):                      $(libnm_core_lib_h_pub_mkenums)
$(src_NetworkManager_OBJECTS):                                              $(libnm_core_lib_h_pub_mkenums)
$(src_devices_adsl_libnm_device_plugin_adsl_la_OBJECTS):                    $(libnm_core_lib_h_pub_mkenums)
$(src_devices_bluetooth_libnm_device_plugin_bluetooth_la_OBJECTS):          $(libnm_core_lib_h_pub_mkenums)
$(src_devices_team_libnm_device_plugin_team_la_OBJECTS):                    $(libnm_core_lib_h_pub_mkenums)
$(src_devices_wifi_libnm_device_plugin_wifi_la_OBJECTS):                    $(libnm_core_lib_h_pub_mkenums)
$(src_devices_wwan_libnm_device_plugin_wwan_la_OBJECTS):                    $(libnm_core_lib_h_pub_mkenums)
964
$(src_devices_ovs_libnm_device_plugin_ovs_la_OBJECTS):                      $(libnm_core_lib_h_pub_mkenums)
965

966
libnm_core_libnm_core_la_CPPFLAGS = \
967
	$(dflt_cppflags_libnm_core) \
968
	-DG_LOG_DOMAIN=\""libnm"\" \
969 970
	-DNETWORKMANAGER_COMPILATION=NM_NETWORKMANAGER_COMPILATION_LIBNM_CORE \
	$(NULL)
971

972 973 974 975
if WITH_JSON_VALIDATION
libnm_core_libnm_core_la_CPPFLAGS += $(JANSSON_CFLAGS)
endif

976
libnm_core_libnm_core_la_SOURCES = \
977 978 979 980 981
	$(libnm_core_lib_h_pub_real) \
	$(libnm_core_lib_h_priv) \
	$(libnm_core_lib_c_real)

nodist_libnm_core_libnm_core_la_SOURCES = \
982 983
	$(libnm_core_lib_h_pub_mkenums) \
	$(libnm_core_lib_c_mkenums)
984 985 986

libnm_core_libnm_core_la_LIBADD = \
	$(GLIB_LIBS) \
987
	$(UUID_LIBS) \
988
	$(NULL)
989

990
libnm_core_libnm_core_la_LDFLAGS = \
991
	$(CODE_COVERAGE_LDFLAGS) \
992 993
	$(SANITIZER_LIB_LDFLAGS) \
	$(NULL)
994

995
EXTRA_DIST += \
996 997
	libnm-core/nm-crypto-gnutls.c \
	libnm-core/nm-crypto-nss.c \
998 999
	libnm-core/nm-core-enum-types.c.template \
	libnm-core/nm-core-enum-types.h.template \
1000 1001
	libnm-core/meson.build \
	$(NULL)
1002

1003
libnm-core/nm-vpn-dbus-types.xml: libnm-core/nm-vpn-dbus-interface.h tools/enums-to-docbook.pl
1004
	@$(MKDIR_P) libnm-core/
1005
	$(AM_V_GEN) @PERL@ $(srcdir)/tools/enums-to-docbook.pl 'nm-vpn-dbus-types' 'VPN Plugin D-Bus API Types' $< >$@
1006

1007
libnm-core/nm-dbus-types.xml: libnm-core/nm-dbus-interface.h tools/enums-to-docbook.pl
1008
	@$(MKDIR_P) libnm-core/
1009
	$(AM_V_GEN) @PERL@ $(srcdir)/tools/enums-to-docbook.pl 'nm-dbus-types' 'NetworkManager D-Bus API Types' $< >$@
1010 1011 1012 1013 1014

BUILT_SOURCES += \
	libnm-core/nm-vpn-dbus-types.xml \
	libnm-core/nm-dbus-types.xml

1015 1016 1017 1018
dist_dependencies += \
	libnm-core/nm-vpn-dbus-types.xml \
	libnm-core/nm-dbus-types.xml

1019 1020
###############################################################################

1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034
if HAVE_CRYPTO_GNUTLS
if WITH_GNUTLS
libnm_crypto_lib = libnm-core/libnm-crypto-gnutls.la
else
check_ltlibraries += libnm-core/libnm-crypto-gnutls.la
endif

libnm_core_libnm_crypto_gnutls_la_SOURCES = libnm-core/nm-crypto-gnutls.c
libnm_core_libnm_crypto_gnutls_la_CPPFLAGS = \
	$(libnm_core_libnm_core_la_CPPFLAGS) \
	$(GNUTLS_CFLAGS)
libnm_core_libnm_crypto_gnutls_la_LDFLAGS = \
	$(libnm_core_libnm_core_la_LDFLAGS)
libnm_core_libnm_crypto_gnutls_la_LIBADD = \
1035
	$(GLIB_LIBS) \
1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052
	$(GNUTLS_LIBS)
endif

if HAVE_CRYPTO_NSS
if WITH_NSS
libnm_crypto_lib = libnm-core/libnm-crypto-nss.la
else
check_ltlibraries += libnm-core/libnm-crypto-nss.la
endif

libnm_core_libnm_crypto_nss_la_SOURCES = libnm-core/nm-crypto-nss.c
libnm_core_libnm_crypto_nss_la_CPPFLAGS = \
	$(libnm_core_libnm_core_la_CPPFLAGS) \
	$(NSS_CFLAGS)
libnm_core_libnm_crypto_nss_la_LDFLAGS = \
	$(libnm_core_libnm_core_la_LDFLAGS)
libnm_core_libnm_crypto_nss_la_LIBADD = \
1053
	$(GLIB_LIBS) \
1054 1055 1056 1057 1058 1059 1060
	$(NSS_LIBS)
endif

noinst_LTLIBRARIES += $(libnm_crypto_lib)

###############################################################################

1061
check_programs += \
1062 1063 1064 1065 1066
	libnm-core/tests/test-compare \
	libnm-core/tests/test-crypto \
	libnm-core/tests/test-general \
	libnm-core/tests/test-keyfile \
	libnm-core/tests/test-secrets \
1067
	libnm-core/tests/test-setting \
1068 1069 1070 1071 1072 1073 1074
	libnm-core/tests/test-settings-defaults

GLIB_GENERATED += \
	libnm-core/tests/nm-core-tests-enum-types.h \
	libnm-core/tests/nm-core-tests-enum-types.c
nm_core_tests_enum_types_sources = libnm-core/tests/test-general-enums.h

1075 1076 1077
libnm-core/tests/nm-core-tests-enum-types.h.stamp: libnm-core/tests/.dirstamp
libnm-core/tests/nm-core-tests-enum-types.c.stamp: libnm-core/tests/.dirstamp

1078 1079
$(libnm_core_tests_test_general_OBJECTS): libnm-core/tests/nm-core-tests-enum-types.h

1080 1081
libnm_core_tests_cppflags = \
	-I$(srcdir)/libnm-core/tests \
1082
	-I$(builddir)/libnm-core/tests \
1083
	$(dflt_cppflags_libnm_core) \
1084 1085
	-DNETWORKMANAGER_COMPILATION_TEST \
	-DNETWORKMANAGER_COMPILATION=NM_NETWORKMANAGER_COMPILATION_LIBNM_CORE \
1086
	$(SANITIZER_EXEC_CFLAGS) \
1087
	$(NULL)
1088 1089 1090 1091 1092 1093

libnm_core_tests_test_compare_CPPFLAGS = $(libnm_core_tests_cppflags)
libnm_core_tests_test_crypto_CPPFLAGS = $(libnm_core_tests_cppflags)
libnm_core_tests_test_general_CPPFLAGS = $(libnm_core_tests_cppflags)
libnm_core_tests_test_keyfile_CPPFLAGS = $(libnm_core_tests_cppflags)
libnm_core_tests_test_secrets_CPPFLAGS = $(libnm_core_tests_cppflags)
1094
libnm_core_tests_test_setting_CPPFLAGS = $(libnm_core_tests_cppflags)
1095 1096 1097 1098
libnm_core_tests_test_settings_defaults_CPPFLAGS = $(libnm_core_tests_cppflags)

libnm_core_tests_test_general_SOURCES = \
	libnm-core/tests/test-general-enums.h \
1099 1100
	libnm-core/tests/test-general.c \
	$(NULL)
1101

1102 1103
nodist_libnm_core_tests_test_general_SOURCES = \
	libnm-core/tests/nm-core-tests-enum-types.c \
1104 1105
	libnm-core/tests/nm-core-tests-enum-types.h \
	$(NULL)
1106

1107
libnm_core_tests_ldadd = \
1108
	shared/nm-libnm-core-aux/libnm-libnm-core-aux.la \
1109
	libnm-core/libnm-core.la \
1110 1111
	$(libnm_crypto_lib) \
	shared/nm-libnm-core-intern/libnm-libnm-core-intern.la \
1112 1113
	shared/systemd/libnm-systemd-shared.la \
	shared/systemd/libnm-systemd-logging-stub.la \
1114
	shared/nm-glib-aux/libnm-glib-aux.la \
1115
	shared/nm-std-aux/libnm-std-aux.la \
1116
	shared/libcsiphash.la \
1117 1118
	$(GLIB_LIBS) \
	$(NULL)
1119

1120
libnm_core_tests_ldflags = \
1121 1122
	$(SANITIZER_EXEC_LDFLAGS) \
	$(NULL)
1123

1124 1125 1126 1127 1128
libnm_core_tests_test_compare_LDADD = $(libnm_core_tests_ldadd)
libnm_core_tests_test_crypto_LDADD = $(libnm_core_tests_ldadd)
libnm_core_tests_test_general_LDADD = $(libnm_core_tests_ldadd)
libnm_core_tests_test_keyfile_LDADD = $(libnm_core_tests_ldadd)
libnm_core_tests_test_secrets_LDADD = $(libnm_core_tests_ldadd)
1129
libnm_core_tests_test_setting_LDADD = $(libnm_core_tests_ldadd)
1130 1131
libnm_core_tests_test_settings_defaults_LDADD = $(libnm_core_tests_ldadd)

1132 1133 1134 1135 1136 1137 1138 1139
libnm_core_tests_test_compare_LDFLAGS = $(libnm_core_tests_ldflags)
libnm_core_tests_test_crypto_LDFLAGS = $(libnm_core_tests_ldflags)
libnm_core_tests_test_general_LDFLAGS = $(libnm_core_tests_ldflags)
libnm_core_tests_test_keyfile_LDFLAGS = $(libnm_core_tests_ldflags)
libnm_core_tests_test_secrets_LDFLAGS = $(libnm_core_tests_ldflags)
libnm_core_tests_test_setting_LDFLAGS = $(libnm_core_tests_ldflags)
libnm_core_tests_test_settings_defaults_LDFLAGS = $(libnm_core_tests_ldflags)

1140 1141 1142 1143 1144
$(libnm_core_tests_test_compare_OBJECTS): $(libnm_core_lib_h_pub_mkenums)
$(libnm_core_tests_test_crypto_OBJECTS): $(libnm_core_lib_h_pub_mkenums)
$(libnm_core_tests_test_general_OBJECTS): $(libnm_core_lib_h_pub_mkenums)
$(libnm_core_tests_test_keyfile_OBJECTS): $(libnm_core_lib_h_pub_mkenums)
$(libnm_core_tests_test_secrets_OBJECTS): $(libnm_core_lib_h_pub_mkenums)
1145
$(libnm_core_tests_test_setting_OBJECTS): $(libnm_core_lib_h_pub_mkenums)
1146 1147
$(libnm_core_tests_test_settings_defaults_OBJECTS): $(libnm_core_lib_h_pub_mkenums)

1148 1149 1150
# test-cert.p12 created with:
#
# openssl pkcs12 -export \
1151 1152 1153 1154 1155
#    -in test_key_and_cert.pem \
#    -inkey test_key_and_cert.pem \
#    -certfile test_ca_cert.pem \
#    -name "test-pkcs12" \
#    -out test-cert.p12
1156 1157 1158 1159 1160 1161 1162 1163 1164

EXTRA_DIST += \
	libnm-core/tests/certs/ca-no-ending-newline.pem \
	libnm-core/tests/certs/pkcs8-decrypted.der \
	libnm-core/tests/certs/pkcs8-enc-key.pem \
	libnm-core/tests/certs/pkcs8-noenc-key.pem \
	libnm-core/tests/certs/test2_ca_cert.pem \
	libnm-core/tests/certs/test2-cert.p12 \
	libnm-core/tests/certs/test2_key_and_cert.pem \
1165 1166
	libnm-core/tests/certs/test-aes-128-key.pem \
	libnm-core/tests/certs/test-aes-256-key.pem \
1167 1168 1169 1170 1171 1172 1173 1174
	libnm-core/tests/certs/test_ca_cert.der \
	libnm-core/tests/certs/test_ca_cert.pem \
	libnm-core/tests/certs/test-ca-cert.pem \
	libnm-core/tests/certs/test-cert.p12 \
	libnm-core/tests/certs/test_key_and_cert.pem \
	libnm-core/tests/certs/test-key-and-cert.pem \
	libnm-core/tests/certs/test-key-only-decrypted.der \
	libnm-core/tests/certs/test-key-only-decrypted.pem \
1175
	libnm-core/tests/certs/test-key-only.pem \
1176
	libnm-core/tests/certs/test-tpm2wrapped-key.pem \
1177 1178 1179
	libnm-core/tests/nm-core-tests-enum-types.c.template \
	libnm-core/tests/nm-core-tests-enum-types.h.template \
	libnm-core/tests/meson.build
Thomas Haller's avatar