mescc: Tinycc support: strchr stub.
[mes.git] / mlibc / libc-mes+tcc.c
1 /* -*-comment-start: "//";comment-end:""-*-
2  * Mes --- Maxwell Equations of Software
3  * Copyright © 2017 Jan Nieuwenhuizen <janneke@gnu.org>
4  *
5  * This file is part of Mes.
6  *
7  * Mes is free software; you can redistribute it and/or modify it
8  * under the terms of the GNU General Public License as published by
9  * the Free Software Foundation; either version 3 of the License, or (at
10  * your option) any later version.
11  *
12  * Mes is distributed in the hope that it will be useful, but
13  * WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with Mes.  If not, see <http://www.gnu.org/licenses/>.
19  */
20
21 #include <libc-mes.c>
22 #include <stdio.h>
23 #include <string.h>
24 #include <time.h>
25
26 void
27 close ()
28 {
29   asm ("mov____0x8(%ebp),%ebx !8");
30
31   asm ("mov____$i32,%eax SYS_close");
32   asm ("int____$0x80");
33 }
34
35 int
36 fprintf (FILE *stream, char const *format, ...)
37 {
38   return 0;
39 }
40
41 struct tm *
42 localtime (time_t const *timep)
43 {
44   return 0;
45 }
46
47 void *
48 memcpy (void *dest, void const *src, size_t n)
49 {
50   return 0;
51 }
52
53 void *
54 memmove (void *dest, void const *src, size_t n)
55 {
56   return 0;
57 }
58
59 void *
60 memset (void *s, int c, size_t n)
61 {
62   return 0;
63 }
64
65 int
66 memcmp (void const *s1, void const *s2, size_t n)
67 {
68   return 0;
69 }
70
71 int
72 snprintf(char *str,  size_t size,  char const *format, ...)
73 {
74   return 0;
75 }
76
77 char *
78 strchr (char const *s, int c)
79 {
80   return 0;
81 }
82
83 unsigned long
84 strtoul (char const *nptr, char **endptr, int base)
85 {
86   return 0;
87 }
88
89 time_t time (time_t *tloc)
90 {
91   return 0;
92 }