libpulse: introduce PA_CHECK_VERSION macro

This commit is contained in:
Lennart Poettering 2009-05-26 22:31:05 +02:00
parent e8f7eb616a
commit 699bd542f3

View file

@ -60,6 +60,13 @@ const char* pa_get_library_version(void);
/** The micro version of PA. \since 0.9.15 */
#define PA_MICRO @PA_MICRO@
/** Evaluates to TRUE if the PulseAudio library version is equal or
* newer than the specified. \since 0.9.16 */
#define PA_CHECK_VERSION(major,minor,micro) \
((PA_MAJOR > (major)) || \
(PA_MAJOR == (major) && CA_MINOR > (minor)) || \
(PA_MAJOR == (major) && CA_MINOR == (minor) && CA_MICRO >= (micro)))
PA_C_DECL_END
#endif