Skip to content

Commit

Permalink
x11/x3270: Update to 4.3ga4 and fix -CURRENT kcmp collision
Browse files Browse the repository at this point in the history
  • Loading branch information
kev009 committed Feb 12, 2024
1 parent 1d66f2f commit 573c1a0
Show file tree
Hide file tree
Showing 5 changed files with 73 additions and 7 deletions.
7 changes: 3 additions & 4 deletions x11/x3270/Makefile
@@ -1,9 +1,8 @@
PORTNAME?= x3270
PORTVERSION= 4.2
PORTREVISION= 2
PORTVERSION= 4.3
CATEGORIES?= x11 net
MASTER_SITES= http://x3270.bgp.nu/download/04.02/
DISTFILES= suite3270-${PORTVERSION}ga10-src.tgz
MASTER_SITES= http://x3270.bgp.nu/download/04.03/
DISTFILES= suite3270-${PORTVERSION}ga4-src.tgz

MAINTAINER= kbowling@FreeBSD.org
COMMENT?= 3270 Terminal emulator
Expand Down
6 changes: 3 additions & 3 deletions x11/x3270/distinfo
@@ -1,3 +1,3 @@
TIMESTAMP = 1685990899
SHA256 (suite3270-4.2ga10-src.tgz) = db513225f074144a5a0221d57ede37cca1468c2c2d158ea09981f50012ebdbe7
SIZE (suite3270-4.2ga10-src.tgz) = 12739495
TIMESTAMP = 1707720825
SHA256 (suite3270-4.3ga4-src.tgz) = 3b7bf11de9a05a5f203cb845bd8e7fb805c2a06ca606ccf8cdee4ff5c80caa4b
SIZE (suite3270-4.3ga4-src.tgz) = 13163509
47 changes: 47 additions & 0 deletions x11/x3270/files/patch-Common_c3270_keymap.c
@@ -0,0 +1,47 @@
--- Common/c3270/keymap.c.orig 2024-02-12 06:58:07 UTC
+++ Common/c3270/keymap.c
@@ -111,7 +111,7 @@ static int
* Returns 0 if equal, nonzero if not.
*/
static int
-kcmp(k_t *a, k_t *b)
+kcmp3270(k_t *a, k_t *b)
{
if (a->key && b->key && (a->key == b->key)) {
return 0;
@@ -139,7 +139,7 @@ kvcmp(k_t *a, k_t *b, int len)
int i;

for (i = 0; i < len; i++) {
- if (kcmp(&a[i], &b[i]))
+ if (kcmp3270(&a[i], &b[i]))
return 1;
}
return 0;
@@ -673,7 +673,7 @@ lookup_key(int kcode, ucs4_t ucs4, int modifiers)
for (k = master_keymap; k != NULL; k = k->next) {
if (IS_INACTIVE(k))
continue;
- if (!kcmp(&code, &k->codes[0])) {
+ if (!kcmp3270(&code, &k->codes[0])) {
if (k->ncodes == 1) {
shortest = k;
break;
@@ -693,7 +693,7 @@ lookup_key(int kcode, ucs4_t ucs4, int modifiers)
}

/* See if this character matches the next one we want. */
- if (!kcmp(&code, &current_match->codes[consumed])) {
+ if (!kcmp3270(&code, &current_match->codes[consumed])) {
consumed++;
if (consumed == current_match->ncodes) {
/* Final match. */
@@ -721,7 +721,7 @@ lookup_key(int kcode, ucs4_t ucs4, int modifiers)
continue;
}
if (k->ncodes > consumed && !codecmp(k, current_match, consumed) &&
- !kcmp(&k->codes[consumed], &code)) {
+ !kcmp3270(&k->codes[consumed], &code)) {
consumed++;
if (k->ncodes == consumed) {
j = ambiguous(k, consumed);
19 changes: 19 additions & 0 deletions x11/x3270/files/patch-pr3287_Makefile.obj.in
@@ -0,0 +1,19 @@
--- pr3287/Makefile.obj.in.orig 2024-02-12 07:06:47 UTC
+++ pr3287/Makefile.obj.in
@@ -45,6 +45,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
LIBS = @LIBS@
INSTALL = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_DATA = @INSTALL_DATA@

HOST = @host@
@@ -70,7 +71,7 @@ install: pr3287 prtodir
[ -d $(DESTDIR)$(BINDIR) ] || \
mkdir -p $(DESTDIR)$(BINDIR)
$(INSTALL_PROGRAM) pr3287 $(DESTDIR)$(BINDIR)/pr3287
- $(INSTALL_PROGRAM) prtodir $(DESTDIR)$(BINDIR)/prtodir
+ $(INSTALL_SCRIPT) prtodir $(DESTDIR)$(BINDIR)/prtodir

install.man: man
[ -d $(DESTDIR)$(MANDIR)/man1 ] || \
1 change: 1 addition & 0 deletions x11/x3270/pkg-plist
@@ -1,6 +1,7 @@
bin/b3270
bin/c3270
bin/pr3287
bin/prtodir
bin/s3270
bin/tcl3270
%%X3270%%bin/x3270
Expand Down

0 comments on commit 573c1a0

Please sign in to comment.