summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWill Thompson <will.thompson@collabora.co.uk>2012-01-31 16:58:02 +0000
committerWill Thompson <will.thompson@collabora.co.uk>2012-02-06 13:26:16 +0000
commit2f0be660cd161f5abcb2ab57331e85d0415415ea (patch)
tree45874fab4f18f59dfd39e72088f7df2d326f5617
parent4c8a53c6d00231203cab1f9f14959825a2adedb3 (diff)
Make #include <wocky/wocky.h> the only legal import.
-rw-r--r--examples/receive-messages.c4
-rw-r--r--examples/register.c3
-rw-r--r--examples/send-message.c4
-rw-r--r--examples/unregister.c3
-rw-r--r--tests/wocky-bare-contact-test.c4
-rw-r--r--tests/wocky-caps-hash-test.c3
-rw-r--r--tests/wocky-connector-test.c6
-rw-r--r--tests/wocky-contact-factory-test.c3
-rw-r--r--tests/wocky-data-form-test.c5
-rw-r--r--tests/wocky-http-proxy-test.c8
-rw-r--r--tests/wocky-jid-validation-test.c2
-rw-r--r--tests/wocky-loopback-test.c3
-rw-r--r--tests/wocky-node-tree-test.c3
-rw-r--r--tests/wocky-pep-service-test.c4
-rw-r--r--tests/wocky-ping-test.c5
-rw-r--r--tests/wocky-porter-test.c5
-rw-r--r--tests/wocky-pubsub-node-test.c4
-rw-r--r--tests/wocky-pubsub-service-test.c6
-rw-r--r--tests/wocky-pubsub-test-helpers.c2
-rw-r--r--tests/wocky-pubsub-test-helpers.h2
-rw-r--r--tests/wocky-resource-contact-test.c3
-rw-r--r--tests/wocky-roster-test.c8
-rw-r--r--tests/wocky-sasl-utils-test.c2
-rw-r--r--tests/wocky-scram-sha1-test.c2
-rw-r--r--tests/wocky-session-test.c3
-rw-r--r--tests/wocky-stanza-test.c5
-rw-r--r--tests/wocky-test-connector-server.c13
-rw-r--r--tests/wocky-test-helper.c2
-rw-r--r--tests/wocky-test-helper.h4
-rw-r--r--tests/wocky-test-sasl-auth-server.c3
-rw-r--r--tests/wocky-test-sasl-auth-server.h3
-rw-r--r--tests/wocky-test-sasl-auth.c4
-rw-r--r--tests/wocky-test-sasl-handler.c2
-rw-r--r--tests/wocky-tls-test.c3
-rw-r--r--tests/wocky-utils-test.c2
-rw-r--r--tests/wocky-xmpp-connection-test.c3
-rw-r--r--tests/wocky-xmpp-node-test.c5
-rw-r--r--tests/wocky-xmpp-reader-test.c2
-rw-r--r--tests/wocky-xmpp-readwrite-test.c4
-rw-r--r--wocky/Makefile.am4
-rw-r--r--wocky/wocky-auth-handler.h3
-rw-r--r--wocky/wocky-auth-registry.h5
-rw-r--r--wocky/wocky-bare-contact.h3
-rw-r--r--wocky/wocky-c2s-porter.h3
-rw-r--r--wocky/wocky-caps-cache.h3
-rw-r--r--wocky/wocky-caps-hash.h3
-rw-r--r--wocky/wocky-connector.h3
-rw-r--r--wocky/wocky-contact-factory.h3
-rw-r--r--wocky/wocky-contact.h3
-rw-r--r--wocky/wocky-data-form.h3
-rw-r--r--wocky/wocky-debug.h3
-rw-r--r--wocky/wocky-disco-identity.h3
-rw-r--r--wocky/wocky-heartbeat-source.h4
-rw-r--r--wocky/wocky-http-proxy.h3
-rw-r--r--wocky/wocky-jabber-auth-digest.h4
-rw-r--r--wocky/wocky-jabber-auth-password.h4
-rw-r--r--wocky/wocky-jabber-auth.h3
-rw-r--r--wocky/wocky-ll-connection-factory.h3
-rw-r--r--wocky/wocky-ll-connector.h3
-rw-r--r--wocky/wocky-ll-contact.h3
-rw-r--r--wocky/wocky-loopback-stream.h3
-rw-r--r--wocky/wocky-meta-porter.h3
-rw-r--r--wocky/wocky-muc.h4
-rw-r--r--wocky/wocky-namespaces.h3
-rw-r--r--wocky/wocky-node-private.h3
-rw-r--r--wocky/wocky-node-tree.h3
-rw-r--r--wocky/wocky-node.h3
-rw-r--r--wocky/wocky-pep-service.h3
-rw-r--r--wocky/wocky-ping.h3
-rw-r--r--wocky/wocky-porter.h3
-rw-r--r--wocky/wocky-pubsub-helpers.h3
-rw-r--r--wocky/wocky-pubsub-node-protected.h3
-rw-r--r--wocky/wocky-pubsub-node.h3
-rw-r--r--wocky/wocky-pubsub-service-protected.h3
-rw-r--r--wocky/wocky-pubsub-service.h3
-rw-r--r--wocky/wocky-resource-contact.h3
-rw-r--r--wocky/wocky-roster.h3
-rw-r--r--wocky/wocky-sasl-auth.h3
-rw-r--r--wocky/wocky-sasl-digest-md5.h4
-rw-r--r--wocky/wocky-sasl-plain.h4
-rw-r--r--wocky/wocky-sasl-scram.h5
-rw-r--r--wocky/wocky-session.h3
-rw-r--r--wocky/wocky-stanza.h3
-rw-r--r--wocky/wocky-tls-connector.h3
-rw-r--r--wocky/wocky-tls-handler.h3
-rw-r--r--wocky/wocky-tls.h3
-rw-r--r--wocky/wocky-types.h3
-rw-r--r--wocky/wocky-utils.h3
-rw-r--r--wocky/wocky-xep-0115-capabilities.h3
-rw-r--r--wocky/wocky-xmpp-connection.h3
-rw-r--r--wocky/wocky-xmpp-error.h3
-rw-r--r--wocky/wocky-xmpp-reader.h3
-rw-r--r--wocky/wocky-xmpp-writer.h3
-rw-r--r--wocky/wocky.h53
94 files changed, 268 insertions, 110 deletions
diff --git a/examples/receive-messages.c b/examples/receive-messages.c
index f3f7d02..fbec62f 100644
--- a/examples/receive-messages.c
+++ b/examples/receive-messages.c
@@ -6,11 +6,7 @@
#include <glib.h>
#include <gio/gio.h>
-#include <wocky/wocky-connector.h>
-#include <wocky/wocky-xmpp-connection.h>
#include <wocky/wocky.h>
-#include <wocky/wocky-porter.h>
-#include <wocky/wocky-session.h>
GMainLoop *mainloop;
diff --git a/examples/register.c b/examples/register.c
index 97374cf..d59bf80 100644
--- a/examples/register.c
+++ b/examples/register.c
@@ -6,8 +6,7 @@
#include <glib.h>
#include <gio/gio.h>
-#include <wocky/wocky-connector.h>
-#include <wocky/wocky-utils.h>
+#include <wocky/wocky.h>
GMainLoop *mainloop;
diff --git a/examples/send-message.c b/examples/send-message.c
index 828ad6e..3e10465 100644
--- a/examples/send-message.c
+++ b/examples/send-message.c
@@ -6,11 +6,7 @@
#include <glib.h>
#include <gio/gio.h>
-#include <wocky/wocky-connector.h>
-#include <wocky/wocky-xmpp-connection.h>
#include <wocky/wocky.h>
-#include <wocky/wocky-porter.h>
-#include <wocky/wocky-session.h>
GMainLoop *mainloop;
char *recipient;
diff --git a/examples/unregister.c b/examples/unregister.c
index 0f8211e..34e09b1 100644
--- a/examples/unregister.c
+++ b/examples/unregister.c
@@ -6,8 +6,7 @@
#include <glib.h>
#include <gio/gio.h>
-#include <wocky/wocky-connector.h>
-#include <wocky/wocky-utils.h>
+#include <wocky/wocky.h>
GMainLoop *mainloop;
int rval = -1;
diff --git a/tests/wocky-bare-contact-test.c b/tests/wocky-bare-contact-test.c
index b03e528..336df13 100644
--- a/tests/wocky-bare-contact-test.c
+++ b/tests/wocky-bare-contact-test.c
@@ -4,9 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-bare-contact.h>
-#include <wocky/wocky-resource-contact.h>
-#include <wocky/wocky-utils.h>
+#include <wocky/wocky.h>
#include "wocky-test-helper.h"
diff --git a/tests/wocky-caps-hash-test.c b/tests/wocky-caps-hash-test.c
index 8cbd83b..55cf9e3 100644
--- a/tests/wocky-caps-hash-test.c
+++ b/tests/wocky-caps-hash-test.c
@@ -1,7 +1,6 @@
#include <glib.h>
-#include <wocky/wocky-caps-hash.h>
-#include <wocky/wocky-stanza.h>
+#include <wocky/wocky.h>
#include "wocky-test-helper.h"
diff --git a/tests/wocky-connector-test.c b/tests/wocky-connector-test.c
index 663cc49..82c12b2 100644
--- a/tests/wocky-connector-test.c
+++ b/tests/wocky-connector-test.c
@@ -19,11 +19,7 @@
#include <arpa/inet.h>
#endif
-#include <wocky/wocky-connector.h>
-#include <wocky/wocky-namespaces.h>
-#include <wocky/wocky-sasl-auth.h>
-#include <wocky/wocky-utils.h>
-#include <wocky/wocky-xmpp-error.h>
+#include <wocky/wocky.h>
#include "wocky-test-connector-server.h"
#include "test-resolver.h"
diff --git a/tests/wocky-contact-factory-test.c b/tests/wocky-contact-factory-test.c
index 864e15a..99dd7b1 100644
--- a/tests/wocky-contact-factory-test.c
+++ b/tests/wocky-contact-factory-test.c
@@ -4,8 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-contact-factory.h>
-#include <wocky/wocky-utils.h>
+#include <wocky/wocky.h>
#include "wocky-test-helper.h"
diff --git a/tests/wocky-data-form-test.c b/tests/wocky-data-form-test.c
index 6ea1e69..29c4410 100644
--- a/tests/wocky-data-form-test.c
+++ b/tests/wocky-data-form-test.c
@@ -4,10 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-data-form.h>
-#include <wocky/wocky-stanza.h>
-#include <wocky/wocky-namespaces.h>
-#include <wocky/wocky-utils.h>
+#include <wocky/wocky.h>
#include "wocky-test-helper.h"
diff --git a/tests/wocky-http-proxy-test.c b/tests/wocky-http-proxy-test.c
index 9567401..ac9cca2 100644
--- a/tests/wocky-http-proxy-test.c
+++ b/tests/wocky-http-proxy-test.c
@@ -3,8 +3,14 @@
#include <string.h>
+#include <wocky/wocky.h>
+
+/* WockyHttpProxy isn't public API, so we need to be a bit sneaky to get the
+ * header.
+ */
+#define WOCKY_COMPILATION
#include <wocky/wocky-http-proxy.h>
-#include <wocky/wocky-utils.h>
+#undef WOCKY_COMPILATION
typedef enum
{
diff --git a/tests/wocky-jid-validation-test.c b/tests/wocky-jid-validation-test.c
index e3f10ca..b2d22bf 100644
--- a/tests/wocky-jid-validation-test.c
+++ b/tests/wocky-jid-validation-test.c
@@ -1,6 +1,6 @@
#include <glib.h>
-#include <wocky/wocky-utils.h>
+#include <wocky/wocky.h>
#include "wocky-test-helper.h"
diff --git a/tests/wocky-loopback-test.c b/tests/wocky-loopback-test.c
index 712fc3e..9afc7a3 100644
--- a/tests/wocky-loopback-test.c
+++ b/tests/wocky-loopback-test.c
@@ -1,5 +1,4 @@
-#include <wocky/wocky-c2s-porter.h>
-#include <wocky/wocky-loopback-stream.h>
+#include <wocky/wocky.h>
#include "wocky-test-helper.h"
diff --git a/tests/wocky-node-tree-test.c b/tests/wocky-node-tree-test.c
index 5dc6cb6..8385bea 100644
--- a/tests/wocky-node-tree-test.c
+++ b/tests/wocky-node-tree-test.c
@@ -4,8 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-node-tree.h>
-#include <wocky/wocky-namespaces.h>
+#include <wocky/wocky.h>
#include "wocky-test-helper.h"
diff --git a/tests/wocky-pep-service-test.c b/tests/wocky-pep-service-test.c
index bb8bcae..85f88fc 100644
--- a/tests/wocky-pep-service-test.c
+++ b/tests/wocky-pep-service-test.c
@@ -4,9 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-pep-service.h>
-#include <wocky/wocky-utils.h>
-#include <wocky/wocky-namespaces.h>
+#include <wocky/wocky.h>
#include "wocky-test-stream.h"
#include "wocky-test-helper.h"
diff --git a/tests/wocky-ping-test.c b/tests/wocky-ping-test.c
index 22783e5..6470791 100644
--- a/tests/wocky-ping-test.c
+++ b/tests/wocky-ping-test.c
@@ -4,10 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-ping.h>
-#include <wocky/wocky-utils.h>
-#include <wocky/wocky-namespaces.h>
-#include <wocky/wocky-xmpp-error.h>
+#include <wocky/wocky.h>
#include "wocky-test-stream.h"
#include "wocky-test-helper.h"
diff --git a/tests/wocky-porter-test.c b/tests/wocky-porter-test.c
index 662428a..e96f965 100644
--- a/tests/wocky-porter-test.c
+++ b/tests/wocky-porter-test.c
@@ -4,10 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-c2s-porter.h>
-#include <wocky/wocky-utils.h>
-#include <wocky/wocky-namespaces.h>
-#include <wocky/wocky-xmpp-error.h>
+#include <wocky/wocky.h>
#include "wocky-test-stream.h"
#include "wocky-test-helper.h"
diff --git a/tests/wocky-pubsub-node-test.c b/tests/wocky-pubsub-node-test.c
index fb53370..6320753 100644
--- a/tests/wocky-pubsub-node-test.c
+++ b/tests/wocky-pubsub-node-test.c
@@ -4,9 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-pubsub-node.h>
-#include <wocky/wocky-utils.h>
-#include <wocky/wocky-namespaces.h>
+#include <wocky/wocky.h>
#include "wocky-pubsub-test-helpers.h"
#include "wocky-test-helper.h"
diff --git a/tests/wocky-pubsub-service-test.c b/tests/wocky-pubsub-service-test.c
index 2ea4df4..ee91547 100644
--- a/tests/wocky-pubsub-service-test.c
+++ b/tests/wocky-pubsub-service-test.c
@@ -4,11 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-pubsub-service.h>
-#include <wocky/wocky-pubsub-node.h>
-#include <wocky/wocky-utils.h>
-#include <wocky/wocky-namespaces.h>
-#include <wocky/wocky-xmpp-error.h>
+#include <wocky/wocky.h>
#include "wocky-pubsub-test-helpers.h"
#include "wocky-test-helper.h"
diff --git a/tests/wocky-pubsub-test-helpers.c b/tests/wocky-pubsub-test-helpers.c
index 102377e..96c5a96 100644
--- a/tests/wocky-pubsub-test-helpers.c
+++ b/tests/wocky-pubsub-test-helpers.c
@@ -1,6 +1,6 @@
#include "wocky-pubsub-test-helpers.h"
-#include <wocky/wocky-pubsub-node.h>
+#include <wocky/wocky.h>
void
test_pubsub_add_subscription_nodes (
diff --git a/tests/wocky-pubsub-test-helpers.h b/tests/wocky-pubsub-test-helpers.h
index 98824dd..8ba455c 100644
--- a/tests/wocky-pubsub-test-helpers.h
+++ b/tests/wocky-pubsub-test-helpers.h
@@ -2,7 +2,7 @@
#define WOCKY_PUBSUB_TEST_HELPERS_H
#include <glib.h>
-#include <wocky/wocky-pubsub-service.h>
+#include <wocky/wocky.h>
typedef struct {
const gchar *node;
diff --git a/tests/wocky-resource-contact-test.c b/tests/wocky-resource-contact-test.c
index 00fe11a..355a76e 100644
--- a/tests/wocky-resource-contact-test.c
+++ b/tests/wocky-resource-contact-test.c
@@ -4,8 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-resource-contact.h>
-#include <wocky/wocky-utils.h>
+#include <wocky/wocky.h>
#include "wocky-test-helper.h"
diff --git a/tests/wocky-roster-test.c b/tests/wocky-roster-test.c
index 7ead218..37c1309 100644
--- a/tests/wocky-roster-test.c
+++ b/tests/wocky-roster-test.c
@@ -4,13 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-roster.h>
-#include <wocky/wocky-porter.h>
-#include <wocky/wocky-utils.h>
-#include <wocky/wocky-xmpp-connection.h>
-#include <wocky/wocky-bare-contact.h>
-#include <wocky/wocky-namespaces.h>
-#include <wocky/wocky-session.h>
+#include <wocky/wocky.h>
#include "wocky-test-stream.h"
#include "wocky-test-helper.h"
diff --git a/tests/wocky-sasl-utils-test.c b/tests/wocky-sasl-utils-test.c
index 98a1d08..aec6cf4 100644
--- a/tests/wocky-sasl-utils-test.c
+++ b/tests/wocky-sasl-utils-test.c
@@ -18,7 +18,7 @@
*/
#include <stdio.h>
-#include <wocky/wocky-sasl-utils.h>
+#include <wocky/wocky.h>
typedef struct {
guint8 *key;
diff --git a/tests/wocky-scram-sha1-test.c b/tests/wocky-scram-sha1-test.c
index ca889ef..a1a8ed8 100644
--- a/tests/wocky-scram-sha1-test.c
+++ b/tests/wocky-scram-sha1-test.c
@@ -18,7 +18,7 @@
*/
#include <stdio.h>
-#include <wocky/wocky-sasl-scram.h>
+#include <wocky/wocky.h>
#include "wocky-test-helper.h"
diff --git a/tests/wocky-session-test.c b/tests/wocky-session-test.c
index 8cca2a5..60eb2ac 100644
--- a/tests/wocky-session-test.c
+++ b/tests/wocky-session-test.c
@@ -4,8 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-session.h>
-#include <wocky/wocky-utils.h>
+#include <wocky/wocky.h>
#include "wocky-test-helper.h"
diff --git a/tests/wocky-stanza-test.c b/tests/wocky-stanza-test.c
index cf60d17..87a9508 100644
--- a/tests/wocky-stanza-test.c
+++ b/tests/wocky-stanza-test.c
@@ -4,10 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-stanza.h>
-#include <wocky/wocky-xmpp-error.h>
-#include <wocky/wocky-utils.h>
-#include <wocky/wocky-namespaces.h>
+#include <wocky/wocky.h>
#include "wocky-test-helper.h"
diff --git a/tests/wocky-test-connector-server.c b/tests/wocky-test-connector-server.c
index a908493..45c3f28 100644
--- a/tests/wocky-test-connector-server.c
+++ b/tests/wocky-test-connector-server.c
@@ -28,18 +28,17 @@
#include "wocky-test-connector-server.h"
-#include <wocky/wocky-stanza.h>
-#include <wocky/wocky-xmpp-connection.h>
-
-#include <wocky/wocky-namespaces.h>
-#include <wocky/wocky-utils.h>
-
-#include <wocky/wocky-tls.h>
+#include <wocky/wocky.h>
#define INITIAL_STREAM_ID "0-HAI"
+/* We're being a bit naughty here by including wocky-debug.h, but we're
+ * internal *enough*.
+ */
#define DEBUG_FLAG DEBUG_CONNECTOR
+#define WOCKY_COMPILATION
#include <wocky/wocky-debug.h>
+#undef WOCKY_COMPILATION
G_DEFINE_TYPE (TestConnectorServer, test_connector_server, G_TYPE_OBJECT);
diff --git a/tests/wocky-test-helper.c b/tests/wocky-test-helper.c
index 0acc7cf..e8713f0 100644
--- a/tests/wocky-test-helper.c
+++ b/tests/wocky-test-helper.c
@@ -1,6 +1,4 @@
#include <wocky/wocky.h>
-#include <wocky/wocky-xmpp-connection.h>
-#include <wocky/wocky-porter.h>
#include "wocky-test-helper.h"
#include "wocky-test-stream.h"
diff --git a/tests/wocky-test-helper.h b/tests/wocky-test-helper.h
index 9cc47cf..4c9b25c 100644
--- a/tests/wocky-test-helper.h
+++ b/tests/wocky-test-helper.h
@@ -3,9 +3,7 @@
G_BEGIN_DECLS
-#include <wocky/wocky-xmpp-connection.h>
-#include <wocky/wocky-porter.h>
-#include <wocky/wocky-session.h>
+#include <wocky/wocky.h>
#include "wocky-test-stream.h"
typedef struct {
diff --git a/tests/wocky-test-sasl-auth-server.c b/tests/wocky-test-sasl-auth-server.c
index 2e4da52..d4647b2 100644
--- a/tests/wocky-test-sasl-auth-server.c
+++ b/tests/wocky-test-sasl-auth-server.c
@@ -28,9 +28,6 @@
#include "wocky-test-sasl-auth-server.h"
-#include <wocky/wocky-xmpp-connection.h>
-#include <wocky/wocky-utils.h>
-#include <wocky/wocky-namespaces.h>
#include "config.h"
#ifdef HAVE_LIBSASL2
diff --git a/tests/wocky-test-sasl-auth-server.h b/tests/wocky-test-sasl-auth-server.h
index e2fe0b9..d24a9fa 100644
--- a/tests/wocky-test-sasl-auth-server.h
+++ b/tests/wocky-test-sasl-auth-server.h
@@ -25,8 +25,7 @@
#include <gio/gio.h>
-#include <wocky/wocky-stanza.h>
-#include <wocky/wocky-xmpp-connection.h>
+#include <wocky/wocky.h>
G_BEGIN_DECLS
diff --git a/tests/wocky-test-sasl-auth.c b/tests/wocky-test-sasl-auth.c
index 8629172..8a5ce63 100644
--- a/tests/wocky-test-sasl-auth.c
+++ b/tests/wocky-test-sasl-auth.c
@@ -5,9 +5,7 @@
#include "wocky-test-stream.h"
#include "wocky-test-helper.h"
-#include <wocky/wocky-xmpp-connection.h>
-#include <wocky/wocky-sasl-auth.h>
-#include <wocky/wocky-auth-registry.h>
+#include <wocky/wocky.h>
typedef struct {
gchar *description;
diff --git a/tests/wocky-test-sasl-handler.c b/tests/wocky-test-sasl-handler.c
index 3305aa3..d7c83c0 100644
--- a/tests/wocky-test-sasl-handler.c
+++ b/tests/wocky-test-sasl-handler.c
@@ -1,7 +1,7 @@
#include "wocky-test-sasl-handler.h"
-#include <wocky/wocky-auth-handler.h>
+#include <wocky/wocky.h>
static void
auth_handler_iface_init (gpointer g_iface);
diff --git a/tests/wocky-tls-test.c b/tests/wocky-tls-test.c
index dac091c..9412631 100644
--- a/tests/wocky-tls-test.c
+++ b/tests/wocky-tls-test.c
@@ -6,8 +6,7 @@
#include <glib.h>
-#include <wocky/wocky-utils.h>
-#include <wocky/wocky-tls.h>
+#include <wocky/wocky.h>
#include "wocky-test-stream.h"
#include "wocky-test-helper.h"
diff --git a/tests/wocky-utils-test.c b/tests/wocky-utils-test.c
index 57419be..efd9808 100644
--- a/tests/wocky-utils-test.c
+++ b/tests/wocky-utils-test.c
@@ -18,7 +18,7 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#include <wocky/wocky-utils.h>
+#include <wocky/wocky.h>
static void
test_compose_jid (void)
diff --git a/tests/wocky-xmpp-connection-test.c b/tests/wocky-xmpp-connection-test.c
index a9031c1..01623d4 100644
--- a/tests/wocky-xmpp-connection-test.c
+++ b/tests/wocky-xmpp-connection-test.c
@@ -4,8 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-xmpp-connection.h>
-#include <wocky/wocky-stanza.h>
+#include <wocky/wocky.h>
#include "wocky-test-stream.h"
#include "wocky-test-helper.h"
diff --git a/tests/wocky-xmpp-node-test.c b/tests/wocky-xmpp-node-test.c
index b1ba458..0bef12b 100644
--- a/tests/wocky-xmpp-node-test.c
+++ b/tests/wocky-xmpp-node-test.c
@@ -4,10 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-stanza.h>
-#include <wocky/wocky-utils.h>
-#include <wocky/wocky-namespaces.h>
-#include <wocky/wocky-xmpp-error.h>
+#include <wocky/wocky.h>
#include "wocky-test-helper.h"
diff --git a/tests/wocky-xmpp-reader-test.c b/tests/wocky-xmpp-reader-test.c
index fd592e4..de64cf1 100644
--- a/tests/wocky-xmpp-reader-test.c
+++ b/tests/wocky-xmpp-reader-test.c
@@ -5,8 +5,6 @@
#include <glib.h>
#include <wocky/wocky.h>
-#include <wocky/wocky-xmpp-reader.h>
-#include <wocky/wocky-utils.h>
#include "wocky-test-helper.h"
diff --git a/tests/wocky-xmpp-readwrite-test.c b/tests/wocky-xmpp-readwrite-test.c
index 2a70ead..a9f9511 100644
--- a/tests/wocky-xmpp-readwrite-test.c
+++ b/tests/wocky-xmpp-readwrite-test.c
@@ -4,9 +4,7 @@
#include <glib.h>
-#include <wocky/wocky-xmpp-reader.h>
-#include <wocky/wocky-xmpp-writer.h>
-#include <wocky/wocky-utils.h>
+#include <wocky/wocky.h>
#include "wocky-test-helper.h"
diff --git a/wocky/Makefile.am b/wocky/Makefile.am
index 1a15061..5a801b9 100644
--- a/wocky/Makefile.am
+++ b/wocky/Makefile.am
@@ -210,7 +210,9 @@ wocky-signals-marshal.list: $(handwritten_sources) Makefile.am
AM_CFLAGS = $(ERROR_CFLAGS) $(GCOV_CFLAGS) \
@GLIB_CFLAGS@ @LIBXML2_CFLAGS@ @SQLITE_CFLAGS@ @TLS_CFLAGS@ \
@LIBIPHB_CFLAGS@ \
- -DG_LOG_DOMAIN=\"wocky\"
+ -DG_LOG_DOMAIN=\"wocky\" \
+ -DWOCKY_COMPILATION
+
AM_LDFLAGS = $(GCOV_LIBS) @GLIB_LIBS@ @LIBXML2_LIBS@ @SQLITE_LIBS@ @TLS_LIBS@ @LIBIPHB_LIBS@
diff --git a/wocky/wocky-auth-handler.h b/wocky/wocky-auth-handler.h
index dfef4f9..b72b6c1 100644
--- a/wocky/wocky-auth-handler.h
+++ b/wocky/wocky-auth-handler.h
@@ -1,3 +1,6 @@
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef _WOCKY_AUTH_HANDLER_H
#define _WOCKY_AUTH_HANDLER_H
diff --git a/wocky/wocky-auth-registry.h b/wocky/wocky-auth-registry.h
index 1d81f8e..30da931 100644
--- a/wocky/wocky-auth-registry.h
+++ b/wocky/wocky-auth-registry.h
@@ -1,5 +1,8 @@
-/* wocky-auth-registry.h */
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
+/* wocky-auth-registry.h */
#ifndef _WOCKY_AUTH_REGISTRY_H
#define _WOCKY_AUTH_REGISTRY_H
diff --git a/wocky/wocky-bare-contact.h b/wocky/wocky-bare-contact.h
index 1ebe270..e902bae 100644
--- a/wocky/wocky-bare-contact.h
+++ b/wocky/wocky-bare-contact.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_BARE_CONTACT_H__
#define __WOCKY_BARE_CONTACT_H__
diff --git a/wocky/wocky-c2s-porter.h b/wocky/wocky-c2s-porter.h
index 70e43af..83f7638 100644
--- a/wocky/wocky-c2s-porter.h
+++ b/wocky/wocky-c2s-porter.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_C2S_PORTER_H__
#define __WOCKY_C2S_PORTER_H__
diff --git a/wocky/wocky-caps-cache.h b/wocky/wocky-caps-cache.h
index 178daf1..a22331d 100644
--- a/wocky/wocky-caps-cache.h
+++ b/wocky/wocky-caps-cache.h
@@ -16,6 +16,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_CAPS_CACHE_H__
#define __WOCKY_CAPS_CACHE_H__
diff --git a/wocky/wocky-caps-hash.h b/wocky/wocky-caps-hash.h
index 5a8480c..83e369c 100644
--- a/wocky/wocky-caps-hash.h
+++ b/wocky/wocky-caps-hash.h
@@ -16,6 +16,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_CAPS_HASH_H__
#define __WOCKY_CAPS_HASH_H__
diff --git a/wocky/wocky-connector.h b/wocky/wocky-connector.h
index ee466bc..3d5d600 100644
--- a/wocky/wocky-connector.h
+++ b/wocky/wocky-connector.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_CONNECTOR_H__
#define __WOCKY_CONNECTOR_H__
diff --git a/wocky/wocky-contact-factory.h b/wocky/wocky-contact-factory.h
index be3c39a..06eba01 100644
--- a/wocky/wocky-contact-factory.h
+++ b/wocky/wocky-contact-factory.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_CONTACT_FACTORY_H__
#define __WOCKY_CONTACT_FACTORY_H__
diff --git a/wocky/wocky-contact.h b/wocky/wocky-contact.h
index 763c8b4..addfa61 100644
--- a/wocky/wocky-contact.h
+++ b/wocky/wocky-contact.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_CONTACT_H__
#define __WOCKY_CONTACT_H__
diff --git a/wocky/wocky-data-form.h b/wocky/wocky-data-form.h
index 44aa19f..931c535 100644
--- a/wocky/wocky-data-form.h
+++ b/wocky/wocky-data-form.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef WOCKY_DATA_FORM_H
#define WOCKY_DATA_FORM_H
diff --git a/wocky/wocky-debug.h b/wocky/wocky-debug.h
index daef7d6..ac5f812 100644
--- a/wocky/wocky-debug.h
+++ b/wocky/wocky-debug.h
@@ -1,3 +1,6 @@
+#if !defined (WOCKY_COMPILATION)
+# error "This is an internal header."
+#endif
#ifndef __WOCKY_DEBUG_H__
#define __WOCKY_DEBUG_H__
diff --git a/wocky/wocky-disco-identity.h b/wocky/wocky-disco-identity.h
index c66fe35..2a9b13e 100644
--- a/wocky/wocky-disco-identity.h
+++ b/wocky/wocky-disco-identity.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_DISCO_IDENTITY_H__
#define __WOCKY_DISCO_IDENTITY_H__
diff --git a/wocky/wocky-heartbeat-source.h b/wocky/wocky-heartbeat-source.h
index 73009e1..056726e 100644
--- a/wocky/wocky-heartbeat-source.h
+++ b/wocky/wocky-heartbeat-source.h
@@ -18,6 +18,10 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_COMPILATION)
+# error "This is an internal header."
+#endif
+
#ifndef WOCKY_HEARTBEAT_SOURCE_H
#define WOCKY_HEARTBEAT_SOURCE_H
diff --git a/wocky/wocky-http-proxy.h b/wocky/wocky-http-proxy.h
index 235a00b..b9f9485 100644
--- a/wocky/wocky-http-proxy.h
+++ b/wocky/wocky-http-proxy.h
@@ -18,6 +18,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_COMPILATION)
+# error "This is an internal header."
+#endif
#ifndef _WOCKY_HTTP_PROXY_H_
#define _WOCKY_HTTP_PROXY_H_
diff --git a/wocky/wocky-jabber-auth-digest.h b/wocky/wocky-jabber-auth-digest.h
index c9e0fee..878efa3 100644
--- a/wocky/wocky-jabber-auth-digest.h
+++ b/wocky/wocky-jabber-auth-digest.h
@@ -1,3 +1,7 @@
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
+
#ifndef _WOCKY_JABBER_AUTH_DIGEST_H
#define _WOCKY_JABBER_AUTH_DIGEST_H
diff --git a/wocky/wocky-jabber-auth-password.h b/wocky/wocky-jabber-auth-password.h
index 7e6ae63..d05cdae 100644
--- a/wocky/wocky-jabber-auth-password.h
+++ b/wocky/wocky-jabber-auth-password.h
@@ -1,3 +1,7 @@
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
+
#ifndef _WOCKY_JABBER_AUTH_PASSWORD_H
#define _WOCKY_JABBER_AUTH_PASSWORD_H
diff --git a/wocky/wocky-jabber-auth.h b/wocky/wocky-jabber-auth.h
index b55f9e1..d8181c0 100644
--- a/wocky/wocky-jabber-auth.h
+++ b/wocky/wocky-jabber-auth.h
@@ -16,6 +16,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_JABBER_AUTH_H__
#define __WOCKY_JABBER_AUTH_H__
diff --git a/wocky/wocky-ll-connection-factory.h b/wocky/wocky-ll-connection-factory.h
index f4437cc..d73cb96 100644
--- a/wocky/wocky-ll-connection-factory.h
+++ b/wocky/wocky-ll-connection-factory.h
@@ -16,6 +16,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_LL_CONNECTION_FACTORY_H__
#define __WOCKY_LL_CONNECTION_FACTORY_H__
diff --git a/wocky/wocky-ll-connector.h b/wocky/wocky-ll-connector.h
index b9a6b7f..60fe040 100644
--- a/wocky/wocky-ll-connector.h
+++ b/wocky/wocky-ll-connector.h
@@ -16,6 +16,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_LL_CONNECTOR_H__
#define __WOCKY_LL_CONNECTOR_H__
diff --git a/wocky/wocky-ll-contact.h b/wocky/wocky-ll-contact.h
index 13ae1d9..ba26171 100644
--- a/wocky/wocky-ll-contact.h
+++ b/wocky/wocky-ll-contact.h
@@ -16,6 +16,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_LL_CONTACT_H__
#define __WOCKY_LL_CONTACT_H__
diff --git a/wocky/wocky-loopback-stream.h b/wocky/wocky-loopback-stream.h
index b31063e..d44412f 100644
--- a/wocky/wocky-loopback-stream.h
+++ b/wocky/wocky-loopback-stream.h
@@ -16,6 +16,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_LOOPBACK_STREAM_H__
#define __WOCKY_LOOPBACK_STREAM_H__
diff --git a/wocky/wocky-meta-porter.h b/wocky/wocky-meta-porter.h
index 35f4200..e2264d9 100644
--- a/wocky/wocky-meta-porter.h
+++ b/wocky/wocky-meta-porter.h
@@ -16,6 +16,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_META_PORTER_H__
#define __WOCKY_META_PORTER_H__
diff --git a/wocky/wocky-muc.h b/wocky/wocky-muc.h
index 546baa1..c5b348d 100644
--- a/wocky/wocky-muc.h
+++ b/wocky/wocky-muc.h
@@ -17,6 +17,10 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
+
#ifndef __WOCKY_MUC_H__
#define __WOCKY_MUC_H__
diff --git a/wocky/wocky-namespaces.h b/wocky/wocky-namespaces.h
index 7af9b36..5ea47c6 100644
--- a/wocky/wocky-namespaces.h
+++ b/wocky/wocky-namespaces.h
@@ -1,3 +1,6 @@
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_NAMESPACES_H__
#define __WOCKY_NAMESPACES_H__
diff --git a/wocky/wocky-node-private.h b/wocky/wocky-node-private.h
index b1a82bb..6c4a64d 100644
--- a/wocky/wocky-node-private.h
+++ b/wocky/wocky-node-private.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_COMPILATION)
+# error "This is an internal header."
+#endif
#ifndef __WOCKY__NODE_PRIVATE_H__
#define __WOCKY__NODE_PRIVATE_H__
diff --git a/wocky/wocky-node-tree.h b/wocky/wocky-node-tree.h
index 8c8d62d..aadc949 100644
--- a/wocky/wocky-node-tree.h
+++ b/wocky/wocky-node-tree.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_NODE_TREE_H__
#define __WOCKY_NODE_TREE_H__
diff --git a/wocky/wocky-node.h b/wocky/wocky-node.h
index dd8b6d4..b8b2e5a 100644
--- a/wocky/wocky-node.h
+++ b/wocky/wocky-node.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY__NODE_H__
#define __WOCKY__NODE_H__
diff --git a/wocky/wocky-pep-service.h b/wocky/wocky-pep-service.h
index ff508b3..cbedcae 100644
--- a/wocky/wocky-pep-service.h
+++ b/wocky/wocky-pep-service.h
@@ -16,6 +16,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_PEP_SERVICE_H__
#define __WOCKY_PEP_SERVICE_H__
diff --git a/wocky/wocky-ping.h b/wocky/wocky-ping.h
index e9b2262..c0c4bb8 100644
--- a/wocky/wocky-ping.h
+++ b/wocky/wocky-ping.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_PING_H__
#define __WOCKY_PING_H__
diff --git a/wocky/wocky-porter.h b/wocky/wocky-porter.h
index 6e09eca..6a852d2 100644
--- a/wocky/wocky-porter.h
+++ b/wocky/wocky-porter.h
@@ -16,6 +16,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_PORTER_H__
#define __WOCKY_PORTER_H__
diff --git a/wocky/wocky-pubsub-helpers.h b/wocky/wocky-pubsub-helpers.h
index bc83298..cbb5cf2 100644
--- a/wocky/wocky-pubsub-helpers.h
+++ b/wocky/wocky-pubsub-helpers.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef WOCKY_PUBSUB_HELPERS_H
#define WOCKY_PUBSUB_HELPERS_H
diff --git a/wocky/wocky-pubsub-node-protected.h b/wocky/wocky-pubsub-node-protected.h
index 8e7f65e..13ad85a 100644
--- a/wocky/wocky-pubsub-node-protected.h
+++ b/wocky/wocky-pubsub-node-protected.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef WOCKY_PUBSUB_NODE_PROTECTED_H
#define WOCKY_PUBSUB_NODE_PROTECTED_H
diff --git a/wocky/wocky-pubsub-node.h b/wocky/wocky-pubsub-node.h
index 4c03915..31e35cc 100644
--- a/wocky/wocky-pubsub-node.h
+++ b/wocky/wocky-pubsub-node.h
@@ -16,6 +16,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_PUBSUB_NODE_H__
#define __WOCKY_PUBSUB_NODE_H__
diff --git a/wocky/wocky-pubsub-service-protected.h b/wocky/wocky-pubsub-service-protected.h
index d18d3f4..7472765 100644
--- a/wocky/wocky-pubsub-service-protected.h
+++ b/wocky/wocky-pubsub-service-protected.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef WOCKY_PUBSUB_SERVICE_PROTECTED_H
#define WOCKY_PUBSUB_SERVICE_PROTECTED_H
diff --git a/wocky/wocky-pubsub-service.h b/wocky/wocky-pubsub-service.h
index 4824430..676bc04 100644
--- a/wocky/wocky-pubsub-service.h
+++ b/wocky/wocky-pubsub-service.h
@@ -16,6 +16,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_PUBSUB_SERVICE_H__
#define __WOCKY_PUBSUB_SERVICE_H__
diff --git a/wocky/wocky-resource-contact.h b/wocky/wocky-resource-contact.h
index 0207b4b..e7749ff 100644
--- a/wocky/wocky-resource-contact.h
+++ b/wocky/wocky-resource-contact.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_RESOURCE_CONTACT_H__
#define __WOCKY_RESOURCE_CONTACT_H__
diff --git a/wocky/wocky-roster.h b/wocky/wocky-roster.h
index 971812e..6ca8d7a 100644
--- a/wocky/wocky-roster.h
+++ b/wocky/wocky-roster.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_ROSTER_H__
#define __WOCKY_ROSTER_H__
diff --git a/wocky/wocky-sasl-auth.h b/wocky/wocky-sasl-auth.h
index 27cc2cc..28efa8a 100644
--- a/wocky/wocky-sasl-auth.h
+++ b/wocky/wocky-sasl-auth.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_SASL_AUTH_H__
#define __WOCKY_SASL_AUTH_H__
diff --git a/wocky/wocky-sasl-digest-md5.h b/wocky/wocky-sasl-digest-md5.h
index 6f39bbd..0d2fdf4 100644
--- a/wocky/wocky-sasl-digest-md5.h
+++ b/wocky/wocky-sasl-digest-md5.h
@@ -1,3 +1,7 @@
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
+
#ifndef _WOCKY_SASL_DIGEST_MD5_H
#define _WOCKY_SASL_DIGEST_MD5_H
diff --git a/wocky/wocky-sasl-plain.h b/wocky/wocky-sasl-plain.h
index 19bb004..9546671 100644
--- a/wocky/wocky-sasl-plain.h
+++ b/wocky/wocky-sasl-plain.h
@@ -1,3 +1,7 @@
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
+
#ifndef _WOCKY_SASL_PLAIN_H
#define _WOCKY_SASL_PLAIN_H
diff --git a/wocky/wocky-sasl-scram.h b/wocky/wocky-sasl-scram.h
index 1a35551..204053b 100644
--- a/wocky/wocky-sasl-scram.h
+++ b/wocky/wocky-sasl-scram.h
@@ -1,4 +1,3 @@
-#ifndef _WOCKY_SASL_SCRAM_H
/*
* wocky-sasl-scram.h - SCRAM-SHA1 implementation (to be RFC 5802)
* Copyright (C) 2010 Sjoerd Simons <sjoerd@luon.net>
@@ -17,7 +16,11 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
+#ifndef _WOCKY_SASL_SCRAM_H
#define _WOCKY_SASL_SCRAM_H
#include <glib-object.h>
diff --git a/wocky/wocky-session.h b/wocky/wocky-session.h
index fc3243b..95fde2f 100644
--- a/wocky/wocky-session.h
+++ b/wocky/wocky-session.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_SESSION_H__
#define __WOCKY_SESSION_H__
diff --git a/wocky/wocky-stanza.h b/wocky/wocky-stanza.h
index c637cb1..9a9c4b0 100644
--- a/wocky/wocky-stanza.h
+++ b/wocky/wocky-stanza.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_STANZA_H__
#define __WOCKY_STANZA_H__
diff --git a/wocky/wocky-tls-connector.h b/wocky/wocky-tls-connector.h
index a1b8e38..db9d878 100644
--- a/wocky/wocky-tls-connector.h
+++ b/wocky/wocky-tls-connector.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_TLS_CONNECTOR_H__
#define __WOCKY_TLS_CONNECTOR_H__
diff --git a/wocky/wocky-tls-handler.h b/wocky/wocky-tls-handler.h
index 1fb7f76..ee3ea0c 100644
--- a/wocky/wocky-tls-handler.h
+++ b/wocky/wocky-tls-handler.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_TLS_HANDLER_H__
#define __WOCKY_TLS_HANDLER_H__
diff --git a/wocky/wocky-tls.h b/wocky/wocky-tls.h
index 58497ef..57ae27f 100644
--- a/wocky/wocky-tls.h
+++ b/wocky/wocky-tls.h
@@ -22,6 +22,9 @@
* 'g' prefixes changes to 'wocky' and server-side TLS support added.
*
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef _wocky_tls_h_
#define _wocky_tls_h_
diff --git a/wocky/wocky-types.h b/wocky/wocky-types.h
index 8837268..ff22426 100644
--- a/wocky/wocky-types.h
+++ b/wocky/wocky-types.h
@@ -16,6 +16,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_TYPES_H__
#define __WOCKY_TYPES_H__
diff --git a/wocky/wocky-utils.h b/wocky/wocky-utils.h
index cc143be..652c038 100644
--- a/wocky/wocky-utils.h
+++ b/wocky/wocky-utils.h
@@ -16,6 +16,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_UTILS_H__
#define __WOCKY_UTILS_H__
diff --git a/wocky/wocky-xep-0115-capabilities.h b/wocky/wocky-xep-0115-capabilities.h
index 69cfe6e..5d65ce3 100644
--- a/wocky/wocky-xep-0115-capabilities.h
+++ b/wocky/wocky-xep-0115-capabilities.h
@@ -18,6 +18,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_XEP_0115_CAPABILITIES_H__
#define __WOCKY_XEP_0115_CAPABILITIES_H__
diff --git a/wocky/wocky-xmpp-connection.h b/wocky/wocky-xmpp-connection.h
index d28c33d..edbd106 100644
--- a/wocky/wocky-xmpp-connection.h
+++ b/wocky/wocky-xmpp-connection.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_XMPP_CONNECTION_H__
#define __WOCKY_XMPP_CONNECTION_H__
diff --git a/wocky/wocky-xmpp-error.h b/wocky/wocky-xmpp-error.h
index bcdf3da..826efb2 100644
--- a/wocky/wocky-xmpp-error.h
+++ b/wocky/wocky-xmpp-error.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_XMPP_ERROR_H__
#define __WOCKY_XMPP_ERROR_H__
diff --git a/wocky/wocky-xmpp-reader.h b/wocky/wocky-xmpp-reader.h
index 56cbb32..fd8d63b 100644
--- a/wocky/wocky-xmpp-reader.h
+++ b/wocky/wocky-xmpp-reader.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_XMPP_READER_H__
#define __WOCKY_XMPP_READER_H__
diff --git a/wocky/wocky-xmpp-writer.h b/wocky/wocky-xmpp-writer.h
index 17de3df..07f58e1 100644
--- a/wocky/wocky-xmpp-writer.h
+++ b/wocky/wocky-xmpp-writer.h
@@ -17,6 +17,9 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#if !defined (WOCKY_H_INSIDE) && !defined (WOCKY_COMPILATION)
+# error "Only <wocky/wocky.h> can be included directly."
+#endif
#ifndef __WOCKY_XMPP_WRITER_H__
#define __WOCKY_XMPP_WRITER_H__
diff --git a/wocky/wocky.h b/wocky/wocky.h
index 78fc704..e2bea2c 100644
--- a/wocky/wocky.h
+++ b/wocky/wocky.h
@@ -23,6 +23,59 @@
#include <glib.h>
+#define WOCKY_H_INSIDE
+#include "wocky-auth-handler.h"
+#include "wocky-auth-registry.h"
+#include "wocky-bare-contact.h"
+#include "wocky-c2s-porter.h"
+#include "wocky-caps-cache.h"
+#include "wocky-caps-hash.h"
+#include "wocky-connector.h"
+#include "wocky-contact-factory.h"
+#include "wocky-contact.h"
+#include "wocky-data-form.h"
+#include "wocky-disco-identity.h"
+#include "wocky-jabber-auth-digest.h"
+#include "wocky-jabber-auth.h"
+#include "wocky-jabber-auth-password.h"
+#include "wocky-ll-connection-factory.h"
+#include "wocky-ll-connector.h"
+#include "wocky-ll-contact.h"
+#include "wocky-loopback-stream.h"
+#include "wocky-meta-porter.h"
+#include "wocky-muc.h"
+#include "wocky-namespaces.h"
+#include "wocky-node.h"
+#include "wocky-node-tree.h"
+#include "wocky-pep-service.h"
+#include "wocky-ping.h"
+#include "wocky-porter.h"
+#include "wocky-pubsub-helpers.h"
+#include "wocky-pubsub-node.h"
+#include "wocky-pubsub-node-protected.h"
+#include "wocky-pubsub-service.h"
+#include "wocky-pubsub-service-protected.h"
+#include "wocky-resource-contact.h"
+#include "wocky-roster.h"
+#include "wocky-sasl-auth.h"
+#include "wocky-sasl-digest-md5.h"
+#include "wocky-sasl-plain.h"
+#include "wocky-sasl-scram.h"
+#include "wocky-sasl-utils.h"
+#include "wocky-session.h"
+#include "wocky-stanza.h"
+#include "wocky-tls-connector.h"
+#include "wocky-tls.h"
+#include "wocky-tls-handler.h"
+#include "wocky-types.h"
+#include "wocky-utils.h"
+#include "wocky-xep-0115-capabilities.h"
+#include "wocky-xmpp-connection.h"
+#include "wocky-xmpp-error.h"
+#include "wocky-xmpp-reader.h"
+#include "wocky-xmpp-writer.h"
+#undef WOCKY_H_INSIDE
+
G_BEGIN_DECLS
void wocky_init (void);