]> ncurses.scripts.mit.edu Git - ncurses.git/commitdiff
ncurses 6.0 - patch 20160917
authorThomas E. Dickey <dickey@invisible-island.net>
Sun, 18 Sep 2016 02:03:51 +0000 (02:03 +0000)
committerThomas E. Dickey <dickey@invisible-island.net>
Sun, 18 Sep 2016 02:03:51 +0000 (02:03 +0000)
+ build-fix for gnat6, which unhelpfully attempts to compile C files.
+ fix typo in 20160910 changes (Debian #837892, patch by Sven Joachim).

18 files changed:
Ada95/src/Makefile.in
Ada95/src/library-cfg.sh [new file with mode: 0644]
Ada95/src/library.gpr
MANIFEST
NEWS
VERSION
dist.mk
ncurses/tinfo/MKfallback.sh
ncurses/tinfo/write_entry.c
ncurses/win32con/win_driver.c
package/debian-mingw/changelog
package/debian-mingw64/changelog
package/debian/changelog
package/mingw-ncurses.nsi
package/mingw-ncurses.spec
package/ncurses.spec
test/ncurses.c
test/worm.c

index 10bd2ce7259a3b05a68136a27d2c9880d4e198d9..557c8a51de10a72ce46af70c7b5bb7c938540446 100644 (file)
@@ -28,7 +28,7 @@
 #
 #  Author:  Juergen Pfeifer, 1996
 #
-#  $Id: Makefile.in,v 1.72 2016/08/13 18:04:27 tom Exp $
+#  $Id: Makefile.in,v 1.73 2016/09/18 00:25:32 tom Exp $
 #
 .SUFFIXES:
 
@@ -90,7 +90,7 @@ ADAFLAGS        = @ADAFLAGS@ -I. -I$(srcdir)
 LIB_NAME       = AdaCurses
 SONAME         = @ADA_SHAREDLIB@
 
-GNAT_PROJECT   = $(srcdir)/library.gpr
+GNAT_PROJECT   = AdaCurses.gpr
 
 # build/source are the Ada95 tree
 BUILD_DIR      = ..
@@ -270,8 +270,10 @@ STATIC_DIRS = \
 @USE_GNAT_PROJECTS@            $(ABASE)-trace.adb \
 @USE_GNAT_PROJECTS@            $(STATIC_C_OBJS) \
 @USE_GNAT_PROJECTS@            $(STATIC_DIRS)
+@USE_GNAT_PROJECTS@    $(SHELL) $(srcdir)/library-cfg.sh $(srcdir)/library.gpr $(CFLAGS_NORMAL) >$(GNAT_PROJECT)
 @USE_GNAT_PROJECTS@    $(ADAMAKE) $(ADAMAKEFLAGS) -XLIB_KIND=static
 @USE_GNAT_PROJECTS@    $(AR) $(ARFLAGS) $@ $(STATIC_C_OBJS)
+@USE_GNAT_PROJECTS@    -rm -f $(GNAT_PROJECT)
 @USE_GNAT_PROJECTS@
 @USE_GNAT_LIBRARIES@install \
 @USE_GNAT_LIBRARIES@install.libs :: \
@@ -302,7 +304,9 @@ SHARED_DIRS = \
 @MAKE_ADA_SHAREDLIB@           $(SHARED_DIRS) \
 @MAKE_ADA_SHAREDLIB@           $(SHARED_OBJS)
 @MAKE_ADA_SHAREDLIB@   cp $(SHARED_OBJS) $(BUILD_DIR)/dynamic-obj/
+@MAKE_ADA_SHAREDLIB@   $(SHELL) $(srcdir)/library-cfg.sh $(srcdir)/library.gpr $(CFLAGS_SHARED) >$(GNAT_PROJECT)
 @MAKE_ADA_SHAREDLIB@   $(ADAMAKE) $(ADAMAKEFLAGS) -XLIB_KIND=dynamic
+@MAKE_ADA_SHAREDLIB@   -rm -f $(GNAT_PROJECT)
 
 install \
 install.libs :: $(ADA_INCLUDE)
diff --git a/Ada95/src/library-cfg.sh b/Ada95/src/library-cfg.sh
new file mode 100644 (file)
index 0000000..d1c1ce3
--- /dev/null
@@ -0,0 +1,50 @@
+#!/bin/sh
+##############################################################################
+# Copyright (c) 2016 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"), #
+# to deal in the Software without restriction, including without limitation  #
+# the rights to use, copy, modify, merge, publish, distribute, distribute    #
+# with modifications, sublicense, and/or sell copies of the Software, and to #
+# permit persons to whom the Software is furnished to do so, subject to the  #
+# following conditions:                                                      #
+#                                                                            #
+# The above copyright notice and this permission notice shall be included in #
+# all copies or substantial portions of the Software.                        #
+#                                                                            #
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR #
+# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,   #
+# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL    #
+# THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER      #
+# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING    #
+# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER        #
+# DEALINGS IN THE SOFTWARE.                                                  #
+#                                                                            #
+# Except as contained in this notice, the name(s) of the above copyright     #
+# holders shall not be used in advertising or otherwise to promote the sale, #
+# use or other dealings in this Software without prior written               #
+# authorization.                                                             #
+##############################################################################
+#
+# $Id: library-cfg.sh,v 1.1 2016/09/17 23:45:03 tom Exp $
+#
+# Work around incompatible behavior introduced with gnat6, which causes
+# gnatmake to attempt to compile all of the C objects which might be part of
+# the project.  This can only work if we provide the compiler flags (done here
+# by making a copy of the project file with that information filled in).
+input=$1
+shift 1
+param=
+while test $# != 0
+do
+       test -n "$param" && param="$param,"
+       param="$param\"$1\"" 
+       shift 1
+done
+
+sed \
+       -e '/for Default_Switches ("C") use/s,-- ,,' \
+       -e '/for Default_Switches ("C") use/s% use .*'%" use($param);"% \
+       $input
+exit 0
index e7380f09f7fc6e95864867d31592d1fa03af1983..dc31103a1bf169ba2ea758d772c0c49d4dcf7921 100644 (file)
 -- sale, use or other dealings in this Software without prior written       --
 -- authorization.                                                           --
 ------------------------------------------------------------------------------
--- $Id: library.gpr,v 1.9 2014/06/01 01:13:09 tom Exp $
+-- $Id: library.gpr,v 1.10 2016/09/18 00:25:54 tom Exp $
 -- http://gcc.gnu.org/onlinedocs/gnat_ugn_unw/Library-Projects.html
 -- http://www.adaworld.com/debian/debian-ada-policy.html
-project Library is
+project AdaCurses is
   Build_Dir := External ("BUILD_DIR");
   Source_Dir := External ("SOURCE_DIR");
   Source_Dir2 := External ("SOURCE_DIR2");
@@ -51,6 +51,7 @@ project Library is
         "-gnatafno",
         "-gnatVa",   -- All validity checks
         "-gnatwa");  -- Activate all optional errors
