092231a8d6
fortran/ 2009-05-26 Tobias Burnus <burnus@net-b.de> PR fortran/39178 * gfortranspec.c (lang_specific_driver): Stop linking libgfortranbegin. * trans-decl.c (gfc_build_builtin_function_decls): Stop making MAIN__ publicly visible. (gfc_build_builtin_function_decls): Add gfor_fndecl_set_args. (create_main_function) New function. (gfc_generate_function_code): Use it. libgfortran/ 2009-05-26 Tobias Burnus <burnus@net-b.de> PR fortran/39178 * runtime/main.c (store_exe_path): Make static and multiple-times callable. (set_args): Call store_exe_path. * libgfortran.h: Remove store_exe_path prototype. * fmain.c (main): Remove store_exe_path call. From-SVN: r147883
22 lines
526 B
C
22 lines
526 B
C
#include "libgfortran.h"
|
|
|
|
/* The main Fortran program actually is a function, called MAIN__.
|
|
We call it from the main() function in this file. */
|
|
void MAIN__ (void);
|
|
|
|
/* Main procedure for fortran programs. All we do is set up the environment
|
|
for the Fortran program. */
|
|
int
|
|
main (int argc, char *argv[])
|
|
{
|
|
/* Set up the runtime environment. */
|
|
PREFIX(set_args) (argc, argv);
|
|
|
|
/* Call the Fortran main program. Internally this is a function
|
|
called MAIN__ */
|
|
MAIN__ ();
|
|
|
|
/* Bye-bye! */
|
|
return 0;
|
|
}
|