diff options
Diffstat (limited to 'sys-apps/kbd/files/kbd-1.06-othervt.patch')
-rw-r--r-- | sys-apps/kbd/files/kbd-1.06-othervt.patch | 55 |
1 files changed, 55 insertions, 0 deletions
diff --git a/sys-apps/kbd/files/kbd-1.06-othervt.patch b/sys-apps/kbd/files/kbd-1.06-othervt.patch new file mode 100644 index 000000000000..5a4d69eaa7d0 --- /dev/null +++ b/sys-apps/kbd/files/kbd-1.06-othervt.patch @@ -0,0 +1,55 @@ +--- kbd-1.06/src/setfont.c.p4 Mon Feb 12 11:17:59 2001 ++++ kbd-1.06/src/setfont.c Wed Jul 18 18:06:38 2001 +@@ -84,6 +84,7 @@ + " setfont -{8|14|16} codepage.cp[.gz] Load 8x<N> font from codepage.cp\n" + "Explicitly (with -m or -u) or implicitly (in the fontfile) given mappings\n" + "will be loaded and, in the case of consolemaps, activated.\n" ++" --tty=device Use `device' as console device for ioctls.\n" + " -h<N> (no space) Override font height.\n" + " -m <fn> Load console screen map.\n" + " -u <fn> Load font unicode map.\n" +@@ -101,7 +101,7 @@ + int + main(int argc, char *argv[]) { + char *ifiles[MAXIFILES]; +- char *mfil, *ufil, *Ofil, *ofil, *omfil, *oufil; ++ char *mfil, *ufil, *Ofil, *ofil, *omfil, *oufil, *tty; + int ifilct = 0, fd, i, iunit, hwunit, no_m, no_u; + int restore = 0; + +@@ -111,9 +111,7 @@ + bindtextdomain(PACKAGE, LOCALEDIR); + textdomain(PACKAGE); + +- fd = getfd(); +- +- ifiles[0] = mfil = ufil = Ofil = ofil = omfil = oufil = 0; ++ ifiles[0] = mfil = ufil = Ofil = ofil = omfil = oufil = tty = NULL; + iunit = hwunit = 0; + no_m = no_u = 0; + +@@ -160,6 +158,8 @@ + hwunit = atoi(argv[i]+2); + if (hwunit <= 0 || hwunit > 32) + usage(); ++ } else if (!strncmp(argv[i], "--tty", 5)) { ++ tty = argv[i] + 6; + } else if (argv[i][0] == '-') { + iunit = atoi(argv[i]+1); + if(iunit <= 0 || iunit > 32) +@@ -171,6 +171,15 @@ + } + ifiles[ifilct++] = argv[i]; + } ++ } ++ ++ if (tty) { ++ if ((fd = open(tty, O_RDWR)) == -1) { ++ perror("open"); ++ exit(EX_OSERR); ++ } ++ } else { ++ fd = getfd(); + } + + if (ifilct && restore) { |