Gentoo Archives: gentoo-commits

From: Maciej Mrozowski <reavertm@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-libs/libmspack/files/
Date: Fri, 03 Nov 2017 01:05:05
Message-Id: 1509671089.df1387eae217481b44a32fd9fe04919def2099f3.reavertm@gentoo
1 commit: df1387eae217481b44a32fd9fe04919def2099f3
2 Author: Maciej Mrozowski <reavertm <AT> gentoo <DOT> org>
3 AuthorDate: Fri Nov 3 01:04:02 2017 +0000
4 Commit: Maciej Mrozowski <reavertm <AT> gentoo <DOT> org>
5 CommitDate: Fri Nov 3 01:04:49 2017 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=df1387ea
7
8 dev-libs/libmspack: Fix "Fix tests" patch, bug 636110
9
10 Package-Manager: Portage-2.3.8, Repoman-2.3.4
11
12 .../files/libmspack-0.6_alpha-fix-tests.patch | 86 +---------------------
13 1 file changed, 2 insertions(+), 84 deletions(-)
14
15 diff --git a/dev-libs/libmspack/files/libmspack-0.6_alpha-fix-tests.patch b/dev-libs/libmspack/files/libmspack-0.6_alpha-fix-tests.patch
16 index 2f010d87a37..22b0461ae7e 100644
17 --- a/dev-libs/libmspack/files/libmspack-0.6_alpha-fix-tests.patch
18 +++ b/dev-libs/libmspack/files/libmspack-0.6_alpha-fix-tests.patch
19 @@ -1,36 +1,7 @@
20 -From deb65056f436a4ce06946c4dde270f533e3cab4d Mon Sep 17 00:00:00 2001
21 -From: Stuart Caie <kyzer@××××××××××××××.uk>
22 -Date: Mon, 16 Oct 2017 13:59:05 +0100
23 -Subject: [PATCH] Fix cabd_test.c test and msdecompile_md5 script
24 -
25 ----
26 - libmspack/ChangeLog | 10 +++++++++
27 - libmspack/test/cabd_test.c | 3 ++-
28 - libmspack/test/msdecompile_md5 | 47 +++++++++++++++++++++---------------------
29 - 3 files changed, 36 insertions(+), 24 deletions(-)
30 -
31 -diff --git a/libmspack/ChangeLog b/libmspack/ChangeLog
32 -index 6861b19..4aef85f 100644
33 ---- a/libmspack/ChangeLog
34 -+++ b/libmspack/ChangeLog
35 -@@ -1,3 +1,13 @@
36 -+2017-10-16 Stuart Caie <kyzer@××××××××××××××.uk>
37 -+
38 -+ * test/cabd_test.c: update the short string tests to expect not only
39 -+ MSPACK_ERR_DATAFORMAT but also MSPACK_ERR_READ, because of the recent
40 -+ change to cabd_read_string(). Thanks to maitreyee43 for spotting this.
41 -+
42 -+ * test/msdecompile_md5: update the setup instructions for this script,
43 -+ and also change the script so it works with current Wine. Again, thanks
44 -+ to maitreyee43 for trying to use it and finding it not working.
45 -+
46 - 2017-08-13 Stuart Caie <kyzer@××××××××××××××.uk>
47 -
48 - * src/chmextract.c: support MinGW one-arg mkdir(). Thanks to AntumDeluge
49 diff --git a/libmspack/test/cabd_test.c b/libmspack/test/cabd_test.c
50 index 5e8851c..abed65c 100644
51 ---- a/libmspack/test/cabd_test.c
52 -+++ b/libmspack/test/cabd_test.c
53 +--- a/test/cabd_test.c
54 ++++ b/test/cabd_test.c
55 @@ -186,7 +186,8 @@ void cabd_open_test_05() {
56 for (i = 0; i < (sizeof(str_files)/sizeof(char *)); i++) {
57 cab = cabd->open(cabd, str_files[i]);
58 @@ -41,56 +12,3 @@ index 5e8851c..abed65c 100644
59 }
60
61 /* lack of data blocks should NOT be a problem for merely reading */
62 -diff --git a/libmspack/test/msdecompile_md5 b/libmspack/test/msdecompile_md5
63 -index a1d3b4b..9efbfac 100755
64 ---- a/libmspack/test/msdecompile_md5
65 -+++ b/libmspack/test/msdecompile_md5
66 -@@ -1,24 +1,25 @@
67 --#!/usr/bin/perl -w
68 --# put hh.exe, hhctrl.ocx and itss.dll into this directory
69 --# for this script to work. You can get them by downloading
70 --# the HTML Help Workshop from Microsoft and then doing:
71 --# $ cabextract -F 'hh*' htmlhelp.exe
72 --# $ cabextract -F itircl.dll hhupd.exe
73 --# $ cabextract -F itss.dll hhupd.exe
74 --# $ cp -a itircl.dll ~/.wine/drive_c/windows/system32/
75 --# $ cp -a itss.dll ~/.wine/drive_c/windows/system32/
76 --# $ wine regsvr32 /s 'C:\WINDOWS\SYSTEM32\itircl.dll'
77 --# $ wine regsvr32 /s 'C:\WINDOWS\SYSTEM32\itss.dll'
78 -+#!/bin/sh
79 -+# This script needs the following setup to work:
80 -+# - hh.exe and hhctrl.ocx copied to Wine's system32
81 -+# - itss.dll and itircl.dll installed as Wine DLLs
82 -+#
83 -+# Download the HTML Help Workshop (htmlhelp.exe) from Microsoft:
84 -+#
85 -+# https://msdn.microsoft.com/en-us/library/windows/desktop/ms669985(v=vs.85).aspx
86 -+#
87 -+# and then run these commands:
88 -+#
89 -+# cabextract htmlhelp.exe -F hhupd.exe
90 -+# cabextract hhupd.exe -F hh.exe
91 -+# cabextract hhupd.exe -F hhctrl.ocx
92 -+# cabextract hhupd.exe -F itircl.dll
93 -+# cabextract hhupd.exe -F itss.dll
94 -+# mv hh.exe hhctrl.ocx itircl.dll itss.dll ~/.wine/drive_c/windows/system32/
95 -+# wine regsvr32 /s 'c:\windows\system32\itircl.dll'
96 -+# wine regsvr32 /s 'c:\windows\system32\itss.dll'
97 -
98 --use strict;
99 --use File::Temp qw(tempdir);
100 --
101 --die "Usage: $0 <file.chm>\n" unless @ARGV == 1;
102 --my $hh = $0; $hh =~ s{[^/]+$}{hh.exe};
103 --my $dir = tempdir("./.tempXXXX", CLEANUP => 1);
104 --
105 --$ENV{LANG} = 'C';
106 --$ENV{WINEDLLOVERRIDES}='hhctrl.ocx,itss=n';
107 --print "*** $ARGV[0]\n";
108 --system("wine $hh -decompile $dir $ARGV[0] 1>&2 && " .
109 -- "cd $dir && find * -type f -print0 | xargs -0 md5sum");
110 -+dir=`mktemp -d`
111 -+echo "*** $1"
112 -+LANG=C WINEDLLOVERRIDES='hhctrl.ocx=n' wine hh -decompile $dir "$1"
113 -+cd $dir && find * -type f -exec md5sum {} +
114 -+rm -rf $dir