diff --git a/libpurple/purpleversion.h b/pidgin/pidginversion.h
copy from libpurple/purpleversion.h
copy to pidgin/pidginversion.h
--- a/libpurple/purpleversion.h
+++ b/pidgin/pidginversion.h
@@ -1,8 +1,8 @@
 /*
- * Purple - Internet Messaging Library
+ * Pidgin - Internet Messenger
  * Copyright (C) Pidgin Developers <devel@pidgin.im>
  *
- * Purple is the legal property of its developers, whose names are too numerous
+ * Pidgin is the legal property of its developers, whose names are too numerous
  * to list here.  Please refer to the COPYRIGHT file distributed with this
  * source distribution.
  *
@@ -20,428 +20,353 @@
  * along with this program; if not, see <https://www.gnu.org/licenses/>.
  */
 
-#if !defined(PURPLE_GLOBAL_HEADER_INSIDE) && !defined(PURPLE_COMPILATION)
-# error "only <purple.h> may be included directly"
+#if !defined(PIDGIN_GLOBAL_HEADER_INSIDE) && !defined(PIDGIN_COMPILATION)
+# error "only <pidgin.h> may be included directly"
 #endif
 
-#ifndef PURPLE_VERSION_H
-#define PURPLE_VERSION_H
+#ifndef PIDGIN_VERSION_H
+#define PIDGIN_VERSION_H
 
 #include <glib.h>
 
-#include "purpleversionconsts.h"
+#include "pidginversionconsts.h"
 
 #if (defined(_WIN32) || defined(__CYGWIN__)) && \
-	!defined(PURPLE_STATIC_COMPILATION)
-#define _PURPLE_EXPORT __declspec(dllexport)
-#define _PURPLE_IMPORT __declspec(dllimport)
+	!defined(PIDGIN_STATIC_COMPILATION)
+#define _PIDGIN_EXPORT __declspec(dllexport)
+#define _PIDGIN_IMPORT __declspec(dllimport)
 #elif __GNUC__ >= 4
-#define _PURPLE_EXPORT __attribute__((visibility("default")))
-#define _PURPLE_IMPORT
+#define _PIDGIN_EXPORT __attribute__((visibility("default")))
+#define _PIDGIN_IMPORT
 #else
-#define _PURPLE_EXPORT
-#define _PURPLE_IMPORT
+#define _PIDGIN_EXPORT
+#define _PIDGIN_IMPORT
 #endif
-#ifdef PURPLE_COMPILATION
-#define _PURPLE_API _PURPLE_EXPORT
+#ifdef PIDGIN_COMPILATION
+#define _PIDGIN_API _PIDGIN_EXPORT
 #else
-#define _PURPLE_API _PURPLE_IMPORT
+#define _PIDGIN_API _PIDGIN_IMPORT
 #endif
 
-#define _PURPLE_EXTERN _PURPLE_API extern
+#define _PIDGIN_EXTERN _PIDGIN_API extern
 
-#ifdef PURPLE_DISABLE_DEPRECATION_WARNINGS
-#define PURPLE_DEPRECATED _PURPLE_EXTERN
-#define PURPLE_DEPRECATED_FOR(f) _PURPLE_EXTERN
-#define PURPLE_UNAVAILABLE(maj, min) _PURPLE_EXTERN
-#define PURPLE_UNAVAILABLE_STATIC_INLINE(maj, min)
-#define PURPLE_UNAVAILABLE_TYPE(maj, min)
+#ifdef PIDGIN_DISABLE_DEPRECATION_WARNINGS
+#define PIDGIN_DEPRECATED _PIDGIN_EXTERN
+#define PIDGIN_DEPRECATED_FOR(f) _PIDGIN_EXTERN
+#define PIDGIN_UNAVAILABLE(maj, min) _PIDGIN_EXTERN
+#define PIDGIN_UNAVAILABLE_STATIC_INLINE(maj, min)
+#define PIDGIN_UNAVAILABLE_TYPE(maj, min)
 #else
-#define PURPLE_DEPRECATED G_DEPRECATED _PURPLE_EXTERN
-#define PURPLE_DEPRECATED_FOR(f) G_DEPRECATED_FOR(f) _PURPLE_EXTERN
-#define PURPLE_UNAVAILABLE(maj, min) G_UNAVAILABLE(maj, min) _PURPLE_EXTERN
-#define PURPLE_UNAVAILABLE_STATIC_INLINE(maj, min) G_UNAVAILABLE(maj, min)
-#define PURPLE_UNAVAILABLE_TYPE(maj, min) G_UNAVAILABLE(maj, min)
+#define PIDGIN_DEPRECATED G_DEPRECATED _PIDGIN_EXTERN
+#define PIDGIN_DEPRECATED_FOR(f) G_DEPRECATED_FOR(f) _PIDGIN_EXTERN
+#define PIDGIN_UNAVAILABLE(maj, min) G_UNAVAILABLE(maj, min) _PIDGIN_EXTERN
+#define PIDGIN_UNAVAILABLE_STATIC_INLINE(maj, min) G_UNAVAILABLE(maj, min)
+#define PIDGIN_UNAVAILABLE_TYPE(maj, min) G_UNAVAILABLE(maj, min)
 #endif
 
 /**
- * PURPLE_VERSION_CUR_STABLE:
+ * PIDGIN_VERSION_CUR_STABLE:
  *
- * A macro that evaluates to the current stable version of libpurple, in a format
+ * A macro that evaluates to the current stable version of Pidgin, in a format
  * that can be used by the C pre-processor.
  *
  * Since: 3.0.0
  */
