[Bug 697229] Re: openmpi link failure with ld --as-needed

Bug Watch Updater 697229 at bugs.launchpad.net
Tue Oct 4 16:14:50 UTC 2011


Launchpad has imported 2 comments from the remote bug at
http://sourceware.org/bugzilla/show_bug.cgi?id=13250.

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 2011-10-04T08:52:46+00:00 Matthias Klose wrote:

fails on the 2.22 branch and trunk, works with ld.gold on both the
branch and the trunk.

$ cat mpitest.f90
program main
include 'mpif.h'
integer ierr
call mpi_init(ierr)
end
$ mpif90 -Wl,--as-needed -g mpitest.f90 
/usr/bin/ld: /tmp/cc9rtjMR.o(.debug_info+0x493): unresolvable R_X86_64_64 relocation against symbol `mpi_fortran_argv_null_'
/usr/bin/ld: /tmp/cc9rtjMR.o(.debug_info+0x4ad): unresolvable R_X86_64_64 relocation against symbol `mpi_fortran_argv_null_'
/usr/bin/ld: /tmp/cc9rtjMR.o(.debug_info+0x523): unresolvable R_X86_64_64 relocation against symbol `mpi_fortran_errcodes_ignore_'
/usr/bin/ld: /tmp/cc9rtjMR.o(.debug_info+0x53d): unresolvable R_X86_64_64 relocation against symbol `mpi_fortran_errcodes_ignore_'

The undefined references to `__libc_csu_(init|fini)' are an artefact in
the self-contained testcase.

Reply at: https://bugs.launchpad.net/binutils/+bug/697229/comments/5

------------------------------------------------------------------------
On 2011-10-04T08:58:59+00:00 Matthias Klose wrote:

self-contained test case at
http://people.debian.org/~doko/tmp/mpi.tar.xz

Reply at: https://bugs.launchpad.net/binutils/+bug/697229/comments/8


** Changed in: binutils
       Status: Unknown => Confirmed

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

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

Title:
  openmpi link failure with ld --as-needed

Status in binutils:
  Confirmed
Status in “binutils” package in Ubuntu:
  Confirmed
Status in “openmpi” package in Ubuntu:
  Confirmed
Status in “openmpi” package in Debian:
  New

Bug description:
  $ cat test.F
        program main
         include 'mpif.h'
         integer ierr
         call mpi_init(ierr)
        end
  $ mpif90 test.F -Wl,--as-needed -Wall -Wno-unused-variable -g   -I/usr/lib/openmpi/include -I/usr/lib/openmpi/lib -L/usr/lib/openmpi/lib -L/usr/lib/gcc/i686-linux-gnu/4.5.2 -ldl -lmpi -lopen-rte -lopen-pal -lnsl -lutil -lgcc_s -lpthread -ldl        /usr/bin/ld: /tmp/cccq3IWF.o(.debug_info+0x48d): unresolvable R_X86_64_64 relocation against symbol `mpi_fortran_argv_null_'
  /usr/bin/ld: /tmp/cccq3IWF.o(.debug_info+0x4a7): unresolvable R_X86_64_64 relocation against symbol `mpi_fortran_argv_null_'
  /usr/bin/ld: /tmp/cccq3IWF.o(.debug_info+0x511): unresolvable R_X86_64_64 relocation against symbol `mpi_fortran_errcodes_ignore_'
  /usr/bin/ld: /tmp/cccq3IWF.o(.debug_info+0x52b): unresolvable R_X86_64_64 relocation against symbol `mpi_fortran_errcodes_ignore_'

  works with --no-as-needed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/binutils/+bug/697229/+subscriptions




More information about the foundations-bugs mailing list