valgrind can't redirect strlen for 32-bit executables

Bug #948004 reported by Jay Foad
38
This bug affects 8 people
Affects Status Importance Assigned to Milestone
valgrind (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

On x86_64 I can't valgrind even a simple 32-bit program that uses strlen. I get:

$ cat s.c
#include <string.h>
int main(int argc, const char *argv[]) {
  return strlen(argv[0]);
}
$ gcc -m32 -o s s.c && valgrind ./s
==6462== Memcheck, a memory error detector
==6462== Copyright (C) 2002-2011, and GNU GPL'd, by Julian Seward et al.
==6462== Using Valgrind-3.7.0 and LibVEX; rerun with -h for copyright info
==6462== Command: ./s
==6462==

valgrind: Fatal error at startup: a function redirection
valgrind: which is mandatory for this platform-tool combination
valgrind: cannot be set up. Details of the redirection are:
valgrind:
valgrind: A must-be-redirected function
valgrind: whose name matches the pattern: strlen
valgrind: in an object with soname matching: ld-linux.so.2
valgrind: was not found whilst processing
valgrind: symbols from the object with soname: ld-linux.so.2
valgrind:
valgrind: Possible fixes: (1, short term): install glibc's debuginfo
valgrind: package on this machine. (2, longer term): ask the packagers
valgrind: for your Linux distribution to please in future ship a non-
valgrind: stripped ld.so (or whatever the dynamic linker .so is called)
valgrind: that exports the above-named function using the standard
valgrind: calling conventions for this platform. The package you need
valgrind: to install for fix (1) is called
valgrind:
valgrind: On Debian, Ubuntu: libc6-dbg
valgrind: On SuSE, openSuSE, Fedora, RHEL: glibc-debuginfo
valgrind:
valgrind: Cannot continue -- exiting now. Sorry.

However, I already have libc6-dbg installed, and I can't find any 32-bit multilib package called "libc6-dbg-i386" or similar.

ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: valgrind 1:3.7.0-0ubuntu2
ProcVersionSignature: Ubuntu 3.2.0-18.28-generic 3.2.9
Uname: Linux 3.2.0-18-generic x86_64
ApportVersion: 1.94-0ubuntu2
Architecture: amd64
Date: Tue Mar 6 13:33:39 2012
InstallationMedia: Ubuntu 12.04 LTS "Precise Pangolin" - Alpha amd64 (20120201.1)
ProcEnviron:
 LANGUAGE=en_GB:en
 TERM=xterm
 PATH=(custom, user)
 LANG=en_GB.UTF-8
 SHELL=/bin/bash
SourcePackage: valgrind
UpgradeStatus: Upgraded to precise on 2012-03-05 (1 days ago)

Revision history for this message
Jay Foad (jay-foad) wrote :
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in valgrind (Ubuntu):
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.