https://bugs.launchpad.net/percona-server/+bug/1496315 https://svnweb.freebsd.org/ports/head/databases/percona56-server/files/patch-sql_mysqld.cc?view=markup&pathrev=399074 --- percona-server-5.7.18-15/sql/mysqld.cc.~1~ 2017-05-25 10:03:51.000000000 +0000 +++ percona-server-5.7.18-15/sql/mysqld.cc 2017-07-25 10:41:57.046304506 +0000 @@ -1482,6 +1482,16 @@ ****************************************************************************/ /* Initialise proxy protocol. */ + +/* At least OpenBSD and NexentaCore do not +* define s6_addr32 for user land settings. +*/ +#if !defined s6_addr32 && defined __sun__ +# define s6_addr32 _S6_un._S6_u32 +#elif !defined s6_addr32 && ( defined __OpenBSD__ || defined __FreeBSD__ ) +# define s6_addr32 __u6_addr.__u6_addr32 +#endif /* !defined s6_addr32 */ + static void set_proxy() { const char *p; --- percona-server-5.6.28-76.1/vio/viosocket.c.1 2016-01-21 14:13:49.783597806 +0300 +++ percona-server-5.6.28-76.1/vio/viosocket.c 2016-01-21 14:14:43.695032467 +0300 @@ -29,6 +29,15 @@ # include #endif +/* At least OpenBSD and NexentaCore do not + * define s6_addr32 for user land settings. + */ +#if !defined s6_addr32 && defined __sun__ +# define s6_addr32 _S6_un._S6_u32 +#elif !defined s6_addr32 && ( defined __OpenBSD__ || defined __FreeBSD__ ) +# define s6_addr32 __u6_addr.__u6_addr32 +#endif /* !defined s6_addr32 */ + /* Network io wait callbacks for threadpool */ static void (*before_io_wait)(void)= 0; static void (*after_io_wait)(void)= 0;