Changeset 04b687b in mainline


Ignore:
Timestamp:
2008-12-29T11:17:44Z (16 years ago)
Author:
Jiri Svoboda <jirik.svoboda@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
63088cc1
Parents:
8b74af07
Message:

Some ANSI C stream functions (stdio).

Location:
uspace
Files:
3 added
7 edited

Legend:

Unmodified
Added
Removed
  • uspace/app/tester/Makefile

    r8b74af07 r04b687b  
    5858        devmap/devmap1.c \
    5959        console/console1.c \
     60        stdio/stdio1.c \
    6061        vfs/vfs1.c
    6162
  • uspace/app/tester/tester.c

    r8b74af07 r04b687b  
    6060#include "vfs/vfs1.def"
    6161#include "console/console1.def"
     62#include "stdio/stdio1.def"
    6263        {NULL, NULL, NULL}
    6364};
  • uspace/app/tester/tester.h

    r8b74af07 r04b687b  
    7373extern char * test_vfs1(bool quiet);
    7474extern char * test_console1(bool quiet);
     75extern char * test_stdio1(bool quiet);
    7576
    7677extern test_t tests[];
  • uspace/lib/libc/Makefile

    r8b74af07 r04b687b  
    6161        generic/io/io.c \
    6262        generic/io/printf.c \
     63        generic/io/stdio.c \
    6364        generic/io/stream.c \
    6465        generic/io/sprintf.c \
  • uspace/lib/libc/generic/libc.c

    r8b74af07 r04b687b  
    5454extern int main(int argc, char *argv[]);
    5555
     56int _errno;
     57
    5658void _exit(int status)
    5759{
  • uspace/lib/libc/include/errno.h

    r8b74af07 r04b687b  
    3636#define LIBC_ERRNO_H_
    3737
     38/* TODO: support threads/fibrils */
     39extern int _errno;
     40#define errno _errno
     41
    3842#include <kernel/errno.h>
    3943
  • uspace/lib/libc/include/stdio.h

    r8b74af07 r04b687b  
    5353}
    5454
     55typedef struct {
     56        /** Underlying file descriptor. */
     57        int fd;
     58
     59        /** Error indicator. */
     60        int error;
     61
     62        /** End-of-file indicator. */
     63        int eof;
     64} FILE;
     65
    5566extern int getchar(void);
    5667
     
    7182extern int rename(const char *, const char *);
    7283
     84extern FILE *fopen(const char *, const char *);
     85extern int fclose(FILE *);
     86extern size_t fread(void *, size_t, size_t, FILE *);
     87extern size_t fwrite(const void *, size_t, size_t, FILE *);
     88extern int feof(FILE *);
     89extern int ferror(FILE *);
     90extern void clearerr(FILE *);
     91
    7392#endif
    7493
Note: See TracChangeset for help on using the changeset viewer.