[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
lynx-dev CYGWIN patch for dev.14
From: |
Doug Kaufman |
Subject: |
lynx-dev CYGWIN patch for dev.14 |
Date: |
Mon, 15 Nov 1999 00:24:59 -0800 (PST) |
I had a chance to play with dev.14 and CYGWIN. This was the first
time I tried to compile using the WIN_EX define. The following patch
allowed me to compile, but I also needed to make changes in makefile
and lynx_cfg.h by hand. These can probably be done in the configure
script, but I didn't see how to do it.
Change to lynx_cfg.h: ANSI_VARARGS should be defined to 1, but came
out undefined after configure. (Not tested with leaks testing on, so
this only goes to the number of arguments in va_start.)
Change to makefile: Needs "-luser32" in LIBS.
In this patch, I put the WIN_EX and _WINDOWS_NSL in lynx_cfg.h. If
this seems inappropriate, they could easily go in www_tcp.h
I compiled with SLang, and didn't test with other libraries. CYGWIN
doesn't have a clear() function, and I don't believe that SLang
has one either. I hope that the change for clear() doesn't affect
other compilers adversely. If so it can be ifdef'd to USE_SLANG &&
__CYGWIN__.
I hope that someone else is compiling with CYGWIN for Win32 to check
this.
Doug
--- lynx2-8-3/src/LYCurses.c Wed Nov 3 18:41:40 1999
+++ lynx2-8-3/src/LYCurses.c.new Sun Nov 14 22:51:08 1999
@@ -876,8 +876,13 @@
#endif /* USE_SLANG */
#if defined(WIN_EX)
+#ifdef USE_SLANG
+ SLsmg_cls();
+ SLsmg_refresh();
+#else
clear();
-#endif
+#endif /* USE_SLANG */
+#endif /* WIN_EX */
LYCursesON = TRUE;
CTRACE((tfp, "start_curses: done.\n"));
@@ -979,7 +984,7 @@
*/
if(LYCursesON == TRUE) {
lynx_enable_mouse (0);
-#ifndef WIN_EX /* @@@ */
+#if !defined(WIN_EX) || defined(__CYGWIN__) /* @@@ */
endwin(); /* stop curses */
#endif
}
--- lynx2-8-3/src/LYMainLoop.c Sun Nov 14 16:40:50 1999
+++ lynx2-8-3/src/LYMainLoop.c.new Sun Nov 14 16:42:44 1999
@@ -6172,7 +6172,9 @@
default:
break;
}
+#ifdef CJK_EX
set_ws_title(p);
+#endif
} else {
if (user_mode == ADVANCED_MODE) {
p = curdoc.title;
@@ -6185,18 +6187,24 @@
if (strchr(temp_buff, '%')) {
HTUnEscape(temp_buff);
}
+#ifdef CJK_EX
str_sjis(sjis_buff, temp_buff);
set_ws_title(string_short(sjis_buff, 10));
+#endif
}
}
} else {
if (strlen(curdoc.address) < 1000) {
if (user_mode == ADVANCED_MODE) {
+#ifdef CJK_EX
str_sjis(temp_buff, curdoc.title);
+#endif
} else {
strcpy(temp_buff, curdoc.address);
}
+#ifdef CJK_EX
set_ws_title(HTUnEscape(temp_buff));
+#endif
}
}
#endif /* WIN_EX */
--- lynx2-8-3/config.hin Wed Nov 3 18:41:40 1999
+++ lynx2-8-3/config.hin.new Sun Nov 14 23:24:22 1999
@@ -245,4 +245,9 @@
extern char * strstr ();
#endif
+#ifdef __CYGWIN__
+#define _WINDOWS_NSL
+#define WIN_EX
+#endif
+
#endif /* LYNX_CFG_H */
__
Doug Kaufman
Internet: address@hidden
- lynx-dev CYGWIN patch for dev.14,
Doug Kaufman <=