Author: oxygene Date: 2009-11-19 23:03:12 +0100 (Thu, 19 Nov 2009) New Revision: 55
Modified: trunk/SerialICE/util/kconfig/confdata.c trunk/SerialICE/util/kconfig/symbol.c Log: Win32 for Kconfig, 1/x
Modified: trunk/SerialICE/util/kconfig/confdata.c =================================================================== --- trunk/SerialICE/util/kconfig/confdata.c 2009-11-19 20:24:33 UTC (rev 54) +++ trunk/SerialICE/util/kconfig/confdata.c 2009-11-19 22:03:12 UTC (rev 55) @@ -15,6 +15,10 @@ #define LKC_DIRECT_LINK #include "lkc.h"
+#ifdef WIN32 +#define mkdir(x,y) mkdir(x) +#endif + static void conf_warning(const char *fmt, ...) __attribute__ ((format (printf, 1, 2)));
Modified: trunk/SerialICE/util/kconfig/symbol.c =================================================================== --- trunk/SerialICE/util/kconfig/symbol.c 2009-11-19 20:24:33 UTC (rev 54) +++ trunk/SerialICE/util/kconfig/symbol.c 2009-11-19 22:03:12 UTC (rev 55) @@ -7,7 +7,9 @@ #include <stdlib.h> #include <string.h> #include <regex.h> +#ifndef WIN32 #include <sys/utsname.h> +#endif
#define LKC_DIRECT_LINK #include "lkc.h" @@ -46,19 +48,27 @@ void sym_init(void) { struct symbol *sym; +#ifndef WIN32 struct utsname uts; +#endif static bool inited = false;
if (inited) return; inited = true;
+#ifndef WIN32 uname(&uts); +#endif
sym = sym_lookup("UNAME_RELEASE", 0); sym->type = S_STRING; sym->flags |= SYMBOL_AUTO; +#ifndef WIN32 sym_add_default(sym, uts.release); +#else + sym_add_default(sym, ""); +#endif }
enum symbol_type sym_get_type(struct symbol *sym)