[packages/librhtv] Rel 4

arekm arekm at pld-linux.org
Sun Mar 15 16:58:13 CET 2026


commit 9636a50ab53e503e48c21cd1809741dc8767d812
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date:   Sun Mar 15 16:58:06 2026 +0100

    Rel 4

 abs-ambiguous.patch | 40 ++++++++++++++++++++++++++
 gcc-fixes.patch     | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++
 librhtv.spec        |  8 +++++-
 perl-inc.patch      | 13 +++++++++
 4 files changed, 141 insertions(+), 1 deletion(-)
---
diff --git a/librhtv.spec b/librhtv.spec
index 7c12637..309d378 100644
--- a/librhtv.spec
+++ b/librhtv.spec
@@ -2,7 +2,7 @@ Summary:	Unix port of Borland TurboVision library
 Summary(pl.UTF-8):	Uniksowa wersja biblioteki TurboVision Borlanda
 Name:		librhtv
 Version:	2.2.1
-Release:	3
+Release:	4
 License:	Borland, some modifications are BSD-like licensed (generally free)
 Group:		Libraries
 Source0:	http://download.sourceforge.net/tvision/rhtvision_%{version}-1.tar.gz
@@ -12,6 +12,9 @@ Patch1:		%{name}-fcntl.patch
 Patch2:		%{name}-ncurses.patch
 Patch3:		format-security.patch
 Patch4:		infinite-loop.patch
+Patch5:		perl-inc.patch
+Patch6:		abs-ambiguous.patch
+Patch7:		gcc-fixes.patch
 URL:		http://tvision.sourceforge.net/
 BuildRequires:	xorg-lib-libX11-devel
 BuildRequires:	gpm-devel
@@ -68,6 +71,9 @@ Biblioteki statyczne rhtvision.
 %patch -P2 -p1
 %patch -P3 -p1
 %patch -P4 -p1
+%patch -P5 -p1
+%patch -P6 -p1
+%patch -P7 -p1
 
 %build
 %{__perl} config.pl \
