On Wed, Aug 16, 2017 at 01:37:37PM +0000, Davide Palma wrote: > Hello, > I'm trying to strace an application directly in a real embedded MIPS32 > chipset that runs uclinux. > > This is the toolchain I used to compile strace: > david@devuan:~$ mipsel-buildroot-linux-uclibc-gcc -v > Using built-in specs. > COLLECT_GCC=/home/david/Downloads/buildroot-2017.05.2/output/host/usr/bin/mipsel-buildroot-linux-uclibc-gcc.br_real > COLLECT_LTO_WRAPPER=/home/david/Downloads/buildroot-2017.05.2/output/host/usr/libexec/gcc/mipsel-buildroot-linux-uclibc/5.4.0/lto-wrapper > Target: mipsel-buildroot-linux-uclibc > Configured with: ./configure > --prefix=/home/david/Downloads/buildroot-2017.05.2/output/host/usr > --sysconfdir=/home/david/Downloads/buildroot-2017.05.2/output/host/etc > --enable-static --target=mipsel-buildroot-linux-uclibc > --with-sysroot=/home/david/Downloads/buildroot-2017.05.2/output/host/usr/mipsel-buildroot-linux-uclibc/sysroot > --disable-__cxa_atexit --with-gnu-ld --disable-libssp --disable-multilib > --with-gmp=/home/david/Downloads/buildroot-2017.05.2/output/host/usr > --with-mpc=/home/david/Downloads/buildroot-2017.05.2/output/host/usr > --with-mpfr=/home/david/Downloads/buildroot-2017.05.2/output/host/usr > --with-pkgversion='Buildroot 2017.05.2' --with-bugurl= > http://bugs.buildroot.net/ --disable-libquadmath --disable-libsanitizer > --enable-tls --disable-libmudflap --enable-threads --without-isl > --without-cloog --with-float=soft --disable-decimal-float > --with-arch=mips32 --with-abi=32 --enable-languages=c > --with-build-time-tools=/home/david/Downloads/buildroot-2017.05.2/output/host/usr/mipsel-buildroot-linux-uclibc/bin > --enable-shared --disable-libgomp > Thread model: posix > gcc version 5.4.0 (Buildroot 2017.05.2) > > > And this is what happens in the system: > # ./strace -V > strace -- version 4.15 > # ./strace -dv echo foo > ./strace: ptrace_setoptions = 0x51 > ./strace: PTRACE_SEIZE doesn't work > ./strace: new tcb for pid 323, active tcbs:1 > ./strace: [wait(0x00177f) = 323] WIFSTOPPED,sig=SIGSTOP > ./strace: pid 323 has TCB_STARTUP, initializing it > ./strace: setting opts 0x51 on pid 323 > ./strace: ignored SIGSTOP on pid 323 > ./strace: [wait(0x00857f) = 323] WIFSTOPPED,sig=133 > execve(./strace: process_vm_readv: Unknown error -89 > 0x7fad0a68, ./strace: process_vm_readv: Unknown error -89 > 0x7fad1ebc, ./strace: process_vm_readv: Unknown error -89 > 0x7fad1ec8./strace: [wait(0x04057f) = 323] > WIFSTOPPED,sig=SIGTRAP,EVENT_EXEC (4) > ./strace: [wait(0x00857f) = 323] WIFSTOPPED,sig=133 > ) = 0 > ./strace: [wait(0x00857f) = 323] WIFSTOPPED,sig=133 > ./strace: process_vm_readv: Unknown error -89 > mmap( > //strace hangs up here, I press control c > ./strace: cleanup: looking at pid 323 > ./strace: Process 323 detached > ./strace: dropped tcb for pid 323, 0 remain > <detached ...> > # > > What do you suggest me to do?
-89 == -ENOSYS on mips; looks like syscall() function provided by libc does not initialize errno properly. -- ldv
signature.asc
Description: PGP signature
------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________ Strace-devel mailing list Strace-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/strace-devel