src/moonshot-webp-parser.vala \
src/moonshot-id.vala
-src_moonshot_VALAFLAGS = --pkg gdk-2.0 gtk+-2.0 $(AM_VALAFLAGS)
+src_moonshot_VALAFLAGS = --pkg gdk-2.0 --pkg gtk+-2.0 $(AM_VALAFLAGS)
src_moonshot_CPPFLAGS = $(moonshot_CFLAGS) $(AM_CPPFLAGS)
src_moonshot_LDADD = $(moonshot_LIBS)
noinst_PROGRAMS = \
examples/client \
+ examples/service-selection \
tests/basic
+examples_service_selection_SOURCES = examples/service-selection.c
+examples_service_selection_CPPFLAGS = $(libmoonshot_CFLAGS) $(AM_CPPFLAGS)
+examples_service_selection_LDADD = ${top_builddir}/libmoonshot/libmoonshot.la
+
examples_client_SOURCES = examples/client.c
examples_client_CPPFLAGS = $(libmoonshot_CFLAGS) $(AM_CPPFLAGS)
examples_client_LDADD = ${top_builddir}/libmoonshot/libmoonshot.la
--- /dev/null
+#include <glib.h>
+#include "libmoonshot.h"
+
+int main (int argc, char *argv[])
+{
+ MoonshotError *error;
+ gboolean success;
+
+ char *nai,
+ *password,
+ *server_certificate_hash,
+ *ca_certificate,
+ *subject_name_constraint,
+ *subject_alt_name_constraint;
+
+ success = moonshot_get_identity ("user1@foo.baz",
+ "",
+ "",
+ &nai,
+ &password,
+ &server_certificate_hash,
+ &ca_certificate,
+ &subject_name_constraint,
+ &subject_alt_name_constraint,
+ &error);
+
+ if (success)
+ g_debug ("Got id: %s %s\n", nai, password);
+
+ moonshot_free (nai);
+ moonshot_free (password);
+ moonshot_free (server_certificate_hash);
+ moonshot_free (ca_certificate);
+ moonshot_free (subject_name_constraint);
+ moonshot_free (subject_alt_name_constraint);
+}
<password></password>
<realm>foo.baz</realm>
<services>
+ <service>irc@jabber.project-moonshot.org</service>
<service>xmpp@jabber.project-moonshot.org</service>
</services>
<selection-rules>
<password></password>
<realm>foo.bar</realm>
<services>
+ <service>irc@jabber.project-moonshot.org</service>
<service>email@project-moonshot.org</service>
</services>
<selection-rules>
<password></password>
<realm>foo.com</realm>
<services>
+ <service>irc@jabber.project-moonshot.org</service>
<service>email@project-moonshot.org</service>
</services>
<trust-anchor>