-#define PURPLE_VERSION_CUR_STABLE \
-	(G_ENCODE_VERSION(PURPLE_MAJOR_VERSION, PURPLE_MINOR_VERSION))
+#define PIDGIN_VERSION_CUR_STABLE \
+	(G_ENCODE_VERSION(PIDGIN_MAJOR_VERSION, PIDGIN_MINOR_VERSION))
 
-/* If the package sets PURPLE_VERSION_MIN_REQUIRED to some future
- * PURPLE_VERSION_X_Y value that we don't know about, it will compare as 0 in
+/* If the package sets PIDGIN_VERSION_MIN_REQUIRED to some future
+ * PIDGIN_VERSION_X_Y value that we don't know about, it will compare as 0 in
  * preprocessor tests.
  */
-#ifndef PURPLE_VERSION_MIN_REQUIRED
-#define PURPLE_VERSION_MIN_REQUIRED (PURPLE_VERSION_CUR_STABLE)
-#elif PURPLE_VERSION_MIN_REQUIRED == 0
-#undef PURPLE_VERSION_MIN_REQUIRED
-#define PURPLE_VERSION_MIN_REQUIRED (PURPLE_VERSION_CUR_STABLE + 1)
-#endif /* PURPLE_VERSION_MIN_REQUIRED */
+#ifndef PIDGIN_VERSION_MIN_REQUIRED
+#define PIDGIN_VERSION_MIN_REQUIRED (PIDGIN_VERSION_CUR_STABLE)
+#elif PIDGIN_VERSION_MIN_REQUIRED == 0
+#undef PIDGIN_VERSION_MIN_REQUIRED
+#define PIDGIN_VERSION_MIN_REQUIRED (PIDGIN_VERSION_CUR_STABLE + 1)
+#endif /* PIDGIN_VERSION_MIN_REQUIRED */
 
-#if !defined(PURPLE_VERSION_MAX_ALLOWED) || (PURPLE_VERSION_MAX_ALLOWED == 0)
-#undef PURPLE_VERSION_MAX_ALLOWED
-#define PURPLE_VERSION_MAX_ALLOWED (PURPLE_VERSION_CUR_STABLE)
-#endif /* PURPLE_VERSION_MAX_ALLOWED */
+#if !defined(PIDGIN_VERSION_MAX_ALLOWED) || (PIDGIN_VERSION_MAX_ALLOWED == 0)
+#undef PIDGIN_VERSION_MAX_ALLOWED
+#define PIDGIN_VERSION_MAX_ALLOWED (PIDGIN_VERSION_CUR_STABLE)
+#endif /* PIDGIN_VERSION_MAX_ALLOWED */
 
 /* sanity checks */
-#if PURPLE_VERSION_MIN_REQUIRED > PURPLE_VERSION_CUR_STABLE
-#error "PURPLE_VERSION_MIN_REQUIRED must be <= PURPLE_VERSION_CUR_STABLE"
+#if PIDGIN_VERSION_MIN_REQUIRED > PIDGIN_VERSION_CUR_STABLE
+#error "PIDGIN_VERSION_MIN_REQUIRED must be <= PIDGIN_VERSION_CUR_STABLE"
 #endif
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_MIN_REQUIRED
-#error "PURPLE_VERSION_MAX_ALLOWED must be >= PURPLE_VERSION_MIN_REQUIRED"
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_MIN_REQUIRED
+#error "PIDGIN_VERSION_MAX_ALLOWED must be >= PIDGIN_VERSION_MIN_REQUIRED"
 #endif
-#if PURPLE_VERSION_MIN_REQUIRED < G_ENCODE_VERSION(2, 0)
-#error "PURPLE_VERSION_MIN_REQUIRED must be >= PURPLE_VERSION_2_0"
+#if PIDGIN_VERSION_MIN_REQUIRED < G_ENCODE_VERSION(2, 0)
+#error "PIDGIN_VERSION_MIN_REQUIRED must be >= PIDGIN_VERSION_2_0"
 #endif
 
