Add skeleton libc definition
[bootloader-ap.git] / include / string.h
1 /*
2   libc string and memory functions
3   Copyright (c) 2010 TJ <linux@tjworld.net>
4
5     This program is free software: you can redistribute it and/or modify
6     it under the terms of the GNU General Public License as published by
7     the Free Software Foundation, either version 3 of the License, or
8     (at your option) any later version.
9
10     This program is distributed in the hope that it will be useful,
11     but WITHOUT ANY WARRANTY; without even the implied warranty of
12     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13     GNU General Public License for more details.
14
15     You should have received a copy of the GNU General Public License
16     along with this program (See the COPYRIGHT file the base directory).
17     If not, see <http://www.gnu.org/licenses/>.
18 */
19
20 #ifndef __STRING_H
21 #define __STRING_H
22
23 #include <stddef.h> // for size_t
24
25 char    *strcpy(char *s1, const char *s2);
26 size_t   strlen(const char *s1);
27 int      strcmp(const char *s1, const char *s2);
28 char    *strcat(char *s1, const char *s2);
29 int      strncmp(const char *s1, const char *s2, size_t n);
30 char    *strchr(const char *str, int c);
31 int      __strcmp(const char *s1, const char *s2);
32 void    *memset(void *p, int c, size_t n);
33 void    *memcpy(void *p1, const void *p2, size_t n);
34 void    *memmove(void *p1, const void *p2, size_t n);
35 int      memcmp(const void *p1, const void *p2, size_t n);
36
37 /*
38   These functions are unused and not defined
39
40 void    *memccpy(void *, const void *, int, size_t);
41 void    *memchr(const void *, int, size_t);
42 int      strcoll(const char *, const char *);
43 size_t   strcspn(const char *, const char *);
44 char    *strdup(const char *);
45 char    *strerror(int);
46 char    *strncat(char *, const char *, size_t);
47 char    *strncpy(char *, const char *, size_t);
48 char    *strpbrk(const char *, const char *);
49 char    *strrchr(const char *, int);
50 size_t   strspn(const char *, const char *);
51 char    *strstr(const char *, const char *);
52 char    *strtok(char *, const char *);
53 char    *strtok_r(char *, const char *, char **);
54 size_t   strxfrm(char *, const char *, size_t);
55 */
56
57 #endif