+     -- for Default_Switches ("C") use 
   end Compiler;
   for Languages use ("C", "Ada");
-end Library;
+end AdaCurses;
index 528f07a0ff0319ac1ebadaa67b9976291757f021..a038ad637a051bbf1a3dd13782c3454013815d72 100644 (file)
--- a/MANIFEST
+++ b/MANIFEST
 ./Ada95/src/c_threaded_variables.h
 ./Ada95/src/c_varargs_to_ada.c
 ./Ada95/src/c_varargs_to_ada.h
+./Ada95/src/library-cfg.sh
 ./Ada95/src/library.gpr
 ./Ada95/src/modules
 ./Ada95/src/ncurses_compat.c
diff --git a/NEWS b/NEWS
index b43ff725a2535911430309386fd9f40dfc6fddb7..1ecda2f66a7c964e4809500974717de80aa25bd1 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -25,7 +25,7 @@
 -- sale, use or other dealings in this Software without prior written        --
 -- authorization.                                                            --
 -------------------------------------------------------------------------------
--- $Id: NEWS,v 1.2664 2016/09/10 22:07:14 tom Exp $
+-- $Id: NEWS,v 1.2667 2016/09/18 00:38:06 tom Exp $
 -------------------------------------------------------------------------------
 
 This is a log of changes that ncurses has gone through since Zeyd started