-#define PURPLE_VAR _PURPLE_EXTERN
-#define PURPLE_AVAILABLE_IN_ALL _PURPLE_EXTERN
+#define PIDGIN_VAR _PIDGIN_EXTERN
+#define PIDGIN_AVAILABLE_IN_ALL _PIDGIN_EXTERN
 
 /**
- * PURPLE_VERSION_2_0:
+ * PIDGIN_VERSION_2_0:
  *
- * A macro that evaluates to the 2.0 version of libpurple, in a format that
- * can be used by the C pre-processor.
+ * A macro that evaluates to the 2.0 version of Pidgin, in a format that can be
+ * used by the C pre-processor.
  *
  * Since: 3.0.0
  */
-#define PURPLE_VERSION_2_0 (G_ENCODE_VERSION(2, 0))
-
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_0
-#define PURPLE_AVAILABLE_IN_2_0 PURPLE_UNAVAILABLE(2, 0)
-#else
-#define PURPLE_AVAILABLE_IN_2_0 _PURPLE_EXTERN
-#endif
+#define PIDGIN_VERSION_2_0 (G_ENCODE_VERSION(2, 0))
 
-/**
- * PURPLE_VERSION_2_1:
- *
- * A macro that evaluates to the 2.1 version of libpurple, in a format that
- * can be used by the C pre-processor.
- *
- * Since: 3.0.0
- */
-#define PURPLE_VERSION_2_1 (G_ENCODE_VERSION(2, 1))
-
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_1
-#define PURPLE_AVAILABLE_IN_2_1 PURPLE_UNAVAILABLE(2, 1)
-#define PURPLE_AVAILABLE_ENUMERATOR_IN_2_1 PURPLE_UNAVAILABLE_ENUMERATOR(2, 1)
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_2_0
+#define PIDGIN_AVAILABLE_IN_2_0 PIDGIN_UNAVAILABLE(2, 0)
 #else
-#define PURPLE_AVAILABLE_IN_2_1 _PURPLE_EXTERN
-#define PURPLE_AVAILABLE_ENUMERATOR_IN_2_1
+#define PIDGIN_AVAILABLE_IN_2_0 _PIDGIN_EXTERN
 #endif
 
 /**
- * PURPLE_VERSION_2_2:
+ * PIDGIN_VERSION_2_1:
  *
- * A macro that evaluates to the 2.2 version of libpurple, in a format that
- * can be used by the C pre-processor.
+ * A macro that evaluates to the 2.1 version of Pidgin, in a format that can be
+ * used by the C pre-processor.
  *
  * Since: 3.0.0
  */
-#define PURPLE_VERSION_2_2 (G_ENCODE_VERSION(2, 2))
-
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_2
-#define PURPLE_AVAILABLE_IN_2_2 PURPLE_UNAVAILABLE(2, 2)
-#define PURPLE_AVAILABLE_ENUMERATOR_IN_2_2 PURPLE_UNAVAILABLE_ENUMERATOR(2, 2)
-#else
-#define PURPLE_AVAILABLE_IN_2_2 _PURPLE_EXTERN
-#define PURPLE_AVAILABLE_ENUMERATOR_IN_2_2
-#endif
+#define PIDGIN_VERSION_2_1 (G_ENCODE_VERSION(2, 1))
 
-/**
- * PURPLE_VERSION_2_3:
- *
- * A macro that evaluates to the 2.3 version of libpurple, in a format that
- * can be used by the C pre-processor.
- *
- * Since: 3.0.0
- */
-#define PURPLE_VERSION_2_3 (G_ENCODE_VERSION(2, 3))
-
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_3
-#define PURPLE_AVAILABLE_IN_2_3 PURPLE_UNAVAILABLE(2, 3)
-#define PURPLE_AVAILABLE_TYPE_IN_2_3 PURPLE_UNAVAILABLE_TYPE(2, 3)
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_2_1
+#define PIDGIN_AVAILABLE_IN_2_1 PIDGIN_UNAVAILABLE(2, 1)
 #else
-#define PURPLE_AVAILABLE_IN_2_3 _PURPLE_EXTERN
-#define PURPLE_AVAILABLE_TYPE_IN_2_3
+#define PIDGIN_AVAILABLE_IN_2_1 _PIDGIN_EXTERN
 #endif
 
 /**
- * PURPLE_VERSION_2_4:
+ * PIDGIN_VERSION_2_2:
  *
- * A macro that evaluates to the 2.4 version of libpurple, in a format that
- * can be used by the C pre-processor.
+ * A macro that evaluates to the 2.2 version of Pidgin, in a format that can be
+ * used by the C pre-processor.
  *
  * Since: 3.0.0
  */