diff --git a/abs-ambiguous.patch b/abs-ambiguous.patch
new file mode 100644
index 0000000..d7c679d
--- /dev/null
+++ b/abs-ambiguous.patch
@@ -0,0 +1,40 @@
+--- tvision/classes/tdesktop.cc.orig	2026-03-15 16:11:37.066561896 +0100
++++ tvision/classes/tdesktop.cc	2026-03-15 16:11:53.989562447 +0100
+@@ -144,7 +144,7 @@
+ {
+     unsigned res1 = 2;
+     unsigned res2 = i/res1;
+-    while( abs( res1 - res2 ) > 1 )
++    while( abs( (int)(res1 - res2) ) > 1 )
+         {
+         res1 = (res1 + res2)/2;
+         res2 = i/res1;
+--- tvision/classes/tdisplay.cc.orig	2026-03-15 16:11:37.069895229 +0100
++++ tvision/classes/tdisplay.cc	2026-03-15 16:12:00.433389298 +0100
+@@ -381,10 +381,10 @@
+  if (firstXMatch!=-1)
+    {// Return the closest y that match x
+     i=indexMin=firstXMatch;
+-    minDif=abs(res[i].y-y);
++    minDif=abs((int)(res[i].y-y));
+     while (++i<cant && res[i].x==x)
+       {
+-       dif=abs(res[i].y-y);
++       dif=abs((int)(res[i].y-y));
+        if (dif<minDif)
+          {
+           minDif=dif;
+@@ -396,11 +396,11 @@
+    }
+  // No x match, looks the one with minimum differences
+  indexMin=0;
+- minDif=abs(res[0].y-y)+abs(res[0].x-x);
++ minDif=abs((int)(res[0].y-y))+abs((int)(res[0].x-x));
+  i=1;
+  while (i<cant)
+    {
+-    dif=abs(res[i].y-y)+abs(res[i].x-x);
++    dif=abs((int)(res[i].y-y))+abs((int)(res[i].x-x));
+     if (dif<minDif)
+       {
+        minDif=dif;
diff --git a/gcc-fixes.patch b/gcc-fixes.patch
new file mode 100644
index 0000000..d2cc9f9
--- /dev/null
+++ b/gcc-fixes.patch
@@ -0,0 +1,81 @@
+--- tvision/classes/tvtext1.cc.orig	2026-03-15 16:14:05.326561897 +0100
++++ tvision/classes/tvtext1.cc	2026-03-15 16:14:11.898686851 +0100
+@@ -110,10 +110,10 @@
+ char TCheckBoxes::button[] = " [ ] ";
+ char TCheckBoxes::obutton[] = " [ ] ";
+ 
+-TScrollChars TScrollBar::vChars = {30, 31, 177, 254, 178}; // 
���
+-TScrollChars TScrollBar::ovChars = {30, 31, 177, 254, 178}; // 
���
+-TScrollChars TScrollBar::hChars = {17, 16, 177, 254, 178}; // ���
+-TScrollChars TScrollBar::ohChars = {17, 16, 177, 254, 178}; // ���
++TScrollChars TScrollBar::vChars = {30, 31, (char)177, (char)254, (char)178}; // 
���
++TScrollChars TScrollBar::ovChars = {30, 31, (char)177, (char)254, (char)178}; // 
���
++TScrollChars TScrollBar::hChars = {17, 16, (char)177, (char)254, (char)178}; // ���
++TScrollChars TScrollBar::ohChars = {17, 16, (char)177, (char)254, (char)178}; // ���
+ 
+ char TButton::shadows[] = "\xDC\xDB\xDF"; // ���
+ char TButton::oshadows[] = "\xDC\xDB\xDF"; // ���
+--- tvision/classes/unix/unixkey.cc.orig	2026-03-15 16:14:05.326561897 +0100
++++ tvision/classes/unix/unixkey.cc	2026-03-15 16:14:15.072075550 +0100
+@@ -45,6 +45,7 @@
+ #else
+  #include <curses.h>
+ #endif
++#include <termios.h>
+ #include <term.h>
+ 
+ #ifdef HAVE_KEYSYMS
+--- tvision/classes/unix/unixscr.cc.orig	2026-03-15 16:14:05.329895230 +0100
++++ tvision/classes/unix/unixscr.cc	2026-03-15 16:14:24.268317914 +0100
+@@ -46,6 +46,7 @@
+ #include <tv/unix/mouse.h>
+ #include <tv/linux/mouse.h>
+ 
++#define NCURSES_INTERNALS
+ #ifdef TVOSf_FreeBSD
+  #include <ncurses.h>
+ #else
+--- tvision/classes/x11/x11src.cc.orig	2026-03-15 16:16:10.686561897 +0100
++++ tvision/classes/x11/x11src.cc	2026-03-15 16:16:20.027948123 +0100
+@@ -2538,8 +2538,8 @@
+  else
+    {
+     unsigned target=fW*fH;
+-    int dif1=abs(8*16-target);
+-    int dif2=abs(10*20-target);
++    int dif1=abs((int)(8*16-target));
++    int dif2=abs((int)(10*20-target));
+     if (dif1<dif2)
+        nFont=&font8x16;
+     else
+@@ -2634,7 +2634,7 @@
+ 
+ Cursor TScreenX11::busyCursor,
+        TScreenX11::leftPtr;
+-char   TScreenX11::busyCursorMap[]=
++unsigned char   TScreenX11::busyCursorMap[]=
+ {
+  0xff, 0xff, 0xff, 0x1f,
+  0xfd, 0xff, 0xff, 0x1f,
+@@ -2657,7 +2657,7 @@
+  0xff, 0x7f, 0xc0, 0x1f,
+  0xff, 0xff, 0xff, 0x1f
+ };
+-char TScreenX11::busyCursorMask[]=
++unsigned char TScreenX11::busyCursorMask[]=
+ {
+  0xfc, 0xff, 0xff, 0x1f,
+  0xf8, 0xff, 0xff, 0x1f,
+--- tvision/include/tv/x11/screen.h.orig	2026-03-15 16:16:10.689895230 +0100
++++ tvision/include/tv/x11/screen.h	2026-03-15 16:16:29.659895230 +0100
+@@ -198,8 +198,8 @@
+  static char  dontResizeToCells;
+  // Busy cursor stuff
+  static Cursor busyCursor, leftPtr;
+- static char busyCursorMap[];
+- static char busyCursorMask[];
++ static unsigned char busyCursorMap[];
++ static unsigned char busyCursorMask[];
+  // For testing purposes should be removed
+  void LoadFontAsUnicode();
+  char *SearchX11Font(const char *foundry, const char *family, int w, int h);
diff --git a/perl-inc.patch b/perl-inc.patch
new file mode 100644
index 0000000..900b09c
--- /dev/null
+++ b/perl-inc.patch
@@ -0,0 +1,13 @@
+--- tvision/config.pl.orig	2009-03-22 00:00:00.000000000 +0100
++++ tvision/config.pl	2009-03-22 00:00:00.000000000 +0100
+@@ -5,8 +5,8 @@
+ # To specify the compilation flags define the CFLAGS environment variable.
+ #
+
+-require "miscperl.pl";
+-require "conflib.pl";
++require "./miscperl.pl";
++require "./conflib.pl";
+
+ # If the script is newer discard the cache.
+ #GetCache() unless (-M 'config.pl' < -M 'configure.cache');
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/librhtv.git/commitdiff/9636a50ab53e503e48c21cd1809741dc8767d812



More information about the pld-cvs-commit mailing list