@@ -45,6 +45,10 @@ See the AUTHORS file for the corresponding full names.
 Changes through 1.9.9e did not credit all contributions;
 it is not possible to add this information.
 
+20160917
+       + build-fix for gnat6, which unhelpfully attempts to compile C files.
+       + fix typo in 20160910 changes (Debian #837892, patch by Sven Joachim).
+
 20160910
        + trim dead code ifdef'd with HIDE_EINTR since 970830 (discussion with
          Leon Winter).
diff --git a/VERSION b/VERSION
index c2e12e304d1b16d5130401343d56175f9332e681..3bf18a61f657c204cfd218e27e6fec4687692cd2 100644 (file)
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-5:0:9  6.0     20160910
+5:0:9  6.0     20160917
diff --git a/dist.mk b/dist.mk
index a6426d6a2ad50d0a25a73583ded688ade0549eef..44b75de30e61e1b8e3647dde3cabbb631fa66c3f 100644 (file)
--- a/dist.mk
+++ b/dist.mk
@@ -25,7 +25,7 @@
 # use or other dealings in this Software without prior written               #
 # authorization.                                                             #
 ##############################################################################
-# $Id: dist.mk,v 1.1123 2016/09/04 17:02:31 tom Exp $
+# $Id: dist.mk,v 1.1124 2016/09/17 13:25:35 tom Exp $
 # Makefile for creating ncurses distributions.
 #
 # This only needs to be used directly as a makefile by developers, but
@@ -37,7 +37,7 @@ SHELL = /bin/sh
 # These define the major/minor/patch versions of ncurses.
 NCURSES_MAJOR = 6
 NCURSES_MINOR = 0
-NCURSES_PATCH = 20160910
+NCURSES_PATCH = 20160917
 
 # We don't append the patch to the version, since this only applies to releases
 VERSION = $(NCURSES_MAJOR).$(NCURSES_MINOR)
index 11f1d2ead138703f33d5a7157a6a017f3dd3184a..53d05f87e9f758311bd15afb9f936f4de50db832 100755 (executable)
@@ -1,6 +1,6 @@
 #!/bin/sh
 ##############################################################################
-# Copyright (c) 1998-2009,2010 Free Software Foundation, Inc.                #
+# Copyright (c) 1998-2010,2016 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"), #
@@ -26,7 +26,7 @@
 # use or other dealings in this Software without prior written               #
 # authorization.                                                             #
 ##############################################################################
-# $Id: MKfallback.sh,v 1.15 2010/08/07 20:32:34 tom Exp $
+# $Id: MKfallback.sh,v 1.16 2016/09/17 21:28:03 tom Exp $
 #
 # MKfallback.sh -- create fallback table for entry reads
 #
@@ -119,17 +119,19 @@ then
     const TERMTYPE     *tp;
 
     for (tp = fallbacks;
-               tp < fallbacks + sizeof(fallbacks)/sizeof(TERMTYPE);
-               tp++)
-       if (_nc_name_match(tp->term_names, name, "|"))
+        tp < fallbacks + sizeof(fallbacks)/sizeof(TERMTYPE);
+        tp++) {
+       if (_nc_name_match(tp->term_names, name, "|")) {
            return(tp);
+       }
+    }
 EOF
 else
        echo "  /* the fallback list is empty */";
 fi
 
 cat <<EOF
-       return((TERMTYPE *)0);
+    return((TERMTYPE *)0);
 }
 EOF
 
index b76a109d67a664472dad6845fd5d8084741c5e7c..0000aa1669cc7cf49e8311983b9090c024960640 100644 (file)
@@ -47,7 +47,7 @@
 #define TRACE_OUT(p)           /*nothing */
 #endif
 
-MODULE_ID("$Id: write_entry.c,v 1.95 2016/09/10 20:22:42 tom Exp $")
+MODULE_ID("$Id: write_entry.c,v 1.96 2016/09/17 19:06:26 Sven.Joachim Exp $")
 
 static int total_written;
 
