TARGET_DIR = $(CURDIR)/debian/adacurses
SAMPLE_DIR = $(TARGET_DIR)/usr/bin/AdaCurses
-CFLAGS =
+CFLAGS = $(shell dpkg-buildflags --get CFLAGS) $(CC_NORMAL)
+CPPFLAGS = $(shell dpkg-buildflags --get CPPFLAGS)
+LDFLAGS = $(shell dpkg-buildflags --get LDFLAGS)
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
CFLAGS += -O0
configure-stamp:
dh_testdir
- CFLAGS="$(CFLAGS)" ./configure \
+ CFLAGS="$(CFLAGS)" \
+ CPPFLAGS="$(CPPFLAGS)" \
+ LDFLAGS="$(LDFLAGS)" ./configure \
--host=$(DEB_HOST_GNU_TYPE) \
--build=$(DEB_BUILD_GNU_TYPE) \
--prefix=/usr \
-- sale, use or other dealings in this Software without prior written --
-- authorization. --
-------------------------------------------------------------------------------
--- $Id: NEWS,v 1.2888 2017/07/15 22:29:41 tom Exp $
+-- $Id: NEWS,v 1.2893 2017/07/22 23:56:31 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.
+20170722
+ + improve test-packages for ncurses-examples and AdaCurses for lintian
+ + modify logic for endwin-state to be able to detect the case where
+ the screen was never initialized, using that to trigger a flush of
+ ncurses' buffer for mvcur, e.g., in test/dots_mvcur.c for the
+ term-driver configuration.
+ + add dependency upon ncurses_cfg.h to a few other internal header
+ files to allow each to be compiled separately.
+ + add dependency upon ncurses_cfg.h to tic's header-files; any program
+ using tic-library will have to supply this file. Legacy tack
+ versions supply this file; ongoing tack development has dropped the
+ dependency upon tic-library and new releases will not be affected.
+
20170715
+ modify command-line parameters for "convert" used in picsmap to work
with ImageMagick 6.8 and newer.
-5:0:9 6.0 20170715
+5:0:9 6.0 20170722
# use or other dealings in this Software without prior written #
# authorization. #
##############################################################################
-# $Id: dist.mk,v 1.1172 2017/07/13 00:15:27 tom Exp $
+# $Id: dist.mk,v 1.1173 2017/07/22 16:49:12 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 = 6
NCURSES_MINOR = 0
-NCURSES_PATCH = 20170715
+NCURSES_PATCH = 20170722
# We don't append the patch to the version, since this only applies to releases
VERSION = $(NCURSES_MAJOR).$(NCURSES_MINOR)
#!/bin/sh
##############################################################################
-# Copyright (c) 1998-2006,2014 Free Software Foundation, Inc. #
+# Copyright (c) 1998-2014,2017 Free Software Foundation, Inc. #
# #
# Permission is hereby granted, free of charge, to any person obtaining a #
# copy of this software and associated documentation files (the "Software"), #
# use or other dealings in this Software without prior written #
# authorization. #
##############################################################################
-# $Id: MKparametrized.sh,v 1.7 2014/05/24 15:07:19 tom Exp $
+# $Id: MKparametrized.sh,v 1.8 2017/07/22 16:32:27 tom Exp $
#
# MKparametrized.sh -- generate indirection vectors for various sort methods
#
#
CAPS="${1-Caps}"
cat <<EOF
+#ifndef PARAMETRIZED_H
+#define PARAMETRIZED_H 1
/*
* parametrized.h --- is a termcap capability parametrized?
*
END {printf("} /* %d entries */;\n\n", count);}
'
+echo "#endif /* PARAMETRIZED_H */"
****************************************************************************/
/*
- * $Id: hashed_db.h,v 1.7 2017/02/26 22:59:23 Andre.Sa Exp $
+ * $Id: hashed_db.h,v 1.8 2017/07/22 16:22:49 tom Exp $
*/
#ifndef HASHED_DB_H
#define HASHED_DB_H 1
+#include <ncurses_cfg.h>
+
#include <curses.h>
#if USE_HASHED_DB
/****************************************************************************
- * Copyright (c) 1998-2012,2013 Free Software Foundation, Inc. *
+ * Copyright (c) 1998-2013,2017 Free Software Foundation, Inc. *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
/****************************************************************************
* Author: Thomas E. Dickey 1996-on *
****************************************************************************/
-/* $Id: nc_alloc.h,v 1.22 2013/01/26 21:56:51 tom Exp $ */
+/* $Id: nc_alloc.h,v 1.23 2017/07/22 16:59:37 tom Exp $ */
#ifndef NC_ALLOC_included
#define NC_ALLOC_included 1
/* *INDENT-OFF* */
+#include <ncurses_cfg.h>
+#include <curses.h>
+
#ifdef __cplusplus
extern "C" {
#endif
/****************************************************************************
- * Copyright (c) 2008-2009,2010 Free Software Foundation, Inc. *
+ * Copyright (c) 2008-2010,2017 Free Software Foundation, Inc. *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
/****************************************************************************
* Author: Thomas Dickey, 2008-on *
- * *
****************************************************************************/
-/* $Id: nc_mingw.h,v 1.3 2010/09/25 22:16:12 juergen Exp $ */
+/* $Id: nc_mingw.h,v 1.4 2017/07/22 17:06:38 tom Exp $ */
#ifndef NC_MINGW_H
#define NC_MINGW_H 1
+#ifdef __MINGW32__
#ifdef WINVER
# if WINVER < 0x0501
# error WINVER must at least be 0x0501
#define wcwidth(ucs) _nc_wcwidth(ucs)
extern int _nc_wcwidth(wchar_t);
+#endif /* __MINGW32__ */
+
#endif /* NC_MINGW_H */
/****************************************************************************
- * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc. *
+ * Copyright (c) 1998-2009,2017 Free Software Foundation, Inc. *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
****************************************************************************/
/*
- * $Id: nc_panel.h,v 1.7 2009/07/04 18:20:02 tom Exp $
+ * $Id: nc_panel.h,v 1.9 2017/07/22 17:06:03 tom Exp $
*
* nc_panel.h
*
#ifndef NC_PANEL_H
#define NC_PANEL_H 1
+#include <ncurses_cfg.h>
+#include <curses.h>
+
#ifdef __cplusplus
extern "C"
{
/****************************************************************************
- * Copyright (c) 2011,2014 Free Software Foundation, Inc. *
+ * Copyright (c) 2011-2014,2017 Free Software Foundation, Inc. *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
* Author: Thomas E. Dickey 2011 *
****************************************************************************/
-/* $Id: nc_termios.h,v 1.3 2014/05/03 19:40:10 juergen Exp $ */
+/* $Id: nc_termios.h,v 1.5 2017/07/23 00:02:08 tom Exp $ */
#ifndef NC_TERMIOS_included
#define NC_TERMIOS_included 1
+#include <ncurses_cfg.h>
+
#if HAVE_TERMIOS_H && HAVE_TCGETATTR
#else /* !HAVE_TERMIOS_H */
/****************************************************************************
- * Copyright (c) 2006-2010,2012 Free Software Foundation, Inc. *
+ * Copyright (c) 2006-2012,2017 Free Software Foundation, Inc. *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
* Author: Thomas E. Dickey 2006 *
****************************************************************************/
-/* $Id: nc_tparm.h,v 1.6 2012/02/18 21:34:42 tom Exp $ */
+/* $Id: nc_tparm.h,v 1.8 2017/07/22 17:09:46 tom Exp $ */
#ifndef NC_TPARM_included
#define NC_TPARM_included 1
+#include <ncurses_cfg.h>
+#include <curses.h>
+
/*
* Cast parameters past the formatting-string for tparm() to match the
* assumption of the varargs code.
/****************************************************************************
- * Copyright (c) 1998-2015,2016 Free Software Foundation, Inc. *
+ * Copyright (c) 1998-2016,2017 Free Software Foundation, Inc. *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
* Author: Thomas E. Dickey 1997-on *
****************************************************************************/
/*
- * $Id: ncurses_cfg.hin,v 1.9 2016/03/05 21:45:24 tom Exp $
+ * $Id: ncurses_cfg.hin,v 1.10 2017/07/22 17:01:10 tom Exp $
+ *
+ * Both ncurses_cfg.h and ncurses_def.h are internal header-files used when
+ * building ncurses.
*
* This is a template-file used to generate the "ncurses_cfg.h" file.
*
/****************************************************************************
- * Copyright (c) 1998-2011,2014 Free Software Foundation, Inc. *
+ * Copyright (c) 1998-2014,2017 Free Software Foundation, Inc. *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
/****************************************************************************
* Author: Juergen Pfeifer, 2008-on *
- * *
****************************************************************************/
-/* $Id: ncurses_mingw.h,v 1.3 2014/05/03 19:40:19 juergen Exp $ */
+/* $Id: ncurses_mingw.h,v 1.4 2017/07/22 17:06:49 tom Exp $ */
/*
* This is a placeholder up to now and describes what needs to be implemented
* to support I/O to external terminals with ncurses on the Windows OS.
*/
-#if __MINGW32__
+#ifdef __MINGW32__
#ifndef _NC_MINGWH
#define _NC_MINGWH
****************************************************************************/
/*
- * $Id: tic.h,v 1.73 2017/03/18 17:14:19 tom Exp $
+ * $Id: tic.h,v 1.74 2017/07/22 16:25:10 tom Exp $
* tic.h - Global variables and structures for the terminfo compiler.
*/
extern "C" {
#endif
+#include <ncurses_cfg.h>
+
#include <curses.h> /* for the _tracef() prototype, ERR/OK, bool defs */
/*
/****************************************************************************
- * Copyright (c) 1998-2009,2014 Free Software Foundation, Inc. *
+ * Copyright (c) 1998-2014,2017 Free Software Foundation, Inc. *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
#include <curses.priv.h>
-MODULE_ID("$Id: lib_endwin.c,v 1.23 2014/03/08 20:32:59 tom Exp $")
+MODULE_ID("$Id: lib_endwin.c,v 1.24 2017/07/22 23:29:40 tom Exp $")
NCURSES_EXPORT(int)
NCURSES_SP_NAME(endwin) (NCURSES_SP_DCL0)
#ifdef USE_TERM_DRIVER
TERMINAL_CONTROL_BLOCK *TCB = TCBOf(SP_PARM);
- SP_PARM->_endwin = TRUE;
+ SP_PARM->_endwin = ewSuspend;
if (TCB && TCB->drv && TCB->drv->td_scexit)
TCB->drv->td_scexit(SP_PARM);
#else
- SP_PARM->_endwin = TRUE;
+ SP_PARM->_endwin = ewSuspend;
SP_PARM->_mouse_wrap(SP_PARM);
_nc_screen_wrap();
_nc_mvcur_wrap(); /* wrap up cursor addressing */
/****************************************************************************
- * Copyright (c) 1998-2000,2009 Free Software Foundation, Inc. *
+ * Copyright (c) 1998-2009,2017 Free Software Foundation, Inc. *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
#include <curses.priv.h>
-MODULE_ID("$Id: lib_isendwin.c,v 1.7 2009/02/15 00:36:24 tom Exp $")
+MODULE_ID("$Id: lib_isendwin.c,v 1.8 2017/07/22 23:29:49 tom Exp $")
NCURSES_EXPORT(bool)
NCURSES_SP_NAME(isendwin) (NCURSES_SP_DCL0)
{
if (SP_PARM == NULL)
return FALSE;
- return SP_PARM->_endwin;
+ return (SP_PARM->_endwin == ewSuspend);
}
#if NCURSES_SP_FUNCS
#include <tic.h>
-MODULE_ID("$Id: lib_newterm.c,v 1.99 2017/07/01 18:14:07 tom Exp $")
+MODULE_ID("$Id: lib_newterm.c,v 1.100 2017/07/22 23:19:00 tom Exp $")
#ifdef USE_TERM_DRIVER
#define NumLabels InfoOf(SP_PARM).numlabels
#else
SP_PARM->_use_meta = FALSE;
#endif
- SP_PARM->_endwin = FALSE;
+ SP_PARM->_endwin = ewInitial;
#ifndef USE_TERM_DRIVER
/*
* Check whether we can optimize scrolling under dumb terminals in
****************************************************************************/
/*
- * $Id: curses.priv.h,v 1.581 2017/07/15 20:17:01 tom Exp $
+ * $Id: curses.priv.h,v 1.583 2017/07/22 23:19:00 tom Exp $
*
* curses.priv.h
*
extern NCURSES_EXPORT_VAR(NCURSES_PRESCREEN) _nc_prescreen;
+typedef enum {
+ ewInitial = 0,
+ ewRunning,
+ ewSuspend
+} ENDWIN;
+
/*
* The SCREEN structure.
*/
sp->_cbreak = 0; \
sp->_echo = TRUE; \
sp->_fifohead = -1; \
- sp->_endwin = TRUE; \
+ sp->_endwin = ewSuspend; \
sp->_cursor = -1; \
SP_INIT_WINDOWLIST(sp); \
sp->_outch = NCURSES_OUTC_FUNC; \
&& (a).chars[3] == (b).chars[3] \
&& (a).chars[4] == (b).chars[4] \
if_EXT_COLORS(&& (a).ext_color == (b).ext_color))
+#elif CCHARW_MAX > 0
+#error Inconsistent values for CCHARW_MAX
#else
#define CharEq(a,b) (!memcmp(&(a), &(b), sizeof(a)))
#endif
#define CUR SP_TERMTYPE
#endif
-MODULE_ID("$Id: lib_mvcur.c,v 1.141 2017/04/07 00:34:22 tom Exp $")
+MODULE_ID("$Id: lib_mvcur.c,v 1.144 2017/07/22 23:59:07 tom Exp $")
#define WANT_CHAR(sp, y, x) NewScreen(sp)->_line[y].text[x] /* desired state */
/*
* A different, possibly better way to arrange this would be to set the
- * SCREEN's _endwin to TRUE at window initialization time and let this be
- * called by doupdate's return-from-shellout code.
+ * SCREEN's _endwin at window initialization time and let this be called by
+ * doupdate's return-from-shellout code.
*/
NCURSES_SP_NAME(_nc_mvcur_resume) (NCURSES_SP_ARG);
}
int yold, int xold,
int ynew, int xnew)
{
- return _nc_real_mvcur(NCURSES_SP_ARGx yold, xold, ynew, xnew,
- NCURSES_SP_NAME(_nc_outch),
- TRUE);
+ int rc;
+ rc = _nc_real_mvcur(NCURSES_SP_ARGx yold, xold, ynew, xnew,
+ NCURSES_SP_NAME(_nc_outch),
+ TRUE);
+ /*
+ * With the terminal-driver, we cannot distinguish between internal and
+ * external calls. Flush the output if the screen has not been
+ * initialized, e.g., when used from low-level terminfo programs.
+ */
+ if ((SP_PARM != 0) && (SP_PARM->_endwin == ewInitial))
+ NCURSES_SP_NAME(_nc_flush) (NCURSES_SP_ARG);
+ return rc;
}
#if NCURSES_SP_FUNCS
NCURSES_EXPORT(int)
TINFO_MVCUR(NCURSES_SP_DCLx int yold, int xold, int ynew, int xnew)
{
- return _nc_real_mvcur(NCURSES_SP_ARGx
- yold, xold,
- ynew, xnew,
- NCURSES_SP_NAME(_nc_outch),
- TRUE);
+ int rc;
+ rc = _nc_real_mvcur(NCURSES_SP_ARGx
+ yold, xold,
+ ynew, xnew,
+ NCURSES_SP_NAME(_nc_outch),
+ TRUE);
+ if ((SP_PARM != 0) && (SP_PARM->_endwin == ewInitial))
+ NCURSES_SP_NAME(_nc_flush) (NCURSES_SP_ARG);
+ NCURSES_SP_NAME(_nc_flush) (NCURSES_SP_ARG);
+ return rc;
}
#else /* !USE_TERM_DRIVER */
int fy, fx, ty, tx, n, i;
char buf[BUFSIZ], capname[BUFSIZ];
- (void) fputs("> ", stdout);
- (void) fgets(buf, sizeof(buf), stdin);
+ if (fputs("> ", stdout) == EOF)
+ break;
+ if (fgets(buf, sizeof(buf), stdin) == 0)
+ break;
if (buf[0] == '?') {
(void) puts("? -- display this help message");
/****************************************************************************
- * Copyright (c) 1998-2013,2014 Free Software Foundation, Inc. *
+ * Copyright (c) 1998-2014,2017 Free Software Foundation, Inc. *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
#include <SigAction.h>
-MODULE_ID("$Id: lib_tstp.c,v 1.48 2014/04/26 18:47:35 juergen Exp $")
+MODULE_ID("$Id: lib_tstp.c,v 1.49 2017/07/22 23:29:58 tom Exp $")
#if defined(SIGTSTP) && (HAVE_SIGACTION || HAVE_SIGVEC)
#define USE_SIGTSTP 1
* taken ownership of the tty and modified the settings when our
* parent was stopped before us, and we would likely pick up the
* settings already modified by the shell.
+ *
+ * Don't do this if we're not in curses -
*/
- if (sp != 0 && !sp->_endwin) /* don't do this if we're not in curses */
+ if (sp != 0 && (sp->_endwin == ewRunning))
#if HAVE_TCGETPGRP
if (tcgetpgrp(STDIN_FILENO) == getpgrp())
#endif
set_term(scan);
NCURSES_SP_NAME(endwin) (NCURSES_SP_ARG);
if (sp)
- sp->_endwin = FALSE; /* in case of reuse */
+ sp->_endwin = ewInitial; /* in case of reuse */
}
}
}
#include <ctype.h>
-MODULE_ID("$Id: tty_update.c,v 1.289 2017/06/30 11:47:01 tom Exp $")
+MODULE_ID("$Id: tty_update.c,v 1.290 2017/07/22 23:30:28 tom Exp $")
/*
* This define controls the line-breakout optimization. Every once in a
SP_PARM->_fifohold--;
#if USE_SIZECHANGE
- if (SP_PARM->_endwin || _nc_handle_sigwinch(SP_PARM)) {
+ if ((SP_PARM->_endwin == ewRunning)
+ || _nc_handle_sigwinch(SP_PARM)) {
/*
* This is a transparent extension: XSI does not address it,
* and applications need not know that ncurses can do it.
}
#endif
- if (SP_PARM->_endwin) {
+ if (SP_PARM->_endwin == ewSuspend) {
T(("coming back from shell mode"));
NCURSES_SP_NAME(reset_prog_mode) (NCURSES_SP_ARG);
NCURSES_SP_NAME(_nc_screen_resume) (NCURSES_SP_ARG);
SP_PARM->_mouse_resume(SP_PARM);
- SP_PARM->_endwin = FALSE;
+ SP_PARM->_endwin = ewRunning;
}
#if USE_TRACE_TIMES
/* zero the metering machinery */
#define CUR TerminalType(my_term).
-MODULE_ID("$Id: win_driver.c,v 1.58 2017/04/14 09:11:00 tom Exp $")
+MODULE_ID("$Id: win_driver.c,v 1.59 2017/07/22 21:10:28 tom Exp $")
#ifndef __GNUC__
# error We need GCC to compile for MinGW
CurScreen(sp)->_clear,
NewScreen(sp)->_clear));
- if (SP_PARM->_endwin) {
+ if (SP_PARM->_endwin == ewSuspend) {
T(("coming back from shell mode"));
NCURSES_SP_NAME(reset_prog_mode) (NCURSES_SP_ARG);
NCURSES_SP_NAME(_nc_screen_resume) (NCURSES_SP_ARG);
SP_PARM->_mouse_resume(SP_PARM);
- SP_PARM->_endwin = FALSE;
+ SP_PARM->_endwin = ewRunning;
}
if ((CurScreen(sp)->_clear || NewScreen(sp)->_clear)) {
-ncurses6 (6.0+20170715) unstable; urgency=low
+ncurses6 (6.0+20170722) unstable; urgency=low
* latest weekly patch
- -- Thomas E. Dickey <dickey@invisible-island.net> Wed, 12 Jul 2017 20:15:27 -0400
+ -- Thomas E. Dickey <dickey@invisible-island.net> Sat, 22 Jul 2017 12:49:12 -0400
ncurses6 (5.9-20131005) unstable; urgency=low
-ncurses6 (6.0+20170715) unstable; urgency=low
+ncurses6 (6.0+20170722) unstable; urgency=low
* latest weekly patch
- -- Thomas E. Dickey <dickey@invisible-island.net> Wed, 12 Jul 2017 20:15:27 -0400
+ -- Thomas E. Dickey <dickey@invisible-island.net> Sat, 22 Jul 2017 12:49:12 -0400
ncurses6 (5.9-20131005) unstable; urgency=low
-ncurses6 (6.0+20170715) unstable; urgency=low
+ncurses6 (6.0+20170722) unstable; urgency=low
* latest weekly patch
- -- Thomas E. Dickey <dickey@invisible-island.net> Wed, 12 Jul 2017 20:15:27 -0400
+ -- Thomas E. Dickey <dickey@invisible-island.net> Sat, 22 Jul 2017 12:49:12 -0400
ncurses6 (5.9-20120608) unstable; urgency=low
-; $Id: mingw-ncurses.nsi,v 1.220 2017/07/13 00:15:27 tom Exp $\r
+; $Id: mingw-ncurses.nsi,v 1.221 2017/07/22 16:49:12 tom Exp $\r
\r
; TODO add examples\r
; TODO bump ABI to 6\r
!define VERSION_MAJOR "6"\r
!define VERSION_MINOR "0"\r
!define VERSION_YYYY "2017"\r
-!define VERSION_MMDD "0715"\r
+!define VERSION_MMDD "0722"\r
!define VERSION_PATCH ${VERSION_YYYY}${VERSION_MMDD}\r
\r
!define MY_ABI "5"\r
Summary: shared libraries for terminal handling
Name: mingw32-ncurses6
Version: 6.0
-Release: 20170715
+Release: 20170722
License: X11
Group: Development/Libraries
Source: ncurses-%{version}-%{release}.tgz
Summary: shared libraries for terminal handling
Name: ncurses6
Version: 6.0
-Release: 20170715
+Release: 20170722
License: X11
Group: Development/Libraries
Source: ncurses-%{version}-%{release}.tgz
DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
-CFLAGS =
+CFLAGS = $(shell dpkg-buildflags --get CFLAGS)
+CPPFLAGS = $(shell dpkg-buildflags --get CPPFLAGS)
+LDFLAGS = $(shell dpkg-buildflags --get LDFLAGS)
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
CFLAGS += -O0
verbose = # -v
configure = \
- CFLAGS="$(CFLAGS)" ../../configure \
+ CFLAGS="$(CFLAGS)" \
+ CPPFLAGS="$(CPPFLAGS)" \
+ LDFLAGS="$(LDFLAGS)" ../../configure \
--host=$(DEB_HOST_GNU_TYPE) \
--build=$(DEB_BUILD_GNU_TYPE) \
--prefix=/usr \