$OpenBSD: patch-garglk_launchgtk_c,v 1.1 2010/10/23 09:15:16 jasper Exp $

Remove Linux'ism to figure out the libexec dir.

--- garglk/launchgtk.c.orig	Fri Sep 24 12:36:30 2010
+++ garglk/launchgtk.c	Fri Oct 22 18:00:34 2010
@@ -146,6 +146,7 @@ void winbrowsefile(char *buffer)
 
 void winpath(char *buffer)
 {
+#if defined(__linux__)
     char exepath[MaxBuffer] = {0};
     unsigned int exelen;
 
@@ -157,6 +158,10 @@ void winpath(char *buffer)
     }
 
     strcpy(buffer, exepath);
+#elif defined(__OpenBSD__)
+    char exepath[MaxBuffer] = "${LOCALBASE}/libexec/gargoyle/";
+    snprintf(buffer, sizeof(exepath), "%s", exepath );
+#endif
 
     char *dirpos = strrchr(buffer, *DirSeparator);
     if ( dirpos != NULL )
