Changeset 56fa418 in mainline for uspace/lib/libc
- Timestamp:
- 2009-04-05T15:50:53Z (16 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 0175246
- Parents:
- 726ef849
- Location:
- uspace/lib/libc
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/libc/Makefile.toolchain
r726ef849 r56fa418 27 27 # 28 28 29 CFLAGS = -fno-builtin -Wall -Werror-implicit-function-declaration -Wmissing-prototypes -O3 -nostdlib -nostdinc -imacros $(LIBC_PREFIX)/../../../config.h -I$(LIBC_PREFIX)/include -pipe -g 29 CFLAGS = -fno-builtin -Wall -Werror-implicit-function-declaration\ 30 -fexec-charset=UTF-8 -fwide-exec-charset=UTF-32 -finput-charset=UTF-8\ 31 -Wmissing-prototypes -O3 -nostdlib -nostdinc -imacros\ 32 $(LIBC_PREFIX)/../../../config.h -I$(LIBC_PREFIX)/include -pipe -g 30 33 LFLAGS = -M -N $(SOFTINT_PREFIX)/libsoftint.a 31 34 AFLAGS = -
uspace/lib/libc/generic/console.c
r726ef849 r56fa418 58 58 59 59 static ssize_t cons_write(const char *buf, size_t nbyte); 60 static void cons_putchar( int c);60 static void cons_putchar(wchar_t c); 61 61 62 62 static void cbuffer_flush(void); … … 120 120 } 121 121 122 void console_putchar(int c) 123 { 124 cbuffer_putc(c); 122 void console_putchar(wchar_t c) 123 { 124 // cbuffer_putc(c); 125 cbuffer_flush(); 126 cons_putchar(c); 125 127 } 126 128 … … 163 165 164 166 /** Write one character to the console via IPC. */ 165 static void cons_putchar( int c)167 static void cons_putchar(wchar_t c) 166 168 { 167 169 int cons_phone = console_phone_get(true); -
uspace/lib/libc/generic/io/io.c
r726ef849 r56fa418 37 37 #include <stdio.h> 38 38 #include <io/io.h> 39 #include <string.h> 40 #include <errno.h> 39 41 40 42 const static char nl = '\n'; … … 88 90 int putchar(int c) 89 91 { 90 unsigned char ch = c; 91 if (write_stdout((void *) &ch, 1) == 1) 92 char buf[STR_BOUNDS(1)]; 93 size_t offs; 94 95 offs = 0; 96 if (chr_encode(c, buf, &offs, STR_BOUNDS(1)) != EOK) 97 return EOF; 98 99 if (write_stdout((void *) buf, offs) == offs) 92 100 return c; 93 101 94 102 return EOF; 95 103 } -
uspace/lib/libc/include/console.h
r726ef849 r56fa418 38 38 #include <console/style.h> 39 39 #include <console/color.h> 40 #include <sys/types.h> 40 41 #include <bool.h> 41 42 … … 48 49 extern void console_clear(void); 49 50 extern void console_goto(int, int); 50 extern void console_putchar( int);51 extern void console_putchar(wchar_t); 51 52 extern ssize_t console_write(const char *buf, size_t nbyte); 52 53 extern void console_putstr(const char *s);
Note:
See TracChangeset
for help on using the changeset viewer.