1 /* Copyright (C) 2002-2003 Free Software Foundation, Inc.
2 Contributed by Andy Vaught and Paul Brook <paul@nowt.org>
4 This file is part of the GNU Fortran 95 runtime library (libgfor).
6 Libgfor is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2, or (at your option)
11 Libgfor is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with libgfor; see the file COPYING. If not, write to
18 the Free Software Foundation, 59 Temple Place - Suite 330,
19 Boston, MA 02111-1307, USA. */
27 #include "libgfortran.h"
29 /* This is the offset (in bytes) required to cast from logical(8)* to
30 logical(4)*. and still get the same result. Will be 0 for little-endian
31 machines and 4 for big-endian machines. */
35 /* Figure out endianness for this machine. */
37 #define detetmine_endianness prefix(determine_endianness)
39 determine_endianness (void)
53 runtime_error ("Unable to determine machine endianness");
58 static char **argv_save;
60 /* Set the saved values of the command line arguments. */
63 set_args (int argc, char **argv)
69 /* Retrieve the saved values of the command line arguments. */
72 get_args (int *argc, char ***argv)
80 /* Initialize the runtime library. */
82 static void __attribute__((constructor))
85 /* Figure out the machine endianness. */
86 determine_endianness ();
94 /* Check for special command lines. */
96 if (argc > 1 && strcmp (argv[1], "--help") == 0)
99 /* if (argc > 1 && strcmp(argv[1], "--resume") == 0) resume(); */
103 random_seed(NULL,NULL,NULL);
108 /* Cleanup the runtime library. */
110 static void __attribute__((destructor))