I have installed Solaris studio and wanted to use the memory analyzer from there. I am trying it on a sample program, but it returns the above error and does not instrument the executable. Could you please help me tracing where am I going wrong.
# which cc
# /opt/SolarisStudio12.3-solaris-sparc-bin/solarisstudio12.3/bin/cc -V
cc: Sun C 5.12 SunOS_sparc 2011/11/16
# cc -g -O2 test.c
# file a.out
a.out: ELF 32-bit MSB executable SPARC32PLUS Version 1, V8+ Required, dynamically linked, not stripped
# ldd ./a.out
libc.so.1 => /usr/lib/libc.so.1
libm.so.2 => /usr/lib/libm.so.2
# /SolarisStudio12.3-solaris-sparc-bin/solarisstudio12.3/bin/discover -w - ./a.out
discover: error: The file /a.out was linked by an older link step. Please use the latest compiler to do the link.