[packages/slang] - updated to 2.3.2 - removed obsolete perms,32bit-terminfo patches

qboosh qboosh at pld-linux.org
Sun Mar 18 07:17:09 CET 2018


commit 91b922c43f665083bdee192a87883fbd0d4a1036
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Sun Mar 18 07:19:39 2018 +0100

    - updated to 2.3.2
    - removed obsolete perms,32bit-terminfo patches

 slang-2.2.4-perms.patch    |  45 ----------
 slang-32bit-terminfo.patch | 199 ---------------------------------------------
 slang.spec                 |   8 +-
 3 files changed, 2 insertions(+), 250 deletions(-)
---
diff --git a/slang.spec b/slang.spec
index 62256c5..de26c79 100644
--- a/slang.spec
+++ b/slang.spec
@@ -14,17 +14,15 @@ Summary(ru.UTF-8):	Разделяемая библиотека C-подобно
 Summary(tr.UTF-8):	C benzeri dil için ortak kitaplık
 Summary(uk.UTF-8):	Бібліотека спільного користування C-подібної мови розширення S-Lang
 Name:		slang
-Version:	2.3.1a
+Version:	2.3.2
 Release:	2
 Epoch:		1
 License:	GPL v2+
 Group:		Libraries
 Source0:	http://www.jedsoft.org/releases/slang/%{name}-%{version}.tar.bz2
-# Source0-md5:	c5235313042ed0e71ec708f7b85ec241
+# Source0-md5:	c2d5a7aa0246627da490be4e399c87cb
 Patch0:		%{name}-nodevel.patch
 Patch1:		%{name}-remove_unused_terminfo_paths.patch
-Patch2:		slang-2.2.4-perms.patch
-Patch3:		slang-32bit-terminfo.patch
 URL:		http://www.jedsoft.org/slang/
 %{?with_png:BuildRequires:	libpng-devel}
 %{?with_onig:BuildRequires:	oniguruma-devel}
@@ -249,8 +247,6 @@ Moduł PCRE dla Slanga.
 %setup -q
 %patch0 -p1
 %patch1 -p1
-%patch2 -p1
-%patch3 -p1
 
 %build
 %configure \