-#define PURPLE_VERSION_2_4 (G_ENCODE_VERSION(2, 4))
+#define PIDGIN_VERSION_2_2 (G_ENCODE_VERSION(2, 2))
 
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_4
-#define PURPLE_AVAILABLE_IN_2_4 PURPLE_UNAVAILABLE(2, 4)
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_2_2
+#define PIDGIN_AVAILABLE_IN_2_2 PIDGIN_UNAVAILABLE(2, 2)
 #else
-#define PURPLE_AVAILABLE_IN_2_4 _PURPLE_EXTERN
+#define PIDGIN_AVAILABLE_IN_2_2 _PIDGIN_EXTERN
 #endif
 
 /**
- * PURPLE_VERSION_2_5:
- *
- * A macro that evaluates to the 2.5 version of libpurple, in a format that
- * can be used by the C pre-processor.
+ * PIDGIN_VERSION_2_3:
  *
- * Since: 3.0.0
- */
-#define PURPLE_VERSION_2_5 (G_ENCODE_VERSION(2, 5))
-
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_5
-#define PURPLE_AVAILABLE_IN_2_5 PURPLE_UNAVAILABLE(2, 5)
-#else
-#define PURPLE_AVAILABLE_IN_2_5 _PURPLE_EXTERN
-#endif
-
-/**
- * PURPLE_VERSION_2_6:
- *
- * A macro that evaluates to the 2.6 version of libpurple, in a format that
- * can be used by the C pre-processor.
+ * A macro that evaluates to the 2.3 version of Pidgin, in a format that can be
+ * used by the C pre-processor.
  *
  * Since: 3.0.0
  */
-#define PURPLE_VERSION_2_6 (G_ENCODE_VERSION(2, 6))
-
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_6
-#define PURPLE_AVAILABLE_IN_2_6 PURPLE_UNAVAILABLE(2, 6)
-#define PURPLE_AVAILABLE_STATIC_INLINE_IN_2_6 PURPLE_UNAVAILABLE_STATIC_INLINE(2, 6)
-#define PURPLE_AVAILABLE_TYPE_IN_2_6 PURPLE_UNAVAILABLE_TYPE(2, 6)
-#else
-#define PURPLE_AVAILABLE_IN_2_6 _PURPLE_EXTERN
-#define PURPLE_AVAILABLE_STATIC_INLINE_IN_2_6
-#define PURPLE_AVAILABLE_TYPE_IN_2_6
-#endif
+#define PIDGIN_VERSION_2_3 (G_ENCODE_VERSION(2, 3))
 
-/**
- * PURPLE_VERSION_2_7:
- *
- * A macro that evaluates to the 2.7 version of libpurple, in a format that
- * can be used by the C pre-processor.
- *
- * Since: 3.0.0
- */
-#define PURPLE_VERSION_2_7 (G_ENCODE_VERSION(2, 7))
-
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_7
-#define PURPLE_AVAILABLE_IN_2_7 PURPLE_UNAVAILABLE(2, 7)
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_2_3
+#define PIDGIN_AVAILABLE_IN_2_3 PIDGIN_UNAVAILABLE(2, 3)
 #else
-#define PURPLE_AVAILABLE_IN_2_7 _PURPLE_EXTERN
+#define PIDGIN_AVAILABLE_IN_2_3 _PIDGIN_EXTERN
 #endif
 
 /**
- * PURPLE_VERSION_2_8:
+ * PIDGIN_VERSION_2_4:
  *
- * A macro that evaluates to the 2.8 version of libpurple, in a format that
- * can be used by the C pre-processor.
+ * A macro that evaluates to the 2.4 version of Pidgin, in a format that can be
+ * used by the C pre-processor.
  *
  * Since: 3.0.0
  */
-#define PURPLE_VERSION_2_8 (G_ENCODE_VERSION(2, 8))
+#define PIDGIN_VERSION_2_4 (G_ENCODE_VERSION(2, 4))
 
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_8
-#define PURPLE_AVAILABLE_IN_2_8 PURPLE_UNAVAILABLE(2, 8)
-#define PURPLE_AVAILABLE_ENUMERATOR_IN_2_8 PURPLE_UNAVAILABLE_ENUMERATOR(2, 8)
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_2_4
+#define PIDGIN_AVAILABLE_IN_2_4 PIDGIN_UNAVAILABLE(2, 4)
 #else
-#define PURPLE_AVAILABLE_IN_2_8 _PURPLE_EXTERN
-#define PURPLE_AVAILABLE_ENUMERATOR_IN_2_8
+#define PIDGIN_AVAILABLE_IN_2_4 _PIDGIN_EXTERN
 #endif
 
 /**
- * PURPLE_VERSION_2_9:
+ * PIDGIN_VERSION_2_5:
  *
- * A macro that evaluates to the 2.9 version of libpurple, in a format that
- * can be used by the C pre-processor.
+ * A macro that evaluates to the 2.5 version of Pidgin, in a format that can be
+ * used by the C pre-processor.
  *
  * Since: 3.0.0
  */
