summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--Makefile8
-rw-r--r--term_ascii.c9
2 files changed, 13 insertions, 4 deletions
diff --git a/Makefile b/Makefile
index a0d7d14c..efc89875 100644
--- a/Makefile
+++ b/Makefile
@@ -13,9 +13,11 @@
VERSION = 1.11.2
VDATE = 12 May 2011
-# If your system doesn't support multi-byte functions (specifically
-# setlocale(), wcwidth(), putwchar()), then remove -DUSE_WCHAR. You'll
-# still be able to use -Tlocale, but it becomes a synonym for -Tascii.
+# IFF your system supports multi-byte functions (setlocale(), wcwidth(),
+# putwchar()) AND has __STDC_ISO_10646__ (that is, wchar_t is simply a
+# UCS-4 value) should you define USE_WCHAR. If you define it and your
+# system DOESN'T support this, -Tlocale will produce garbage.
+# If you don't define it, -Tlocale is a synonym for -Tacsii.
CFLAGS += -g -DUSE_WCHAR -DHAVE_CONFIG_H -DVERSION="\"$(VERSION)\""
CFLAGS += -W -Wall -Wstrict-prototypes -Wno-unused-parameter -Wwrite-strings
PREFIX = /usr/local
diff --git a/term_ascii.c b/term_ascii.c
index 7619907e..3b4ca241 100644
--- a/term_ascii.c
+++ b/term_ascii.c
@@ -1,4 +1,4 @@
-/* $Id: term_ascii.c,v 1.15 2011/05/17 22:32:45 kristaps Exp $ */
+/* $Id: term_ascii.c,v 1.16 2011/05/19 15:48:58 kristaps Exp $ */
/*
* Copyright (c) 2010 Kristaps Dzonsons <kristaps@bsd.lv>
*
@@ -37,9 +37,16 @@
#include "term.h"
#include "main.h"
+/*
+ * Sadly, this doesn't seem to be defined on systems even when they
+ * support it. For the time being, remove it and let those compiling
+ * the software decide for themselves what to use.
+ */
+#if 0
#if ! defined(__STDC_ISO_10646__)
# undef USE_WCHAR
#endif
+#endif
static struct termp *ascii_init(enum termenc, char *);
static double ascii_hspan(const struct termp *,