PolicyKit: Branch 'master'

David Zeuthen david at kemper.freedesktop.org
Sun Feb 1 09:41:47 PST 2009


 src/polkitagent/Makefile.am           |    2 +-
 src/polkitagent/polkitagent.h         |    9 +++++++--
 src/polkitagent/polkitagentlistener.c |    1 +
 src/polkitagent/polkitagentlistener.h |    4 ++++
 src/polkitagent/polkitagentsession.c  |    1 +
 src/polkitagent/polkitagentsession.h  |    4 ++++
 src/polkitagent/polkitagenttypes.h    |    4 ++++
 7 files changed, 22 insertions(+), 3 deletions(-)

New commits:
commit a114ed8f1fee8dabffe004cf8092d986601e9510
Author: David Zeuthen <davidz at redhat.com>
Date:   Sun Feb 1 12:39:21 2009 -0500

    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.

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 at 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 at 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 at 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
 


More information about the hal-commit mailing list