--- lightdm-1.19.3/src/session-child.c.1	2016-08-07 22:50:16.026918519 +0300
+++ lightdm-1.19.3/src/session-child.c	2016-08-07 22:52:50.877831516 +0300
@@ -192,6 +192,7 @@
     return x_authority_new (x_authority_family, x_authority_address, x_authority_address_length, x_authority_number, x_authority_name, x_authority_data, x_authority_data_length);
 }
 
+#ifndef __sun__
 /* GNU provides this but we can't rely on that so let's make our own version */
 static void
 updwtmpx (const gchar *wtmp_file, struct utmpx *ut)
@@ -213,6 +213,7 @@
 
     updwtmp (wtmp_file, &u);
 }
+#endif
 
 #if HAVE_LIBAUDIT
 static void