summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDavid Zeuthen <davidz@redhat.com>2009-02-01 12:39:21 -0500
committerDavid Zeuthen <davidz@redhat.com>2009-02-01 12:39:21 -0500
commita114ed8f1fee8dabffe004cf8092d986601e9510 (patch)
tree917ac15260457d110fd30f63468eb210ca32231b /src
parent2f0e640fb93cec4395e926f3ea50037435cf78d0 (diff)
downloadpolkit-a114ed8f1fee8dabffe004cf8092d986601e9510.tar.gz
require POLKIT_AGENT_I_KNOW_API_IS_SUBJECT_TO_CHANGE to be defined
Also use @stability in the docs to indicate that the interface is currently subject to change.
Diffstat (limited to 'src')
-rw-r--r--src/polkitagent/Makefile.am2
-rw-r--r--src/polkitagent/polkitagent.h9
-rw-r--r--src/polkitagent/polkitagentlistener.c1
-rw-r--r--src/polkitagent/polkitagentlistener.h4
-rw-r--r--src/polkitagent/polkitagentsession.c1
-rw-r--r--src/polkitagent/polkitagentsession.h4
-rw-r--r--src/polkitagent/polkitagenttypes.h4
7 files changed, 22 insertions, 3 deletions
diff --git a/src/polkitagent/Makefile.am b/src/polkitagent/Makefile.am
index 49f6afd..0acdc7f 100644
--- a/src/polkitagent/Makefile.am
+++ b/src/polkitagent/Makefile.am
@@ -12,6 +12,7 @@ INCLUDES = \
-DPACKAGE_LIB_DIR=\""$(libdir)"\" \
-D_POSIX_PTHREAD_SEMANTICS \
-D_REENTRANT \
+ -DPOLKIT_AGENT_COMPILATION \
-DEGG_DBUS_I_KNOW_API_IS_SUBJECT_TO_CHANGE \
$(NULL)
@@ -60,7 +61,6 @@ libpolkit_agent_1_la_SOURCES = \
$(NULL)
libpolkit_agent_1_la_CFLAGS = \
- -D_POLKIT_AGENT_COMPILATION \
$(GLIB_CFLAGS) \
$(EGG_DBUS_CFLAGS) \
$(NULL)
diff --git a/src/polkitagent/polkitagent.h b/src/polkitagent/polkitagent.h
index 4b56683..d417e5d 100644
--- a/src/polkitagent/polkitagent.h
+++ b/src/polkitagent/polkitagent.h
@@ -22,9 +22,14 @@
#ifndef __POLKIT_AGENT_H
#define __POLKIT_AGENT_H
-#define _POLKIT_AGENT_INSIDE_POLKIT_AGENT_H 1
+#if !defined (POLKIT_AGENT_I_KNOW_API_IS_SUBJECT_TO_CHANGE) && !defined (POLKIT_AGENT_COMPILATION)
+#error "libpolkitagent is unstable API and subject to change. You must define POLKIT_AGENT_I_KNOW_API_IS_SUBJECT_TO_CHANGE to acknowledge this."
+#endif
+
+#define POLKIT_AGENT_INSIDE_POLKIT_AGENT_H 1
+#include <polkitagent/polkitagenttypes.h>
#include <polkitagent/polkitagentlistener.h>
#include <polkitagent/polkitagentsession.h>
-#undef _POLKIT_AGENT_INSIDE_POLKIT_AGENT_H
+#undef POLKIT_AGENT_INSIDE_POLKIT_AGENT_H
#endif /* __POLKIT_AGENT_H */
diff --git a/src/polkitagent/polkitagentlistener.c b/src/polkitagent/polkitagentlistener.c
index 313d38f..c1c6771 100644
--- a/src/polkitagent/polkitagentlistener.c
+++ b/src/polkitagent/polkitagentlistener.c
@@ -30,6 +30,7 @@
* SECTION:polkitagentlistener
* @title: PolkitAgentListener
* @short_description: Abstract base class for Authentication Agents
+ * @stability: Unstable
*
* #PolkitAgentListener is an abstract base class used for implementing authentication
* agents. To implement an authentication agent, simply subclass #PolkitAgentListener and
diff --git a/src/polkitagent/polkitagentlistener.h b/src/polkitagent/polkitagentlistener.h
index b50e922..dc17bc3 100644
--- a/src/polkitagent/polkitagentlistener.h
+++ b/src/polkitagent/polkitagentlistener.h
@@ -19,6 +19,10 @@
* Author: David Zeuthen <davidz@redhat.com>
*/
+#if !defined(POLKIT_AGENT_INSIDE_POLKIT_AGENT_H) && !defined (POLKIT_AGENT_COMPILATION)
+#error "Only <polkitagent/polkitagent.h> can be included directly, this file may disappear or change contents"
+#endif
+
#ifndef __POLKIT_AGENT_LISTENER_H
#define __POLKIT_AGENT_LISTENER_H
diff --git a/src/polkitagent/polkitagentsession.c b/src/polkitagent/polkitagentsession.c
index 184dd2b..4327b4b 100644
--- a/src/polkitagent/polkitagentsession.c
+++ b/src/polkitagent/polkitagentsession.c
@@ -23,6 +23,7 @@
* SECTION:polkitagentsession
* @title: PolkitAgentSession
* @short_description: Authentication Session
+ * @stability: Unstable
*
* The #PolkitAgentSession class is an abstraction used for interacting with the
* native authentication system (for example PAM) for obtaining authorizations.
diff --git a/src/polkitagent/polkitagentsession.h b/src/polkitagent/polkitagentsession.h
index acba074..be01852 100644
--- a/src/polkitagent/polkitagentsession.h
+++ b/src/polkitagent/polkitagentsession.h
@@ -19,6 +19,10 @@
* Author: David Zeuthen <davidz@redhat.com>
*/
+#if !defined(POLKIT_AGENT_INSIDE_POLKIT_AGENT_H) && !defined (POLKIT_AGENT_COMPILATION)
+#error "Only <polkitagent/polkitagent.h> can be included directly, this file may disappear or change contents"
+#endif
+
#ifndef __POLKIT_AGENT_SESSION_H
#define __POLKIT_AGENT_SESSION_H
diff --git a/src/polkitagent/polkitagenttypes.h b/src/polkitagent/polkitagenttypes.h
index 2405ebc..c1143be 100644
--- a/src/polkitagent/polkitagenttypes.h
+++ b/src/polkitagent/polkitagenttypes.h
@@ -19,6 +19,10 @@
* Author: David Zeuthen <davidz@redhat.com>
*/
+#if !defined(POLKIT_AGENT_INSIDE_POLKIT_AGENT_H) && !defined (POLKIT_AGENT_COMPILATION)
+#error "Only <polkitagent/polkitagent.h> can be included directly, this file may disappear or change contents"
+#endif
+
#ifndef __POLKIT_AGENT_TYPES_H
#define __POLKIT_AGENT_TYPES_H