-#define PURPLE_VERSION_2_9 (G_ENCODE_VERSION(2, 9))
+#define PIDGIN_VERSION_2_5 (G_ENCODE_VERSION(2, 5))
 
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_9
-#define PURPLE_AVAILABLE_IN_2_9 PURPLE_UNAVAILABLE(2, 9)
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_2_5
+#define PIDGIN_AVAILABLE_IN_2_5 PIDGIN_UNAVAILABLE(2, 5)
 #else
-#define PURPLE_AVAILABLE_IN_2_9 _PURPLE_EXTERN
+#define PIDGIN_AVAILABLE_IN_2_5 _PIDGIN_EXTERN
 #endif
 
 /**
- * PURPLE_VERSION_2_10:
+ * PIDGIN_VERSION_2_6:
  *
- * A macro that evaluates to the 2.10 version of libpurple, in a format that
- * can be used by the C pre-processor.
+ * A macro that evaluates to the 2.6 version of Pidgin, in a format that can be
+ * used by the C pre-processor.
  *
  * Since: 3.0.0
  */
-#define PURPLE_VERSION_2_10 (G_ENCODE_VERSION(2, 10))
+#define PIDGIN_VERSION_2_6 (G_ENCODE_VERSION(2, 6))
 
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_10
-#define PURPLE_AVAILABLE_IN_2_10 PURPLE_UNAVAILABLE(2, 10)
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_2_6
+#define PIDGIN_AVAILABLE_IN_2_6 PIDGIN_UNAVAILABLE(2, 6)
 #else
-#define PURPLE_AVAILABLE_IN_2_10 _PURPLE_EXTERN
+#define PIDGIN_AVAILABLE_IN_2_6 _PIDGIN_EXTERN
 #endif
 
 /**
- * PURPLE_VERSION_2_11:
- *
- * A macro that evaluates to the 2.11 version of libpurple, in a format that
- * can be used by the C pre-processor.
+ * PIDGIN_VERSION_2_7:
  *
- * Since: 3.0.0
- */
-#define PURPLE_VERSION_2_11 (G_ENCODE_VERSION(2, 11))
-
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_11
-#define PURPLE_AVAILABLE_IN_2_11 PURPLE_UNAVAILABLE(2, 11)
-#else
-#define PURPLE_AVAILABLE_IN_2_11 _PURPLE_EXTERN
-#endif
-
-/**
- * PURPLE_VERSION_2_12:
- *
- * A macro that evaluates to the 2.12 version of libpurple, in a format that
- * can be used by the C pre-processor.
+ * A macro that evaluates to the 2.7 version of Pidgin, in a format that can be
+ * used by the C pre-processor.
  *
  * Since: 3.0.0
  */
-#define PURPLE_VERSION_2_12 (G_ENCODE_VERSION(2, 12))
+#define PIDGIN_VERSION_2_7 (G_ENCODE_VERSION(2, 7))
 
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_12
-#define PURPLE_AVAILABLE_IN_2_12 PURPLE_UNAVAILABLE(2, 12)
-#define PURPLE_AVAILABLE_ENUMERATOR_IN_2_12 PURPLE_UNAVAILABLE_ENUMERATOR(2, 12)
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_2_7
+#define PIDGIN_AVAILABLE_IN_2_7 PIDGIN_UNAVAILABLE(2, 7)
 #else
-#define PURPLE_AVAILABLE_IN_2_12 _PURPLE_EXTERN
-#define PURPLE_AVAILABLE_ENUMERATOR_IN_2_12
+#define PIDGIN_AVAILABLE_IN_2_7 _PIDGIN_EXTERN
 #endif
 
 /**
- * PURPLE_VERSION_2_13:
+ * PIDGIN_VERSION_2_8:
  *
- * A macro that evaluates to the 2.13 version of libpurple, in a format that
- * can be used by the C pre-processor.
+ * A macro that evaluates to the 2.8 version of Pidgin, in a format that can be
+ * used by the C pre-processor.
  *
  * Since: 3.0.0
  */
-#define PURPLE_VERSION_2_13 (G_ENCODE_VERSION(2, 13))
+#define PIDGIN_VERSION_2_8 (G_ENCODE_VERSION(2, 8))
 
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_13
-#define PURPLE_AVAILABLE_IN_2_13 PURPLE_UNAVAILABLE(2, 13)
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_2_8
+#define PIDGIN_AVAILABLE_IN_2_8 PIDGIN_UNAVAILABLE(2, 8)
 #else
-#define PURPLE_AVAILABLE_IN_2_13 _PURPLE_EXTERN
+#define PIDGIN_AVAILABLE_IN_2_8 _PIDGIN_EXTERN
 #endif
 
 /**
- * PURPLE_VERSION_2_14:
+ * PIDGIN_VERSION_2_9:
  *
- * A macro that evaluates to the 2.14 version of libpurple, in a format that
- * can be used by the C pre-processor.
+ * A macro that evaluates to the 2.9 version of Pidgin, in a format that can be
+ * used by the C pre-processor.
  *
  * Since: 3.0.0
  */
