Launchpad has imported 5 comments from the remote bug at
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18885.

If you reply to an imported comment from within Launchpad, your comment
will be sent to the remote bug automatically. Read more about
Launchpad's inter-bugtracker facilities at
https://help.launchpad.net/InterBugTracking.

------------------------------------------------------------------------
On 2004-12-08T09:48:25+00:00 Micis wrote:

The GCC manual states that libmudflap will be linked if the -fmudflap option is 
give to the linker:

    The instrumentation relies on a separate runtime library (libmudflap),
    which will be linked into a program if -fmudflap is given at link time.

But that is not true, the program links only if -lmudflap is also given to the 
linker.

Michael Cieslinski

Reply at: https://bugs.launchpad.net/gcc/+bug/92638/comments/0

------------------------------------------------------------------------
On 2004-12-08T15:32:50+00:00 Pinskia wrote:

Confirmed, but I don't know it was removed.

Reply at: https://bugs.launchpad.net/gcc/+bug/92638/comments/1

------------------------------------------------------------------------
On 2004-12-13T10:29:13+00:00 Micis wrote:

Maybe it never worked as stated in the documentation, but then either the 
manual should be changed or libmudflap should be automatically linked.

In my opinion libmudflap should be automatically linked, linker command lines 
are already long enough.

Michael Cieslinski

Reply at: https://bugs.launchpad.net/gcc/+bug/92638/comments/2

------------------------------------------------------------------------
On 2005-08-19T14:48:20+00:00 Ppluzhnikov wrote:

Note that threaded programs need -lmudflapth instead of -lmudflap.

The driver should add correct version of libmudflap automatically, or you'll
get bug reports from users who link the wrong version in.

Alternatively, libmudflap could use weak unresolved pthread_* symbols, so that
a single version of libmudflap works in both threaded and non-threaded
environment.

Reply at: https://bugs.launchpad.net/gcc/+bug/92638/comments/3

------------------------------------------------------------------------
On 2011-02-08T15:58:22+00:00 Ludo-gnu wrote:

I can confirm the problem with 4.5.1 on x86_64-linux-gnu.

Indeed, the `mflib' spec lacks `-lmudflap':

$ gcc -dumpspecs |grep -A2 -E '(mflib|link_command)'
*mflib:
%{fmudflap|fmudflapth: -export-dynamic}

--
*link_command:
%{!fsyntax-only:%{!c:%{!M:%{!MM:%{!E:%{!S:    %(linker)     
%{fuse-linker-plugin:     -plugin %(linker_plugin_file)     
-plugin-opt=%(lto_wrapper)     -plugin-opt=%(lto_gcc)     
%{static|static-libgcc:-plugin-opt=-pass-through=%(lto_libgcc)}         
%{static:-plugin-opt=-pass-through=-lc}         %{O*:-plugin-opt=-O%*}     
%{w:-plugin-opt=-w}     %{f*:-plugin-opt=-f%*}     %{m*:-plugin-opt=-m%*}     
%{v:-plugin-opt=-v}     }     %{flto} %{fwhopr} %l %{pie:-pie} %X %{o*} %{A} 
%{d} %{e*} %{m} %{N} %{n} %{r}    %{s} %{t} %{u*} %{x} %{z} %{Z} 
%{!A:%{!nostdlib:%{!nostartfiles:%S}}}    %{static:} %{L*} %(mfwrap) 
%(link_libgcc) %o    
%{fopenmp|ftree-parallelize-loops=*:%:include(libgomp.spec)%(link_gomp)} 
%(mflib)    %{fprofile-arcs|fprofile-generate*|coverage:-lgcov}    
%{!nostdlib:%{!nodefaultlibs:%(link_ssp) %(link_gcc_c_sequence)}}    
%{!A:%{!nostdlib:%{!nostartfiles:%E}}} %{T*} }}}}}}

Reply at: https://bugs.launchpad.net/gcc/+bug/92638/comments/7


** Changed in: gcc
   Importance: Unknown => Medium

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/92638

Title:
  [PR18885] linker does not link libmudflap automatically with -fmudflap

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to