$NetBSD$

--- parse.c.orig	2010-05-27 20:21:36.000000000 +0000
+++ parse.c
@@ -880,8 +880,10 @@ parse_cflags (Package *pkg, const char *
             pkg->other_cflags = g_slist_prepend (pkg->other_cflags,
                                                  g_strdup (arg));
 	  if (strcmp("-idirafter", arg) == 0) {
+	      char *n;
+		  
               tmp = trim_string(argv[++i]);
-	      char *n = strdup_escape_shell(tmp);
+	      n = strdup_escape_shell(tmp);
 	      pkg->other_cflags = g_slist_prepend(pkg->other_cflags, n);
 	      g_free(tmp);
 	  }
@@ -1460,102 +1462,8 @@ get_compat_package (const char *name)
     }
   else
     {
-      /* Check for the module in gnome-config */
-      char *output;
-      char *p;
-      char *command;
-
-      debug_spew ("Calling gnome-config\n");
-      
-      /* Annoyingly, --modversion doesn't return a failure
-       * code if the lib is unknown, so we have to use --libs
-       * for that.
-       */
-      
-      command = g_strdup_printf ("gnome-config --libs %s",
-                                 name);
-      
-      if (!try_command (command))
-        {
-          g_free (command);
-          g_free (pkg);
-          return NULL;
-        }
-      else
-        g_free (command);
-      
-      command = g_strdup_printf ("gnome-config --modversion %s",
-                                 name);
-      
-      output = backticks (command);
-      g_free (command);
-      if (output == NULL)
-        {
-          g_free (pkg);
-          return NULL;
-        }
-      
-      /* Unknown modules give "Unknown library `foo'" from gnome-config
-       * (but on stderr so this is useless, nevermind)
-       */
-      if (strstr (output, "Unknown") || *output == '\0')
-        {
-          g_free (output);
-          g_free (pkg);
-          return NULL;
-        }
-
-      /* gnome-config --modversion gnomeui outputs e.g. "gnome-libs-1.2.4"
-       * or libglade-0.12
-       */
-      p = output;
-
-      while (*p && isspace ((guchar)*p))
-        ++p;
-
-      if (*p == '\0')
-        {
-          /* empty output */
-          g_free (output);
-          g_free (pkg);
-          return NULL;
-        }
-
-      /* only heuristic; find a number or . */
-      while (*p && ! (isdigit ((guchar)*p) || *p == '.'))
-        ++p;      
-
-      pkg->version = g_strdup (p);
-
-      g_free (output);
-      
-      /* Strip newline */
-      p = pkg->version;
-      while (*p)
-        {
-          if (*p == '\n')
-            *p = '\0';
-
-          ++p;
-        }
-      
-      pkg->name = g_strdup (name);
-      pkg->key = g_strdup (name);
-      pkg->description = g_strdup ("No description");
-
-      command = g_strdup_printf ("gnome-config --libs %s", name);
-      output = backticks (command);
-      g_free (command);
-      parse_libs (pkg, output, "gnome-config");
-      g_free (output);
-
-      command = g_strdup_printf ("gnome-config --cflags %s", name);
-      output = backticks (command);
-      g_free (command);
-      parse_cflags (pkg, output, "gnome-config");
-      g_free (output);
-
-      return pkg;
+      g_free (pkg);
+      return NULL;
     }
 #endif
 }
