gdb-2.8.1
[deliverable/binutils-gdb.git] / gdb / firstfile.c
1 /* Find the initialization functions of following files.
2 This goes with initialize.h and lastfile.c.
3
4 Copyright (C) 1986 Free Software Foundation, Inc.
5
6 NO WARRANTY
7
8 BECAUSE THIS PROGRAM IS LICENSED FREE OF CHARGE, WE PROVIDE ABSOLUTELY
9 NO WARRANTY, TO THE EXTENT PERMITTED BY APPLICABLE STATE LAW. EXCEPT
10 WHEN OTHERWISE STATED IN WRITING, FREE SOFTWARE FOUNDATION, INC,
11 RICHARD M. STALLMAN AND/OR OTHER PARTIES PROVIDE THIS PROGRAM "AS IS"
12 WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
13 BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
14 FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY
15 AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE
16 DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR
17 CORRECTION.
18
19 IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW WILL RICHARD M.
20 STALLMAN, THE FREE SOFTWARE FOUNDATION, INC., AND/OR ANY OTHER PARTY
21 WHO MAY MODIFY AND REDISTRIBUTE THIS PROGRAM AS PERMITTED BELOW, BE
22 LIABLE TO YOU FOR DAMAGES, INCLUDING ANY LOST PROFITS, LOST MONIES, OR
23 OTHER SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
24 USE OR INABILITY TO USE (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR
25 DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY THIRD PARTIES OR
26 A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS) THIS
27 PROGRAM, EVEN IF YOU HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH
28 DAMAGES, OR FOR ANY CLAIM BY ANY OTHER PARTY.
29
30 GENERAL PUBLIC LICENSE TO COPY
31
32 1. You may copy and distribute verbatim copies of this source file
33 as you receive it, in any medium, provided that you conspicuously and
34 appropriately publish on each copy a valid copyright notice "Copyright
35 (C) 1986 Free Software Foundation, Inc."; and include following the
36 copyright notice a verbatim copy of the above disclaimer of warranty
37 and of this License. You may charge a distribution fee for the
38 physical act of transferring a copy.
39
40 2. You may modify your copy or copies of this source file or
41 any portion of it, and copy and distribute such modifications under
42 the terms of Paragraph 1 above, provided that you also do the following:
43
44 a) cause the modified files to carry prominent notices stating
45 that you changed the files and the date of any change; and
46
47 b) cause the whole of any work that you distribute or publish,
48 that in whole or in part contains or is a derivative of this
49 program or any part thereof, to be licensed at no charge to all
50 third parties on terms identical to those contained in this
51 License Agreement (except that you may choose to grant more extensive
52 warranty protection to some or all third parties, at your option).
53
54 c) You may charge a distribution fee for the physical act of
55 transferring a copy, and you may at your option offer warranty
56 protection in exchange for a fee.
57
58 Mere aggregation of another unrelated program with this program (or its
59 derivative) on a volume of a storage or distribution medium does not bring
60 the other program under the scope of these terms.
61
62 3. You may copy and distribute this program (or a portion or derivative
63 of it, under Paragraph 2) in object code or executable form under the terms
64 of Paragraphs 1 and 2 above provided that you also do one of the following:
65
66 a) accompany it with the complete corresponding machine-readable
67 source code, which must be distributed under the terms of
68 Paragraphs 1 and 2 above; or,
69
70 b) accompany it with a written offer, valid for at least three
71 years, to give any third party free (except for a nominal
72 shipping charge) a complete machine-readable copy of the
73 corresponding source code, to be distributed under the terms of
74 Paragraphs 1 and 2 above; or,
75
76 c) accompany it with the information you received as to where the
77 corresponding source code may be obtained. (This alternative is
78 allowed only for noncommercial distribution and only if you
79 received the program in object code or executable form alone.)
80
81 For an executable file, complete source code means all the source code for
82 all modules it contains; but, as a special exception, it need not include
83 source code for modules which are standard libraries that accompany the
84 operating system on which the executable file runs.
85
86 4. You may not copy, sublicense, distribute or transfer this program
87 except as expressly provided under this License Agreement. Any attempt
88 otherwise to copy, sublicense, distribute or transfer this program is void and
89 your rights to use the program under this License agreement shall be
90 automatically terminated. However, parties who have received computer
91 software programs from you with this License Agreement will not have
92 their licenses terminated so long as such parties remain in full compliance.
93
94 5. If you wish to incorporate parts of this program into other free
95 programs whose distribution conditions are different, write to the Free
96 Software Foundation at 675 Mass Ave, Cambridge, MA 02139. We have not yet
97 worked out a simple rule that can be stated here, but we will often permit
98 this. We will be guided by the two goals of preserving the free status of
99 all derivatives of our free software and of promoting the sharing and reuse of
100 software.
101
102
103 In other words, you are welcome to use, share and improve this program.
104 You are forbidden to forbid anyone else to use, share and improve
105 what you give them. Help stamp out software-hoarding! */
106
107
108
109 /* This is a magical hack for finding, automatically,
110 all the files that are linked together
111 and calling an initialization function in each one
112 without requiring the main file to know which other
113 files there are.
114
115 Call initialize_all_files to run the initialization functions
116 of all the files. Each initialization function can enter
117 the commands of its file into a global data base so that the
118 contents of the file can be used.
119
120 The files to be found must follow this file. Each of them
121 must start START_FILE, before any other functions,
122 and end with END_FILE, after any other functions.
123 These macros are defined in initialize.h.
124 In addition, each file must contain a function named
125 `initialize', which will be called with no arguments.
126
127 After the files to be found must come the file `lastfile'
128 which ends the chain of calls. */
129
130 #include "initialize.h"
131
132 static initialize_next_file ();
133 static initialize_dummy_1 ();
134 static initialize_dummy_2 ();
135
136 initialize_all_files ()
137 {
138 initialize_next_file ((char *) initialize_dummy_2
139 - (char *) initialize_dummy_1);
140 }
141
142 /* The next two functions exist just so we can find
143 out how long the first of them is.
144 That tells us how long initialize_next_file is,
145 since that function has the same definition as this one. */
146
147 static
148 initialize_dummy_1 (offset)
149 int offset;
150 {
151 long addr = FILEADDR_ROUND ((int) initialize_next_file + offset);
152 (*(void (*) ()) addr) (offset);
153 }
154
155 static
156 initialize_dummy_2 ()
157 {
158 }
159
160 /* This makes the function initialize_next_file. */
161
162 END_FILE
This page took 0.048538 seconds and 5 git commands to generate.