update minicom to 2.8

fixes -fno-common build
tested by Thaison Nguyen
This commit is contained in:
jsg 2021-02-06 13:03:49 +00:00
parent ec601a4350
commit 04465f980f
10 changed files with 58 additions and 50 deletions

View File

@ -1,11 +1,10 @@
# $OpenBSD: Makefile,v 1.67 2020/03/20 16:44:21 naddy Exp $
# $OpenBSD: Makefile,v 1.68 2021/02/06 13:03:49 jsg Exp $
COMMENT= MS-DOS Telix-like serial communication program
DISTNAME= minicom-2.7.1
REVISION= 3
DISTNAME= minicom-2.8
CATEGORIES= comms
MASTER_SITES= https://alioth-archive.debian.org/releases/minicom/Source/2.7.1/
MASTER_SITES= https://salsa.debian.org/minicom-team/minicom/-/archive/2.8/
HOMEPAGE= https://salsa.debian.org/minicom-team/minicom

View File

@ -1,2 +1,2 @@
SHA256 (minicom-2.7.1.tar.gz) = Uy+Da3pnfrDLHcqNcDArc3KcPTDfJtWDaNcS5cygQfE=
SIZE (minicom-2.7.1.tar.gz) = 875939
SHA256 (minicom-2.8.tar.gz) = no3ujn4fbWEV0OGVXaW4AeRLkSifaz4yCEKUlIjUsi8=
SIZE (minicom-2.8.tar.gz) = 948015

View File

@ -1,9 +1,9 @@
$OpenBSD: patch-man_minicom_1,v 1.6 2017/05/06 21:57:27 sthen Exp $
$OpenBSD: patch-man_minicom_1,v 1.7 2021/02/06 13:03:49 jsg Exp $
Index: man/minicom.1
--- man/minicom.1.orig
+++ man/minicom.1
@@ -842,7 +842,8 @@ $HOME/minicom.log
@@ -862,7 +862,8 @@ $HOME/minicom.log
/usr/share/locale/*/LC_MESSAGES/minicom.mo
.fi
.SH SEE ALSO

View File

@ -1,4 +1,4 @@
$OpenBSD: patch-src_main_c,v 1.7 2017/05/06 22:00:53 sthen Exp $
$OpenBSD: patch-src_main_c,v 1.8 2021/02/06 13:03:49 jsg Exp $
Index: src/main.c
--- src/main.c.orig
@ -13,7 +13,7 @@ Index: src/main.c
#include "port.h"
#include "minicom.h"
#include "intl.h"
@@ -333,6 +336,17 @@ nolock:
@@ -416,6 +419,17 @@ nolock:
/* Set CLOCAL mode */
m_nohang(portfd);
@ -31,7 +31,7 @@ Index: src/main.c
/* Set Hangup on Close if program crashes. (Hehe) */
m_hupcl(portfd, 1);
if (doinit > 0)
@@ -553,9 +567,10 @@ static void show_status_fmt(const char *fmt)
@@ -641,9 +655,10 @@ static void show_status_fmt(const char *fmt)
bufi += snprintf(buf + bufi, COLS - bufi, "%s",
P_HASDCD[0] == 'Y' ? _("Offline") : _("OFFLINE"));
else

View File