-#define PURPLE_VERSION_2_14 (G_ENCODE_VERSION(2, 14))
+#define PIDGIN_VERSION_2_9 (G_ENCODE_VERSION(2, 9))
 
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_14
-#define PURPLE_AVAILABLE_IN_2_14 PURPLE_UNAVAILABLE(2, 14)
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_2_9
+#define PIDGIN_AVAILABLE_IN_2_9 PIDGIN_UNAVAILABLE(2, 9)
 #else
-#define PURPLE_AVAILABLE_IN_2_14 _PURPLE_EXTERN
+#define PIDGIN_AVAILABLE_IN_2_9 _PIDGIN_EXTERN
 #endif
 
 /**
- * PURPLE_VERSION_3_0:
+ * PIDGIN_VERSION_2_10:
  *
- * A macro that evaluates to the 3.0 version of libpurple, in a format that can
+ * A macro that evaluates to the 2.10 version of Pidgin, in a format that can
  * be used by the C pre-processor.
  *
  * Since: 3.0.0
  */
-#define PURPLE_VERSION_3_0 (G_ENCODE_VERSION(3, 0))
+#define PIDGIN_VERSION_2_10 (G_ENCODE_VERSION(2, 10))
+
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_2_10
+#define PIDGIN_AVAILABLE_IN_2_10 PIDGIN_UNAVAILABLE(2, 10)
+#else
+#define PIDGIN_AVAILABLE_IN_2_10 _PIDGIN_EXTERN
+#endif
+
+/**
+ * PIDGIN_VERSION_2_11:
+ *
+ * A macro that evaluates to the 2.11 version of Pidgin, in a format that can
+ * be used by the C pre-processor.
+ *
+ * Since: 3.0.0
+ */
+#define PIDGIN_VERSION_2_11 (G_ENCODE_VERSION(2, 11))
 
-#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_3_0
-#define PURPLE_AVAILABLE_IN_3_0 PURPLE_UNAVAILABLE(3, 0)
-#define PURPLE_AVAILABLE_STATIC_INLINE_IN_3_0 PURPLE_UNAVAILABLE_STATIC_INLINE(3, 0)
-#define PURPLE_AVAILABLE_MACRO_IN_3_0 PURPLE_UNAVAILABLE_MACRO(3, 0)
-#define PURPLE_AVAILABLE_ENUMERATOR_IN_3_0 PURPLE_UNAVAILABLE_ENUMERATOR(3, 0)
-#define PURPLE_AVAILABLE_TYPE_IN_3_0 PURPLE_UNAVAILABLE_TYPE(3, 0)
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_2_11
+#define PIDGIN_AVAILABLE_IN_2_11 PIDGIN_UNAVAILABLE(2, 11)
 #else
-#define PURPLE_AVAILABLE_IN_3_0 _PURPLE_EXTERN
-#define PURPLE_AVAILABLE_STATIC_INLINE_IN_3_0
-#define PURPLE_AVAILABLE_MACRO_IN_3_0
-#define PURPLE_AVAILABLE_ENUMERATOR_IN_3_0
-#define PURPLE_AVAILABLE_TYPE_IN_3_0
+#define PIDGIN_AVAILABLE_IN_2_11 _PIDGIN_EXTERN
+#endif
+
+/**
+ * PIDGIN_VERSION_2_12:
+ *
+ * A macro that evaluates to the 2.12 version of Pidgin, in a format that can
+ * be used by the C pre-processor.
+ *
+ * Since: 3.0.0
+ */
+#define PIDGIN_VERSION_2_12 (G_ENCODE_VERSION(2, 12))
+
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_2_12
+#define PIDGIN_AVAILABLE_IN_2_12 PIDGIN_UNAVAILABLE(2, 12)
+#else
+#define PIDGIN_AVAILABLE_IN_2_12 _PIDGIN_EXTERN
 #endif
 
 /**
- * PURPLE_VERSION_CHECK:
- * @major: The major version to check for.
- * @minor: The minor version to check for.
- * @micro: The micro version to check for.
+ * PIDGIN_VERSION_2_13:
  *
- * Checks the version of libpurple being compiled against.  See
- * #purple_version_check for a runtime check.
+ * A macro that evaluates to the 2.13 version of Pidgin, in a format that can
+ * be used by the C pre-processor.
  *
- * Returns: %TRUE if the version of libpurple is the same or newer than the
- *          passed-in version.
+ * Since: 3.0.0
  */
