1. 22 Jun, 2016 3 commits
  2. 21 Jun, 2016 14 commits
  3. 20 Jun, 2016 2 commits
  4. 18 Jun, 2016 1 commit
  5. 17 Jun, 2016 9 commits
  6. 16 Jun, 2016 8 commits
    • Thomas Haller's avatar
      shared: add also "shared/nm-utils/nm-vpn-plugin-macros.h" · af507cd0
      Thomas Haller authored
      It has the very similar purpose as "nm-utils/nm-vpn-plugin-utils.[ch]", except
      that is is header-only.
    • Thomas Haller's avatar
      tests: fix checking NM_ASSERT_NO_MSG define in "nm-test-utils.h" · 89d32944
      Thomas Haller authored
      "nm-test-utils.h" may also be used by the VPN plugins, there
      we have no NM_ASSERT_NO_MSG define.
    • Thomas Haller's avatar
    • Thomas Haller's avatar
      shared/tests: build "nm-utils/nm-vpn-plugin-utils.c" · 2c02f3a8
      Thomas Haller authored
      For testing, add a build target to build those files too.
    • Thomas Haller's avatar
      shared: include "nm-glib.h" from "nm-macros-internal.h" · 3bcec406
      Thomas Haller authored
      "nm-glib.h" is our most basic header. "nm-macros-internal.h" extends
      on that. Thus, let "nm-macros-internal.h" include "nm-glib.h".
    • Thomas Haller's avatar
      shared: include "gsystem-local-alloc.h" from "nm-glib.h" · 037462e9
      Thomas Haller authored
      "nm-glib.h" is the most basic header, the one we cannot do without.
      ("nm-default.h", is already more generic, the one which every common
      source file in NetworkManager repository should include).
      Let "gsystem-local-alloc.h" be included by "nm-glib.h" and nowhere
    • Thomas Haller's avatar
      shared: add "nm-utils/nm-vpn-plugin-utils.h" · 5d55492b
      Thomas Haller authored
      This file is only used by plugins and copied between them.
      It's purpose is to contain general utility functions that are
      only relevant for implementing NetworkManager's VPN plugins.
      In principle the utility functions could be part of libnm, however,
      there are a few problems with that:
        - if they are part of libnm, adding and using a new utility function
          requires the plugin to bump the required libnm version. Since you
          usally can work around/reimplement utility functions, this results
          in not using the API from libnm, not adding the API to libnm,
          and reimplementing it over and over in the plugin.
        - plugins compile both against libnm and libnm-glib. Thus, either
          the utility function would also be needed in libnm-glib, or again,
          it is not usable by the plugin.
      We must avoid that the utility functions diverge and no local
      modifications to these files should be made in the plugin.
      Instead, one special location of the utility functions shall be
      extended and re-imported (copied) to the plugin as needed.
      Add the files to NetworkManager's repository. Although they are not
      needed for NetworkManager itself, they are a different API provided
      by NetworkManager. An API that is reused and shared by copying the files
    • Thomas Haller's avatar
      shared: move shared files to subdirectory "shared/nm-utils/" · 4b288136
      Thomas Haller authored
      The "shared" directory contains files that are possibly used by all components
      of NetworkManager repository.
      Some of these files are even copied as-is to other projects (VPN plugins, nm-applet)
      and used there without modification. Move those files to a separate directory.
      By moving them to a common directory, it is clearer that they belong
      together. Also, you can easier compare the copied versions to their
      original via
        $ diff -r ./shared/nm-utils/ /path/to/nm-vpn-plugin/shared/nm-utils/
  7. 15 Jun, 2016 3 commits
    • Thomas Haller's avatar
    • Thomas Haller's avatar
      libnm/vpn: add nm_vpn_editor_plugin_load_vt() · cf34211c
      Thomas Haller authored
      Let VPN plugins return a virtual function table to extend
      the API while bypassing libnm. This allows to add and use
      new functionality to VPN plugins without updating libnm.
      The actual definitions are in a header-only file
      "nm-vpn-editor-plugin-call.h", which can be copied to the
    • Thomas Haller's avatar
      libnm/vpn: pass NMVpnPluginInfo to the NMVpnEditorPlugin instance · 1c42375e
      Thomas Haller authored
      The NMVpnPluginInfo is essentially the .name file, that is, a
      configuration file about the plugin itself. Via NMVpnPluginInfo
      instance, the NMVpnEditorPlugin can be created.
      Usually, one would create a NMVpnPluginInfo (that is, reading the
      .name file) and then create a NMVpnEditorPlugin instance from there.
      In this case, usually the editor-plugin is owned by the plugin-info
      instance (although the API allows for creating the editor-plugin
      Now, pass the  NMVpnPluginInfo to the editor-plugin too.
      This is useful, because then the editor-plugin can look at the .name
      The .name file is not user configuration. Instead it is configuration
      about the plugin itself. Although the .name file is part of the plugin
      build artefacts, it is useful to allow the plugin to access the .name
      file. The reason is, that this can allow the user to easily change a
      configuration knob of the plugin without requiring to patch or the