diff options
author | jbeich <jbeich@FreeBSD.org> | 2017-01-28 03:26:22 +0800 |
---|---|---|
committer | jbeich <jbeich@FreeBSD.org> | 2017-01-28 03:26:22 +0800 |
commit | af0cd6f5e597248dfd61cfd0e7d4772aab7c7222 (patch) | |
tree | c6432f7b371c92f4a2e0757685b1e858eca8211d /databases | |
parent | 3c62a73ecebf52fd6c3fbf600d99085c7d0cbcc0 (diff) | |
download | freebsd-ports-gnome-af0cd6f5e597248dfd61cfd0e7d4772aab7c7222.tar.gz freebsd-ports-gnome-af0cd6f5e597248dfd61cfd0e7d4772aab7c7222.tar.zst freebsd-ports-gnome-af0cd6f5e597248dfd61cfd0e7d4772aab7c7222.zip |
databases/mysql-proxy: unbreak with libevent >= 2.1
chassis-mainloop.c:102:54: error: use of undeclared identifier '_EVENT_VERSION'
if (0 != chassis_check_version(event_get_version(), _EVENT_VERSION)) {
^
chassis-mainloop.c:104:15: error: use of undeclared identifier '_EVENT_VERSION'
G_STRLOC, _EVENT_VERSION, event_get_version());
^
/usr/local/include/glib-2.0/glib/gmessages.h:161:32: note: expanded from macro 'g_critical'
__VA_ARGS__)
^
chassis-mainloop.c:119:37: error: use of undeclared identifier '_EVENT_VERSION'
chas->event_hdr_version = g_strdup(_EVENT_VERSION);
^
PR: 216527
Diffstat (limited to 'databases')
-rw-r--r-- | databases/mysql-proxy/files/patch-src_chassis-mainloop.c | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/databases/mysql-proxy/files/patch-src_chassis-mainloop.c b/databases/mysql-proxy/files/patch-src_chassis-mainloop.c new file mode 100644 index 000000000000..95f8dac6af2d --- /dev/null +++ b/databases/mysql-proxy/files/patch-src_chassis-mainloop.c @@ -0,0 +1,40 @@ +Switch away from deprecated libevent macros. + +--- src/chassis-mainloop.c.orig 2013-12-23 22:57:16 UTC ++++ src/chassis-mainloop.c +@@ -99,9 +99,9 @@ int chassis_check_version(const char *li + chassis *chassis_new() { + chassis *chas; + +- if (0 != chassis_check_version(event_get_version(), _EVENT_VERSION)) { ++ if (0 != chassis_check_version(event_get_version(), LIBEVENT_VERSION)) { + g_critical("%s: chassis is build against libevent %s, but now runs against %s", +- G_STRLOC, _EVENT_VERSION, event_get_version()); ++ G_STRLOC, LIBEVENT_VERSION, event_get_version()); + return NULL; + } + +@@ -116,7 +116,7 @@ chassis *chassis_new() { + + chas->threads = chassis_event_threads_new(); + +- chas->event_hdr_version = g_strdup(_EVENT_VERSION); ++ chas->event_hdr_version = g_strdup(LIBEVENT_VERSION); + + chas->shutdown_hooks = chassis_shutdown_hooks_new(); + +@@ -225,10 +225,10 @@ static void event_log_use_glib(int libev + + GLogLevelFlags glib_log_level = G_LOG_LEVEL_DEBUG; + +- if (libevent_log_level == _EVENT_LOG_DEBUG) glib_log_level = G_LOG_LEVEL_DEBUG; +- else if (libevent_log_level == _EVENT_LOG_MSG) glib_log_level = G_LOG_LEVEL_MESSAGE; +- else if (libevent_log_level == _EVENT_LOG_WARN) glib_log_level = G_LOG_LEVEL_WARNING; +- else if (libevent_log_level == _EVENT_LOG_ERR) glib_log_level = G_LOG_LEVEL_CRITICAL; ++ if (libevent_log_level == EVENT_LOG_DEBUG) glib_log_level = G_LOG_LEVEL_DEBUG; ++ else if (libevent_log_level == EVENT_LOG_MSG) glib_log_level = G_LOG_LEVEL_MESSAGE; ++ else if (libevent_log_level == EVENT_LOG_WARN) glib_log_level = G_LOG_LEVEL_WARNING; ++ else if (libevent_log_level == EVENT_LOG_ERR) glib_log_level = G_LOG_LEVEL_CRITICAL; + + g_log(G_LOG_DOMAIN, glib_log_level, "(libevent) %s", msg); + } |