@@ -443,7 +443,7 @@ _nc_write_entry(TERMTYPE *const tp)
                _nc_STRNCPY(symlinkname, first_name, MY_SIZE);
            } else {
                _nc_STRCPY(symlinkname, "../", sizeof(symlinkname));
-               _nc_STRNCPY(symlinkname + 3, first_name, MY_SIZE - 3);
+               _nc_STRNCPY(symlinkname + 3, filename, MY_SIZE - 3);
            }
            symlinkname[MY_SIZE] = '\0';
 #endif /* USE_SYMLINKS */
index 78ccfeda1b8289f472ccbf72084121a6919d3e8e..cc9fd2b293ee137a47a32f3725378d91985243c4 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2014,2015 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2015,2016 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            *
@@ -54,7 +54,7 @@
 
 #define CUR my_term.type.
 
-MODULE_ID("$Id: win_driver.c,v 1.55 2015/02/28 21:30:23 tom Exp $")
+MODULE_ID("$Id: win_driver.c,v 1.56 2016/09/17 22:02:44 tom Exp $")
 
 #ifndef __GNUC__
 #  error We need GCC to compile for MinGW
@@ -2108,7 +2108,7 @@ _nc_mingw_console_read(
        if (b && nRead > 0) {
            if (rc < 0)
                rc = 0;
-           rc += nRead;
+           rc = rc + (int) nRead;
            if (inp_rec.EventType == KEY_EVENT) {
                if (!inp_rec.Event.KeyEvent.bKeyDown)
                    continue;
index 5385754fdfa104b8506614d8ed235018513490f1..cf4d4727c4d37859f0dfb98965ae3bdc07f61fdd 100644 (file)
@@ -1,8 +1,8 @@
-ncurses6 (6.0+20160910) unstable; urgency=low
+ncurses6 (6.0+20160917) unstable; urgency=low
 
   * latest weekly patch
 
- -- Thomas E. Dickey <dickey@invisible-island.net>  Sun, 04 Sep 2016 13:02:31 -0400
+ -- Thomas E. Dickey <dickey@invisible-island.net>  Sat, 17 Sep 2016 09:25:35 -0400
 
 ncurses6 (5.9-20131005) unstable; urgency=low
 
index 5385754fdfa104b8506614d8ed235018513490f1..cf4d4727c4d37859f0dfb98965ae3bdc07f61fdd 100644 (file)
@@ -1,8 +1,8 @@
-ncurses6 (6.0+20160910) unstable; urgency=low
+ncurses6 (6.0+20160917) unstable; urgency=low
 
   * latest weekly patch
 
- -- Thomas E. Dickey <dickey@invisible-island.net>  Sun, 04 Sep 2016 13:02:31 -0400
+ -- Thomas E. Dickey <dickey@invisible-island.net>  Sat, 17 Sep 2016 09:25:35 -0400
 
 ncurses6 (5.9-20131005) unstable; urgency=low
 
index bf3b36abea226b13e6866ae060df84f3d4bbea0d..f1716303f73b78c7e08623f3df3c65527169067a 100644 (file)
@@ -1,8 +1,8 @@
-ncurses6 (6.0+20160910) unstable; urgency=low
+ncurses6 (6.0+20160917) unstable; urgency=low
 
   * latest weekly patch
 
- -- Thomas E. Dickey <dickey@invisible-island.net>  Sun, 04 Sep 2016 13:02:31 -0400
+ -- Thomas E. Dickey <dickey@invisible-island.net>  Sat, 17 Sep 2016 09:25:35 -0400
 
 ncurses6 (5.9-20120608) unstable; urgency=low
 
index 0ebea19d685b2fbfef3b1a3c5a8166179bf1cd23..b8d4960d57ddc68d35adc3a50d5044eff91f8eb7 100644 (file)
@@ -1,4 +1,4 @@
-; $Id: mingw-ncurses.nsi,v 1.175 2016/09/04 17:02:31 tom Exp $\r
+; $Id: mingw-ncurses.nsi,v 1.176 2016/09/17 13:25:35 tom Exp $\r
 \r
 ; TODO add examples\r
 ; TODO bump ABI to 6\r
@@ -10,7 +10,7 @@
 !define VERSION_MAJOR "6"\r
 !define VERSION_MINOR "0"\r
 !define VERSION_YYYY  "2016"\r
-!define VERSION_MMDD  "0910"\r
+!define VERSION_MMDD  "0917"\r
 !define VERSION_PATCH ${VERSION_YYYY}${VERSION_MMDD}\r
 \r
 !define MY_ABI   "5"\r
index 258de5f77bfc6e57088ca7279b7735fe94cc8e3b..348a9d0a4a9aeb3a95b579f5a61a35a0ce629d2e 100644 (file)
@@ -3,7 +3,7 @@
 Summary: shared libraries for terminal handling
 Name: mingw32-ncurses6
 Version: 6.0
-Release: 20160910
+Release: 20160917
 License: X11
 Group: Development/Libraries
 Source: ncurses-%{version}-%{release}.tgz
index a63bf1dc4371f1323ac8710b008780407cdbd96b..5284b886b42b28437e4ed624dcbb3c76b8df076a 100644 (file)
@@ -1,7 +1,7 @@
 Summary: shared libraries for terminal handling
 Name: ncurses6
 Version: 6.0
-Release: 20160910
+Release: 20160917
 License: X11
 Group: Development/Libraries
 Source: ncurses-%{version}-%{release}.tgz
index 8f3ac071e339b70a17d67c5f32fc4e73fe38f54e..ddd054e4d208615903cba4d28144b1b7de52d846 100644 (file)
@@ -40,7 +40,7 @@ AUTHOR
    Author: Eric S. Raymond <esr@snark.thyrsus.com> 1993
            Thomas E. Dickey (beginning revision 1.27 in 1996).
 
-$Id: ncurses.c,v 1.445 2016/09/10 23:30:15 tom Exp $
+$Id: ncurses.c,v 1.446 2016/09/17 21:12:04 tom Exp $
 
 ***************************************************************************/
 
@@ -2704,7 +2704,8 @@ init_all_colors(bool xterm_colors, char *palette_file)
        int n;
        int got;
        char result[BUFSIZ];
-       int check_n, check_r, check_g, check_b;
+       int check_n;
+       unsigned check_r, check_g, check_b;
 
        raw();
        noecho();
@@ -6925,11 +6926,11 @@ show_settings(void)
     show_string_setting("longname", longname());
     show_number_setting("baudrate", baudrate());
     if (erasechar() > 0) {
-       show_string_setting("unctrl(erasechar)", unctrl(erasechar()));
+       show_string_setting("unctrl(erasechar)", unctrl((chtype) erasechar()));
        show_string_setting("keyname(erasechar)", keyname(erasechar()));
     }
     if (killchar() > 0) {
-       show_string_setting("unctrl(killchar)", unctrl(killchar()));
+       show_string_setting("unctrl(killchar)", unctrl((chtype) killchar()));
        show_string_setting("keyname(killchar)", keyname(killchar()));
     }
 #if USE_WIDEC_SUPPORT
index c3fc0da822ef2619246c5ed831c0d9eb9bee48af..92bdb254986719d46a2fb42c53a70a11ea14a260 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2012,2013 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2013,2016 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            *
@@ -61,7 +61,7 @@ Options:
   traces will be dumped.  The program stops and waits for one character of
   input at the beginning and end of the interval.
 
-  $Id: worm.c,v 1.65 2013/06/22 20:01:41 tom Exp $
+  $Id: worm.c,v 1.66 2016/09/17 21:12:30 tom Exp $
 */
 
 #include <test.priv.h>
@@ -324,9 +324,9 @@ draw_worm(WINDOW *win, void *data)
 static bool
 quit_worm(int bitnum)
 {
-    pending |= (1 << bitnum);
+    pending = (pending | (unsigned) (1 << bitnum));
     napms(10);                 /* let the other thread(s) have a chance */
-    pending &= ~(1 << bitnum);
+    pending = (pending & (unsigned) ~(1 << bitnum));
     return quitting;
 }
 
@@ -335,7 +335,7 @@ start_worm(void *arg)
 {
     unsigned long compare = 0;
     Trace(("start_worm"));
-    while (!quit_worm(((struct worm *) arg) - worm)) {
+    while (!quit_worm((int) (((struct worm *) arg) - worm))) {
        while (compare < sequence) {
            ++compare;
 #if HAVE_USE_WINDOW