|
|
1.1 ! root 1: /* aoutos.h -- operating system specific defines to be used when ! 2: targeting GCC for some system that uses a.out file format. ! 3: Copyright (C) 1992 Free Software Foundation, Inc. ! 4: ! 5: Written by Ron Guilmette ([email protected]). ! 6: ! 7: This file is part of GNU CC. ! 8: ! 9: GNU CC is free software; you can redistribute it and/or modify ! 10: it under the terms of the GNU General Public License as published by ! 11: the Free Software Foundation; either version 2, or (at your option) ! 12: any later version. ! 13: ! 14: GNU CC is distributed in the hope that it will be useful, ! 15: but WITHOUT ANY WARRANTY; without even the implied warranty of ! 16: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ! 17: GNU General Public License for more details. ! 18: ! 19: You should have received a copy of the GNU General Public License ! 20: along with GNU CC; see the file COPYING. If not, write to ! 21: the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ ! 22: ! 23: /* To use this file, make up a file with a name like: ! 24: ! 25: ?????aout.h ! 26: ! 27: where ????? is replaced by the name of the basic hardware that you ! 28: are targeting for. Then, in the file ?????aout.h, put something ! 29: like: ! 30: ! 31: #include "?????.h" ! 32: #include "aoutos.h" ! 33: ! 34: followed by any really system-specific defines (or overrides of ! 35: defines) which you find that you need. Now, modify the configure ! 36: or configure.in script to properly use the new ?????aout.h file ! 37: when configuring for the system. */ ! 38: ! 39: /* Define a symbol indicating that we are using aoutos.h. */ ! 40: #define USING_AOUTOS_H ! 41: ! 42: /* A C statement (sans semicolon) to output an element in the table of ! 43: global constructors. ! 44: If using GNU LD, tell it that this is part of the static destructor set. ! 45: This code works for any machine provided you use GNU as/ld. ! 46: If not using GNU LD, rely on a "collect" program to look for names defined ! 47: in the particular form we choose as global constructor function names. */ ! 48: ! 49: #define ASM_OUTPUT_CONSTRUCTOR(FILE,NAME) \ ! 50: do { \ ! 51: if (flag_gnu_linker) \ ! 52: { \ ! 53: /* Output an N_SETT (0x16, 22.) for the name. */ \ ! 54: fprintf (FILE, "%s \"___CTOR_LIST__\",22,0,0,", ASM_STABS_OP); \ ! 55: assemble_name (FILE, NAME); \ ! 56: fputc ('\n', FILE); \ ! 57: } \ ! 58: } while (0) ! 59: ! 60: ! 61: /* A C statement (sans semicolon) to output an element in the table of ! 62: global destructors. */ ! 63: ! 64: #define ASM_OUTPUT_DESTRUCTOR(FILE,NAME) \ ! 65: do { \ ! 66: if (flag_gnu_linker) \ ! 67: { \ ! 68: /* Output an N_SETT (0x16, 22.) for the name. */ \ ! 69: fprintf (FILE, "%s \"___DTOR_LIST__\",22,0,0,", ASM_STABS_OP); \ ! 70: assemble_name (FILE, NAME); \ ! 71: fputc ('\n', FILE); \ ! 72: } \ ! 73: } while (0) ! 74: ! 75: /* Likewise for entries we want to record for garbage collection. ! 76: Garbage collection is still under development. */ ! 77: ! 78: #define ASM_OUTPUT_GC_ENTRY(FILE,NAME) \ ! 79: do { \ ! 80: if (flag_gnu_linker) \ ! 81: { \ ! 82: /* Output an N_SETT (0x16, 22.) for the name. */ \ ! 83: fprintf (FILE, "%s \"___PTR_LIST__\",22,0,0,", ASM_STABS_OP); \ ! 84: assemble_name (FILE, NAME); \ ! 85: fputc ('\n', FILE); \ ! 86: } \ ! 87: } while (0)
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.