Bug 40267 - Eventually get rid of libgfortranbegin.a
Summary: Eventually get rid of libgfortranbegin.a
Status: NEW
Alias: None
Product: gcc
Classification: Unclassified
Component: libfortran (show other bugs)
Version: 4.5.0
: P3 enhancement
Target Milestone: ---
Assignee: Not yet assigned to anyone
Depends on:
Reported: 2009-05-27 07:28 UTC by Tobias Burnus
Modified: 2009-05-28 21:50 UTC (History)
1 user (show)

See Also:
Known to work:
Known to fail:
Last reconfirmed: 2009-05-28 16:03:12


Note You need to log in before you can comment on or make changes to this bug.
Description Tobias Burnus 2009-05-27 07:28:33 UTC
Follow up to PR 39178. Until that patch for GCC 4.5, gfortran generated for the main PROGRAM only "MAIN__" and no "main"; the latter was then included by linking libgfortran.a

With the patch (PR 39178), libgfortran.a became obsolete and is no longer linked by gfortran. It is still present, however, and thus "gcc ... -llibgfortranbegin" still works - but it has no effect. (At least when the *.o file with "main()" comes first - otherwise one gets a double-"main" linker error.)

Some makefiles explicitly link libgfortranbegin thus they will break when libgfortranbegin.a is removed (cf. link below).

Removal: Remove libgfortran/fmain.c, update libgfortran/Makefile.am and (re)generate libgfortran/Makefile.in

See the following thread about sentiments regarding the removal:

Comment 1 Tobias Burnus 2009-05-28 21:50:44 UTC
Before removal, one may deprecate it as explained at:
(I needed to remove the   , "rd"  to get it assemble. And testing did not show an error for linking "file.o libgfortranbegin.a".)