diff --git a/cpu/6502/6502def.h b/cpu/6502/6502def.h
index 8f63c5ddc..aa90befd8 100644
--- a/cpu/6502/6502def.h
+++ b/cpu/6502/6502def.h
@@ -30,12 +30,14 @@
*
* Author: Oliver Schmidt
*
- * @(#)$Id: 6502def.h,v 1.3 2007/12/15 00:06:27 oliverschmidt Exp $
+ * @(#)$Id: 6502def.h,v 1.4 2007/12/16 17:03:27 oliverschmidt Exp $
*/
#ifndef __6502DEF_H__
#define __6502DEF_H__
+#include
+#include
#include
/* These names are deprecated, use C99 names. */
@@ -44,8 +46,6 @@ typedef uint16_t u16_t;
typedef uint32_t u32_t;
typedef int32_t s32_t;
-typedef unsigned short uip_stats_t;
-
#define CC_CONF_REGISTER_ARGS 1
#define CC_CONF_FASTCALL __fastcall__
@@ -55,7 +55,13 @@ typedef unsigned short uip_stats_t;
#define CLOCK_CONF_SECOND 2
typedef unsigned short clock_time_t;
+typedef unsigned short uip_stats_t;
+
#define UIP_ARCH_ADD32 1
#define UIP_ARCH_CHKSUM 1
+#define ctk_arch_keyavail kbhit
+#define ctk_arch_getkey cgetc
+#define ctk_arch_isprint isprint
+
#endif /* __6502DEF_H__ */
diff --git a/cpu/6502/Makefile.6502 b/cpu/6502/Makefile.6502
index 77ad8d60d..6fab22da1 100644
--- a/cpu/6502/Makefile.6502
+++ b/cpu/6502/Makefile.6502
@@ -30,7 +30,7 @@
#
# Author: Oliver Schmidt
#
-# $Id: Makefile.6502,v 1.21 2007/12/15 11:05:38 oliverschmidt Exp $
+# $Id: Makefile.6502,v 1.22 2007/12/16 17:03:27 oliverschmidt Exp $
#
ifndef CONTIKI
@@ -55,13 +55,14 @@ CONTIKI_TARGET_DIRS = . lib sys
CONTIKI_CPU_DIRS = . lib sys net
CONTIKI_TARGET_MAIN = ${addprefix $(OBJECTDIR)/,contiki-main.o}
-CONTIKI_TARGET_SOURCEFILES = contiki-main.c error.c cfs-posix.c petsciiconv.c
+CONTIKI_TARGET_SOURCEFILES = contiki-main.c error.c
CONTIKI_CPU_SOURCEFILES = log.c config.c clock.c lc-asm.S \
mtarch.c mtarch-asm.S \
uip_arch.c ethernet-drv.c ethernet.c
-CONTIKI_SOURCEFILES += $(CONTIKI_CPU_SOURCEFILES) $(CONTIKI_TARGET_SOURCEFILES)
-
+CONTIKI_SOURCEFILES += $(CTK) ctk-conio.c cfs-posix.c petsciiconv.c \
+ $(CONTIKI_TARGET_SOURCEFILES) $(CONTIKI_CPU_SOURCEFILES)
+
TARGET_STARTFILES = $(TARGET).o --start-group
TARGET_LIBFILES = $(TARGET).lib --end-group