diff options
author | Dan Williams <dcbw@redhat.com> | 2005-12-06 23:37:09 +0000 |
---|---|---|
committer | Dan Williams <dcbw@redhat.com> | 2005-12-06 23:37:09 +0000 |
commit | 6bcf90acf26ace92a8384c6a378fa07de3cbf88c (patch) | |
tree | 9a9e51f605850476314263765269d1347c66c98b | |
parent | 4c42d4052c19eba7e8885576b8e1b09c176757d5 (diff) | |
download | NetworkManager-6bcf90acf26ace92a8384c6a378fa07de3cbf88c.tar.gz |
2005-12-06 Dan Williams <dcbw@redhat.com>
* Move NetworkManager.h -> include/NetworkManager.h
* Split out VPN stuff to include/NetworkManagerVPN.h
* Fix up makefiles to include new location
* Fix up sources to include NetworkManagerVPN.h
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1130 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | Makefile.am | 7 | ||||
-rw-r--r-- | configure.in | 1 | ||||
-rw-r--r-- | dispatcher-daemon/Makefile.am | 3 | ||||
-rw-r--r-- | gnome/applet/Makefile.am | 2 | ||||
-rw-r--r-- | gnome/applet/vpn-connection.h | 1 | ||||
-rw-r--r-- | gnome/libnm_glib/Makefile.am | 2 | ||||
-rw-r--r-- | include/Makefile.am | 7 | ||||
-rw-r--r-- | include/NetworkManager.h (renamed from NetworkManager.h) | 57 | ||||
-rw-r--r-- | include/NetworkManagerVPN.h | 90 | ||||
-rw-r--r-- | src/Makefile.am | 7 | ||||
-rw-r--r-- | src/backends/Makefile.am | 7 | ||||
-rw-r--r-- | src/dhcp-manager/Makefile.am | 6 | ||||
-rw-r--r-- | src/vpn-manager/Makefile.am | 6 | ||||
-rw-r--r-- | src/vpn-manager/nm-dbus-vpn.c | 1 | ||||
-rw-r--r-- | src/vpn-manager/nm-vpn-service.h | 1 | ||||
-rw-r--r-- | test/Makefile.am | 5 | ||||
-rw-r--r-- | vpn-daemons/openvpn/src/nm-openvpn-service.c | 1 | ||||
-rw-r--r-- | vpn-daemons/vpnc/src/Makefile.am | 2 | ||||
-rw-r--r-- | vpn-daemons/vpnc/src/nm-vpnc-service.c | 1 |
20 files changed, 142 insertions, 72 deletions
@@ -1,5 +1,12 @@ 2005-12-06 Dan Williams <dcbw@redhat.com> + * Move NetworkManager.h -> include/NetworkManager.h + * Split out VPN stuff into include/NetworkManagerVPN.h + * Fix up makefiles to include new location + * Fix up sources to include NetworkManagerVPN.h + +2005-12-06 Dan Williams <dcbw@redhat.com> + Various changes in the applet to move VPN connection "state" -> "stage", which it actually is. I'd like to change the signal as well when we break compat in the near future. diff --git a/Makefile.am b/Makefile.am index 02504ed123..e903c35401 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,9 +1,8 @@ -SUBDIRS = utils src dispatcher-daemon gnome initscript test po +SUBDIRS = utils src dispatcher-daemon gnome initscript test po include EXTRA_DIST = \ CONTRIBUTING \ NetworkManager.pc.in \ - NetworkManager.h \ intltool-extract.in \ intltool-merge.in \ intltool-update.in @@ -13,7 +12,3 @@ DISTCLEANFILES = intltool-extract intltool-merge intltool-update pkgconfigdir = $(libdir)/pkgconfig pkgconfig_DATA = NetworkManager.pc - -NetworkManagerincludedir=$(includedir)/NetworkManager - -NetworkManagerinclude_HEADERS = NetworkManager.h diff --git a/configure.in b/configure.in index 11ae23da5e..97996c5996 100644 --- a/configure.in +++ b/configure.in @@ -280,6 +280,7 @@ fi AC_OUTPUT([ Makefile +include/Makefile utils/Makefile src/Makefile src/named-manager/Makefile diff --git a/dispatcher-daemon/Makefile.am b/dispatcher-daemon/Makefile.am index 6278ca41f8..2841d45217 100644 --- a/dispatcher-daemon/Makefile.am +++ b/dispatcher-daemon/Makefile.am @@ -1,4 +1,5 @@ -INCLUDES = -I${top_srcdir} -I${top_srcdir}/utils +INCLUDES = -I${top_srcdir} -I${top_srcdir}/utils -I${top_srcdir}/include + NULL= bin_PROGRAMS = NetworkManagerDispatcher diff --git a/gnome/applet/Makefile.am b/gnome/applet/Makefile.am index a01b02f19a..d229fb9996 100644 --- a/gnome/applet/Makefile.am +++ b/gnome/applet/Makefile.am @@ -2,7 +2,7 @@ SUBDIRS=icons NULL= -INCLUDES = -I${top_srcdir} -I${top_srcdir}/utils +INCLUDES = -I${top_srcdir} -I${top_srcdir}/utils -I${top_srcdir}/include bin_PROGRAMS = nm-applet diff --git a/gnome/applet/vpn-connection.h b/gnome/applet/vpn-connection.h index ed5e58d4a9..e710a6fd43 100644 --- a/gnome/applet/vpn-connection.h +++ b/gnome/applet/vpn-connection.h @@ -23,6 +23,7 @@ #define VPN_CONNECTION_H #include "applet.h" +#include "NetworkManagerVPN.h" VPNConnection * nmwa_vpn_connection_new (const char *name); VPNConnection * nmwa_vpn_connection_copy (VPNConnection *vpn); diff --git a/gnome/libnm_glib/Makefile.am b/gnome/libnm_glib/Makefile.am index 5ad8d7f8a7..2bc9dd8ff6 100644 --- a/gnome/libnm_glib/Makefile.am +++ b/gnome/libnm_glib/Makefile.am @@ -1,4 +1,4 @@ -INCLUDES = -I${top_srcdir} -I${top_srcdir}/utils +INCLUDES = -I${top_srcdir} -I${top_srcdir}/utils -I${top_srcdir}/include lib_LTLIBRARIES=libnm_glib.la diff --git a/include/Makefile.am b/include/Makefile.am new file mode 100644 index 0000000000..280122f52e --- /dev/null +++ b/include/Makefile.am @@ -0,0 +1,7 @@ +EXTRA_DIST = \ + NetworkManager.h \ + NetworkManagerVPN.h + +NetworkManagerincludedir=$(includedir)/NetworkManager + +NetworkManagerinclude_HEADERS = NetworkManager.h NetworkManagerVPN.h diff --git a/NetworkManager.h b/include/NetworkManager.h index 04b03e3301..e81dc85fc4 100644 --- a/NetworkManager.h +++ b/include/NetworkManager.h @@ -33,8 +33,6 @@ #define NM_DBUS_INTERFACE_DEVICES "org.freedesktop.NetworkManager.Devices" #define NM_DBUS_PATH_DHCP "/org/freedesktop/NetworkManager/DhcpOptions" #define NM_DBUS_INTERFACE_DHCP "org.freedesktop.NetworkManager.DhcpOptions" -#define NM_DBUS_PATH_VPN "/org/freedesktop/NetworkManager/VPNConnections" -#define NM_DBUS_INTERFACE_VPN "org.freedesktop.NetworkManager.VPNConnections" #define NMI_DBUS_SERVICE "org.freedesktop.NetworkManagerInfo" #define NMI_DBUS_PATH "/org/freedesktop/NetworkManagerInfo" @@ -50,30 +48,6 @@ #define NM_DBUS_NO_ACTIVE_DEVICE_ERROR "org.freedesktop.NetworkManager.NoActiveDevice" #define NM_DBUS_NO_ACTIVE_NET_ERROR "org.freedesktop.NetworkManager.NoActiveNetwork" -#define NM_DBUS_NO_ACTIVE_VPN_CONNECTION "org.freedesktop.NetworkManager.VPNConnections.NoActiveVPNConnection" -#define NM_DBUS_NO_VPN_CONNECTIONS "org.freedesktop.NetworkManager.VPNConnections.NoVPNConnections" -#define NM_DBUS_INVALID_VPN_CONNECTION "org.freedesktop.NetworkManager.VPNConnections.InvalidVPNConnection" - -#define NM_DBUS_VPN_STARTING_IN_PROGRESS "StartingInProgress" -#define NM_DBUS_VPN_ALREADY_STARTED "AlreadyStarted" -#define NM_DBUS_VPN_STOPPING_IN_PROGRESS "StoppingInProgress" -#define NM_DBUS_VPN_ALREADY_STOPPED "AlreadyStopped" -#define NM_DBUS_VPN_WRONG_STATE "WrongState" -#define NM_DBUS_VPN_BAD_ARGUMENTS "BadArguments" - - -/* - * VPN daemon signals - */ -#define NM_DBUS_VPN_SIGNAL_LOGIN_BANNER "LoginBanner" -#define NM_DBUS_VPN_SIGNAL_LOGIN_FAILED "LoginFailed" -#define NM_DBUS_VPN_SIGNAL_LAUNCH_FAILED "LaunchFailed" -#define NM_DBUS_VPN_SIGNAL_CONNECT_FAILED "ConnectFailed" -#define NM_DBUS_VPN_SIGNAL_VPN_CONFIG_BAD "VPNConfigBad" -#define NM_DBUS_VPN_SIGNAL_IP_CONFIG_BAD "IPConfigBad" -#define NM_DBUS_VPN_SIGNAL_STATE_CHANGE "StateChange" -#define NM_DBUS_VPN_SIGNAL_IP4_CONFIG "IP4Config" - /* * NetworkManager signals @@ -177,37 +151,6 @@ typedef enum NMDeviceAuthMethod /* - * VPN daemon states - */ -typedef enum NMVPNState -{ - NM_VPN_STATE_UNKNOWN = 0, - NM_VPN_STATE_INIT, - NM_VPN_STATE_SHUTDOWN, - NM_VPN_STATE_STARTING, - NM_VPN_STATE_STARTED, - NM_VPN_STATE_STOPPING, - NM_VPN_STATE_STOPPED -} NMVPNState; - - -/* - * VPN connection activation stages - */ -typedef enum NMVPNActStage -{ - NM_VPN_ACT_STAGE_UNKNOWN = 0, - NM_VPN_ACT_STAGE_DISCONNECTED, - NM_VPN_ACT_STAGE_PREPARE, - NM_VPN_ACT_STAGE_CONNECT, - NM_VPN_ACT_STAGE_IP_CONFIG_GET, - NM_VPN_ACT_STAGE_ACTIVATED, - NM_VPN_ACT_STAGE_FAILED, - NM_VPN_ACT_STAGE_CANCELED -} NMVPNActStage; - - -/* * Device activation stages */ typedef enum NMActStage diff --git a/include/NetworkManagerVPN.h b/include/NetworkManagerVPN.h new file mode 100644 index 0000000000..6927da105d --- /dev/null +++ b/include/NetworkManagerVPN.h @@ -0,0 +1,90 @@ +/* NetworkManager -- Network link manager + * + * Dan Williams <dcbw@redhat.com> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * + * (C) Copyright 2004 Red Hat, Inc. + */ + +#ifndef NETWORK_MANAGER_VPN_H +#define NETWORK_MANAGER_VPN_H + +/* + * dbus services details + */ +#define NM_DBUS_PATH_VPN "/org/freedesktop/NetworkManager/VPNConnections" +#define NM_DBUS_INTERFACE_VPN "org.freedesktop.NetworkManager.VPNConnections" + + +/* + * VPN Errors + */ +#define NM_DBUS_NO_ACTIVE_VPN_CONNECTION "org.freedesktop.NetworkManager.VPNConnections.NoActiveVPNConnection" +#define NM_DBUS_NO_VPN_CONNECTIONS "org.freedesktop.NetworkManager.VPNConnections.NoVPNConnections" +#define NM_DBUS_INVALID_VPN_CONNECTION "org.freedesktop.NetworkManager.VPNConnections.InvalidVPNConnection" + +#define NM_DBUS_VPN_STARTING_IN_PROGRESS "StartingInProgress" +#define NM_DBUS_VPN_ALREADY_STARTED "AlreadyStarted" +#define NM_DBUS_VPN_STOPPING_IN_PROGRESS "StoppingInProgress" +#define NM_DBUS_VPN_ALREADY_STOPPED "AlreadyStopped" +#define NM_DBUS_VPN_WRONG_STATE "WrongState" +#define NM_DBUS_VPN_BAD_ARGUMENTS "BadArguments" + + +/* + * VPN daemon signals + */ +#define NM_DBUS_VPN_SIGNAL_LOGIN_BANNER "LoginBanner" +#define NM_DBUS_VPN_SIGNAL_LOGIN_FAILED "LoginFailed" +#define NM_DBUS_VPN_SIGNAL_LAUNCH_FAILED "LaunchFailed" +#define NM_DBUS_VPN_SIGNAL_CONNECT_FAILED "ConnectFailed" +#define NM_DBUS_VPN_SIGNAL_VPN_CONFIG_BAD "VPNConfigBad" +#define NM_DBUS_VPN_SIGNAL_IP_CONFIG_BAD "IPConfigBad" +#define NM_DBUS_VPN_SIGNAL_STATE_CHANGE "StateChange" +#define NM_DBUS_VPN_SIGNAL_IP4_CONFIG "IP4Config" + +/* + * VPN daemon states + */ +typedef enum NMVPNState +{ + NM_VPN_STATE_UNKNOWN = 0, + NM_VPN_STATE_INIT, + NM_VPN_STATE_SHUTDOWN, + NM_VPN_STATE_STARTING, + NM_VPN_STATE_STARTED, + NM_VPN_STATE_STOPPING, + NM_VPN_STATE_STOPPED +} NMVPNState; + + +/* + * VPN connection activation stages + */ +typedef enum NMVPNActStage +{ + NM_VPN_ACT_STAGE_UNKNOWN = 0, + NM_VPN_ACT_STAGE_DISCONNECTED, + NM_VPN_ACT_STAGE_PREPARE, + NM_VPN_ACT_STAGE_CONNECT, + NM_VPN_ACT_STAGE_IP_CONFIG_GET, + NM_VPN_ACT_STAGE_ACTIVATED, + NM_VPN_ACT_STAGE_FAILED, + NM_VPN_ACT_STAGE_CANCELED +} NMVPNActStage; + + +#endif /* NETWORK_MANAGER_VPN_H */ diff --git a/src/Makefile.am b/src/Makefile.am index 5e23322017..356755c0a0 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -1,6 +1,11 @@ SUBDIRS=named-manager vpn-manager dhcp-manager backends -INCLUDES = -I${top_srcdir} -I${top_srcdir}/src/named-manager -I${top_srcdir}/src/vpn-manager -I${top_srcdir}/src/dhcp-manager -I${top_srcdir}/utils +INCLUDES = -I${top_srcdir} \ + -I${top_srcdir}/include \ + -I${top_srcdir}/src/named-manager \ + -I${top_srcdir}/src/vpn-manager \ + -I${top_srcdir}/src/dhcp-manager \ + -I${top_srcdir}/utils bin_PROGRAMS = NetworkManager diff --git a/src/backends/Makefile.am b/src/backends/Makefile.am index f25998f606..3e1ad3b038 100644 --- a/src/backends/Makefile.am +++ b/src/backends/Makefile.am @@ -1,4 +1,9 @@ -INCLUDES = -I${top_srcdir} -I${top_srcdir}/src/named-manager -I${top_srcdir}/src/vpn-manager -I${top_srcdir}/src -I${top_srcdir}/utils +INCLUDES = -I${top_srcdir} \ + -I${top_srcdir}/include \ + -I${top_srcdir}/utils \ + -I${top_srcdir}/src \ + -I${top_srcdir}/src/vpn-manager \ + -I${top_srcdir}/src/named-manager noinst_LTLIBRARIES = libnmbackend.la diff --git a/src/dhcp-manager/Makefile.am b/src/dhcp-manager/Makefile.am index 6e00438d5f..500c9b32dd 100644 --- a/src/dhcp-manager/Makefile.am +++ b/src/dhcp-manager/Makefile.am @@ -1,4 +1,8 @@ -INCLUDES = -I${top_srcdir} -I${top_srcdir}/utils -I${top_srcdir}/src -I${top_srcdir}/src/named-manager +INCLUDES = -I${top_srcdir} \ + -I${top_srcdir}/include \ + -I${top_srcdir}/utils \ + -I${top_srcdir}/src \ + -I${top_srcdir}/src/named-manager noinst_LTLIBRARIES = libdhcp-manager.la diff --git a/src/vpn-manager/Makefile.am b/src/vpn-manager/Makefile.am index 51dc6d9959..d7b72e3d11 100644 --- a/src/vpn-manager/Makefile.am +++ b/src/vpn-manager/Makefile.am @@ -1,4 +1,8 @@ -INCLUDES = -I${top_srcdir} -I${top_srcdir}/utils -I${top_srcdir}/src -I${top_srcdir}/src/named-manager +INCLUDES = -I${top_srcdir} \ + -I${top_srcdir}/include \ + -I${top_srcdir}/utils \ + -I${top_srcdir}/src \ + -I${top_srcdir}/src/named-manager noinst_LTLIBRARIES = libvpn-manager.la diff --git a/src/vpn-manager/nm-dbus-vpn.c b/src/vpn-manager/nm-dbus-vpn.c index 99102d8d90..78bca57023 100644 --- a/src/vpn-manager/nm-dbus-vpn.c +++ b/src/vpn-manager/nm-dbus-vpn.c @@ -25,6 +25,7 @@ #include "NetworkManagerDevice.h" #include "NetworkManagerDbus.h" #include "NetworkManagerUtils.h" +#include "NetworkManagerVPN.h" #include "nm-dbus-vpn.h" #include "nm-vpn-manager.h" #include "nm-vpn-connection.h" diff --git a/src/vpn-manager/nm-vpn-service.h b/src/vpn-manager/nm-vpn-service.h index 253fdb6553..b1ee92ff60 100644 --- a/src/vpn-manager/nm-vpn-service.h +++ b/src/vpn-manager/nm-vpn-service.h @@ -25,6 +25,7 @@ #include <dbus/dbus.h> #include "NetworkManager.h" +#include "NetworkManagerVPN.h" #include "NetworkManagerMain.h" #include "nm-vpn-connection.h" diff --git a/test/Makefile.am b/test/Makefile.am index 5f80bea2ef..d5665716d1 100644 --- a/test/Makefile.am +++ b/test/Makefile.am @@ -1,4 +1,7 @@ -INCLUDES = -I${top_srcdir} -I${top_srcdir}/gnome/libnm_glib -I${top_srcdir}/utils +INCLUDES = -I${top_srcdir} \ + -I${top_srcdir}/gnome/libnm_glib \ + -I${top_srcdir}/utils \ + -I${top_srcdir}/include AM_CPPFLAGS = \ $(DBUS_CFLAGS) \ diff --git a/vpn-daemons/openvpn/src/nm-openvpn-service.c b/vpn-daemons/openvpn/src/nm-openvpn-service.c index 8de2af2426..0be20033e9 100644 --- a/vpn-daemons/openvpn/src/nm-openvpn-service.c +++ b/vpn-daemons/openvpn/src/nm-openvpn-service.c @@ -45,6 +45,7 @@ #include <ctype.h> #include <NetworkManager/NetworkManager.h> +#include <NetworkManager/NetworkManagerVPN.h> #include "nm-openvpn-service.h" #include "nm-utils.h" diff --git a/vpn-daemons/vpnc/src/Makefile.am b/vpn-daemons/vpnc/src/Makefile.am index e6cb9e78fa..87160b8a4b 100644 --- a/vpn-daemons/vpnc/src/Makefile.am +++ b/vpn-daemons/vpnc/src/Makefile.am @@ -1,4 +1,4 @@ -INCLUDES = -I${top_srcdir} -I${top_srcdir}/utils -I${top_srcdir}/vpn-daemons/vpnc +INCLUDES = -I${top_srcdir} -I${top_srcdir}/utils -I${top_srcdir}/vpn-daemons/vpnc AM_CPPFLAGS = \ $(DBUS_CFLAGS) \ diff --git a/vpn-daemons/vpnc/src/nm-vpnc-service.c b/vpn-daemons/vpnc/src/nm-vpnc-service.c index 897b8426a8..b95173ae2d 100644 --- a/vpn-daemons/vpnc/src/nm-vpnc-service.c +++ b/vpn-daemons/vpnc/src/nm-vpnc-service.c @@ -42,6 +42,7 @@ #include <ctype.h> #include <NetworkManager/NetworkManager.h> +#include <NetworkManager/NetworkManagerVPN.h> #include "nm-vpnc-service.h" #include "nm-utils.h" |