@ -0,0 +1,24 @@
$OpenBSD: patch-src_minicom_c,v 1.3 2021/02/06 13:03:49 jsg Exp $
Index: src/minicom.c
--- src/minicom.c.orig
+++ src/minicom.c
@@ -1107,6 +1107,7 @@ int main(int argc, char **argv)
char *remote_charset = NULL; /* Remote charset given on the command line via -R */
char pseudo[64];
/* char* console_encoding = getenv ("LC_CTYPE"); */
+ sigset_t set;
enum {
OPT_CAP_BUF_MODE = 256,
@@ -1544,7 +1545,9 @@ int main(int argc, char **argv)
#endif
/* On some Linux systems SIGALRM is masked by default. Unmask it */
- sigrelse(SIGALRM);
+ if (sigemptyset(&set) != -1 &&
+ sigaddset(&set, SIGALRM) != -1)
+ sigprocmask(SIG_UNBLOCK, &set, NULL);
keyboard(KINSTALL, 0);

View File

@ -1,16 +1,21 @@
$OpenBSD: patch-src_script_c,v 1.2 2017/05/06 21:57:27 sthen Exp $
$OpenBSD: patch-src_script_c,v 1.3 2021/02/06 13:03:49 jsg Exp $
Index: src/script.c
--- src/script.c.orig
+++ src/script.c
@@ -32,6 +32,10 @@
#include <config.h>
@@ -1089,11 +1089,14 @@ void do_args(int argc, char **argv)
int main(int argc, char **argv)
{
char *s;
+ sigset_t set;
#if 0 /* Shouldn't need this.. */
signal(SIGHUP, SIG_IGN);
#endif
/* On some Linux systems SIGALRM is masked by default. Unmask it */
- sigrelse(SIGALRM);
+ if (sigemptyset(&set) != -1 &&
+ sigaddset(&set, SIGALRM) != -1)
+ sigprocmask(SIG_UNBLOCK, &set, NULL);
+#ifdef HAVE_SYS_WAIT_H
+#include <sys/wait.h>
+#endif
+
#include <stdarg.h>
#include "port.h"
/* initialize locale support */
setlocale(LC_ALL, "");

View File

@ -1,9 +1,9 @@
$OpenBSD: patch-src_sysdep1_c,v 1.4 2017/05/06 21:57:27 sthen Exp $
$OpenBSD: patch-src_sysdep1_c,v 1.5 2021/02/06 13:03:49 jsg Exp $
Index: src/sysdep1.c
--- src/sysdep1.c.orig
+++ src/sysdep1.c
@@ -65,13 +65,13 @@ static void m_setrts(int fd)
@@ -66,13 +66,13 @@ static void m_setrts(int fd)
if (portfd_is_socket)
return;
#endif
@ -20,7 +20,7 @@ Index: src/sysdep1.c
}
#endif
}
@@ -180,11 +180,11 @@ int m_getdcd(int fd)
@@ -179,11 +179,11 @@ int m_getdcd(int fd)
return portfd_is_connected;
}
#endif
@ -34,7 +34,7 @@ Index: src/sysdep1.c
return -1;
return mcs & TIOCM_CAR ? 1 : 0;
}
@@ -227,8 +227,8 @@ void m_savestate(int fd)
@@ -226,8 +226,8 @@ void m_savestate(int fd)
ioctl(fd, TIOCLGET, &lsw);
# endif
#endif
@ -45,7 +45,7 @@ Index: src/sysdep1.c
#endif
}
@@ -252,8 +252,8 @@ void m_restorestate(int fd)
@@ -251,8 +251,8 @@ void m_restorestate(int fd)
ioctl(fd, TIOCLSET, &lsw);
# endif
#endif

View File

@ -1,4 +1,4 @@
$OpenBSD: patch-src_updown_c,v 1.6 2017/05/06 21:57:27 sthen Exp $
$OpenBSD: patch-src_updown_c,v 1.7 2021/02/06 13:03:49 jsg Exp $
Index: src/updown.c
--- src/updown.c.orig
@ -12,12 +12,3 @@ Index: src/updown.c
static int init = 0;
if (!init) {
@@ -298,7 +298,7 @@ void updown(int what, int nr)
do_log("%s", cmdline); /* jl 22.06.97 */
if (P_PFULL(g) == 'N') {
- win = mc_wopen(10, 7, 70, 13, BSINGLE, stdattr, mfcolor, mbcolor, 1, 0, 1);
+ win = mc_wopen(5, 5, 74, 11, BSINGLE, stdattr, mfcolor, mbcolor, 1, 0, 1);
snprintf(title, sizeof(title), _("%.30s %s - Press CTRL-C to quit"), P_PNAME(g),
what == 'U' ? _("upload") : _("download"));
mc_wtitle(win, TMID, title);

View File

@ -1,13 +0,0 @@
$OpenBSD: patch-src_windiv_c,v 1.5 2017/05/06 21:57:27 sthen Exp $
Index: src/windiv.c
--- src/windiv.c.orig
+++ src/windiv.c
@@ -20,6 +20,7 @@
#include <config.h>
#endif
+#include <sys/types.h>
#include <dirent.h>
#include <sys/stat.h>
#include "port.h"

View File

@ -1,4 +1,4 @@
@comment $OpenBSD: PLIST,v 1.18 2012/03/19 22:17:43 sthen Exp $
@comment $OpenBSD: PLIST,v 1.19 2021/02/06 13:03:49 jsg Exp $
@bin bin/ascii-xfr
@bin bin/minicom
@bin bin/runscript
@ -77,7 +77,9 @@ share/locale/ru/LC_MESSAGES/minicom.mo
share/locale/rw/
share/locale/rw/LC_MESSAGES/
share/locale/rw/LC_MESSAGES/minicom.mo
share/locale/sr/LC_MESSAGES/minicom.mo
share/locale/sv/LC_MESSAGES/minicom.mo
share/locale/vi/LC_MESSAGES/minicom.mo
share/locale/zh_CN/LC_MESSAGES/minicom.mo
share/locale/zh_TW/LC_MESSAGES/minicom.mo
@extraunexec rm -rf ${SYSCONFDIR}/minicom/*