diff --git a/mknod.patch b/mknod.patch index a1a8362..f660b87 100644 --- a/mknod.patch +++ b/mknod.patch @@ -1,7 +1,7 @@ -Index: x3270-3.3/Examples/peer_script.bash +Index: x3270/Examples/peer_script.bash =================================================================== ---- x3270-3.3/Examples/peer_script.bash.orig -+++ x3270-3.3/Examples/peer_script.bash +--- x3270/Examples/peer_script.bash.orig ++++ x3270/Examples/peer_script.bash @@ -60,9 +60,9 @@ ip=/tmp/ip.$$ op=/tmp/op.$$ rm -f $ip $op @@ -15,10 +15,10 @@ Index: x3270-3.3/Examples/peer_script.bash # Start x3270 x3270 -script -model 2 <$ip >$op & -Index: x3270-3.3/Examples/peer_script.sh +Index: x3270/Examples/peer_script.sh =================================================================== ---- x3270-3.3/Examples/peer_script.sh.orig -+++ x3270-3.3/Examples/peer_script.sh +--- x3270/Examples/peer_script.sh.orig ++++ x3270/Examples/peer_script.sh @@ -59,9 +59,9 @@ ip=/tmp/ip.$$ op=/tmp/op.$$ rm -f $ip $op diff --git a/pr3270-memleak.patch b/pr3270-memleak.patch index aad8f45..b5f5d66 100644 --- a/pr3270-memleak.patch +++ b/pr3270-memleak.patch @@ -1,19 +1,15 @@ -Index: pr3287-3.3/telnet.c +Index: pr3287/telnet.c =================================================================== ---- pr3287-3.3/telnet.c.orig -+++ pr3287-3.3/telnet.c -@@ -453,8 +453,13 @@ negotiate(const char *host, struct socka - cstate != CONNECTED_3270 && /* TN3270 */ - cstate != NOT_CONNECTED) { /* gave up */ +--- pr3287/telnet.c.orig ++++ pr3287/telnet.c +@@ -434,6 +434,10 @@ pr_net_negotiate(const char *host, struc + cstate != NOT_CONNECTED) { /* gave up */ -- if (net_input(s) < 0) -+ if (net_input(s) < 0) { -+ Free(netrbuf); -+ Free(ibuf); -+ netrbuf = NULL; -+ ibuf = NULL; - return -1; -+ } + if (!net_input(s)) { ++ Free(netrbuf); ++ Free(ibuf); ++ netrbuf = NULL; ++ ibuf = NULL; + return false; } - - /* Success. */ + } diff --git a/suite3270-3.3.15ga8-src.tgz b/suite3270-3.3.15ga8-src.tgz deleted file mode 100644 index 16b899e..0000000 --- a/suite3270-3.3.15ga8-src.tgz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:85a29af6ba6cf77dc0d0dc47bf31bcaec35aff57c529924b632b3c5332a555ce -size 6967197 diff --git a/suite3270-3.4ga7-src.tgz b/suite3270-3.4ga7-src.tgz new file mode 100644 index 0000000..6f474c9 --- /dev/null +++ b/suite3270-3.4ga7-src.tgz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f21af93a611d80e2e50338e7831d368fd821ac67a6a292acb48366bbd98155d2 +size 3398617 diff --git a/usr_local_bin.patch b/usr_local_bin.patch index 332ca5d..4831678 100644 --- a/usr_local_bin.patch +++ b/usr_local_bin.patch @@ -1,19 +1,19 @@ GNU binaries live in /bin and /usr/bin in SuSE systems: -Index: x3270-3.3/Examples/peer_script.expect +Index: x3270/Examples/peer_script.expect =================================================================== ---- x3270-3.3/Examples/peer_script.expect.orig -+++ x3270-3.3/Examples/peer_script.expect +--- x3270/Examples/peer_script.expect.orig ++++ x3270/Examples/peer_script.expect @@ -1,4 +1,4 @@ -#! /usr/local/bin/expect +#! /usr/bin/expect # TSO login script, which runs as a peer of x3270. # expect version -Index: x3270-3.3/Examples/cms_logon.bash +Index: x3270/Examples/cms_logon.bash =================================================================== ---- x3270-3.3/Examples/cms_logon.bash.orig 2009-01-17 16:52:06.000000000 +0100 -+++ x3270-3.3/Examples/cms_logon.bash 2011-09-15 10:00:49.214331232 +0200 +--- x3270/Examples/cms_logon.bash.orig 2009-01-17 16:52:06.000000000 +0100 ++++ x3270/Examples/cms_logon.bash 2011-09-15 10:00:49.214331232 +0200 @@ -1,4 +1,4 @@ -#! /usr/local/bin/bash +#! /usr/bin/bash @@ -21,8 +21,8 @@ Index: x3270-3.3/Examples/cms_logon.bash # Copyright (c) 1995-2009, Paul Mattes. # All rights reserved. =================================================================== ---- tcl3270-3.3/Examples/cms_cmd.tcl3270 2011/09/15 08:15:35 1.1 -+++ tcl3270-3.3/Examples/cms_cmd.tcl3270 2011/09/15 08:15:45 +--- tcl3270/Examples/cms_cmd.tcl3270 2011/09/15 08:15:35 1.1 ++++ tcl3270/Examples/cms_cmd.tcl3270 2011/09/15 08:15:45 @@ -1,4 +1,4 @@ -#!tcl3270 +#!/usr/bin/tcl3270 diff --git a/x3270-missing-file.patch b/x3270-missing-file.patch new file mode 100644 index 0000000..2ea6439 --- /dev/null +++ b/x3270-missing-file.patch @@ -0,0 +1,255 @@ +Index: suite3270-3.4/x3270/qcpp.c +=================================================================== +--- /dev/null ++++ suite3270-3.4/x3270/qcpp.c +@@ -0,0 +1,250 @@ ++/* ++ * Copyright (c) 1997-2009, Paul Mattes. ++ * All rights reserved. ++ * ++ * Redistribution and use in source and binary forms, with or without ++ * modification, are permitted provided that the following conditions ++ * are met: ++ * * Redistributions of source code must retain the above copyright ++ * notice, this list of conditions and the following disclaimer. ++ * * Redistributions in binary form must reproduce the above copyright ++ * notice, this list of conditions and the following disclaimer in the ++ * documentation and/or other materials provided with the distribution. ++ * * Neither the name of Paul Mattes nor his contributors may be used ++ * to endorse or promote products derived from this software without ++ * specific prior written permission. ++ * ++ * THIS SOFTWARE IS PROVIDED BY PAUL MATTES "AS IS" AND ANY EXPRESS ++ * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED ++ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE ++ * DISCLAIMED. IN NO EVENT SHALL PAUL MATTES BE LIABLE FOR ANY DIRECT, ++ * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES ++ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR ++ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ++ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, ++ * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING ++ * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE ++ * POSSIBILITY OF SUCH DAMAGE. ++ */ ++ ++/* ++ * Quick C preprocessor substitute, for converting X3270.ad to X3270.ad. ++ * ++ * Understands a limited subset of #ifdef/#ifndef/#else/#endif syntax, and ++ * understands -Dsym or -Usym, but not -Dsym=xxx. ++ */ ++ ++#include ++#include ++#include ++#include ++ ++#define MAX_NEST 50 ++ ++char *me; ++int color = 0; ++ ++typedef struct sym { ++ struct sym *next; ++ char *name; ++ int sl; ++} sym_t; ++ ++sym_t *syms = NULL; ++ ++static int ++is_sym(char *name) ++{ ++ sym_t *s; ++ int sl; ++ ++ sl = strlen(name); ++ if (sl > 0 && name[sl - 1] == '\n') ++ sl--; ++ ++ for (s = syms; s != NULL; s = s->next) { ++ if (s->sl == sl && !strncmp(name, s->name, sl)) ++ return 1; ++ } ++ return 0; ++} ++ ++static void ++usage(void) ++{ ++ fprintf(stderr, "usage: %s [-v] [-Dname]... [-Uname]... " ++ "[infile [outfile]]\n", me); ++ exit(1); ++} ++ ++int ++main(int argc, char *argv[]) ++{ ++ int c; ++ char buf[1024]; ++ FILE *f, *t, *o; ++ int nest = 0; ++ int ln = 0; ++ int pass[MAX_NEST]; ++ int elsed[MAX_NEST]; ++ sym_t *s, *prev; ++ int verbose = 0; ++ ++ if ((me = strrchr(argv[0], '/')) != (char *)NULL) ++ me++; ++ else ++ me = argv[0]; ++ ++ while ((c = getopt(argc, argv, "D:U:v")) != -1) { ++ switch (c) { ++ case 'D': ++ if (!is_sym(optarg)) { ++ s = malloc(sizeof(sym_t) + strlen(optarg) + 1); ++ if (s == NULL) { ++ fprintf(stderr, "out of memory\n"); ++ exit(1); ++ } ++ s->name = (char *)(s + 1); ++ (void) strcpy(s->name, optarg); ++ s->sl = strlen(s->name); ++ s->next = syms; ++ syms = s; ++ if (verbose) ++ printf("defined %s\n", optarg); ++ } ++ break; ++ case 'U': ++ prev = NULL; ++ ++ for (s = syms; s != NULL; s = s->next) { ++ if (!strcmp(s->name, optarg)) { ++ if (prev != NULL) ++ prev->next = s->next; ++ else ++ syms = s->next; ++ free(s); ++ break; ++ } ++ prev = s; ++ } ++ break; ++ case 'v': ++ verbose = 1; ++ break; ++ default: ++ usage(); ++ break; ++ } ++ } ++ switch (argc - optind) { ++ case 0: ++ f = stdin; ++ break; ++ case 1: ++ case 2: ++ if (strcmp(argv[optind], "-")) { ++ f = fopen(argv[optind], "r"); ++ if (f == (FILE *)NULL) { ++ perror(argv[optind]); ++ exit(1); ++ } ++ } else ++ f = stdin; ++ break; ++ default: ++ usage(); ++ break; ++ } ++ ++ t = tmpfile(); ++ if (t == NULL) { ++ perror("tmpfile"); ++ exit(1); ++ } ++ ++ pass[nest] = 1; ++ ++ while (fgets(buf, sizeof(buf), f) != (char *)NULL) { ++ ln++; ++ if (buf[0] != '#') { ++ if (pass[nest]) ++ fprintf(t, "%s", buf); ++ continue; ++ } ++ if (!strncmp(buf, "#ifdef ", 7)) { ++ if (verbose) ++ printf("%d: #ifdef %s -> %d\n", ln, buf + 7, ++ is_sym(buf + 7)); ++ pass[nest+1] = pass[nest] && is_sym(buf + 7); ++ nest++; ++ elsed[nest] = 0; ++ } else if (!strncmp(buf, "#ifndef ", 8)) { ++ if (verbose) ++ printf("%d: #ifndef %s -> %d\n", ln, buf + 8, ++ !is_sym(buf + 8)); ++ pass[nest+1] = pass[nest] && !is_sym(buf + 8); ++ nest++; ++ elsed[nest] = 0; ++ } else if (!strcmp(buf, "#else\n")) { ++ if (!nest) { ++ fprintf(stderr, "line %d: #else without #if\n", ++ ln); ++ exit(1); ++ } ++ if (elsed[nest]) { ++ fprintf(stderr, "line %d: duplicate #else\n", ++ ln); ++ exit(1); ++ } ++ if (pass[nest]) ++ pass[nest] = 0; ++ else if (pass[nest-1]) ++ pass[nest] = 1; ++ elsed[nest] = 1; ++ } else if (!strcmp(buf, "#endif\n")) { ++ if (!nest) { ++ fprintf(stderr, "line %d: #endif without #if\n", ++ ln); ++ exit(1); ++ } ++ --nest; ++ } else { ++ fprintf(stderr, "line %d: unknown directive\n", ln); ++ exit(1); ++ } ++#if 0 ++ fprintf(t, "! line %d nest %d pass[nest] %d\n", ++ ln, nest, pass[nest]); ++#endif ++ } ++ if (nest > 0) { ++ fprintf(stderr, "missing #endif\n"); ++ exit(1); ++ } ++ ++ /* Close the input file, if there was one. */ ++ if (f != stdin) ++ fclose(f); ++ ++ /* Open the output file, if there is one. */ ++ if (argc - optind == 2) { ++ o = fopen(argv[optind + 1], "w"); ++ if (o == NULL) { ++ perror(argv[optind + 1]); ++ exit(1); ++ } ++ } else { ++ o = stdout; ++ } ++ ++ /* Copy the temp file to the output file. */ ++ rewind(t); ++ while (fgets(buf, sizeof(buf), t) != NULL) { ++ fprintf(o, "%s", buf); ++ } ++ fclose(t); ++ if (o != stdout) ++ fclose(o); ++ ++ return 0; ++} diff --git a/x3270-missing-include.patch b/x3270-missing-include.patch new file mode 100644 index 0000000..958954b --- /dev/null +++ b/x3270-missing-include.patch @@ -0,0 +1,12 @@ +Index: suite3270-3.4/x3270/x3270.c +=================================================================== +--- suite3270-3.4.orig/x3270/x3270.c ++++ suite3270-3.4/x3270/x3270.c +@@ -76,6 +76,7 @@ + #include "utils.h" + #include "xactions.h" + #include "xappres.h" ++#include "xglobals.h" + #include "xio.h" + #include "xkybd.h" + #include "xmenubar.h" diff --git a/x3270.changes b/x3270.changes index bbfc4ec..f37ca2a 100644 --- a/x3270.changes +++ b/x3270.changes @@ -1,3 +1,97 @@ +------------------------------------------------------------------- +Mon Sep 7 12:09:58 UTC 2015 - tchvatal@suse.com + +- Version bump to 3.4: + * Recreated tarball and build approach so adapt our system + * Fixed a number of warnings found by the MacOS C compiler, which turned out + to be real issues. + * [all] Synchronize the ReadBuffer action with the Wait(Output) action, just + like Ascii and Ebcdic. + * [all] Fixed an NVT-mode emulation problem. + * [all] Fixed a synchronization issue with scripts and file transfers. + * [c3270, wc3270] Fixed a crash when the Transfer action was called from a + script. + * [x3270] Fixed a crash when visible control characters are turned on in + 3278 mode. + * [pr3287] Changed the pr3287 Makefile to use $INSTALL_DATA (bugs:#13). + * [All Unix] Added -D_DEFAULT_SOURCE wherever a Makefile used -D_BSD_SOURCE, + to get rid of compiler warnings with newer versions of glibc (bugs:#12). + * [x3270, c3270, wc3270] Corrected the OIA display of save-to-printer pages. + * [c3270, wc3270] Made the help for file-transfer reflect the current + defaults. Added help for Keymap. + * [wc3270] Fixed the pager at the wc3270> prompt. Now it adapts to the size + of the console window correctly. + * [pr3287, wpr3287] Fixed a problem with printer session start-up when both + a specific printer LU and an SSL tunnel (L:) are specified. + * [c3270, wc3270] Added a Keymap action to add or remove temporary keymaps. + The semantics are the same as the x3270 action of the same name. + * [all] Made the parameter to ResumeScript optional, and relaxed the + restrictions on when PauseScript can be used, so it can now be used from + macros and command files read with the Source action. + * [c3270, wc3270] Allow the DFT buffer size to be changed in the c3270/wc3270 + file transfer dialog. + * [c3270, wc3270] Allow file transfers to be interrupted with Ctrl-C. + * [x3270] Fixed an issue where the terminal type would not be reported to the + host as IBM-DYNAMIC if the screen was put into oversize mode via a menu + selection (it was correct if oversize came from a resource). Also made sure + that the 'About->Configuration' display of the terminal type is always + correct. + * [all] Added resources to define the default values for each of the IND$FILE + file transfer parameters. The resources have the same names as the Transfer + action keywords, with ft prepended. E.g., the Mode default is controlled by + the ftMode resource. For consistency, deprecated dftBufferSize and + ftCodePage in favor of ftBufferSize and ftWindowsCodePage (the old + resources are still available). + * [all] Added missing functionality to specify the size for avblock TSO file + allocations in IND$FILE file transfers. + * [x3270] Added an aplCircledAlpha resource to allow x3270 to properly + display APL underscored uppercase letters with the APL385 font, by + translating them to the (nonstandard) Unicode circled-alphabetic range + U+24B6 to U+25CF. + * [x3270, c3270, wc3270] Overhauled visible control characters so that field + attributes are completely decoded. Field attributes are now in underlined + yellow in x3270. Added visible control character support to c3270 (also + underlined yellow) and wc3270 (reverse-video yellow), with a menu option. + * [all] Overhauled the build structure. Now there are libraries for common + functions. + * [wc3270] Mapped Alt-left-click onto a lightpen select operation. Added a + lightPenPrimary resource to switch this, so that an unmodified left-click + is a lightpen select and Alt-left-click is a cursor move or copy/paste + highlight. + * [all] Added a B: prefix option to hostnames to disable the automatic + keyboard unlock when a BIND-IMAGE is received. + * [all] Added an -nvt option and an nvtMode resource to force NVT mode as + soon as a session is connected. This overrides the usual behavior of + locking the keyboard and waiting for the host to send NVT-mode data or + negotiate 3270 mode before unlocking. This option also changes the default + terminal type to xterm. + * [c3270] Added a mapping from the Escape key to the Escape() action + (breaking to the c3270> prompt). + * [x3270] Added a maxRecent resource to control the maximum size of the + recent host list in the Connect menu. + * [all] Allow the -scriptport option to specify an address to listen on. + * [all] Added webserver support. The -httpd option starts a webserver + listening on the specified port. The webserver supports a REST API and + some basic HTML objects. + * [all] Removed configurability of tracing, NVT mode, TN3270E support, + scripting, menus file transfer, the x3270 pop-up keypad and printer + sessions (they're always enabled now). + * [x3270, wc3270] Added an overlayPaste toggle. When set, pasting over a + protected field will simply increment the cursor position instead of + locking the keyboard. This allows forms to be copied and pasted with the + protected fields included. Setting this toggle also implicitly sets the + marginedPaste toggle. + * [x3270] Changed the selection logic so that a rectangular selection + (the default for 3270 mode) never ends with a newline character. +- Refresh patches: + * mknod.patch + * pr3270-memleak.patch + * usr_local_bin.patch +- Add new patch to fix missing include: + * x3270-missing-include.patch +- Add new patch to fix missed file from tarball, taken from older version: + * x3270-missing-file.patch + ------------------------------------------------------------------- Sun Apr 26 19:23:56 UTC 2015 - crrodriguez@opensuse.org diff --git a/x3270.spec b/x3270.spec index eb2bbf4..4a4fb81 100644 --- a/x3270.spec +++ b/x3270.spec @@ -16,11 +16,11 @@ # -%define _suffix ga8 +%define _suffix ga7 %define _fullname suite3270-%{version}%{_suffix} %define _x026ver 1.2 Name: x3270 -Version: 3.3.15 +Version: 3.4 Release: 0 Summary: A Family of IBM 3270 Terminal Emulators License: MIT @@ -32,6 +32,8 @@ Patch0: mknod.patch Patch100: usr_local_bin.patch Patch102: x026-offset.diff Patch104: pr3270-memleak.patch +Patch105: x3270-missing-include.patch +Patch106: x3270-missing-file.patch BuildRequires: bdftopcf BuildRequires: fdupes BuildRequires: fontpackages-devel @@ -94,57 +96,33 @@ x026 is a fun toy which emulates an x026 puncher. # will also hold the common config.cache # -q uietly -c reate -name all3270 # -a fter changing into all3270, expand sources -%setup -q -c -n all3270 -T -a0 -a1 +%setup -q -n suite3270-%{version} -a1 %patch0 %patch100 %patch102 %patch104 +%patch105 -p1 +%patch106 -p1 %build export CFLAGS="%{optflags}" export LIBX3270DIR=%{_sysconfdir}/x3270 -# the tcl variant -cd tcl3270-3.3 - %configure \ - --cache-file=../config.cache \ - --enable-ssl - make %{?_smp_mflags} LIBX3270DIR=${LIBX3270DIR} -cd .. -# the X variant -cd x3270-3.3 - %configure \ - --cache-file=../config.cache \ - --enable-app-defaults \ - --x-includes=%{_includedir} \ - --x-libraries=%{_libdir} \ - --with-all-xinstall \ - --with-fontdir=%{_miscfontsdir} \ - --enable-ssl - xmkmf -a - make depend - make %{?_smp_mflags} LIBX3270DIR=${LIBX3270DIR} -cd .. -# the console variant -cd c3270-3.3 - %configure \ - --cache-file=../config.cache \ - --enable-ssl - make %{?_smp_mflags} LIBX3270DIR=${LIBX3270DIR} -cd .. -# the scripting variant -cd s3270-3.3 - %configure \ - --cache-file=../config.cache \ - --enable-ssl - make %{?_smp_mflags} LIBX3270DIR=${LIBX3270DIR} -cd .. -# the printer -cd pr3287-3.3 - %configure \ - --cache-file=../config.cache \ - --enable-ssl - make %{?_smp_mflags} LIBX3270DIR=${LIBX3270DIR} -cd .. +%configure \ + --disable-windows \ + --disable-windows-lib \ + --enable-lib \ + --enable-unix \ + --enable-ssl \ + --enable-app-defaults \ + --x-includes=%{_includedir} \ + --x-libraries=%{_libdir} \ + --with-all-xinstall \ + --with-iconv \ + --with-fontdir=%{_miscfontsdir} +# There is broken generated makefile +sed -i -e 's:$(FALLBACKS_:$(FALLBACKS):g' x3270/Makefile +make depend +make %{?_smp_mflags} LIBX3270DIR=${LIBX3270DIR} unix # the IBM 026 keypunch emulator cd x026-%{_x026ver} xmkmf @@ -155,45 +133,13 @@ cd .. export LIBX3270DIR=%{_sysconfdir}/x3270 # create the default directory structure in the build root mkdir --parents %{buildroot}{%{_bindir},%{_mandir}/{man1,man5}} -# the X variant -cd x3270-3.3 - chmod -x html/Keymap.html - make DESTDIR=%{buildroot} LIBX3270DIR=${LIBX3270DIR} install - make DESTDIR=%{buildroot} LIBX3270DIR=${LIBX3270DIR} install.man - # make install does a mkfontdir, that creates a fonts.dir we don't - # want in the package. remove that: - rm %{buildroot}%{_miscfontsdir}/fonts.dir - install -d -m 755 \ - %{buildroot}%{_datadir}/X11/app-defaults - install -m 644 X3270.xad \ - %{buildroot}%{_datadir}/X11/app-defaults/X3270 - # clean up: - # remove remainders of patching the examples, if existing - rm -v Examples/*.orig || true -cd .. -# the console variant -cd c3270-3.3 - make DESTDIR=%{buildroot} LIBX3270DIR=${LIBX3270DIR} install - make DESTDIR=%{buildroot} LIBX3270DIR=${LIBX3270DIR} install.man -cd .. -# the scripting variant -cd s3270-3.3 - make DESTDIR=%{buildroot} LIBX3270DIR=${LIBX3270DIR} install - make DESTDIR=%{buildroot} LIBX3270DIR=${LIBX3270DIR} install.man -cd .. -# the tcl variant -cd tcl3270-3.3 - make DESTDIR=%{buildroot} LIBX3270DIR=${LIBX3270DIR} install - make DESTDIR=%{buildroot} LIBX3270DIR=${LIBX3270DIR} install.man -cd .. -# the printer -cd pr3287-3.3 - make DESTDIR=%{buildroot} LIBX3270DIR=${LIBX3270DIR} install - make DESTDIR=%{buildroot} LIBX3270DIR=${LIBX3270DIR} install.man -cd .. +chmod -x x3270/html/Keymap.html +chmod -x s3270/Examples/cms_cmd.expect +make DESTDIR=%{buildroot} LIBX3270DIR=${LIBX3270DIR} install +make DESTDIR=%{buildroot} LIBX3270DIR=${LIBX3270DIR} install.man # the IBM 026 keypunch emulator cd x026-%{_x026ver} -make DESTDIR=%{buildroot} install install.man + make DESTDIR=%{buildroot} install install.man cd .. # move site config files to the standard locations mkdir -p %{buildroot}%{_libexecdir}/x3270 @@ -201,17 +147,25 @@ mkdir -p %{buildroot}%{_libexecdir}/x3270 chmod 644 %{buildroot}%{_sysconfdir}/x3270/ibm_hosts # set permissions correct chmod ugo-x %{buildroot}%{_mandir}/man{1,5}/* +# make install does a mkfontdir, that creates a fonts.dir we don't +# want in the package. remove that: +rm %{buildroot}%{_miscfontsdir}/fonts.dir +install -d -m 755 \ + %{buildroot}%{_datadir}/X11/app-defaults +install -m 644 x3270/X3270.ad \ + %{buildroot}%{_datadir}/X11/app-defaults/X3270 # copy the docs mkdir -p %{buildroot}%{_docdir}/%{name} cp -pr --parents Playback %{buildroot}%{_docdir}/%{name} -cp -pr --parents x3270-3.3/{Examples,html} %{buildroot}%{_docdir}/%{name} -cp -pr --parents c3270-3.3/html %{buildroot}%{_docdir}/%{name} -cp -pr --parents pr3287-3.3/html %{buildroot}%{_docdir}/%{name} -cp -pr --parents s3270-3.3/{Examples,html} %{buildroot}%{_docdir}/%{name} -cp -pr --parents tcl3270-3.3/{Examples,html} %{buildroot}%{_docdir}/%{name} +cp -pr --parents x3270/{Examples,html} %{buildroot}%{_docdir}/%{name} +cp -pr --parents c3270/html %{buildroot}%{_docdir}/%{name} +cp -pr --parents pr3287/html %{buildroot}%{_docdir}/%{name} +cp -pr --parents s3270/{Examples,html} %{buildroot}%{_docdir}/%{name} +cp -pr --parents tcl3270/{Examples,html} %{buildroot}%{_docdir}/%{name} # create symlinks in documentation %fdupes -s %{buildroot}/%{_docdir} + %{reconfigure_fonts_scriptlets} %files @@ -232,27 +186,27 @@ cp -pr --parents tcl3270-3.3/{Examples,html} %{buildroot}%{_docdir}/%{name} %dir %{_miscfontsdir} %{_miscfontsdir}/* %doc %{_mandir}/man1/x3270.1x.gz -%doc %{_docdir}/%{name}/x3270-3.3/Examples -%doc %{_docdir}/%{name}/x3270-3.3/html +%doc %{_docdir}/%{name}/x3270/Examples +%doc %{_docdir}/%{name}/x3270/html %doc %{_docdir}/%{name}/Playback # c3270 %{_bindir}/c3270 %doc %{_mandir}/man1/c3270.1.gz -%doc %{_docdir}/%{name}/c3270-3.3/html +%doc %{_docdir}/%{name}/c3270/html # pr3287 %{_bindir}/pr3287 %doc %{_mandir}/man1/pr3287.1.gz -%doc %{_docdir}/%{name}/pr3287-3.3/html +%doc %{_docdir}/%{name}/pr3287/html # s3270 %{_bindir}/s3270 %doc %{_mandir}/man1/s3270.1.gz -%doc %{_docdir}/%{name}/s3270-3.3/Examples -%doc %{_docdir}/%{name}/s3270-3.3/html +%doc %{_docdir}/%{name}/s3270/Examples +%doc %{_docdir}/%{name}/s3270/html # tcl3270 %{_bindir}/tcl3270 %doc %{_mandir}/man1/tcl3270.1.gz -%doc %{_docdir}/%{name}/tcl3270-3.3/Examples -%doc %{_docdir}/%{name}/tcl3270-3.3/html +%doc %{_docdir}/%{name}/tcl3270/Examples +%doc %{_docdir}/%{name}/tcl3270/html # x026 %{_bindir}/x026 %doc %{_mandir}/man1/x026.1x.gz