qulogic/pidgin

Set minimum allowed API to 2.0

8 months ago, Elliott Sales de Andrade
e3886c8b95fe
Parents 185c0b83e408
Children 1433d84e7374
Set minimum allowed API to 2.0

We have not tagged anything before that due to the core/UI split and rename, so
there's no point in going further back.

Also, backfill the macros for the remaining versions, in case people feel like
using them.

Testing Done:
Compiled.

Bugs closed: PIDGIN-17838

Reviewed at https://reviews.imfreedom.org/r/2733/
--- a/libpurple/purpleversion.h Thu Oct 26 22:35:00 2023 -0500
+++ b/libpurple/purpleversion.h Thu Oct 26 22:38:06 2023 -0500
@@ -98,14 +98,30 @@
#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_MIN_REQUIRED
#error "PURPLE_VERSION_MAX_ALLOWED must be >= PURPLE_VERSION_MIN_REQUIRED"
#endif
-#if PURPLE_VERSION_MIN_REQUIRED < G_ENCODE_VERSION(0, 1)
-#error "PURPLE_VERSION_MIN_REQUIRED must be >= PURPLE_VERSION_0_1"
+#if PURPLE_VERSION_MIN_REQUIRED < G_ENCODE_VERSION(2, 0)
+#error "PURPLE_VERSION_MIN_REQUIRED must be >= PURPLE_VERSION_2_0"
#endif
#define PURPLE_VAR _PURPLE_EXTERN
#define PURPLE_AVAILABLE_IN_ALL _PURPLE_EXTERN
/**
+ * PURPLE_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.
+ *
+ * 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
+
+/**
* PURPLE_VERSION_2_1:
*
* A macro that evaluates to the 2.1 version of libpurple, in a format that
@@ -246,6 +262,38 @@
#endif
/**
+ * PURPLE_VERSION_2_9:
+ *
+ * A macro that evaluates to the 2.9 version of libpurple, 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))
+
+#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_9
+#define PURPLE_AVAILABLE_IN_2_9 PURPLE_UNAVAILABLE(2, 9)
+#else
+#define PURPLE_AVAILABLE_IN_2_9 _PURPLE_EXTERN
+#endif
+
+/**
+ * PURPLE_VERSION_2_10:
+ *
+ * A macro that evaluates to the 2.10 version of libpurple, 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))
+
+#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_10
+#define PURPLE_AVAILABLE_IN_2_10 PURPLE_UNAVAILABLE(2, 10)
+#else
+#define PURPLE_AVAILABLE_IN_2_10 _PURPLE_EXTERN
+#endif
+
+/**
* PURPLE_VERSION_2_11:
*
* A macro that evaluates to the 2.11 version of libpurple, in a format that
@@ -280,6 +328,22 @@
#endif
/**
+ * PURPLE_VERSION_2_13:
+ *
+ * A macro that evaluates to the 2.13 version of libpurple, 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))
+
+#if PURPLE_VERSION_MAX_ALLOWED < PURPLE_VERSION_2_13
+#define PURPLE_AVAILABLE_IN_2_13 PURPLE_UNAVAILABLE(2, 13)
+#else
+#define PURPLE_AVAILABLE_IN_2_13 _PURPLE_EXTERN
+#endif
+
+/**
* PURPLE_VERSION_2_14:
*
* A macro that evaluates to the 2.14 version of libpurple, in a format that