https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61418

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |NEW
          Component|driver                      |fortran
           Assignee|rguenth at gcc dot gnu.org         |unassigned at gcc dot 
gnu.org

--- Comment #8 from Richard Biener <rguenth at gcc dot gnu.org> ---
(In reply to Richard Biener from comment #7)
> gfortranspec.c does
> 
>         case OPT_L:
>           if (!spec_file)
>             spec_file = find_spec_file (decoded_options[i].arg);
>           break;
> ...
>   /* Read the specs file corresponding to libgfortran.
>      If we didn't find the spec file on the -L path, we load it
>      via lang_specific_pre_link.  */
>   if (spec_file)
>     append_option (OPT_specs_, spec_file, 1);
> 
> seemingly copied from Java I guess.  lang_specific_pre_link doesn't add
> -specs.

Oh, and that of course conflicts with manually adding -specs=libgfortran.spec.\
That is, the symtom is the same as if you do

> gfortran-4.8 t.o -shared -fPIC 
> -specs=/usr/lib64/gcc/x86_64-suse-linux/4.8/libgfortran.spec 
gfortran-4.8: fatal error:
/usr/lib64/gcc/x86_64-suse-linux/4.8/libgfortran.spec: attempt to rename spec
‘lib’ to already defined spec ‘liborig’
compilation terminated.

Really a long-standing gfortran and java driver issue.

Reply via email to