./mk-0th.awk
./mk-1st.awk
./mk-2nd.awk
-./mk-dlls.sh
+./mk-dlls.sh.in
./mk-hdr.awk
./ncurses/Makefile.in
./ncurses/README
-# $Id: Makefile.in,v 1.26 2010/03/27 23:21:03 tom Exp $
+# $Id: Makefile.in,v 1.28 2010/09/25 22:35:37 tom Exp $
##############################################################################
# Copyright (c) 1998-2008,2010 Free Software Foundation, Inc. #
# #
NCURSES_MINOR = @NCURSES_MINOR@
NCURSES_PATCH = @NCURSES_PATCH@
+top_srcdir = @top_srcdir@
+srcdir = @srcdir@
+
prefix = @prefix@
exec_prefix = @exec_prefix@
echo '** Will overwrite non-ncurses curses.h'
dlls: libs
- sh mk-dlls.sh
+ $(SHELL) $(srcdir)/mk-dlls.sh
+
+distclean \
+realclean ::
+ -rm -f mk-dlls.sh
# Put the common rules here so that we can easily construct the list of
# directories to visit.
-- sale, use or other dealings in this Software without prior written --
-- authorization. --
-------------------------------------------------------------------------------
--- $Id: NEWS,v 1.1593 2010/09/18 22:53:08 tom Exp $
+-- $Id: NEWS,v 1.1595 2010/09/25 22:25:20 tom Exp $
-------------------------------------------------------------------------------
This is a log of changes that ncurses has gone through since Zeyd started
Changes through 1.9.9e did not credit all contributions;
it is not possible to add this information.
+20100925
+ + add "XT" capability to entries for terminals that support both
+ xterm-style mouse- and title-controls, for "screen" which
+ special-cases TERM beginning with "xterm" or "rxvt" -TD
+ > patch by Juergen Pfeifer:
+ + use 64-Bit MinGW toolchain (recommended package from TDM, see
+ README.MinGW).
+ + support pthreads when using the TDM MinGW toolchain
+
20100918
+ regenerated html manpages.
+ minor fixes for symlinks to curs_legacy.3x and curs_slk.3x manpages.
-- sale, use or other dealings in this Software without prior written --
-- authorization. --
-------------------------------------------------------------------------------
--- $Id: README.MinGW,v 1.1 2008/12/14 19:22:16 juergen Exp $
+-- $Id: README.MinGW,v 1.2 2010/09/25 22:16:12 juergen Exp $
-- Author: Juergen Pfeifer
-------------------------------------------------------------------------------
This is work in progress, but it's in an state where one can see it
works at least on the Windows Console.
-To build ncurses for native Windows, you need the MinGW toolchain from
-http://www.mingw.org
+You should install the MSYS package, so that you've a shell environment
+that allows you to run the scripts, especially configure etc. You can get
+that from http://www.mingw.org
-You should install also the MSYS package, so that you've a shell environment
-that allows you to run the scripts, especially configure etc.
+To build ncurses for native Windows, you need the MinGW toolchain. The
+original MinGW toolchain from above site is only for 32-Bit Windows. As
+Windows Server - and even more and more regular workstations - are moving
+to 64-Bit, it seems to be reasonable to have a toolchain that supports
+both architectures. I recommend to use the TDM gcc toolchain which you
+can find at http://tdm-gcc.tdragon.net/download. Go to the download section
+and select the bundle installer for tdm64 (MinGW-w64). This installs a
+multilib version of the gcc toolchain that can compile for native 32- and
+64-Bit Windows versions. It also comes with a working pthread implementation.
+
+The latest config and build scripts we use for MinGW have only be tested
+for the gcc-4.4 compiler toolchain (or better).
Using MinGW is a pragmatic decision, it's the easiest way to port this
heavily UNIX based sourcebase to native Windows. The goal is of course
tools. The LIB.EXE tool is the only one needed. You need this only if
you want to build DLLs that work with native Windows programs. If you
don't have any Microsoft Development tools on your machine, consider
-at least to get the free "Visual C++ 2008 Express Edition".
+at least to get the free "Visual C++ 2010 Express Edition".
It contains the LIB.EXE tool. You may also use this compiler to test
writing native Windows programs using the ncurses DLLs without using
MinGW then for writing apps.
Please unset the TERM environment variable, so that the Console driver
gets activated.
+Please also make sure that MSYS links to the correct directory containing
+your MinGW toolchain. For TDM this is usually C:\MinGW64. In your Windows
+CMD.EXE command shell go to the MSYS root directory (most probably
+C:\MSYS or C:\MSYS\1.0) and verify, that there is a junction point mingw
+that points to the MinGW toolchain directory. If not, delete the mingw
+directory and use the mklink command (or the linkd.exe utility on older
+Windows) to create the junction point.
+
This code requires WindowsNT 5.1 or better, which means on the client
Windows XP or better, on the server Windows Server 2003 or better.
-In order to build the DLLs, you must call
+In order to build ncurses for the planned interop layer with .NET, we
+recommend to use these options with configure
+
+ --disable-home-terminfo
+ --enable-reentrant
+ --enable-sp-funcs
+ --enable-term-driver
+ --enable-interop
+ --with-pthread (if using TDM toolchain as recommended)
+
+This is the configuration commandline as I'm using it at the moment:
+
+./configure --prefix=/mingw --without-cxx-binding --without-ada --enable-warnings --enable-assertions --enable-reentrant --with-debug --with-normal --disable-home-terminfo --enable-sp-funcs --enable-term-driver --enable-interop --with-pthread
+
+
+All the options above are - like the whole Windows support -
+experimental.
+
+In order to build the DLLs, after your regular make you must call
make dlls
+
A lot is still TODO, e.g.:
- Mouse support for the Console
- Wide Character support
The Win32Con driver should actually only use Unicode in the
future.
- - Thread support (locking)
+ - Thread support (locking). If using TDM toolchain this is done by
+ configuring pthreads.
- A GUI console driver
- Support for Terminals attached via a serial port (via terminfo)
- Support for networked Terminal connections (via terminfo)
#! /bin/sh
-# From configure.in Revision: 1.507 .
+# From configure.in Revision: 1.509 .
# Guess values for system-dependent variables and create Makefiles.
# Generated by Autoconf 2.52.20100814.
#
MAKE_TESTS="#"
fi
-ac_config_files="$ac_config_files include/MKterm.h.awk include/curses.head:include/curses.h.in include/ncurses_dll.h include/termcap.h include/unctrl.h $SUB_MAKEFILES Makefile"
+SUB_SCRIPTS=
+case $cf_cv_system_name in #(vi
+*mingw32*) #(vi
+ SUB_SCRIPTS="mk-dlls.sh"
+ ;;
+esac
+
+ac_config_files="$ac_config_files include/MKterm.h.awk include/curses.head:include/curses.h.in include/ncurses_dll.h include/termcap.h include/unctrl.h $SUB_SCRIPTS $SUB_MAKEFILES Makefile"
ac_config_commands="$ac_config_commands default"
cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
: ${CONFIG_STATUS=./config.status}
ac_clean_files_save=$ac_clean_files
ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ echo "$as_me:19103: creating $CONFIG_STATUS" >&5
+{ echo "$as_me:19110: creating $CONFIG_STATUS" >&5
echo "$as_me: creating $CONFIG_STATUS" >&6;}
cat >$CONFIG_STATUS <<_ACEOF
#! $SHELL
echo "$ac_cs_version"; exit 0 ;;
--he | --h)
# Conflict between --help and --header
- { { echo "$as_me:19279: error: ambiguous option: $1
+ { { echo "$as_me:19286: error: ambiguous option: $1
Try \`$0 --help' for more information." >&5
echo "$as_me: error: ambiguous option: $1
Try \`$0 --help' for more information." >&2;}
ac_need_defaults=false;;
# This is an error.
- -*) { { echo "$as_me:19298: error: unrecognized option: $1
+ -*) { { echo "$as_me:19305: error: unrecognized option: $1
Try \`$0 --help' for more information." >&5
echo "$as_me: error: unrecognized option: $1
Try \`$0 --help' for more information." >&2;}
"include/ncurses_dll.h" ) CONFIG_FILES="$CONFIG_FILES include/ncurses_dll.h" ;;
"include/termcap.h" ) CONFIG_FILES="$CONFIG_FILES include/termcap.h" ;;
"include/unctrl.h" ) CONFIG_FILES="$CONFIG_FILES include/unctrl.h" ;;
+ "$SUB_SCRIPTS" ) CONFIG_FILES="$CONFIG_FILES $SUB_SCRIPTS" ;;
"$SUB_MAKEFILES" ) CONFIG_FILES="$CONFIG_FILES $SUB_MAKEFILES" ;;
"Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
"default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
"include/ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ncurses_cfg.h:include/ncurses_cfg.hin" ;;
- *) { { echo "$as_me:19403: error: invalid argument: $ac_config_target" >&5
+ *) { { echo "$as_me:19411: error: invalid argument: $ac_config_target" >&5
echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
{ (exit 1); exit 1; }; };;
esac
esac
if test x"$ac_file" != x-; then
- { echo "$as_me:19809: creating $ac_file" >&5
+ { echo "$as_me:19817: creating $ac_file" >&5
echo "$as_me: creating $ac_file" >&6;}
rm -f "$ac_file"
fi
-) echo $tmp/stdin ;;
[\\/$]*)
# Absolute (can't be DOS-style, as IFS=:)
- test -f "$f" || { { echo "$as_me:19827: error: cannot find input file: $f" >&5
+ test -f "$f" || { { echo "$as_me:19835: error: cannot find input file: $f" >&5
echo "$as_me: error: cannot find input file: $f" >&2;}
{ (exit 1); exit 1; }; }
echo $f;;
echo $srcdir/$f
else
# /dev/null tree
- { { echo "$as_me:19840: error: cannot find input file: $f" >&5
+ { { echo "$as_me:19848: error: cannot find input file: $f" >&5
echo "$as_me: error: cannot find input file: $f" >&2;}
{ (exit 1); exit 1; }; }
fi;;
* ) ac_file_in=$ac_file.in ;;
esac
- test x"$ac_file" != x- && { echo "$as_me:19906: creating $ac_file" >&5
+ test x"$ac_file" != x- && { echo "$as_me:19914: creating $ac_file" >&5
echo "$as_me: creating $ac_file" >&6;}
# First look for the input files in the build tree, otherwise in the
-) echo $tmp/stdin ;;
[\\/$]*)
# Absolute (can't be DOS-style, as IFS=:)
- test -f "$f" || { { echo "$as_me:19917: error: cannot find input file: $f" >&5
+ test -f "$f" || { { echo "$as_me:19925: error: cannot find input file: $f" >&5
echo "$as_me: error: cannot find input file: $f" >&2;}
{ (exit 1); exit 1; }; }
echo $f;;
echo $srcdir/$f
else
# /dev/null tree
- { { echo "$as_me:19930: error: cannot find input file: $f" >&5
+ { { echo "$as_me:19938: error: cannot find input file: $f" >&5
echo "$as_me: error: cannot find input file: $f" >&2;}
{ (exit 1); exit 1; }; }
fi;;
rm -f $tmp/in
if test x"$ac_file" != x-; then
if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
- { echo "$as_me:19988: $ac_file is unchanged" >&5
+ { echo "$as_me:19996: $ac_file is unchanged" >&5
echo "$as_me: $ac_file is unchanged" >&6;}
else
ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
dnl
dnl Author: Thomas E. Dickey 1995-on
dnl
-dnl $Id: configure.in,v 1.507 2010/09/11 16:50:32 tom Exp $
+dnl $Id: configure.in,v 1.509 2010/09/25 22:32:53 tom Exp $
dnl Process this file with autoconf to produce a configure script.
dnl
dnl See http://invisible-island.net/autoconf/ for additional information.
dnl
dnl ---------------------------------------------------------------------------
AC_PREREQ(2.13.20020210)
-AC_REVISION($Revision: 1.507 $)
+AC_REVISION($Revision: 1.509 $)
AC_INIT(ncurses/base/lib_initscr.c)
AC_CONFIG_HEADER(include/ncurses_cfg.h:include/ncurses_cfg.hin)
fi
AC_SUBST(MAKE_TESTS)
+SUB_SCRIPTS=
+case $cf_cv_system_name in #(vi
+*mingw32*) #(vi
+ SUB_SCRIPTS="mk-dlls.sh"
+ ;;
+esac
+
AC_OUTPUT( \
include/MKterm.h.awk \
include/curses.head:include/curses.h.in \
include/ncurses_dll.h \
include/termcap.h \
include/unctrl.h \
+ $SUB_SCRIPTS \
$SUB_MAKEFILES \
Makefile,[
if test "x$cf_with_tests" != xno ; then
# use or other dealings in this Software without prior written #
# authorization. #
##############################################################################
-# $Id: dist.mk,v 1.774 2010/09/18 14:51:01 tom Exp $
+# $Id: dist.mk,v 1.775 2010/09/25 16:51:06 tom Exp $
# Makefile for creating ncurses distributions.
#
# This only needs to be used directly as a makefile by developers, but
# These define the major/minor/patch versions of ncurses.
NCURSES_MAJOR = 5
NCURSES_MINOR = 7
-NCURSES_PATCH = 20100918
+NCURSES_PATCH = 20100925
# We don't append the patch to the version, since this only applies to releases
VERSION = $(NCURSES_MAJOR).$(NCURSES_MINOR)
-# $Id: Makefile.in,v 1.38 2010/04/03 15:27:33 tom Exp $
+# $Id: Makefile.in,v 1.39 2010/09/25 22:16:12 juergen Exp $
##############################################################################
# Copyright (c) 1998,2009,2010 Free Software Foundation, Inc. #
# #
hashsize.h \
ncurses_def.h \
parametrized.h \
+ config.h \
term.h
################################################################################
parametrized.h: $(TERMINFO_CAPS) $(srcdir)/MKparametrized.sh
AWK=$(AWK) sh $(srcdir)/MKparametrized.sh $(TERMINFO_CAPS) >$@
+# This is required by pthread.h on MinGW
+config.h:
+ touch $@
+
tags:
$(CTAGS) *.[ch]
-rm -f $(AUTO_SRC)
distclean :: clean
- -rm -f Makefile $(CONFIG_SRC)
+ -rm -f Makefile $(CONFIG_SRC) config.h
realclean :: distclean
* *
****************************************************************************/
-/* $Id: nc_mingw.h,v 1.2 2010/08/07 18:42:26 tom Exp $ */
+/* $Id: nc_mingw.h,v 1.3 2010/09/25 22:16:12 juergen Exp $ */
#ifndef NC_MINGW_H
#define NC_MINGW_H 1
-#define WINVER 0x0501
+#ifdef WINVER
+# if WINVER < 0x0501
+# error WINVER must at least be 0x0501
+# endif
+#else
+# define WINVER 0x0501
+#endif
#include <windows.h>
#undef sleep
# Report bugs and new terminal descriptions to
# bug-ncurses@gnu.org
#
-# $Revision: 1.368 $
-# $Date: 2010/09/12 00:55:01 $
+# $Revision: 1.369 $
+# $Date: 2010/09/25 18:02:29 $
#
# The original header is preserved below for reference. It is noted that there
# is a "newer" version which differs in some cosmetic details (but actually
# the default behavior -TD
putty|PuTTY terminal emulator,
- am, bce, bw, ccc, hs, mir, msgr, xenl, xon,
+ am, bce, bw, ccc, hs, mir, msgr, xenl, xon, XT,
colors#8, it#8, ncv#22, pairs#64,
acsc=``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~,
bel=^G, blink=\E[5m, bold=\E[1m, cbt=\E[Z, civis=\E[?25l,
# -- MATSUMOTO Shoji)
# kterm implements acsc via built-in table of X Drawable's
kterm|kterm kanji terminal emulator (X window system),
- eslok, hs,
+ eslok, hs, XT,
ncv@,
acsc=``aajjkkllmmnnooppqqrrssttuuvvwwxx~~,
csr=\E[%i%p1%d;%p2%dr, dsl=\E[?H, enacs=, fsl=\E[?F,
# The README's with the distribution also say that it supports SGR 21, 24, 25
# and 27, but they are not present in the terminfo or termcap.
color_xterm|cx|cx100|color_xterm color terminal emulator for X,
- OTbs, am, km, mir, msgr, xenl,
+ OTbs, am, km, mir, msgr, xenl, XT,
cols#80, it#8, lines#65, ncv@,
acsc=``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~,
bel=^G, bold=\E[1m, clear=\E[H\E[2J, cr=^M,
# different from xterm (and vt100's). They have the same behavior in this
# detail, but it is unclear which copies the other.
konsole-base|KDE console window,
- bce, km@, npc,
+ bce, km@, npc, XT,
bel@, blink=\E[5m, civis=\E[?25l, cnorm=\E[?25h,
ech=\E[%p1%dX, flash=\E[?5h$<100/>\E[?5l,
hpa=\E[%i%p1%dG, indn=\E[%p1%dS, kbs=\177, kdch1@,
# control/shift/alt kf1 to kf12 \E[11;8~ to \E[24;8~
#
mlterm|multi lingual terminal emulator,
- am, eslok, km, mc5i, mir, msgr, npc, xenl,
+ am, eslok, km, mc5i, mir, msgr, npc, xenl, XT,
colors#8, cols#80, it#8, lines#24, pairs#64,
acsc=00``aaffgghhjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~,
bel=^G, bold=\E[1m, cbt=\E[Z, civis=\E[?25l,
# removed dch/dch1 because they are inconsistent with bce/ech -TD
# remove km as per tack test -TD
rxvt-basic|rxvt terminal base (X Window System),
- OTbs, am, bce, eo, mir, msgr, xenl, xon,
+ OTbs, am, bce, eo, mir, msgr, xenl, xon, XT,
cols#80, it#8, lines#24,
acsc=``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~,
bel=^G, blink=\E[5m, bold=\E[1m, civis=\E[?25l,
# mrxvt is based on rxvt 2.7.11, but has by default XTERM_FKEYS defined, which
# makes its function-keys different from other flavors of rxvt -TD
mrxvt|multitabbed rxvt,
+ XT,
kEND=\E[8;2~, kHOM=\E[7;2~, kcub1=\E[D, kcud1=\E[B,
kcuf1=\E[C, kcuu1=\E[A, kend=\E[8~, khome=\E[7~,
kEND3=\E[8;3~, kEND4=\E[8;4~, kEND5=\E[8;5~,
# remove nonworking flash -TD
# remove km as per tack test -TD
Eterm|Eterm-color|Eterm with xterm-style color support (X Window System),
- am, bce, bw, eo, mc5i, mir, msgr, xenl, xon,
+ am, bce, bw, eo, mc5i, mir, msgr, xenl, xon, XT,
btns#5, cols#80, it#8, lines#24, lm#0, ncv@,
acsc=``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~,
bel=^G, blink=\E[5m, bold=\E[1m, civis=\E[?25l,
# Based on rxvt 2.4.8, it has a few differences in key bindings
aterm|AfterStep terminal,
+ XT,
kbs=\177, kf1=\EOP, kf2=\EOQ, kf3=\EOR, kf4=\EOS, use=rxvt,
# xiterm 0.5-5.2
use=screen+fkeys, use=screen,
# Other terminals
screen.rxvt|screen in rxvt,
- bw,
+ bw, XT,
cvvis@, flash@, kcub1=\EOD, kcud1=\EOB, kcuf1=\EOC,
kcuu1=\EOA, use=screen+fkeys, use=vt100+enq,
use=rxvt+pcfkeys, use=vt220+keypad, use=screen,
# 2010-09-11
# * reformat acsc strings to canonical format -TD
#
+# 2010-09-25
+# * add "XT" capability to entries for terminals that support both
+# xterm-style mouse- and title-controls, for "screen" which
+# special-cases TERM beginning with "xterm" or "rxvt" -TD
+#
# The following sets edit modes for GNU EMACS.
# Local Variables:
# fill-prefix:"\t"
#!/bin/sh
-# $Id: mk-dlls.sh,v 1.2 2010/01/30 19:23:49 tom Exp $
+# $Id: mk-dlls.sh.in,v 1.1 2010/09/25 22:29:49 juergen Exp $
##############################################################################
# Copyright (c) 2008,2010 Free Software Foundation, Inc. #
# #
#
# Build DLLs on MinGW
#
-gcc -v 2>&1 | grep specs | grep mingw
+LANG=en_US @CC@ -v 2>&1 | grep Target | grep mingw
if [ $? -eq 1 ]; then
echo "$0 requires a mingw environment" >&2
else
if [ -f libncurses${t}${m}.a ]; then
f=libncurses${t}${m}.a
g=`basename $f .a | cut -c 4-`
- gi=libw${g}.a
+ gi=libw${g}.dll.a
td=tmp-${g}
rm -rf "${td}"
mkdir "${td}"
cd "${td}"
ar x ../${f} `ar t ../${f}`
- gcc $cf -o w${g}.dll -Wl,--out-implib,${gi} -Wl,--output-def,w${g}.def -Wl,$lf `ar t ../$f`
+ @CC@ $cf -o w${g}.dll -Wl,--out-implib,${gi} -Wl,--output-def,w${g}.def -Wl,$lf `ar t ../$f` @LIBS@
lib //NOLOGO /MACHINE:i386 /DEF:w${g}.def
rm -f `ar t ../$f`
mv w${g}.dll ..
mv w${g}.lib ..
- mv libw${g}.a ..
+ mv ${gi} ..
cd ..
rm -rf "${td}"
do
g=`basename $f .a | cut -c 4-`
td=tmp-${g}
+ gi2=libw${g}.dll.a
rm -rf "${td}"
mkdir "${td}"
echo $g
cd "${td}"
ar x ../$f `ar t ../$f`
- gcc $cf -o w${g}.dll -Wl,--out-implib,libw${g}.a -Wl,--output-def,w${g}.def -Wl,$lf `ar t ../$f` ../${gi}
+ @CC@ $cf -o w${g}.dll -Wl,--out-implib,${gi2} -Wl,--output-def,w${g}.def -Wl,$lf `ar t ../$f` ../${gi} @LIBS@
lib //NOLOGO /MACHINE:i386 /DEF:w${g}.def
rm -f `ar t ../$f`
mv w${g}.dll ..
mv w${g}.lib ..
- mv libw${g}.a ..
+ mv ${gi2} ..
cd ..
rm -rf "${td}"
done
#include <ctype.h>
-MODULE_ID("$Id: lib_trace.c,v 1.74 2010/01/16 16:31:38 tom Exp $")
+MODULE_ID("$Id: lib_trace.c,v 1.75 2010/09/25 22:16:12 juergen Exp $")
NCURSES_EXPORT_VAR(unsigned) _nc_tracing = 0; /* always define this */
# if USE_WEAK_SYMBOLS
if ((pthread_self))
# endif
+#ifdef __MINGW32__
+ fprintf(TraceFP, "%#lx:", (long) (void *) pthread_self().p);
+#else
fprintf(TraceFP, "%#lx:", (long) (void *) pthread_self());
+#endif
#endif
if (before || after) {
int n;
* authorization. *
****************************************************************************/
/*
- * $Id: rain.c,v 1.36 2010/05/01 19:12:26 tom Exp $
+ * $Id: rain.c,v 1.37 2010/09/25 22:16:12 juergen Exp $
*/
#include <test.priv.h>
* Find myself in the list of threads so we can count the number of loops.
*/
for (mystats = 0; mystats < MAX_THREADS; ++mystats) {
+#ifdef __MINGW32__
+ if (drop_threads[mystats].myself.p == pthread_self().p)
+#else
if (drop_threads[mystats].myself == pthread_self())
+#endif
break;
}