Description: port to multiarched libdpkg.
 multiarch dpkg implies API changes to some of the dpkg structures.  Update
 luau.c accordingly.
Author: Steve Langasek <steve.langasek@canonical.com>
Bug-Ubuntu: https://bugs.launchpad.net/bugs/749092

--- deets-0.1.1.orig/luau.c
+++ deets-0.1.1/luau.c
@@ -68,7 +68,7 @@ dpkg_status (lua_State * L)
 	  lua_error (L);
 	}
 
-      p = pkg_db_find (lua_tostring (L, i));
+      p = pkg_db_find_pkg (lua_tostring (L, i), dpkg_arch_get_native());
       switch (p->status)
 	{
 	case stat_notinstalled:
@@ -107,15 +107,15 @@ static int
 dpkg_pkglist (lua_State * L)
 {
   struct pkgiterator *iter;
-  struct pkginfo *pkg;
+  struct pkgset *set;
   int i = 0;
 
   lua_newtable (L);
 
-  for (iter = pkg_db_iter_new (); (pkg = pkg_db_iter_next (iter));)
+  for (iter = pkg_db_iter_new (); (set = pkg_db_iter_next_set (iter));)
     {
       lua_pushnumber (L, ++i);
-      lua_pushstring (L, pkg->name);
+      lua_pushstring (L, set->name);
       lua_rawset (L, -3);
     }
   pkg_db_iter_free (iter);
@@ -137,7 +137,7 @@ dpkg_conffilelist (lua_State * L)
       lua_error (L);
     }
 
-  p = pkg_db_find (lua_tostring (L, 1));
+  p = pkg_db_find_pkg (lua_tostring (L, 1), dpkg_arch_get_native());
   if (!(c = p->installed.conffiles))
     {
       lua_pushnil (L);
