mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager
synced 2024-10-15 20:45:32 +00:00
libnm: merge libnm-keyfile into libnm-core
Before there was a licensing conflict between the keyfile code (libnm-keyfile) and libnm. The latter would require LGPL-2.1+ while keyfile code was GPL-2.0+. Consequently we were linking libnm-keyfile into the daemon, but not in libnm.so. This conflict has been resolved and keyfile API is part of libnm.so. There is no more need to build a separate (intermediary) library. Merge them. This also makes sense because keyfile code needs access to private code from libnm-core. It is closely tied to libnm-core, so that building them separate makes no sense (anymore).
This commit is contained in:
parent
b13a2b27e9
commit
c971ee2267
44
Makefile.am
44
Makefile.am
|
@ -653,40 +653,6 @@ EXTRA_DIST += libnm-core/nm-libnm-core-aux/README.md
|
|||
|
||||
###############################################################################
|
||||
|
||||
noinst_LTLIBRARIES += libnm-core/nm-keyfile/libnm-keyfile.la
|
||||
|
||||
libnm_core_nm_keyfile_libnm_keyfile_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"\" \
|
||||
$(NULL)
|
||||
|
||||
libnm_core_nm_keyfile_libnm_keyfile_la_SOURCES = \
|
||||
libnm-core/nm-keyfile/nm-keyfile-internal.h \
|
||||
libnm-core/nm-keyfile/nm-keyfile-utils.c \
|
||||
libnm-core/nm-keyfile/nm-keyfile-utils.h \
|
||||
libnm-core/nm-keyfile/nm-keyfile.c \
|
||||
$(NULL)
|
||||
|
||||
libnm_core_nm_keyfile_libnm_keyfile_la_LDFLAGS = \
|
||||
$(CODE_COVERAGE_LDFLAGS) \
|
||||
$(SANITIZER_LIB_LDFLAGS) \
|
||||
$(NULL)
|
||||
|
||||
libnm_core_nm_keyfile_libnm_keyfile_la_LIBADD = \
|
||||
$(GLIB_LIBS) \
|
||||
$(NULL)
|
||||
|
||||
$(libnm_core_nm_keyfile_libnm_keyfile_la_OBJECTS): $(libnm_core_lib_h_pub_mkenums)
|
||||
|
||||
###############################################################################
|
||||
|
||||
noinst_LTLIBRARIES += libnm/nm-libnm-aux/libnm-libnm-aux.la
|
||||
|
||||
libnm_nm_libnm_aux_libnm_libnm_aux_la_CPPFLAGS = \
|
||||
|
@ -1112,6 +1078,8 @@ libnm_core_lib_h_priv = \
|
|||
libnm-core/nm-crypto-impl.h \
|
||||
libnm-core/nm-crypto.h \
|
||||
libnm-core/nm-default-libnm-core.h \
|
||||
libnm-core/nm-keyfile-internal.h \
|
||||
libnm-core/nm-keyfile-utils.h \
|
||||
libnm-core/nm-meta-setting-base-impl.h \
|
||||
libnm-core/nm-meta-setting-base.h \
|
||||
libnm-core/nm-property-compare.h \
|
||||
|
@ -1179,6 +1147,8 @@ libnm_core_lib_c_real = \
|
|||
libnm-core/nm-crypto.c \
|
||||
libnm-core/nm-dbus-utils.c \
|
||||
libnm-core/nm-errors.c \
|
||||
libnm-core/nm-keyfile-utils.c \
|
||||
libnm-core/nm-keyfile.c \
|
||||
libnm-core/nm-meta-setting-base-impl.c \
|
||||
libnm-core/nm-property-compare.c \
|
||||
libnm-core/nm-setting.c \
|
||||
|
@ -1373,7 +1343,6 @@ nodist_libnm_core_tests_test_general_SOURCES = \
|
|||
|
||||
libnm_core_tests_ldadd = \
|
||||
libnm-core/nm-libnm-core-aux/libnm-libnm-core-aux.la \
|
||||
libnm-core/nm-keyfile/libnm-keyfile.la \
|
||||
libnm-core/libnm-core.la \
|
||||
$(libnm_crypto_lib) \
|
||||
libnm-core/nm-libnm-core-intern/libnm-libnm-core-intern.la \
|
||||
|
@ -1607,7 +1576,6 @@ nodist_libnm_libnm_static_la_SOURCES = \
|
|||
|
||||
libnm_libnm_static_la_LIBADD = \
|
||||
libnm-core/nm-libnm-core-aux/libnm-libnm-core-aux.la \
|
||||
libnm-core/nm-keyfile/libnm-keyfile.la \
|
||||
libnm-core/libnm-core.la \
|
||||
$(libnm_crypto_lib) \
|
||||
libnm-core/nm-libnm-core-intern/libnm-libnm-core-intern.la \
|
||||
|
@ -1705,7 +1673,6 @@ libnm_NM_1_0_gir_FILES = \
|
|||
$(libnm_core_lib_c_real) \
|
||||
$(libnm_lib_h_pub_mkenums) \
|
||||
$(libnm_lib_h_pub_real) \
|
||||
libnm-core/nm-keyfile/nm-keyfile.c \
|
||||
$(libnm_lib_c_mkenums) \
|
||||
$(libnm_lib_c_real)
|
||||
libnm_NM_1_0_gir_SCANNERFLAGS = --warn-all --identifier-prefix=NM --symbol-prefix=nm
|
||||
|
@ -2488,7 +2455,6 @@ src_core_libNetworkManager_la_SOURCES = \
|
|||
src_core_libNetworkManager_la_LIBADD = \
|
||||
src/core/libNetworkManagerBase.la \
|
||||
libnm-core/nm-libnm-core-aux/libnm-libnm-core-aux.la \
|
||||
libnm-core/nm-keyfile/libnm-keyfile.la \
|
||||
libnm-core/libnm-core.la \
|
||||
$(libnm_crypto_lib) \
|
||||
libnm-core/nm-libnm-core-intern/libnm-libnm-core-intern.la \
|
||||
|
@ -2602,7 +2568,6 @@ src_core_nm_iface_helper_SOURCES = \
|
|||
src_core_nm_iface_helper_LDADD = \
|
||||
src/core/libNetworkManagerBase.la \
|
||||
libnm-core/nm-libnm-core-aux/libnm-libnm-core-aux.la \
|
||||
libnm-core/nm-keyfile/libnm-keyfile.la \
|
||||
libnm-core/libnm-core.la \
|
||||
$(libnm_crypto_lib) \
|
||||
libnm-core/nm-libnm-core-intern/libnm-libnm-core-intern.la \
|
||||
|
@ -2657,7 +2622,6 @@ src_core_initrd_nm_initrd_generator_LDADD = \
|
|||
src/core/initrd/libnmi-core.la \
|
||||
src/core/libNetworkManagerBase.la \
|
||||
libnm-core/nm-libnm-core-aux/libnm-libnm-core-aux.la \
|
||||
libnm-core/nm-keyfile/libnm-keyfile.la \
|
||||
libnm-core/libnm-core.la \
|
||||
$(libnm_crypto_lib) \
|
||||
libnm-core/nm-libnm-core-intern/libnm-libnm-core-intern.la \
|
||||
|
|
|
@ -181,6 +181,8 @@ libnm_core_sources = libnm_core_settings_sources + files(
|
|||
'nm-crypto.c',
|
||||
'nm-dbus-utils.c',
|
||||
'nm-errors.c',
|
||||
'nm-keyfile-utils.c',
|
||||
'nm-keyfile.c',
|
||||
'nm-meta-setting-base-impl.c',
|
||||
'nm-property-compare.c',
|
||||
'nm-setting.c',
|
||||
|
@ -239,28 +241,6 @@ libnm_libnm_core_aux_dep = declare_dependency(
|
|||
link_with: libnm_libnm_core_aux,
|
||||
)
|
||||
|
||||
nm_keyfile_source = files(
|
||||
'nm-keyfile/nm-keyfile-utils.c',
|
||||
'nm-keyfile/nm-keyfile.c',
|
||||
)
|
||||
|
||||
libnm_keyfile = static_library(
|
||||
'nm-keyfile',
|
||||
sources: nm_keyfile_source + [libnm_core_enum_sources[1]],
|
||||
dependencies: libnm_glib_aux_dep,
|
||||
c_args: [
|
||||
'-DG_LOG_DOMAIN="libnm"',
|
||||
],
|
||||
link_with: libnm_libnm_core_intern,
|
||||
)
|
||||
|
||||
libnm_keyfile_dep = declare_dependency(
|
||||
sources: [libnm_core_enum_sources[1], nm_version_macro_header],
|
||||
include_directories: [libnm_core_inc, shared_inc],
|
||||
dependencies: glib_dep,
|
||||
link_with: libnm_keyfile,
|
||||
)
|
||||
|
||||
docbooks = [
|
||||
['nm-dbus-types', 'nm-dbus-interface.h', 'NetworkManager D-Bus API Types'],
|
||||
['nm-vpn-dbus-types', 'nm-vpn-dbus-interface.h', 'VPN Plugin D-Bus API Types'],
|
||||
|
|
|
@ -22,7 +22,6 @@ foreach test_unit: test_units
|
|||
'libnm-core-' + test_unit,
|
||||
[test_unit + '.c'] + enum_sources,
|
||||
dependencies: [
|
||||
libnm_keyfile_dep,
|
||||
libnm_core_dep,
|
||||
libnm_core_nm_default_dep,
|
||||
libnm_base_dep,
|
||||
|
|
|
@ -57,7 +57,7 @@
|
|||
#include "nm-setting-wireless-security.h"
|
||||
#include "nm-setting-wpan.h"
|
||||
#include "nm-simple-connection.h"
|
||||
#include "nm-keyfile/nm-keyfile-internal.h"
|
||||
#include "nm-keyfile-internal.h"
|
||||
#include "nm-glib-aux/nm-dedup-multi.h"
|
||||
#include "nm-base/nm-ethtool-base.h"
|
||||
#include "nm-base/nm-ethtool-utils-base.h"
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
#include "libnm-core/nm-default-libnm-core.h"
|
||||
|
||||
#include "nm-glib-aux/nm-json-aux.h"
|
||||
#include "nm-keyfile/nm-keyfile-utils.h"
|
||||
#include "nm-keyfile/nm-keyfile-internal.h"
|
||||
#include "nm-keyfile-utils.h"
|
||||
#include "nm-keyfile-internal.h"
|
||||
#include "nm-simple-connection.h"
|
||||
#include "nm-setting-connection.h"
|
||||
#include "nm-setting-wired.h"
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
#include "nm-simple-connection.h"
|
||||
#include "nm-setting-connection.h"
|
||||
#include "nm-errors.h"
|
||||
#include "nm-keyfile/nm-keyfile-internal.h"
|
||||
#include "nm-keyfile-internal.h"
|
||||
|
||||
#include "nm-utils/nm-test-utils.h"
|
||||
|
||||
|
|
|
@ -137,7 +137,6 @@ libnm_static = static_library(
|
|||
libnmdbus_dep,
|
||||
libnm_libnm_core_intern_dep,
|
||||
libnm_nm_default_dep,
|
||||
libnm_keyfile_dep,
|
||||
libnm_udev_aux_dep,
|
||||
libudev_dep,
|
||||
],
|
||||
|
@ -156,7 +155,6 @@ libnm = shared_library(
|
|||
link_whole: [
|
||||
libnm_static,
|
||||
libnm_core,
|
||||
libnm_keyfile,
|
||||
libnmdbus,
|
||||
libnm_systemd_logging_stub,
|
||||
libnm_glib_aux,
|
||||
|
@ -196,7 +194,7 @@ if enable_introspection
|
|||
|
||||
libnm_gir = gnome.generate_gir(
|
||||
libnm,
|
||||
sources: libnm_core_sources + nm_keyfile_source + libnm_core_headers + libnm_core_enum_sources + libnm_sources + libnm_headers + libnm_enum_sources + [nm_version_macro_header],
|
||||
sources: libnm_core_sources + libnm_core_headers + libnm_core_enum_sources + libnm_sources + libnm_headers + libnm_enum_sources + [nm_version_macro_header],
|
||||
includes: 'Gio-2.0',
|
||||
nsversion: nm_gir_version,
|
||||
namespace: 'NM',
|
||||
|
|
|
@ -56,8 +56,8 @@ libnm-core/nm-crypto-gnutls.c
|
|||
libnm-core/nm-crypto-nss.c
|
||||
libnm-core/nm-connection.c
|
||||
libnm-core/nm-dbus-utils.c
|
||||
libnm-core/nm-keyfile/nm-keyfile-utils.c
|
||||
libnm-core/nm-keyfile/nm-keyfile.c
|
||||
libnm-core/nm-keyfile-utils.c
|
||||
libnm-core/nm-keyfile.c
|
||||
libnm-core/nm-libnm-core-aux/nm-libnm-core-aux.c
|
||||
libnm-core/nm-libnm-core-intern/nm-libnm-core-utils.c
|
||||
libnm-core/nm-setting-6lowpan.c
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
#include "src/core/nm-default-daemon.h"
|
||||
#include "nm-core-utils.h"
|
||||
#include "nm-core-internal.h"
|
||||
#include "nm-keyfile/nm-keyfile-internal.h"
|
||||
#include "nm-keyfile-internal.h"
|
||||
#include "nm-initrd-generator.h"
|
||||
#include "nm-glib-aux/nm-io-utils.h"
|
||||
#include "nm-config.h"
|
||||
|
|
|
@ -77,7 +77,6 @@ libNetworkManagerBase = static_library(
|
|||
dependencies: [
|
||||
core_default_dep,
|
||||
libn_dhcp4_dep,
|
||||
libnm_keyfile_dep,
|
||||
libnm_core_dep,
|
||||
libnm_systemd_shared_dep,
|
||||
libnm_udev_aux_dep,
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
#include "nm-config.h"
|
||||
#include "devices/nm-device.h"
|
||||
#include "nm-core-internal.h"
|
||||
#include "nm-keyfile/nm-keyfile-internal.h"
|
||||
#include "nm-keyfile/nm-keyfile-utils.h"
|
||||
#include "nm-keyfile-internal.h"
|
||||
#include "nm-keyfile-utils.h"
|
||||
|
||||
/*****************************************************************************/
|
||||
|
||||
|
|
|
@ -14,8 +14,8 @@
|
|||
#include "devices/nm-device.h"
|
||||
#include "NetworkManagerUtils.h"
|
||||
#include "nm-core-internal.h"
|
||||
#include "nm-keyfile/nm-keyfile-internal.h"
|
||||
#include "nm-keyfile/nm-keyfile-utils.h"
|
||||
#include "nm-keyfile-internal.h"
|
||||
#include "nm-keyfile-utils.h"
|
||||
|
||||
#define DEFAULT_CONFIG_MAIN_FILE NMCONFDIR "/NetworkManager.conf"
|
||||
#define DEFAULT_CONFIG_DIR NMCONFDIR "/conf.d"
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
#define __NM_TEST_UTILS_CORE_H__
|
||||
|
||||
#include "NetworkManagerUtils.h"
|
||||
#include "nm-keyfile/nm-keyfile-internal.h"
|
||||
#include "nm-keyfile-internal.h"
|
||||
|
||||
#define _NMTST_INSIDE_CORE 1
|
||||
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
|
||||
#include "nm-libnm-core-intern/nm-common-macros.h"
|
||||
#include "nm-glib-aux/nm-keyfile-aux.h"
|
||||
#include "nm-keyfile/nm-keyfile-internal.h"
|
||||
#include "nm-keyfile-internal.h"
|
||||
#include "nm-dbus-interface.h"
|
||||
#include "nm-connection.h"
|
||||
#include "nm-setting-8021x.h"
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
#include "nm-utils.h"
|
||||
#include "nm-config.h"
|
||||
#include "nm-core-internal.h"
|
||||
#include "nm-keyfile/nm-keyfile-internal.h"
|
||||
#include "nm-keyfile-internal.h"
|
||||
|
||||
#include "systemd/nm-sd-utils-shared.h"
|
||||
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
|
||||
#include <sys/stat.h>
|
||||
|
||||
#include "nm-keyfile/nm-keyfile-internal.h"
|
||||
#include "nm-keyfile-internal.h"
|
||||
|
||||
#include "NetworkManagerUtils.h"
|
||||
#include "nms-keyfile-utils.h"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
#include <sys/stat.h>
|
||||
|
||||
#include "nm-glib-aux/nm-io-utils.h"
|
||||
#include "nm-keyfile/nm-keyfile-internal.h"
|
||||
#include "nm-keyfile-internal.h"
|
||||
#include "nm-utils.h"
|
||||
#include "nm-setting-wired.h"
|
||||
#include "nm-setting-wireless.h"
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
#include <sys/stat.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "nm-keyfile/nm-keyfile-internal.h"
|
||||
#include "nm-keyfile-internal.h"
|
||||
|
||||
#include "nms-keyfile-utils.h"
|
||||
#include "nms-keyfile-reader.h"
|
||||
|
|
Loading…
Reference in a new issue