xref: /netbsd-src/lib/csu/arch/vax/crtbegin.h (revision 350cb9bc6c688a6620070f2910b6495424963dde)
1*350cb9bcSmatt /*-
2*350cb9bcSmatt  * Copyright (c) 2013 The NetBSD Foundation, Inc.
3*350cb9bcSmatt  * All rights reserved.
4*350cb9bcSmatt  *
5*350cb9bcSmatt  * This code is derived from software contributed to The NetBSD Foundation
6*350cb9bcSmatt  * by Matt Thomas of 3am Software Foundry.
7*350cb9bcSmatt  *
8*350cb9bcSmatt  * Redistribution and use in source and binary forms, with or without
9*350cb9bcSmatt  * modification, are permitted provided that the following conditions
10*350cb9bcSmatt  * are met:
11*350cb9bcSmatt  * 1. Redistributions of source code must retain the above copyright
12*350cb9bcSmatt  *    notice, this list of conditions and the following disclaimer.
13*350cb9bcSmatt  * 2. Redistributions in binary form must reproduce the above copyright
14*350cb9bcSmatt  *    notice, this list of conditions and the following disclaimer in the
15*350cb9bcSmatt  *    documentation and/or other materials provided with the distribution.
16*350cb9bcSmatt  *
17*350cb9bcSmatt  * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
18*350cb9bcSmatt  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
19*350cb9bcSmatt  * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
20*350cb9bcSmatt  * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
21*350cb9bcSmatt  * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
22*350cb9bcSmatt  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
23*350cb9bcSmatt  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
24*350cb9bcSmatt  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
25*350cb9bcSmatt  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
26*350cb9bcSmatt  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
27*350cb9bcSmatt  * POSSIBILITY OF SUCH DAMAGE.
28*350cb9bcSmatt  */
29*350cb9bcSmatt 
30*350cb9bcSmatt __asm(	".pushsection	.init, \"ax\", @progbits"	"\n\t"
31*350cb9bcSmatt 	"calls	$0, __do_global_ctors_aux"		"\n\t"
32*350cb9bcSmatt 	".popsection"					"\n\t"
33*350cb9bcSmatt 	".pushsection	.fini, \"ax\", @progbits"	"\n\t"
34*350cb9bcSmatt 	"calls	$0, __do_global_dtors_aux"		"\n\t"
35*350cb9bcSmatt 	".popsection"
36*350cb9bcSmatt 	);
37