Your message dated Sun, 24 Jun 2012 10:49:24 +0000
with message-id <[email protected]>
and subject line Bug#675063: fixed in libextractor 1:0.6.3-5
has caused the Debian Bug report #675063,
regarding extract: fails to load plugins from path with underscore
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
675063: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=675063
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: extract
Version: 1:0.6.3-4
Severity: important
Tags: upstream patch

Dear Maintainer,

The extract command is currently unusable in Debian amd64.
Every plugin loaded fails with this sort of error message:

>Resolving symbol 
>`EXTRACTOR_64-linux-gnu/libextractor/libextractor_elf_extract' failed,
>so I tried `_EXTRACTOR_64-linux-gnu/libextractor/libextractor_elf_extract', 
>but that failed also.
>Errors are: `/usr/lib/x86_64-linux-gnu/libextractor/libextractor_elf.so: 
>undefined symbol: 
>EXTRACTOR_64-linux-gnu/libextractor/libextractor_elf_extract' and 
>`/usr/lib/x86_64-linux-gnu/libextractor/libextractor_elf.so: undefined symbol: 
>_EXTRACTOR_64-linux-gnu/libextractor/libextractor_elf_extract'.
>Resolving `extract' method of plugin `elf' failed: (null)
>Plugin `elf' failed to load!

The plugins are stored in /usr/lib/x86_64-linux-gnu/libextractor/ on my system.
The program parses the .so name to derive the extract function symbol name,
and is confused by the _ in the lib path.

I have modified the source to search for the last _ in the .so filename instead 
of the first.

The first patch is against Debian's 0.6.3-4 as retrieved by apt-get source.
The second patch is against upstream HEAD (currently rev21634) which has 
re-arranged the code a bit.

These patches are untested as I am having trouble building a working binary
(vanilla or modified) but as you can see the changes are fairly minor.

Regards,
Harun Trefry


-- System Information:
Debian Release: wheezy/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'stable'), (500, 'oldstable')
Architecture: amd64 (x86_64)

Kernel: Linux 3.2.0-2-amd64 (SMP w/3 CPU cores)
Locale: LANG=en_AU.UTF-8, LC_CTYPE=en_AU.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages extract depends on:
ii  dpkg                  1.16.3
ii  install-info          4.13a.dfsg.1-10
ii  libc6                 2.13-32
ii  libextractor-plugins  1:0.6.3-4
ii  libextractor3         1:0.6.3-4

extract recommends no packages.

extract suggests no packages.

-- no debconf information
diff -r -u libextractor-0.6.3/src/main/extractor.c mine/src/main/extractor.c
--- libextractor-0.6.3/src/main/extractor.c	2011-11-28 17:52:27.000000000 +0800
+++ mine/src/main/extractor.c	2012-05-29 23:30:12.772916677 +0800
@@ -691,14 +691,14 @@
   const char *(*opt_fun)(void);
 
   if (NULL != options) *options = NULL;
-  sym_name = strstr (prefix, "_");
+  sym_name = strrchr (prefix, '_');
   if (sym_name == NULL)
     return NULL;
   sym_name++;
   sym = strdup (sym_name);
   if (sym == NULL)
     return NULL;
-  dot = strstr (sym, ".");
+  dot = strchr (sym, '.');
   if (dot != NULL)
     *dot = '\0';
   name = malloc(strlen(sym) + strlen(template) + 1);
Index: extractor_plugins.c
===================================================================
--- extractor_plugins.c	(revision 21634)
+++ extractor_plugins.c	(working copy)
@@ -71,14 +71,14 @@
   const char *(*opt_fun)(void);
 
   if (NULL != options) *options = NULL;
-  sym_name = strstr (prefix, "_");
+  sym_name = strrchr (prefix, '_');
   if (sym_name == NULL)
     return NULL;
   sym_name++;
   sym = strdup (sym_name);
   if (sym == NULL)
     return NULL;
-  dot = strstr (sym, ".");
+  dot = strchr (sym, '.');
   if (dot != NULL)
     *dot = '\0';
   name = malloc(strlen(sym) + strlen(template) + 1);
Index: extractor_plugpath.c
===================================================================
--- extractor_plugpath.c	(revision 21634)
+++ extractor_plugpath.c	(working copy)
@@ -407,7 +407,7 @@
       if ( (NULL != (la = strstr (ent->d_name, ".la"))) &&
 	   (la[3] == '\0') )
 	continue; /* only load '.so' and '.dll' */
-      sym_name = strstr (ent->d_name, "_");
+      sym_name = strrchr (ent->d_name, '_');
       if (sym_name == NULL)
 	continue;	
       sym_name++;
@@ -417,7 +417,7 @@
 	  CLOSEDIR (dir);
 	  return;
 	}
-      dot = strstr (sym, ".");
+      dot = strchr (sym, '.');
       if (dot != NULL)
 	*dot = '\0';
       if (0 == strcmp (sym, sc->short_name))
@@ -491,7 +491,7 @@
 	     (la[2] == '\0')) )
 	continue; /* only load '.so' and '.dll' */
 
-      sym_name = strstr (ent->d_name, "_");
+      sym_name = strrchr (ent->d_name, '_');
       if (sym_name == NULL)
 	continue;
       sym_name++;
@@ -501,7 +501,7 @@
 	  closedir (dir);
 	  return;
 	}
-      dot = strstr (sym, ".");
+      dot = strchr (sym, '.');
       if (dot != NULL)
 	*dot = '\0';
 #if DEBUG > 1

--- End Message ---
--- Begin Message ---
Source: libextractor
Source-Version: 1:0.6.3-5

We believe that the bug you reported is fixed in the latest version of
libextractor, which is due to be installed in the Debian FTP archive:

extract_0.6.3-5_amd64.deb
  to main/libe/libextractor/extract_0.6.3-5_amd64.deb
extract_0.6.3-5_i386.deb
  to main/libe/libextractor/extract_0.6.3-5_i386.deb
libextractor-dbg_0.6.3-5_amd64.deb
  to main/libe/libextractor/libextractor-dbg_0.6.3-5_amd64.deb
libextractor-dbg_0.6.3-5_i386.deb
  to main/libe/libextractor/libextractor-dbg_0.6.3-5_i386.deb
libextractor-dev_0.6.3-5_amd64.deb
  to main/libe/libextractor/libextractor-dev_0.6.3-5_amd64.deb
libextractor-dev_0.6.3-5_i386.deb
  to main/libe/libextractor/libextractor-dev_0.6.3-5_i386.deb
libextractor-plugins_0.6.3-5_amd64.deb
  to main/libe/libextractor/libextractor-plugins_0.6.3-5_amd64.deb
libextractor-plugins_0.6.3-5_i386.deb
  to main/libe/libextractor/libextractor-plugins_0.6.3-5_i386.deb
libextractor3_0.6.3-5_amd64.deb
  to main/libe/libextractor/libextractor3_0.6.3-5_amd64.deb
libextractor3_0.6.3-5_i386.deb
  to main/libe/libextractor/libextractor3_0.6.3-5_i386.deb
libextractor_0.6.3-5.debian.tar.gz
  to main/libe/libextractor/libextractor_0.6.3-5.debian.tar.gz
libextractor_0.6.3-5.dsc
  to main/libe/libextractor/libextractor_0.6.3-5.dsc



A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Bertrand Marc <[email protected]> (supplier of updated libextractor package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Format: 1.8
Date: Sat, 23 Jun 2012 18:45:49 +0200
Source: libextractor
Binary: libextractor3 libextractor-plugins libextractor-dbg libextractor-dev 
extract
Architecture: amd64 i386 source
Version: 1:0.6.3-5
Distribution: unstable
Urgency: low
Maintainer: Bertrand Marc <[email protected]>
Changed-By: Bertrand Marc <[email protected]>
Closes: 673304 675063
Description: 
 extract    - displays meta-data from files of arbitrary type
 libextractor3 - extracts meta-data from files of arbitrary type (library)
 libextractor-dbg - extracts meta-data from files of arbitrary type (debug)
 libextractor-dev - extracts meta-data from files of arbitrary type 
(development)
 libextractor-plugins - extracts meta-data from files of arbitrary type 
(plugins)
Changes: 
 libextractor (1:0.6.3-5) unstable; urgency=low
 .
   * debian/control: add Vcs-Git and Vcs-browser fields.
   * Switch the libpoppler-dev build dependency to libpoppler-private-dev
     (Closes: #673304).
   * Include a patch to load plugins from path with underscore, thanks to Harun
     Trefry (Closes: #675063).
Checksums-Sha1: 
 5624e25086a431a21f9c90f02d4919677acf66d2 1706 libextractor_0.6.3-5.dsc
 f99c331d0401ecdfbf6b1a23fac09ad7d68688aa 8667 
libextractor_0.6.3-5.debian.tar.gz
 384cd165c76b2c716b1cbcd7128b6be9d8e9eb79 141264 libextractor3_0.6.3-5_amd64.deb
 26eacfdb4a502a1ad01251ec7b33c6ee975a76b3 46508 
libextractor-plugins_0.6.3-5_amd64.deb
 85a2b6af459fb68feeec4362e0d49e3db7f39a78 495224 
libextractor-dbg_0.6.3-5_amd64.deb
 a3e22c35801c5b9622c58e3900c55507c543c348 24296 
libextractor-dev_0.6.3-5_amd64.deb
 92b5ea2d4e291d4afa7ba188c58a37e3fa1ad34e 111132 extract_0.6.3-5_amd64.deb
 ce324f82ac757684d5fac52d27e55bafd05f4b04 132700 libextractor3_0.6.3-5_i386.deb
 31778bcd21b5bd05ecb44b9abfedab95bfaae065 45340 
libextractor-plugins_0.6.3-5_i386.deb
 682645fdb2f62e2bb789f462d350f35f262009a7 475146 
libextractor-dbg_0.6.3-5_i386.deb
 26e86be6dca8630ca1d66589c639924ea5e73bc7 24292 
libextractor-dev_0.6.3-5_i386.deb
 e741bebf8e8cfa848cbdda1404355dad82bb933d 110682 extract_0.6.3-5_i386.deb
Checksums-Sha256: 
 78bf7892d2c906dbcef4d6bfe0847f4a17099cc05c92190542c9ae40a4a8f696 1706 
libextractor_0.6.3-5.dsc
 160bf9721a0fdaf8fbaec4e9d608c0928b032b354a99ccbcb1ffb850ef7d4a5c 8667 
libextractor_0.6.3-5.debian.tar.gz
 6ff31766a02704d9583f90151af3938005fcfb23d9b78c8165db3194eb757e53 141264 
libextractor3_0.6.3-5_amd64.deb
 00947ed73e23079ef84281e37515eca7bbe9a06c4dff82188c44dcc07708aa68 46508 
libextractor-plugins_0.6.3-5_amd64.deb
 45b15dfec7d0b241652611a0ce448a424ffca4100fc4682ba38ece9eb83cba3a 495224 
libextractor-dbg_0.6.3-5_amd64.deb
 296bc8bb7aed8f63ef205d820b08a7c99fbec3fae32aa92eb61670f01191e37e 24296 
libextractor-dev_0.6.3-5_amd64.deb
 09b86a7d24b4600203030523ef566b47108216275769a7c51fc0f024835c6664 111132 
extract_0.6.3-5_amd64.deb
 b33cdd6cb610440089be1ccb4115e1591286896ced2d93033c2c38fdf0906faa 132700 
libextractor3_0.6.3-5_i386.deb
 c2b24acb8c4fc7f20cf90ca9e0909ea69a5bb73f33b921707bb6ea1c4dc33601 45340 
libextractor-plugins_0.6.3-5_i386.deb
 ebc4a4cc330553a7c481ec0602c9b5aa181cc478796d978684a01c2ba49275e4 475146 
libextractor-dbg_0.6.3-5_i386.deb
 795ea8566e92dcba67b291c4c5b3d933946d6537cd107aa77c37ee0054d87508 24292 
libextractor-dev_0.6.3-5_i386.deb
 4af6b00732d5a2f37a5c1fc6bacf1f649901953ff86f7e3860d682730ead6514 110682 
extract_0.6.3-5_i386.deb
Files: 
 0b6259e8f72538404572c913a2cc5128 1706 libs optional libextractor_0.6.3-5.dsc
 83d296cf45826f9bedb3a6c4636236d0 8667 libs optional 
libextractor_0.6.3-5.debian.tar.gz
 d33cdf61ebc36fa6303e3072e24624b1 141264 libs optional 
libextractor3_0.6.3-5_amd64.deb
 23c9964733d689c43466ee81bdc7f988 46508 libs optional 
libextractor-plugins_0.6.3-5_amd64.deb
 715f62dea39eff1cad6f0ead276503db 495224 debug extra 
libextractor-dbg_0.6.3-5_amd64.deb
 c4a996b64f24ea3c825ffbe98a189f30 24296 libdevel optional 
libextractor-dev_0.6.3-5_amd64.deb
 98e75d37dce7d675fa883a4ad980de99 111132 utils optional 
extract_0.6.3-5_amd64.deb
 d4299a1984e32b1f087b282ee8e93386 132700 libs optional 
libextractor3_0.6.3-5_i386.deb
 fc2521714de56ab255675eaafd4f854e 45340 libs optional 
libextractor-plugins_0.6.3-5_i386.deb
 9acbdf0f6535b2fd4ccdd194e796999c 475146 debug extra 
libextractor-dbg_0.6.3-5_i386.deb
 6b4c65a607a4a290d3a6f0e0c49637d1 24292 libdevel optional 
libextractor-dev_0.6.3-5_i386.deb
 8a07798c433c631ea52cf05bbe7cca68 110682 utils optional extract_0.6.3-5_i386.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)

iEYEARECAAYFAk/m7fwACgkQvjztR8bOoMmSIQCgvqwodGWwf6w0ettPo+L8S8Xh
LFIAoKQFQMMEGds+Wi2tozBwg9z13W1W
=7CL/
-----END PGP SIGNATURE-----



--- End Message ---

Reply via email to