-#define PURPLE_VERSION_CHECK(major, minor, micro) ((major) == PURPLE_MAJOR_VERSION && \
-                                                   ((minor) < PURPLE_MINOR_VERSION || \
-                                                    ((minor) == PURPLE_MINOR_VERSION && (micro) <= PURPLE_MICRO_VERSION)))
+#define PIDGIN_VERSION_2_13 (G_ENCODE_VERSION(2, 13))
 
-G_BEGIN_DECLS
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_2_13
+#define PIDGIN_AVAILABLE_IN_2_13 PIDGIN_UNAVAILABLE(2, 13)
+#else
+#define PIDGIN_AVAILABLE_IN_2_13 _PIDGIN_EXTERN
+#endif
 
 /**
- * purple_version_check:
- * @required_major: the required major version.
- * @required_minor: the required minor version.
- * @required_micro: the required micro version.
+ * PIDGIN_VERSION_2_14:
+ *
+ * A macro that evaluates to the 2.14 version of Pidgin, in a format that can
+ * be used by the C pre-processor.
  *
- * Checks that the libpurple version is compatible with the requested
- * version
- *
- * Returns: %NULL if the versions are compatible, or a string describing
- *          the version mismatch if not compatible.
+ * Since: 3.0.0
  */
-const char *purple_version_check(guint required_major, guint required_minor, guint required_micro);
+#define PIDGIN_VERSION_2_14 (G_ENCODE_VERSION(2, 14))
+
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_2_14
+#define PIDGIN_AVAILABLE_IN_2_14 PIDGIN_UNAVAILABLE(2, 14)
+#else
+#define PIDGIN_AVAILABLE_IN_2_14 _PIDGIN_EXTERN
+#endif
 
 /**
- * purple_major_version:
+ * PIDGIN_VERSION_3_0:
  *
- * The major version of the running libpurple.  Contrast with
- * #PURPLE_MAJOR_VERSION, which expands at compile time to the major version of
- * libpurple being compiled against.
- */
-PURPLE_VAR const guint purple_major_version;
-
-/**
- * purple_minor_version:
+ * A macro that evaluates to the 3.0 version of Pidgin, in a format that can be
+ * used by the C pre-processor.
  *
- * The minor version of the running libpurple.  Contrast with
- * #PURPLE_MINOR_VERSION, which expands at compile time to the minor version of
- * libpurple being compiled against.
+ * Since: 3.0.0
  */
-PURPLE_VAR const guint purple_minor_version;
+#define PIDGIN_VERSION_3_0 (G_ENCODE_VERSION(3, 0))
 
-/**
- * purple_micro_version:
- *
- * The micro version of the running libpurple.  Contrast with
- * #PURPLE_MICRO_VERSION, which expands at compile time to the micro version of
- * libpurple being compiled against.
- */
-PURPLE_VAR const guint purple_micro_version;
+#if PIDGIN_VERSION_MAX_ALLOWED < PIDGIN_VERSION_3_0
+#define PIDGIN_AVAILABLE_IN_3_0 PIDGIN_UNAVAILABLE(3, 0)
+#define PIDGIN_AVAILABLE_STATIC_INLINE_IN_3_0 PIDGIN_UNAVAILABLE_STATIC_INLINE(3, 0)
+#define PIDGIN_AVAILABLE_MACRO_IN_3_0 PIDGIN_UNAVAILABLE_MACRO(3, 0)
+#define PIDGIN_AVAILABLE_ENUMERATOR_IN_3_0 PIDGIN_UNAVAILABLE_ENUMERATOR(3, 0)
+#define PIDGIN_AVAILABLE_TYPE_IN_3_0 PIDGIN_UNAVAILABLE_TYPE(3, 0)
+#else
+#define PIDGIN_AVAILABLE_IN_3_0 _PIDGIN_EXTERN
+#define PIDGIN_AVAILABLE_STATIC_INLINE_IN_3_0
+#define PIDGIN_AVAILABLE_MACRO_IN_3_0
+#define PIDGIN_AVAILABLE_ENUMERATOR_IN_3_0
+#define PIDGIN_AVAILABLE_TYPE_IN_3_0
+#endif
 
-G_END_DECLS
-
-#endif /* PURPLE_VERSION_H */
+#endif /* PIDGIN_VERSION_H */
diff --git a/libpurple/purpleversionconsts.h.in b/pidgin/pidginversionconsts.h.in
copy from libpurple/purpleversionconsts.h.in
copy to pidgin/pidginversionconsts.h.in
--- a/libpurple/purpleversionconsts.h.in
+++ b/pidgin/pidginversionconsts.h.in
@@ -1,8 +1,8 @@
 /*
- * Purple - Internet Messaging Library
+ * Pidgin - Internet Messenger
  * Copyright (C) Pidgin Developers <devel@pidgin.im>
  *
- * Purple is the legal property of its developers, whose names are too numerous
+ * Pidgin is the legal property of its developers, whose names are too numerous
  * to list here.  Please refer to the COPYRIGHT file distributed with this
  * source distribution.
  *
@@ -20,47 +20,47 @@
  * along with this program; if not, see <https://www.gnu.org/licenses/>.
  */
 