diff --git a/slang-2.2.4-perms.patch b/slang-2.2.4-perms.patch
deleted file mode 100644
index a5fb715..0000000
--- a/slang-2.2.4-perms.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-commit 02ae6621f28d90b717c679b61cd1d1800d5c69e7
-Author: Miroslav Lichvar <mlichvar at redhat.com>
-Date:   Mon Dec 13 16:44:16 2010 +0100
-
-    Install shared objects with executable permissions
-
-diff --git a/autoconf/aclocal.m4 b/autoconf/aclocal.m4
-index d5eb3f2..b5525cf 100644
---- a/autoconf/aclocal.m4
-+++ b/autoconf/aclocal.m4
-@@ -578,7 +578,7 @@ ELFLIB_MAJOR_MINOR_MICRO="\$(ELFLIB_MAJOR_MINOR).\$(ELF_MICRO_VERSION)"
- dnl# This specifies the target to use in the makefile to install the shared library
- INSTALL_ELFLIB_TARGET="install-elf-and-links"
- ELFLIB_BUILD_NAME="\$(ELFLIB_MAJOR_MINOR_MICRO)"
--INSTALL_MODULE="\$(INSTALL_DATA)"
-+INSTALL_MODULE="\$(INSTALL)"
- SLANG_DLL_CFLAGS=""
- M_LIB="-lm"
- 
-diff --git a/modules/Makefile.in b/modules/Makefile.in
-index 0384359..06b71ec 100644
---- a/modules/Makefile.in
-+++ b/modules/Makefile.in
-@@ -61,7 +61,7 @@ SOCKET_LIBS = @X_EXTRA_LIBS@
- MODULE_INSTALL_DIR = @libdir@/slang/v at slang_major_version@/modules
- INSTALL		= @INSTALL@
- INSTALL_DATA	= @INSTALL_DATA@
--INSTALL_MODULE	= @INSTALL_MODULE@
-+INSTALL_MODULE	= @INSTALL@
- MKINSDIR	= $(CONFIG_DIR)/autoconf/mkinsdir.sh
- SLSH_DIR	= $(prefix)/share/slsh
- CMAPS_DIR	= $(SLSH_DIR)/cmaps
-diff --git a/src/Makefile.in b/src/Makefile.in
-index 03fa056..d2b9f1b 100644
---- a/src/Makefile.in
-+++ b/src/Makefile.in
-@@ -195,7 +195,7 @@ install-elf-and-links:
- 	-$(RM) $(DEST_LIBDIR)/$(ELFLIB)
- 	-$(RM) $(DEST_LIBDIR)/$(ELFLIB_MAJOR)
- 	@echo installing $(ELFLIB_BUILD_NAME) in $(DEST_LIBDIR)
--	$(INSTALL_DATA) $(ELFDIR_ELF_LIB) $(DEST_LIBDIR)/
-+	$(INSTALL) $(ELFDIR_ELF_LIB) $(DEST_LIBDIR)/
- 	-cd $(DEST_LIBDIR) && $(LN) $(ELFLIB_BUILD_NAME) $(ELFLIB_MAJOR)
- 	-cd $(DEST_LIBDIR) && $(LN) $(ELFLIB_MAJOR) $(ELFLIB)
- 	@echo ""
diff --git a/slang-32bit-terminfo.patch b/slang-32bit-terminfo.patch
deleted file mode 100644
index e1c47ec..0000000
--- a/slang-32bit-terminfo.patch
+++ /dev/null
@@ -1,199 +0,0 @@
-commit 6dd5ade9a97b52ace4ac033779a6d3c1c51db4d1
-Author: John E. Davis <jed at jedsoft.org>
-Date:   Tue Jan 30 04:04:17 2018 -0500
-
-    pre2.3.2-19: Added support for the new ncurses 32-bit terminfo database entries.
-
-diff --git a/src/sltermin.c b/src/sltermin.c
-index 34bc73c..99fc8f9 100644
---- a/src/sltermin.c
-+++ b/src/sltermin.c
-@@ -33,6 +33,11 @@ USA.
-  * term(4) man page on an SGI.
-  */
- 
-+/* The ncurses terminfo binary files come in two flavors: A legacy
-+ * format that uses 16 bit integers in the number-section, and a new
-+ * 32 bit format (nurses 6, from 2018).
-+ */
-+
- /* Short integers are stored in two 8-bit bytes.  The first byte contains
-  * the least significant 8 bits of the value, and the second byte contains
-  * the most significant 8 bits.  (Thus, the value represented is
-@@ -43,7 +48,7 @@ USA.
-  * source and also is to be considered missing.
-  */
- 
--static int make_integer (unsigned char *buf)
-+static int make_integer16 (unsigned char *buf)
- {
-    register int lo, hi;
-    lo = (int) *buf++; hi = (int) *buf;
-@@ -55,6 +60,20 @@ static int make_integer (unsigned char *buf)
-    return lo + 256 * hi;
- }
- 
-+static int make_integer32 (unsigned char *buf)
-+{
-+   unsigned int u;
-+   int i;
-+
-+   u = (unsigned int)buf[0];
-+   u |= ((unsigned int)buf[1])<<8;
-+   u |= ((unsigned int)buf[2])<<16;
-+   u |= ((unsigned int)buf[3])<<24;
-+
-+   i = (int)u;
-+   return i;
-+}
-+
- /*
-  * The compiled file is created from the source file descriptions of the
-  * terminals (see the -I option of infocmp) by using the terminfo compiler,
-@@ -64,14 +83,15 @@ static int make_integer (unsigned char *buf)
-  *
-  * The header section begins the file.  This section contains six short
-  * integers in the format described below.  These integers are (1) the magic
-- * number (octal 0432); (2) the size, in bytes, of the names section; (3)
-- * the number of bytes in the boolean section; (4) the number of short
-- * integers in the numbers section; (5) the number of offsets (short
-+ * number (legacy:0432, 01036:32 but); (2) the size, in bytes, of the names section; (3)
-+ * the number of bytes in the boolean section; (4) the number of integers
-+ * in the numbers section; (5) the number of offsets (short
-  * integers) in the strings section; (6) the size, in bytes, of the string
-  * table.
-  */
- 
--#define MAGIC 0432
-+#define MAGIC_LEGACY 0432
-+#define MAGIC_32BIT 01036
- 
- /* In this structure, all char * fields are malloced EXCEPT if the
-  * structure is SLTERMCAP.  In that case, only terminal_names is malloced
-@@ -91,6 +111,8 @@ struct _pSLterminfo_Type
- 
-    unsigned int num_numbers;
-    unsigned char *numbers;
-+   unsigned int sizeof_number;
-+   int (*make_integer)(unsigned char *);
- 
-    unsigned int num_string_offsets;
-    unsigned char *string_offsets;
-@@ -109,6 +131,7 @@ static FILE *open_terminfo (char *file, SLterminfo_Type *h)
- {
-    FILE *fp;
-    unsigned char buf[12];
-+   int magic;
- 
-    /* Alan Cox reported a security problem here if the application using the
-     * library is setuid.  So, I need to make sure open the file as a normal
-@@ -122,19 +145,34 @@ static FILE *open_terminfo (char *file, SLterminfo_Type *h)
-    fp = fopen (file, "rb");
-    if (fp == NULL) return NULL;
- 
--   if ((12 == fread ((char *) buf, 1, 12, fp) && (MAGIC == make_integer (buf))))
-+   if (12 != fread ((char *)buf, 1, 12, fp))
-+     {
-+	(void) fclose(fp);
-+	return NULL;
-+     }
-+   magic = make_integer16(buf);
-+   if (magic == MAGIC_LEGACY)
-+     {
-+	h->make_integer = make_integer16;
-+	h->sizeof_number = 2;
-+     }
-+   else if (magic == MAGIC_32BIT)
-      {
--	h->name_section_size = make_integer (buf + 2);
--	h->boolean_section_size = make_integer (buf + 4);
--	h->num_numbers = make_integer (buf + 6);
--	h->num_string_offsets = make_integer (buf + 8);
--	h->string_table_size = make_integer (buf + 10);
-+	h->make_integer = make_integer32;
-+	h->sizeof_number = 4;
-      }
-    else
-      {
--	fclose (fp);
--	fp = NULL;
-+	(void) fclose (fp);
-+	return NULL;
-      }
-+
-+   h->name_section_size = make_integer16 (buf + 2);
-+   h->boolean_section_size = make_integer16 (buf + 4);
-+   h->num_numbers = make_integer16 (buf + 6);
-+   h->num_string_offsets = make_integer16 (buf + 8);
-+   h->string_table_size = make_integer16 (buf + 10);
-+
-    return fp;
- }
- 
-@@ -187,13 +225,14 @@ static unsigned char *read_boolean_flags (FILE *fp, SLterminfo_Type *t)
- 
- /*
-  * The numbers section is similar to the boolean flags section.  Each
-- * capability takes up two bytes, and is stored as a short integer.  If the
-- * value represented is -1 or -2, the capability is taken to be missing.
-+ * capability takes up 2(4) bytes for the legacy(32 bit) format and
-+ * is stored as a integer.  If the value represented is -1 or -2, the
-+ * capability is taken to be missing.
-  */
- 
- static unsigned char *read_numbers (FILE *fp, SLterminfo_Type *t)
- {
--   return t->numbers = read_terminfo_section (fp, 2 * t->num_numbers);
-+   return t->numbers = read_terminfo_section (fp, t->sizeof_number * t->num_numbers);
- }
- 
- /* The strings section is also similar.  Each capability is stored as a
-@@ -402,7 +441,7 @@ char *_pSLtt_tigetstr (SLterminfo_Type *t, SLCONST char *cap)
- 
-    offset = compute_cap_offset (cap, t, Tgetstr_Map, t->num_string_offsets);
-    if (offset < 0) return NULL;
--   offset = make_integer (t->string_offsets + 2 * offset);
-+   offset = make_integer16 (t->string_offsets + 2 * offset);
-    if (offset < 0) return NULL;
-    return t->string_table + offset;
- }
-@@ -418,7 +457,8 @@ int _pSLtt_tigetnum (SLterminfo_Type *t, SLCONST char *cap)
- 
-    offset = compute_cap_offset (cap, t, Tgetnum_Map, t->num_numbers);
-    if (offset < 0) return -1;
--   return make_integer (t->numbers + 2 * offset);
-+
-+   return (*t->make_integer)(t->numbers + t->sizeof_number * offset);
- }
- 
- int _pSLtt_tigetflag (SLterminfo_Type *t, SLCONST char *cap)
-diff --git a/src/untic.c b/src/untic.c
-index bd15478..2fa966a 100644
---- a/src/untic.c
-+++ b/src/untic.c
-@@ -36,7 +36,7 @@ int main (int argc, char **argv)
-    puts (t->terminal_names);
-    while (*map->name != 0)
-      {
--	str = (unsigned char *) SLtt_tigetstr (map->name, (char **) &t);
-+	str = (unsigned char *) SLtt_tigetstr ((SLFUTURE_CONST char *)map->name, (char **) &t);
- 	if (str == NULL)
- 	  {
- 	     map++;
-@@ -76,7 +76,7 @@ int main (int argc, char **argv)
-    while (*map->name != 0)
-      {
- 	int val;
--	if ((val = SLtt_tigetnum (map->name, (char **) &t)) >= 0)
-+	if ((val = SLtt_tigetnum ((SLFUTURE_CONST char *)map->name, (char **) &t)) >= 0)
- 	  {
- 	     fprintf (stdout, "\t%s#%d\t\t%s\n",
- 		      map->name, val,
-@@ -85,6 +85,7 @@ int main (int argc, char **argv)
- 	map++;
-      }
- 
-+   _pSLtt_tifreeent (t);
-    return 0;
- }
- 
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/slang.git/commitdiff/91b922c43f665083bdee192a87883fbd0d4a1036



More information about the pld-cvs-commit mailing list