1 /* GRT replacements for GNAT rts.
2 Copyright (C) 2002, 2003, 2004, 2005 Tristan Gingold.
3
4 This program is free software: you can redistribute it and/or modify
5 it under the terms of the GNU General Public License as published by
6 the Free Software Foundation, either version 2 of the License, or
7 (at your option) any later version.
8
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 GNU General Public License for more details.
13
14 You should have received a copy of the GNU General Public License
15 along with this program. If not, see <gnu.org/licenses>.
16 */
17 #include <stdlib.h>
18
19 #ifndef WITH_GNAT_RUN_TIME
20 void
__gnat_last_chance_handler(void)21 __gnat_last_chance_handler (void)
22 {
23 abort ();
24 }
25
26 void *
__gnat_malloc(size_t size)27 __gnat_malloc (size_t size)
28 {
29 void *res;
30 res = malloc (size);
31 return res;
32 }
33
34 void
__gnat_free(void * ptr)35 __gnat_free (void *ptr)
36 {
37 free (ptr);
38 }
39
40 void *
__gnat_realloc(void * ptr,size_t size)41 __gnat_realloc (void *ptr, size_t size)
42 {
43 return realloc (ptr, size);
44 }
45
46 /* Unused imported symbols with gcc 8.1. */
47 int __gnat_binder_ss_count = 0;
48 size_t __gnat_default_ss_size = 0;
49 void *__gnat_default_ss_pool = NULL;
50
51 void
system__secondary_stack__ss_stackIP(void * t,size_t size)52 system__secondary_stack__ss_stackIP (void *t, size_t size)
53 {
54 }
55 #endif
56