-#if !defined(PURPLE_GLOBAL_HEADER_INSIDE) && !defined(PURPLE_COMPILATION)
-# error "only <purple.h> may be included directly"
+#if !defined(PIDGIN_GLOBAL_HEADER_INSIDE) && !defined(PIDGIN_COMPILATION)
+# error "only <pidgin.h> may be included directly"
 #endif
 
-#ifndef PURPLE_VERSION_CONSTS_H
-#define PURPLE_VERSION_CONSTS_H
+#ifndef PIDGIN_VERSION_CONSTS_H
+#define PIDGIN_VERSION_CONSTS_H
 
 /**
- * PURPLE_MAJOR_VERSION:
+ * PIDGIN_MAJOR_VERSION:
  *
- * The major version of the running libpurple.
+ * The major version of the running Pidgin.
  */
-#define PURPLE_MAJOR_VERSION (@PURPLE_MAJOR_VERSION@)
+#define PIDGIN_MAJOR_VERSION (@PURPLE_MAJOR_VERSION@)
 
 /**
- * PURPLE_MINOR_VERSION:
+ * PIDGIN_MINOR_VERSION:
  *
- * The minor version of the running libpurple.
+ * The minor version of the running Pidgin.
  */
-#define PURPLE_MINOR_VERSION (@PURPLE_MINOR_VERSION@)
+#define PIDGIN_MINOR_VERSION (@PURPLE_MINOR_VERSION@)
 
 /**
- * PURPLE_MICRO_VERSION:
+ * PIDGIN_MICRO_VERSION:
  *
- * The micro version of the running libpurple.
+ * The micro version of the running Pidgin.
  */
-#define PURPLE_MICRO_VERSION (@PURPLE_MICRO_VERSION@)
+#define PIDGIN_MICRO_VERSION (@PURPLE_MICRO_VERSION@)
 
 /**
- * PURPLE_EXTRA_VERSION:
+ * PIDGIN_EXTRA_VERSION:
  *
  * The "extra" part of the version number if anything.  Typical values are
  * "devel", "beta1", "rc2", etc.
  */
-#define PURPLE_EXTRA_VERSION ("@PURPLE_EXTRA_VERSION@")
+#define PIDGIN_EXTRA_VERSION ("@PURPLE_EXTRA_VERSION@")
 
 /**
- * PURPLE_VERSION
+ * PIDGIN_VERSION
  *
  * The entire version as a string.
  */
-#define PURPLE_VERSION ("@PURPLE_VERSION@")
+#define PIDGIN_VERSION ("@PURPLE_VERSION@")
 
-#endif /* PURPLE_VERSION_CONSTS_H */
+#endif /* PIDGIN_VERSION_CONSTS_H */
# HG changeset patch
# Node ID 2f0be5c81910
# Parent  51e7309a4bc2
diff --git a/pidgin/meson.build b/pidgin/meson.build
--- a/pidgin/meson.build
+++ b/pidgin/meson.build
@@ -131,6 +131,7 @@ libpidgin_headers = [
 	'pidginstatusprimitivechooser.h',
 	'pidgintextbuffer.h',
 	'pidginui.h',
+	'pidginversion.h',
 ]
 
 libpidgin_prefs_headers = [
@@ -186,7 +187,7 @@ if IS_WIN32
 endif
 
 PIDGIN_H_INCLUDES = []
-foreach header : libpidgin_headers + libpidgin_prefs_headers
+foreach header : libpidgin_headers + libpidgin_prefs_headers + ['pidginversionconsts.h']
 	PIDGIN_H_INCLUDES += f'#include <pidgin/@header@>'
 endforeach
 pidgin_h_conf = configuration_data()
@@ -196,6 +197,11 @@ pidgin_h = configure_file(input : 'pidgi
                           configuration : pidgin_h_conf,
                           install : true,
                           install_dir : get_option('includedir') / pidgin_filebase)
+pidgin_version_h = configure_file(input : 'pidginversionconsts.h.in',
+                                  output : 'pidginversionconsts.h',
+                                  configuration : version_conf,
+                                  install : true,
+                                  install_dir : get_option('includedir') / pidgin_filebase)
 
 install_headers(libpidgin_headers, subdir : pidgin_include_base)
 install_headers(libpidgin_prefs_headers, subdir : pidgin_include_base / 'prefs')
@@ -217,6 +223,7 @@ libpidgin_built_sources = [
 
 libpidgin_built_headers = [
 	pidgin_h,
+	pidgin_version_h,
 ]
 
 libpidgin_inc = include_directories('.')
