From 9c76b4119e8bea06cbb3a99d79e699f8f2c8391eaa538ded2ee7bc6bde807aff Mon Sep 17 00:00:00 2001 From: Marcus Meissner Date: Sat, 11 Dec 2010 11:57:51 +0000 Subject: [PATCH] - Updated to 1.3.9 development snapshot - Beginnings of support for ActiveX in built-in browser. - Icons on Internet shortcut menu entries. - Standardization of code implementing COM interfaces. - New scheme for auto-generated DLL registrations. - OpenCL library wrapper. - Translation updates. - Various bug fixes. - Updated to 1.3.8 development snapshot - Icons in the "open with" menus. - Man pages for all installed binaries. - Support for schemas in MSXML. - Many installer fixes. - Translation updates. - Various bug fixes. - updated winetricks to 20101106 - updated wisotool to 20101106 - Updated to 1.3.7 development snapshot - Improved system tray support. - Better support for installers with assemblies. - Many of the msvcrt "secure" functions implemented. - A lot of fixes to the GStreamer support. - Many MSXML improvements. - Translation updates. - Various bug fixes. OBS-URL: https://build.opensuse.org/package/show/Emulators/wine?expand=0&rev=74 --- susepatches.patch | 317 +-- wine-1.3.3.tar.bz2 | 3 - wine-1.3.9.tar.bz2 | 3 + wine.changes | 94 + wine.spec | 7 +- winetricks | 965 ++++++--- wisotool | 4842 +++++++++++++++++++++++++++++++++----------- 7 files changed, 4465 insertions(+), 1766 deletions(-) delete mode 100644 wine-1.3.3.tar.bz2 create mode 100644 wine-1.3.9.tar.bz2 diff --git a/susepatches.patch b/susepatches.patch index 96a6f75..a9b8b92 100644 --- a/susepatches.patch +++ b/susepatches.patch @@ -1,320 +1,5 @@ -diff --git a/dlls/crypt32/str.c b/dlls/crypt32/str.c -index 914ccaa..6d0fb5b 100644 ---- a/dlls/crypt32/str.c -+++ b/dlls/crypt32/str.c -@@ -190,6 +190,7 @@ DWORD WINAPI CertNameToStrA(DWORD dwCertEncodingType, PCERT_NAME_BLOB pName, - static const char crlfSep[] = "\r\n"; - static const char plusSep[] = " + "; - static const char spaceSep[] = " "; -+ static const char quoteSep[] = "\""; - DWORD ret = 0, bytes = 0; - BOOL bRet; - CERT_NAME_INFO *info; -@@ -204,7 +205,7 @@ DWORD WINAPI CertNameToStrA(DWORD dwCertEncodingType, PCERT_NAME_BLOB pName, - if (bRet) - { - DWORD i, j, sepLen, rdnSepLen; -- LPCSTR sep, rdnSep; -+ LPCSTR sep, rdnSep, quote; - BOOL reverse = dwStrType & CERT_NAME_STR_REVERSE_FLAG; - const CERT_RDN *rdn = info->rgRDN; - -@@ -222,11 +223,16 @@ DWORD WINAPI CertNameToStrA(DWORD dwCertEncodingType, PCERT_NAME_BLOB pName, - else - rdnSep = plusSep; - rdnSepLen = strlen(rdnSep); -+ if (dwStrType & CERT_NAME_STR_NO_QUOTING_FLAG) -+ quote = NULL; -+ else -+ quote = quoteSep; - for (i = 0; (!psz || ret < csz) && i < info->cRDN; i++) - { - for (j = 0; (!psz || ret < csz) && j < rdn->cRDNAttr; j++) - { - DWORD chars; -+ int needquote = 0; - char prefixBuf[10]; /* big enough for GivenName */ - LPCSTR prefix = NULL; - -@@ -255,13 +261,44 @@ DWORD WINAPI CertNameToStrA(DWORD dwCertEncodingType, PCERT_NAME_BLOB pName, - psz ? psz + ret : NULL, psz ? csz - ret - 1 : 0); - ret += chars; - } -- /* FIXME: handle quoting */ -+ /* FIXME: quoting still misses " (which is replaced by "") */ - chars = CertRDNValueToStrA( - rdn->rgRDNAttr[j].dwValueType, - &rdn->rgRDNAttr[j].Value, psz ? psz + ret : NULL, - psz ? csz - ret : 0); -- if (chars) -+ -+ /* poor mans memmem(), for , seperation */ -+ if (psz && quote && chars) { -+ int xx; -+ for (xx=0;xxrgRDNAttr[j].dwValueType, -+ &rdn->rgRDNAttr[j].Value, psz ? psz + ret : NULL, -+ psz ? csz - ret : 0); - ret += chars - 1; -+ if (psz && ret < csz - strlen(quote) - 1) -+ memcpy (psz + ret, quote, strlen(quote)); -+ ret += strlen(quote); -+ } else { -+ if (chars) -+ ret += chars - 1; -+ } -+ -+ /* FIXME: handle quoting */ - if (j < rdn->cRDNAttr - 1) - { - if (psz && ret < csz - rdnSepLen - 1) -@@ -353,6 +390,7 @@ DWORD cert_name_to_str_with_indent(DWORD dwCertEncodingType, DWORD indentLevel, - static const WCHAR crlfSep[] = { '\r','\n',0 }; - static const WCHAR plusSep[] = { ' ','+',' ',0 }; - static const WCHAR spaceSep[] = { ' ',0 }; -+ static const WCHAR quoteSep[] = { '"',0 }; - DWORD ret = 0, bytes = 0; - BOOL bRet; - CERT_NAME_INFO *info; -@@ -365,7 +403,7 @@ DWORD cert_name_to_str_with_indent(DWORD dwCertEncodingType, DWORD indentLevel, - if (bRet) - { - DWORD i, j, sepLen, rdnSepLen; -- LPCWSTR sep, rdnSep; -+ LPCWSTR sep, rdnSep, quote; - BOOL reverse = dwStrType & CERT_NAME_STR_REVERSE_FLAG; - const CERT_RDN *rdn = info->rgRDN; - -@@ -383,11 +421,16 @@ DWORD cert_name_to_str_with_indent(DWORD dwCertEncodingType, DWORD indentLevel, - else - rdnSep = plusSep; - rdnSepLen = lstrlenW(rdnSep); -+ if (dwStrType & CERT_NAME_STR_NO_QUOTING_FLAG) -+ quote = NULL; -+ else -+ quote = quoteSep; - for (i = 0; (!psz || ret < csz) && i < info->cRDN; i++) - { - for (j = 0; (!psz || ret < csz) && j < rdn->cRDNAttr; j++) - { - DWORD chars; -+ int needquote = 0; - LPCSTR prefixA = NULL; - LPCWSTR prefixW = NULL; - -@@ -435,13 +478,43 @@ DWORD cert_name_to_str_with_indent(DWORD dwCertEncodingType, DWORD indentLevel, - psz ? psz + ret : NULL, psz ? csz - ret - 1 : 0); - ret += chars; - } -- /* FIXME: handle quoting */ -+ /* FIXME: quoting still misses " (which is replaced by "") */ - chars = CertRDNValueToStrW( - rdn->rgRDNAttr[j].dwValueType, - &rdn->rgRDNAttr[j].Value, psz ? psz + ret : NULL, - psz ? csz - ret : 0); -- if (chars) -+ -+ /* poor mans memmem(), for , seperation */ -+ if (psz && quote && chars) { -+ int xx; -+ for (xx=0;xxrgRDNAttr[j].dwValueType, -+ &rdn->rgRDNAttr[j].Value, psz ? psz + ret : NULL, -+ psz ? csz - ret : 0); - ret += chars - 1; -+ if (psz && ret < csz - lstrlenW(quote) - 1) -+ memcpy (psz + ret, quote, lstrlenW(quote) * sizeof(WCHAR)); -+ ret += lstrlenW(quote); -+ } else { -+ if (chars) -+ ret += chars - 1; -+ } -+ - if (j < rdn->cRDNAttr - 1) - { - if (psz && ret < csz - rdnSepLen - 1) -diff --git a/dlls/crypt32/tests/str.c b/dlls/crypt32/tests/str.c -index ebc3342..2549bcc 100644 ---- a/dlls/crypt32/tests/str.c -+++ b/dlls/crypt32/tests/str.c -@@ -67,12 +67,12 @@ static const BYTE cert[] = - 0x73,0x6f,0x74,0x61,0x31,0x14,0x30,0x12,0x6,0x3,0x55,0x4,0x7,0x13,0xb,0x4d, - 0x69,0x6e,0x6e,0x65,0x61,0x70,0x6f,0x6c,0x69,0x73,0x31,0x14,0x30,0x12,0x6,0x3, - 0x55,0x4,0xa,0x13,0xb,0x43,0x6f,0x64,0x65,0x57,0x65,0x61,0x76,0x65,0x72,0x73, -- 0x31,0x19,0x30,0x17,0x6,0x3,0x55,0x4,0xb,0x13,0x10,0x57,0x69,0x6e,0x65,0x20, -+ 0x31,0x19,0x30,0x17,0x6,0x3,0x55,0x4,0xb,0x13,0x10,0x57,0x69,0x6e,0x65,0x2c, - 0x44,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74,0x31,0x12,0x30,0x10, - 0x6,0x3,0x55,0x4,0x3,0x13,0x9,0x6c,0x6f,0x63,0x61,0x6c,0x68,0x6f,0x73,0x74, - 0x31,0x23,0x30,0x21,0x6,0x9,0x2a,0x86,0x48,0x86,0xf7,0xd,0x1,0x9,0x1,0x16, - 0x14,0x61,0x72,0x69,0x63,0x40,0x63,0x6f,0x64,0x65,0x77,0x65,0x61,0x76,0x65, -- 0x72,0x73,0x2e,0x63,0x6f,0x6d,0x30,0x1e,0x17,0xd,0x30,0x36,0x30,0x31,0x32, -+ 0x72,0x73,0x3b,0x63,0x6f,0x6d,0x30,0x1e,0x17,0xd,0x30,0x36,0x30,0x31,0x32, - 0x35,0x31,0x33,0x35,0x37,0x32,0x34,0x5a,0x17,0xd,0x30,0x36,0x30,0x32,0x32, - 0x34,0x31,0x33,0x35,0x37,0x32,0x34,0x5a,0x30,0x81,0xa1,0x31,0xb,0x30,0x9,0x6, - 0x3,0x55,0x4,0x6,0x13,0x2,0x55,0x53,0x31,0x12,0x30,0x10,0x6,0x3,0x55,0x4,0x8, -@@ -80,11 +80,11 @@ static const BYTE cert[] = - 0x3,0x55,0x4,0x7,0x13,0xb,0x4d,0x69,0x6e,0x6e,0x65,0x61,0x70,0x6f,0x6c,0x69, - 0x73,0x31,0x14,0x30,0x12,0x6,0x3,0x55,0x4,0xa,0x13,0xb,0x43,0x6f,0x64,0x65, - 0x57,0x65,0x61,0x76,0x65,0x72,0x73,0x31,0x19,0x30,0x17,0x6,0x3,0x55,0x4,0xb, -- 0x13,0x10,0x57,0x69,0x6e,0x65,0x20,0x44,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d, -+ 0x13,0x10,0x57,0x69,0x6e,0x65,0x2c,0x44,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d, - 0x65,0x6e,0x74,0x31,0x12,0x30,0x10,0x6,0x3,0x55,0x4,0x3,0x13,0x9,0x6c,0x6f, - 0x63,0x61,0x6c,0x68,0x6f,0x73,0x74,0x31,0x23,0x30,0x21,0x6,0x9,0x2a,0x86,0x48, - 0x86,0xf7,0xd,0x1,0x9,0x1,0x16,0x14,0x61,0x72,0x69,0x63,0x40,0x63,0x6f,0x64, -- 0x65,0x77,0x65,0x61,0x76,0x65,0x72,0x73,0x2e,0x63,0x6f,0x6d,0x30,0x81,0x9f, -+ 0x65,0x77,0x65,0x61,0x76,0x65,0x72,0x73,0x3b,0x63,0x6f,0x6d,0x30,0x81,0x9f, - 0x30,0xd,0x6,0x9,0x2a,0x86,0x48,0x86,0xf7,0xd,0x1,0x1,0x1,0x5,0x0,0x3,0x81, - 0x8d,0x0,0x30,0x81,0x89,0x2,0x81,0x81,0x0,0x9b,0xb5,0x8f,0xaf,0xfb,0x9a,0xaf, - 0xdc,0xa2,0x4d,0xb1,0xc8,0x72,0x44,0xef,0x79,0x7f,0x28,0xb6,0xfe,0x50,0xdc, -@@ -107,71 +107,71 @@ static const BYTE cert[] = - 0x91,0x8a,0xf8,0x5,0xef,0x5b,0x3b,0x49,0xbf,0x5f,0x2b}; - - static char issuerStr[] = -- "US, Minnesota, Minneapolis, CodeWeavers, Wine Development, localhost, aric@codeweavers.com"; -+ "US, Minnesota, Minneapolis, CodeWeavers, \"Wine,Development\", localhost, \"aric@codeweavers;com\""; - static char issuerStrSemicolon[] = -- "US; Minnesota; Minneapolis; CodeWeavers; Wine Development; localhost; aric@codeweavers.com"; -+ "US; Minnesota; Minneapolis; CodeWeavers; \"Wine,Development\"; localhost; \"aric@codeweavers;com\""; - static char issuerStrCRLF[] = -- "US\r\nMinnesota\r\nMinneapolis\r\nCodeWeavers\r\nWine Development\r\nlocalhost\r\naric@codeweavers.com"; -+ "US\r\nMinnesota\r\nMinneapolis\r\nCodeWeavers\r\n\"Wine,Development\"\r\nlocalhost\r\n\"aric@codeweavers;com\""; - static char subjectStr[] = -- "2.5.4.6=US, 2.5.4.8=Minnesota, 2.5.4.7=Minneapolis, 2.5.4.10=CodeWeavers, 2.5.4.11=Wine Development, 2.5.4.3=localhost, 1.2.840.113549.1.9.1=aric@codeweavers.com"; -+ "2.5.4.6=US, 2.5.4.8=Minnesota, 2.5.4.7=Minneapolis, 2.5.4.10=CodeWeavers, 2.5.4.11=\"Wine,Development\", 2.5.4.3=localhost, 1.2.840.113549.1.9.1=\"aric@codeweavers;com\""; - static char subjectStrSemicolon[] = -- "2.5.4.6=US; 2.5.4.8=Minnesota; 2.5.4.7=Minneapolis; 2.5.4.10=CodeWeavers; 2.5.4.11=Wine Development; 2.5.4.3=localhost; 1.2.840.113549.1.9.1=aric@codeweavers.com"; -+ "2.5.4.6=US; 2.5.4.8=Minnesota; 2.5.4.7=Minneapolis; 2.5.4.10=CodeWeavers; 2.5.4.11=\"Wine,Development\"; 2.5.4.3=localhost; 1.2.840.113549.1.9.1=\"aric@codeweavers;com\""; - static char subjectStrCRLF[] = -- "2.5.4.6=US\r\n2.5.4.8=Minnesota\r\n2.5.4.7=Minneapolis\r\n2.5.4.10=CodeWeavers\r\n2.5.4.11=Wine Development\r\n2.5.4.3=localhost\r\n1.2.840.113549.1.9.1=aric@codeweavers.com"; --static char x500SubjectStr[] = "C=US, S=Minnesota, L=Minneapolis, O=CodeWeavers, OU=Wine Development, CN=localhost, E=aric@codeweavers.com"; --static char x500SubjectStrSemicolonReverse[] = "E=aric@codeweavers.com; CN=localhost; OU=Wine Development; O=CodeWeavers; L=Minneapolis; S=Minnesota; C=US"; -+ "2.5.4.6=US\r\n2.5.4.8=Minnesota\r\n2.5.4.7=Minneapolis\r\n2.5.4.10=CodeWeavers\r\n2.5.4.11=\"Wine,Development\"\r\n2.5.4.3=localhost\r\n1.2.840.113549.1.9.1=\"aric@codeweavers;com\""; -+static char x500SubjectStr[] = "C=US, S=Minnesota, L=Minneapolis, O=CodeWeavers, OU=\"Wine,Development\", CN=localhost, E=\"aric@codeweavers;com\""; -+static char x500SubjectStrSemicolonReverse[] = "E=\"aric@codeweavers;com\"; CN=localhost; OU=\"Wine,Development\"; O=CodeWeavers; L=Minneapolis; S=Minnesota; C=US"; - static WCHAR issuerStrW[] = { - 'U','S',',',' ','M','i','n','n','e','s','o','t','a',',',' ','M','i','n','n', - 'e','a','p','o','l','i','s',',',' ','C','o','d','e','W','e','a','v','e','r', -- 's',',',' ','W','i','n','e',' ','D','e','v','e','l','o','p','m','e','n','t', -- ',',' ','l','o','c','a','l','h','o','s','t',',',' ','a','r','i','c','@','c', -- 'o','d','e','w','e','a','v','e','r','s','.','c','o','m',0 }; -+ 's',',',' ','"','W','i','n','e',',','D','e','v','e','l','o','p','m','e','n','t','"', -+ ',',' ','l','o','c','a','l','h','o','s','t',',',' ','"','a','r','i','c','@','c', -+ 'o','d','e','w','e','a','v','e','r','s',';','c','o','m','"',0 }; - static WCHAR issuerStrSemicolonW[] = { - 'U','S',';',' ','M','i','n','n','e','s','o','t','a',';',' ','M','i','n','n', - 'e','a','p','o','l','i','s',';',' ','C','o','d','e','W','e','a','v','e','r', -- 's',';',' ','W','i','n','e',' ','D','e','v','e','l','o','p','m','e','n','t', -- ';',' ','l','o','c','a','l','h','o','s','t',';',' ','a','r','i','c','@','c', -- 'o','d','e','w','e','a','v','e','r','s','.','c','o','m',0 }; -+ 's',';',' ','"','W','i','n','e',',','D','e','v','e','l','o','p','m','e','n','t','"', -+ ';',' ','l','o','c','a','l','h','o','s','t',';',' ','"','a','r','i','c','@','c', -+ 'o','d','e','w','e','a','v','e','r','s',';','c','o','m','"',0 }; - static WCHAR issuerStrCRLFW[] = { - 'U','S','\r','\n','M','i','n','n','e','s','o','t','a','\r','\n','M','i','n', - 'n','e','a','p','o','l','i','s','\r','\n','C','o','d','e','W','e','a','v','e', -- 'r','s','\r','\n','W','i','n','e',' ','D','e','v','e','l','o','p','m','e','n', -- 't','\r','\n','l','o','c','a','l','h','o','s','t','\r','\n','a','r','i','c', -- '@','c','o','d','e','w','e','a','v','e','r','s','.','c','o','m',0 }; -+ 'r','s','\r','\n','"','W','i','n','e',',','D','e','v','e','l','o','p','m','e','n', -+ 't','"','\r','\n','l','o','c','a','l','h','o','s','t','\r','\n','"','a','r','i','c', -+ '@','c','o','d','e','w','e','a','v','e','r','s',';','c','o','m','"',0 }; - static WCHAR subjectStrW[] = { - '2','.','5','.','4','.','6','=','U','S',',',' ','2','.','5','.','4','.','8', - '=','M','i','n','n','e','s','o','t','a',',',' ','2','.','5','.','4','.','7', - '=','M','i','n','n','e','a','p','o','l','i','s',',',' ','2','.','5','.','4', - '.','1','0','=','C','o','d','e','W','e','a','v','e','r','s',',',' ','2','.', -- '5','.','4','.','1','1','=','W','i','n','e',' ','D','e','v','e','l','o','p', -- 'm','e','n','t',',',' ','2','.','5','.','4','.','3','=','l','o','c','a','l', -+ '5','.','4','.','1','1','=','"','W','i','n','e',',','D','e','v','e','l','o','p', -+ 'm','e','n','t','"',',',' ','2','.','5','.','4','.','3','=','l','o','c','a','l', - 'h','o','s','t',',',' ','1','.','2','.','8','4','0','.','1','1','3','5','4', -- '9','.','1','.','9','.','1','=','a','r','i','c','@','c','o','d','e','w','e', -- 'a','v','e','r','s','.','c','o','m',0 }; -+ '9','.','1','.','9','.','1','=','"','a','r','i','c','@','c','o','d','e','w','e', -+ 'a','v','e','r','s',';','c','o','m','"',0 }; - static WCHAR subjectStrSemicolonW[] = { - '2','.','5','.','4','.','6','=','U','S',';',' ','2','.','5','.','4','.','8', - '=','M','i','n','n','e','s','o','t','a',';',' ','2','.','5','.','4','.','7', - '=','M','i','n','n','e','a','p','o','l','i','s',';',' ','2','.','5','.','4', - '.','1','0','=','C','o','d','e','W','e','a','v','e','r','s',';',' ','2','.', -- '5','.','4','.','1','1','=','W','i','n','e',' ','D','e','v','e','l','o','p', -- 'm','e','n','t',';',' ','2','.','5','.','4','.','3','=','l','o','c','a','l', -+ '5','.','4','.','1','1','=','"','W','i','n','e',',','D','e','v','e','l','o','p', -+ 'm','e','n','t','"',';',' ','2','.','5','.','4','.','3','=','l','o','c','a','l', - 'h','o','s','t',';',' ','1','.','2','.','8','4','0','.','1','1','3','5','4', -- '9','.','1','.','9','.','1','=','a','r','i','c','@','c','o','d','e','w','e', -- 'a','v','e','r','s','.','c','o','m',0 }; -+ '9','.','1','.','9','.','1','=','"','a','r','i','c','@','c','o','d','e','w','e', -+ 'a','v','e','r','s',';','c','o','m','"',0 }; - static WCHAR subjectStrCRLFW[] = { - '2','.','5','.','4','.','6','=','U','S','\r','\n','2','.','5','.','4','.','8', - '=','M','i','n','n','e','s','o','t','a','\r','\n','2','.','5','.','4','.','7', - '=','M','i','n','n','e','a','p','o','l','i','s','\r','\n','2','.','5','.','4', - '.','1','0','=','C','o','d','e','W','e','a','v','e','r','s','\r','\n','2','.', -- '5','.','4','.','1','1','=','W','i','n','e',' ','D','e','v','e','l','o','p', -- 'm','e','n','t','\r','\n','2','.','5','.','4','.','3','=','l','o','c','a','l', -+ '5','.','4','.','1','1','=','"','W','i','n','e',',','D','e','v','e','l','o','p', -+ 'm','e','n','t','"','\r','\n','2','.','5','.','4','.','3','=','l','o','c','a','l', - 'h','o','s','t','\r','\n','1','.','2','.','8','4','0','.','1','1','3','5','4', -- '9','.','1','.','9','.','1','=','a','r','i','c','@','c','o','d','e','w','e', -- 'a','v','e','r','s','.','c','o','m',0 }; -+ '9','.','1','.','9','.','1','=','"','a','r','i','c','@','c','o','d','e','w','e', -+ 'a','v','e','r','s',';','c','o','m','"',0 }; - static WCHAR x500SubjectStrSemicolonReverseW[] = { -- 'E','=','a','r','i','c','@','c','o','d','e','w','e','a','v','e','r','s','.','c', -- 'o','m',';',' ','C','N','=','l','o','c','a','l','h','o','s','t',';',' ','O','U', -- '=','W','i','n','e',' ','D','e','v','e','l','o','p','m','e','n','t',';',' ','O', -+ 'E','=','"','a','r','i','c','@','c','o','d','e','w','e','a','v','e','r','s',';','c', -+ 'o','m','"',';',' ','C','N','=','l','o','c','a','l','h','o','s','t',';',' ','O','U', -+ '=','"','W','i','n','e',',','D','e','v','e','l','o','p','m','e','n','t','"',';',' ','O', - '=','C','o','d','e','W','e','a','v','e','r','s',';',' ','L','=','M','i','n','n', - 'e','a','p','o','l','i','s',';',' ','S','=','M','i','n','n','e','s','o','t','a', - ';',' ','C','=','U','S',0 }; -@@ -399,11 +399,8 @@ static void test_NameToStrConversionW(PCERT_NAME_BLOB pName, DWORD dwStrType, - sizeof(buffer) / sizeof(buffer[0])); - ok(i == lstrlenW(expected) + 1, "Expected %d chars, got %d\n", - lstrlenW(expected) + 1, i); -- ok(!lstrcmpW(buffer, expected), "Unexpected value\n"); --#ifdef DUMP_STRINGS -- trace("Expected %s, got %s\n", -+ ok(!lstrcmpW(buffer, expected), "Expected %s, got %s\n", - wine_dbgstr_w(expected), wine_dbgstr_w(buffer)); --#endif - } - - static void test_CertNameToStrW(void) diff --git a/dlls/shell32/pidl.c b/dlls/shell32/pidl.c -index 1c9cf22..054683c 100644 +index 266c444..fd28488 100644 --- a/dlls/shell32/pidl.c +++ b/dlls/shell32/pidl.c @@ -1753,13 +1753,13 @@ LPITEMIDLIST _ILCreateEntireNetwork(void) diff --git a/wine-1.3.3.tar.bz2 b/wine-1.3.3.tar.bz2 deleted file mode 100644 index e97451a..0000000 --- a/wine-1.3.3.tar.bz2 +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:8ca08a6e13b9a4a7c2643e5b12ff873360ba4e96187851c169a57365edb7a9e1 -size 18043897 diff --git a/wine-1.3.9.tar.bz2 b/wine-1.3.9.tar.bz2 new file mode 100644 index 0000000..f425a95 --- /dev/null +++ b/wine-1.3.9.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8858f7fe2df6114c2f26d4493b5c9c031634d056cef4fb6ae2e9c843e8e6d276 +size 18378590 diff --git a/wine.changes b/wine.changes index b3b2687..69ba179 100644 --- a/wine.changes +++ b/wine.changes @@ -1,15 +1,109 @@ +------------------------------------------------------------------- +Sat Dec 11 09:30:57 CET 2010 - meissner@suse.de + +- Updated to 1.3.9 development snapshot + - Beginnings of support for ActiveX in built-in browser. + - Icons on Internet shortcut menu entries. + - Standardization of code implementing COM interfaces. + - New scheme for auto-generated DLL registrations. + - OpenCL library wrapper. + - Translation updates. + - Various bug fixes. + +------------------------------------------------------------------- +Sat Nov 27 08:34:15 UTC 2010 - meissner@novell.com + +- Updated to 1.3.8 development snapshot + - Icons in the "open with" menus. + - Man pages for all installed binaries. + - Support for schemas in MSXML. + - Many installer fixes. + - Translation updates. + - Various bug fixes. + +------------------------------------------------------------------- +Sun Nov 21 14:42:05 CET 2010 - meissner@suse.de + +- updated winetricks to 20101106 +- updated wisotool to 20101106 + +------------------------------------------------------------------- +Sat Nov 13 18:27:25 UTC 2010 - meissner@novell.com + +- Updated to 1.3.7 development snapshot + - Improved system tray support. + - Better support for installers with assemblies. + - Many of the msvcrt "secure" functions implemented. + - A lot of fixes to the GStreamer support. + - Many MSXML improvements. + - Translation updates. + - Various bug fixes. + +------------------------------------------------------------------- +Fri Oct 29 23:55:15 CEST 2010 - meissner@suse.de + +- Updated to 1.3.6 development snapshot + - Support for GStreamer filters. + - Mapping of standard cursors to native desktop cursors. + - Improved support for installers with services. + - Many MSXML improvements. + - Decoder for TGA-format images. + - Translation updates. + - Various bug fixes. + ------------------------------------------------------------------- Tue Oct 26 11:22:15 CEST 2010 - meissner@suse.de - nodisplay=true in the .desktop file, so you can click on .exes again bnc#625365 +------------------------------------------------------------------- +Tue Oct 26 11:20:16 CEST 2010 - meissner@suse.de + +- fixed wine.desktop + +------------------------------------------------------------------- +Sun Oct 24 15:23:52 CEST 2010 - meissner@suse.de + +- add gstreamer-0_10-devel + +------------------------------------------------------------------- +Fri Oct 15 21:07:20 UTC 2010 - meissner@novell.com + +- Updated to 1.3.5 development snapshot + - Support for animated cursors. + - Printing directly through CUPS instead of lpr. + - Installer fixes for Office 2010. + - Many MSXML3 improvements. + - Improved Shader Model 4 support. + - Proper icons in built-in Internet Explorer. + - Translation updates. + - Various bug fixes. + +------------------------------------------------------------------- +Thu Oct 14 13:45:30 CEST 2010 - meissner@suse.de + +- fixed the icons for the menu entries + ------------------------------------------------------------------- Sat Oct 9 11:51:11 CEST 2010 - meissner@suse.de - explicitly filter -fomit-frame-pointer as it breaks some copy protections or hooks in Steam. +------------------------------------------------------------------- +Fri Oct 1 22:03:47 CEST 2010 - meissner@suse.de + +- Updated to 1.3.4 development snapshot + - Support for right-to-left mirrored windows. + - Winelib now supports the ARM platform. + - New taskkill.exe built-in application. + - Inetcpl control panel fleshed out. + - AcceptEx is implemented now. + - Improved security checks for SSL connections. + - Translation updates. + - Various bug fixes. + ------------------------------------------------------------------- Mon Sep 20 13:11:42 CEST 2010 - meissner@suse.de diff --git a/wine.spec b/wine.spec index 17d812b..9cdc5ab 100644 --- a/wine.spec +++ b/wine.spec @@ -18,16 +18,19 @@ Name: wine -BuildRequires: alsa-devel bison capi4linux-devel cups-devel desktop-file-utils fdupes flex freeglut-devel freetype2-devel giflib-devel gnutls-devel hal-devel libgphoto2-devel libgsm-devel libjpeg-devel liblcms-devel libpng-devel libtiff-devel libv4l-devel libxslt-devel ncurses-devel openal-soft-devel openldap2-devel prelink update-desktop-files +BuildRequires: alsa-devel bison capi4linux-devel cups-devel desktop-file-utils fdupes flex freeglut-devel freetype2-devel giflib-devel gnutls-devel hal-devel libgphoto2-devel libgsm-devel libjpeg-devel liblcms-devel libpng-devel libtiff-devel libv4l-devel libxslt-devel ncurses-devel openal-soft-devel openldap2-devel prelink update-desktop-files valgrind-devel %if 0%{?suse_version} > 1130 BuildRequires: sane-backends-devel %else BuildRequires: sane-backends %endif +%if 0%{?suse_version} > 1130 +BuildRequires: gstreamer-0_10-plugins-base-devel +%endif License: LGPLv2.1+ Group: System/Emulators/PC AutoReqProv: on -Version: 1.3.3 +Version: 1.3.9 Release: 1 Summary: An MS Windows Emulator Url: http://www.winehq.com diff --git a/winetricks b/winetricks index 4ec6082..15ac9cd 100644 --- a/winetricks +++ b/winetricks @@ -20,81 +20,7 @@ #---- Constants ------------------------------------------------- # Name of this version of winetricks (YYYYMMDD) -VERSION=20100917 - -early_wine() -{ - WINEDLLOVERRIDES=mshtml= $WINE "$@" -} - -# Default values for important settings if not already in environment. -# These settings should not need editing here. -case "$OS" in - "Windows_NT") - # Cheezy fix for getting rid of double slashes when running cygwin in wine - case $HOME in - /) HOME="" ;; - esac - WINE="" - WINEPREFIX=${WINEPREFIX:-$HOME/.wine} - DRIVE_C="C:/" - XXXPATH=cygpath - ;; - *) - WINE=${WINE:-wine} - WINEPREFIX=${WINEPREFIX:-$HOME/.wine} - DRIVE_C="$WINEPREFIX/dosdevices/c:" - XXXPATH="early_wine winepath" - ;; -esac - -# Decide where to store downloaded files -if test ! "$WINETRICKS_CACHE" -a -d $HOME/.winetrickscache -then - # For backwards compatibility - WINETRICKS_CACHE="$HOME/.winetrickscache" -else - # See http://standards.freedesktop.org/basedir-spec/latest/ar01s03.html - XDG_CACHE_HOME=${XDG_CACHE_HOME:-$HOME/.cache} - WINETRICKS_CACHE="${WINETRICKS_CACHE:-$XDG_CACHE_HOME/winetricks}" -fi -test -d "$WINETRICKS_CACHE" || mkdir -p "$WINETRICKS_CACHE" - -# Internal variables; these locations are not too important -WINETRICKS_CACHE_WIN="`$XXXPATH -w $WINETRICKS_CACHE | tr '\012' ' ' | sed 's/ $//'`" -WINETRICKS_TMP="$DRIVE_C"/winetrickstmp -WINETRICKS_TMP_WIN='c:\winetrickstmp' -mkdir -p $WINETRICKS_TMP - -# Handle case where z: doesn't exist -case "$WINETRICKS_CACHE_WIN" in -""|*\?\\unix*) - # WINETRICKS_CACHE isn't accessible via a drive letter mapping, so make one, - # but be sure to clean it up later. - for letter in y x w v u t s r q - do - if ! test -d "$WINEPREFIX"/dosdevices/${letter}: - then - WINETRICKS_CACHE_SYMLINK="$WINEPREFIX"/dosdevices/${letter}: - ln -sf "$WINETRICKS_CACHE" "$WINETRICKS_CACHE_SYMLINK" - break - fi - done - ;; -esac - -# Overridden for windows -ISO_MOUNT_ROOT=/mnt/winetricks - -WINDIR="$DRIVE_C/windows" - -# Which sourceforge mirror to use. Rotate based on time, since -# their mirror picker sometimes persistantly sends you to a broken -# mirror. -case `date +%S` in -*[23]) SOURCEFORGE=http://easynews.dl.sourceforge.net/sourceforge ;; -*) SOURCEFORGE=http://downloads.sourceforge.net;; -esac +VERSION=20101106 #---- Functions ------------------------------------------------- @@ -184,9 +110,11 @@ usage() { echo "Packages:" echo " 7zip 7-zip file archiver" echo " adobeair Adobe AIR runtime" + echo " amstream MS amstream.dll" echo " art2kmin MS Access 2007 runtime" echo " atmlib Adobe Type Manager. Needed for Adobe CS4" echo " autohotkey Autohotkey (open source gui scripting language)" + echo " baekmuk Baekmuk Korean fonts" echo " cmake CMake, the cross-platform, open-source build system" echo " colorprofile Standard RGB color profile" echo " comctl32 MS common controls 5.80" @@ -197,12 +125,16 @@ usage() { echo " crypt32 MS crypt32.dl" echo " cygwin Unix apps for Windows (needed by some build scripts)" echo " d3dx9 MS d3dx9_??.dll (from DirectX 9 user redistributable)" + echo " d3dx9_26 MS d3dx9_26.dll" echo " d3dx9_28 MS d3dx9_28.dll" + echo " d3dx9_31 MS d3dx9_31.dll" + echo " d3dx9_35 MS d3dx9_35.dll" echo " d3dx9_36 MS d3dx9_36.dll" + echo " d3dx9_42 MS d3dx9_42.dll" echo " d3dx10 MS d3dx10_??.dll (from DirectX user redistributable)" echo " d3dxof MS d3dxof.dll (from DirectX user redistributable)" echo " dcom98 MS DCOM (ole32, oleaut32); requires Windows 98 license, but does not check for one" - echo " devenum MS devenum.dll (from DirectX 9 user redistributable)" + echo " devenum MS devenum.dll (from DirectX 9 user redistributable)" echo " dinput8 MS dinput8.dll (from DirectX 9 user redistributable)" echo " dirac the Dirac directshow filter" echo " directmusic MS DirectMusic (from DirectX 9 user redistributable)" @@ -210,6 +142,7 @@ usage() { echo " directx9 MS DirectX 9 user redistributable (not recommended! use d3dx9 instead)" echo " directx9-beta MS DirectX 9 user redistributable - beta verb (not recommended! use d3dx9 instead)" echo " divx divx video codec" + echo " dmsynth MS dmsynth.dll (midi sythesizer from DirectX 9 user redistributable)" echo " dotnet11 MS .NET 1.1 (requires Windows license, but does not check for one)" # Doesn't work yet, don't make it public # echo " dotnet11sdk MS .NET Framework SDK Version 1.1 (requires Windows license, but does not check for one; may not work yet)" @@ -219,9 +152,13 @@ usage() { echo " dotnet20sp2 MS .NET 2.0 sp2 (requires Windows license, but does not check for one)" echo " dotnet30 MS .NET 3.0 (requires Windows license, but does not check for one, might not work yet)" echo " droid Droid fonts (on LCD, looks better with fontsmooth-rgb)" + echo " dsound MS dsound.dll (from DirectX 9 user redistributable)" echo " dxsdk_nov2006 DirectX Software Development Kit, November 2006 version" echo " eadm EA Download Manager" echo " eufonts Updated fonts for Romanian and Bulgarian" + echo " fakechinese Creates aliases for Chinese fonts using WenQuanYi fonts" + echo " fakejapanese Creates aliases for Japanese fonts using Takao fonts" + echo " fakekorean Creates aliases for Korean fonts using Baekmuk fonts" echo " ffdshow ffdshow video codecs" echo " firefox Firefox web browser" echo " flash Adobe Flash Player ActiveX and firefox plugins" @@ -238,10 +175,12 @@ usage() { echo " glut The glut utility library" echo " hosts Adds empty C:\windows\system32\drivers\etc\{hosts,services} files" echo " ie6 Microsoft Internet Explorer 6.0" + echo " ie6_full Microsoft Internet Explorer 6.0, full installer" echo " ie7 Microsoft Internet Explorer 7.0" echo " ie8 Microsoft Internet Explorer 8.0" echo " jet40 MS Jet 4.0 Service Pack 8" echo " kde KDE for Windows installer" + echo " l3codecx MPEG Layer-3 Audio Codec for Microsoft DirectShow" echo " liberation Red Hat Liberation fonts (Sans, Serif, Mono)" echo " lucida MS Lucida Console font" echo " mdac25 MS MDAC 2.5: Microsoft ODBC drivers, etc." @@ -275,14 +214,17 @@ usage() { echo " python-comtypes Python 0.6.1-1 comtypes package" echo " quartz quartz.dll (from Directx 9 user redistributable)" echo " quicktime72 Apple Quicktime 7.2" + echo " quicktime76 Apple Quicktime 7.6" echo " riched20 MS RichEdit Control, riched20 and riched32" echo " riched30 MS RichEdit Control, riched30" echo " richtx32 MS Rich TextBox Control 6.0" - echo " safari Apple Safari web browser" + echo " safari Apple Safari web browser" echo " secur32 MS secur32" echo " shockwave Adobe Shockwave Player" echo " steam Steam Client App from Valve" echo " tahoma MS Tahoma font (not part of corefonts)" + echo " takao Takao Japanese fonts" + echo " unifont Unifont alternative to Arial Unicode MS" echo " urlmon MS urlmon.dll" echo " usp10 MS usp10.dll (Uniscribe)" echo " utorrent uTorrent" @@ -315,12 +257,14 @@ usage() { echo " wsh56 MS Windows Scripting Host 5.6" echo " wsh56vb MS Windows scripting 5.6, vbscript only, no cscript" echo " xact MS XACT Engine (x3daudio?_?.dll, xactengine?_?.dll)" + echo " xinput MS XInput (Xbox controller support, xinput?_?.dll)" echo " xvid xvid video codec" echo "Pseudopackages:" echo " alldlls=builtin Force use of builtin dlls (even if loaded with absolute path) (except for msvcp80 and d3dx9_*)" echo " alldlls=default Remove all DLL overrides" - echo " allfonts All listed fonts (corefonts, droid, eufonts, liberation, lucida, tahoma, wenquanyi)" + echo " allfonts All listed fonts and aliases (corefonts, droid, eufonts, liberation, lucida, tahoma, cjkfonts)" echo " allcodecs All listed codecs (xvid, ffdshow)" + echo " cjkfonts All Chinese, Japanese, Korean fonts and aliases (fakechinese, fakejapanese, fakekorean, unifont)" echo " ddr=gdi Set DirectDrawRenderer to GDI (default)" echo " ddr=opengl Set DirectDrawRenderer to OpenGL" echo " dsoundbug9612 Use DirectSound MaxShadowSize=0 workaround for bug #9612" @@ -335,7 +279,6 @@ usage() { echo " nocrashdialog Disable the graphical crash dialog" echo " orm=backbuffer Registry tweak: OffscreenRenderingMode=backbuffer" echo " orm=fbo Registry tweak: OffscreenRenderingMode=fbo (default)" - echo " orm=pbuffer Registry tweak: OffscreenRenderingMode=pbuffer" echo " rtlm=auto Set RenderTargetLockMode to auto (default)" echo " rtlm=disabled Set RenderTargetLockMode to disabled" echo " rtlm=readdraw Set RenderTargetLockMode to readdraw" @@ -354,6 +297,8 @@ usage() { echo " strictdrawordering=enabled Enable StrictDrawOrdering (default)" echo " strictdrawordering=disabled Disable StrictDrawOrdering" echo " nt40 Set windows version to nt40" + echo " vd=off Disable virtual desktop" + echo " vd=1024x768 Enable virtual desktop, set size to 1024x768" echo " win98 Set windows version to Windows 98" echo " win2k Set windows version to Windows 2000" echo " winxp Set windows version to Windows XP" @@ -370,7 +315,6 @@ usage() { echo " vsm-hard Set VertexShaderMode to hardware" } - #---------------------------------------------------------------- # Trivial GUI just to handle case where user tries running without commandline @@ -419,7 +363,7 @@ showmenu() case $MENU in zenity) echo "zenity --title 'Winetricks' --text 'Select packages to install' --list --checklist --column '' --column Package --column Description --height 440 --width 600 \\" > "$WINETRICKS_TMP"/zenity.sh - usage | grep '^ [0-9a-z]' | sed 's/^ \([^ ]*\) *\(.*\)/FALSE "\1" '"'\2'/" | sed 's/$/ \\/' >> $WINETRICKS_TMP/zenity.sh + usage | grep '^ [0-9a-z]' | sed 's/^ \([^ ]*\) *\(.*\)/FALSE "\1" '"'\2'/" | sed 's/$/ \\/' >> "$WINETRICKS_TMP"/zenity.sh todo="`sh "$WINETRICKS_TMP"/zenity.sh | tr '|' ' '`" ;; kdialog) @@ -440,6 +384,99 @@ showmenu() #----- Helpers ------------------------------------------------ +GUI=0 +case x"$1" in +x) GUI=1 ;; +x-h|x--help|xhelp) usage ; exit 1 ;; +x-V|x--version|xversion) echo "Winetricks version $VERSION. (C) 2007-2010 Dan Kegel et al. LGPL." ; exit 0;; +esac + +early_wine() +{ + WINEDLLOVERRIDES=mshtml= $WINE "$@" +} + +# Default values for important settings if not already in environment. +# These settings should not need editing here. +case "$OS" in + "Windows_NT") + # Cheezy fix for getting rid of double slashes when running cygwin in wine + case $HOME in + /) HOME="" ;; + esac + WINE="" + WINEPREFIX=${WINEPREFIX:-$HOME/.wine} + DRIVE_C="C:/" + XXXPATH=cygpath + ;; + *) + WINE=${WINE:-wine} + WINEPREFIX=${WINEPREFIX:-$HOME/.wine} + DRIVE_C="$WINEPREFIX/dosdevices/c:" + XXXPATH="early_wine winepath" + ;; +esac + +WINDIR="$DRIVE_C/windows" + +# Win(e) 32/64? +# Using the variable SYSTEM32_DLLS instead of SYSTEM32 because some stuff does go under system32 for both arch's +# e.g., spool/drivers/color +if test -d "$DRIVE_C/windows/syswow64" +then + ARCH=win64 + SYSTEM32_DLLS="$WINDIR/syswow64" +else + ARCH=win32 + SYSTEM32_DLLS="$WINDIR/system32" +fi + +# Decide where to store downloaded files +if test ! "$WINETRICKS_CACHE" -a -d $HOME/.winetrickscache +then + # For backwards compatibility + WINETRICKS_CACHE="$HOME/.winetrickscache" +else + # See http://standards.freedesktop.org/basedir-spec/latest/ar01s03.html + XDG_CACHE_HOME=${XDG_CACHE_HOME:-$HOME/.cache} + WINETRICKS_CACHE="${WINETRICKS_CACHE:-$XDG_CACHE_HOME/winetricks}" +fi +test -d "$WINETRICKS_CACHE" || mkdir -p "$WINETRICKS_CACHE" + +# Internal variables; these locations are not too important +WINETRICKS_CACHE_WIN="`$XXXPATH -w $WINETRICKS_CACHE | tr '\012' ' ' | sed 's/ $//'`" +WINETRICKS_TMP="$DRIVE_C"/winetrickstmp +WINETRICKS_TMP_WIN='c:\winetrickstmp' +mkdir -p "$WINETRICKS_TMP" + +# Handle case where z: doesn't exist +case "$WINETRICKS_CACHE_WIN" in +""|*\?\\unix*) + # WINETRICKS_CACHE isn't accessible via a drive letter mapping, so make one, + # but be sure to clean it up later. + for letter in y x w v u t s r q + do + if ! test -d "$WINEPREFIX"/dosdevices/${letter}: + then + WINETRICKS_CACHE_SYMLINK="$WINEPREFIX"/dosdevices/${letter}: + ln -sf "$WINETRICKS_CACHE" "$WINETRICKS_CACHE_SYMLINK" + break + fi + done + ;; +esac + +# Overridden for windows +ISO_MOUNT_ROOT=/mnt/winetricks + +# Which sourceforge mirror to use. Rotate based on time, since +# their mirror picker sometimes persistantly sends you to a broken +# mirror. +case `date +%S` in +*[23]) SOURCEFORGE=http://easynews.dl.sourceforge.net/sourceforge ;; +*) SOURCEFORGE=http://downloads.sourceforge.net;; +esac + # Execute with error checking try() { # "VAR=foo try cmd" fails to put VAR in the environment @@ -531,7 +568,7 @@ download() { fi cache="$WINETRICKS_CACHE/$1" mkdir -p "$cache" - if test ! -f "$cache/$file" + if test ! -f "$cache/$file" || test "$WINETRICKS_CONTINUE_DOWNLOAD" then cd "$cache" # Mac folks tend to have curl rather than wget @@ -730,9 +767,10 @@ _EOF_ } set_videomemorysize() { - echo "Setting video memory size to $1" + size=$1 + echo "Setting video memory size to $size" - case $1 in + case $size in default) cat > "$WINETRICKS_TMP"/set-video.reg <<_EOF_ @@ -748,13 +786,45 @@ _EOF_ REGEDIT4 [HKEY_CURRENT_USER\Software\Wine\Direct3D] -"VideoMemorySize"="$1" +"VideoMemorySize"="$size" _EOF_ esac try_regedit "$WINETRICKS_TMP_WIN"\\set-video.reg } +set_virtualdesktop() { + size=$1 + case $size in + off|disabled) + cat > "$WINETRICKS_TMP"/vd.reg <<_EOF_ +REGEDIT4 + +[HKEY_CURRENT_USER\Software\Wine\Explorer] +"Desktop"=- +[HKEY_CURRENT_USER\Software\Wine\Explorer\Desktops] +"Default"=- + +_EOF_ + ;; + [1-9]*x[1-9]*) + cat > "$WINETRICKS_TMP"/vd.reg <<_EOF_ +REGEDIT4 + +[HKEY_CURRENT_USER\Software\Wine\Explorer] +"Desktop"="Default" +[HKEY_CURRENT_USER\Software\Wine\Explorer\Desktops] +"Default"="$size" + +_EOF_ + ;; + *) + die "you want a virtual desktop of $size? I don't understand." + ;; + esac + try_regedit "$WINETRICKS_TMP"/vd.reg +} + disable_crashdialog() { echo "Disabling graphical crash dialog" cat > "$WINETRICKS_TMP"/crashdialog.reg <<_EOF_ @@ -959,6 +1029,13 @@ load_7zip() { #---------------------------------------------------------------- +load_abiword() { + download $PACKAGE http://www.abisource.com/downloads/abiword/2.8.6/Windows/abiword-setup-2.8.6.exe a91acd3f60e842d23556032d34f1600602768318 + try $WINE "$WINETRICKS_CACHE"/$PACKAGE/abiword-setup-2.8.6.exe $WINETRICKS_S +} + +#---------------------------------------------------------------- + load_adobeair() { # corefonts is necessary to avoid an installer crash. load_corefonts @@ -973,6 +1050,20 @@ load_adobeair() { #---------------------------------------------------------------- +load_amstream() { + helper_directx_dl + + try_cabextract -d "$WINETRICKS_TMP" -L -F dxnt.cab "$WINETRICKS_CACHE"/$DIRECTX_NAME + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'amstream.dll' "$WINETRICKS_TMP/dxnt.cab" + + try $WINE regsvr32 amstream.dll + + override_dlls native amstream + +} + +#---------------------------------------------------------------- + load_art2kmin() { # See http://www.microsoft.com/downloads/details.aspx?familyid=d9ae78d9-9dc6-4b38-9fa6-2c745a175aed&displaylang=en download . http://download.microsoft.com/download/D/2/A/D2A2FC8B-0447-491C-A5EF-E8AA3A74FB98/AccessRuntime.exe 571811b7536e97cf4e4e53bbf8260cddd69f9b2d @@ -989,7 +1080,7 @@ load_atmlib() { download . http://download.microsoft.com/download/E/6/A/E6A04295-D2A8-40D0-A0C5-241BFECD095E/W2KSP4_EN.EXE fadea6d94a014b039839fecc6e6a11c20afa4fa8 cd "$WINETRICKS_TMP" try_cabextract "$WINETRICKS_CACHE"/W2KSP4_EN.EXE i386/atmlib.dl_ - try cp atmlib.dll "$WINDIR"/system32 + try cp atmlib.dll "$SYSTEM32_DLLS" try rm -rf i386 cd "$olddir" } @@ -1005,6 +1096,23 @@ load_autohotkey() { #---------------------------------------------------------------- +load_baekmuk() { + # The Baekmuk fonts provide Korean glyphs. May also be needed with fakekorean function. + # See http://kldp.net/projects/baekmuk for project page + # Need to download from Debian as the project page has unique captcha tokens per visitor + download . http://ftp.de.debian.org/debian/pool/main/t/ttf-baekmuk/ttf-baekmuk_2.2.orig.tar.gz afdee34f700007de6ea87b43c92a88b7385ba65b + cd "$WINETRICKS_TMP/" + gunzip -dc "$WINETRICKS_CACHE/ttf-baekmuk_2.2.orig.tar.gz" | tar -xf - + try mv baekmuk-ttf-2.2/ttf/*.ttf "$winefontsdir" + register_font batang.ttf "Baekmuk Batang" + register_font gulim.ttf "Baekmuk Gulim" + register_font dotum.ttf "Baekmuk Dotum" + register_font hline.ttf "Baekmuk Headline" + cd "$olddir" +} + +#---------------------------------------------------------------- + load_cc580() { # http://www.microsoft.com/downloads/details.aspx?familyid=6f94d31a-d1e0-4658-a566-93af0d8d4a1e download . http://download.microsoft.com/download/platformsdk/redist/5.80.2614.3600/w9xnt4/en-us/cc32inst.exe 94c3c494258cc54bd65d2f0153815737644bffde @@ -1012,7 +1120,7 @@ load_cc580() { try $WINE "$WINETRICKS_CACHE"/cc32inst.exe "/T:$winetricks_tmp_win" /c $WINETRICKS_QUIET try_unzip -o $WINETRICKS_UNIXQUIET -d "$WINDIR"/temp "$WINETRICKS_TMP"/comctl32.exe try $WINE "$WINDIR"/temp/x86/50ComUpd.Exe "/T:$winetricks_tmp_win" /c $WINETRICKS_QUIET - try cp "$WINETRICKS_TMP"/comcnt.dll "$WINDIR"/system32/comctl32.dll + try cp "$WINETRICKS_TMP"/comcnt.dll "$SYSTEM32_DLLS"/comctl32.dll override_dlls native,builtin comctl32 @@ -1036,8 +1144,8 @@ load_comctl32ocx() { download . http://download.microsoft.com/download/3/a/5/3a5925ac-e779-4b1c-bb01-af67dc2f96fc/VisualBasic6-KB896559-v1-ENU.exe f52cf2034488235b37a1da837d1c40eb2a1bad84 try_cabextract -q --directory="$WINETRICKS_TMP" "$WINETRICKS_CACHE"/VisualBasic6-KB896559-v1-ENU.exe - try cp "$WINETRICKS_TMP"/mscomctl.ocx "$WINDIR"/system32/mscomctl.ocx - try cp "$WINETRICKS_TMP"/comctl32.ocx "$WINDIR"/system32/comctl32.ocx + try cp "$WINETRICKS_TMP"/mscomctl.ocx "$SYSTEM32_DLLS"/mscomctl.ocx + try cp "$WINETRICKS_TMP"/comctl32.ocx "$SYSTEM32_DLLS"/comctl32.ocx try $WINE regsvr32 comctl32.ocx try $WINE regsvr32 mscomctl.ocx } @@ -1047,6 +1155,8 @@ load_comctl32ocx() { load_colorprofile() { download . http://download.microsoft.com/download/whistler/hwdev1/1.0/wxp/en-us/ColorProfile.exe 6b72836b32b343c82d0760dff5cb51c2f47170eb try_unzip -o $WINETRICKS_UNIXQUIET -d "$WINETRICKS_TMP" "$WINETRICKS_CACHE"/ColorProfile.exe + + # It's in system32 for both win32/win64 mkdir -p "$WINDIR"/system32/spool/drivers/color try cp -f "$WINETRICKS_TMP/sRGB Color Space Profile.icm" "$WINDIR"/system32/spool/drivers/color } @@ -1056,7 +1166,7 @@ load_colorprofile() { load_comdlg32ocx() { download . http://activex.microsoft.com/controls/vb6/comdlg32.cab d4f3e193c6180eccd73bad53a8500beb5b279cbf try_cabextract --directory="$WINETRICKS_TMP" "$WINETRICKS_CACHE"/comdlg32.cab - try cp "$WINETRICKS_TMP"/comdlg32.ocx "$WINDIR"/system32/comdlg32.ocx + try cp "$WINETRICKS_TMP"/comdlg32.ocx "$SYSTEM32_DLLS"/comdlg32.ocx try $WINE regsvr32 comdlg32.ocx } @@ -1171,7 +1281,7 @@ load_corefonts() { load_crypt32() { # https://www.microsoft.com/downloads/en/details.aspx?FamilyID=3d733ddd-1182-4d46-87c1-3357ca3fed28&DisplayLang=en download . http://download.microsoft.com/download/1/6/2/1629d13a-dc5e-4dc6-a2a4-a6784942b94e/Q823182_XPE_SP2_X86_ENU.EXE c3e0aa35ab5197ede0d495c0edc242cf0fade54a - try_cabextract -d "$WINDIR"/system32 "$WINETRICKS_CACHE"/Q823182_XPE_SP2_X86_ENU.EXE -F rep/329115_crypt32.dll + try_cabextract -d "$SYSTEM32_DLLS" "$WINETRICKS_CACHE"/Q823182_XPE_SP2_X86_ENU.EXE -F rep/329115_crypt32.dll override_dlls native crypt32 } @@ -1205,7 +1315,7 @@ load_d3dx9() { try_cabextract -d "$WINETRICKS_TMP" -L -F '*d3dx9*x86*' "$WINETRICKS_CACHE"/$DIRECTX_NAME for x in `ls "$WINETRICKS_TMP"/*.cab` do - try_cabextract -d "$WINDIR"/system32 -L -F '*.dll' "$x" + try_cabextract -d "$SYSTEM32_DLLS" -L -F '*.dll' "$x" done # For now, not needed, but when Wine starts preferring our builtin dll over native it will be. @@ -1225,7 +1335,7 @@ load_d3dx9_xx() { try_cabextract -d "$WINETRICKS_TMP" -L -F "*$dllname*x86*" "$WINETRICKS_CACHE"/$DIRECTX_NAME for x in `ls "$WINETRICKS_TMP"/*.cab` do - try_cabextract -d "$WINDIR"/system32 -L -F '*.dll' "$x" + try_cabextract -d "$SYSTEM32_DLLS" -L -F '*.dll' "$x" done override_dlls native $dllname @@ -1240,7 +1350,7 @@ load_d3dx10() { try_cabextract -d "$WINETRICKS_TMP" -L -F '*d3dx10*x86*' "$WINETRICKS_CACHE"/$DIRECTX_NAME for x in `ls "$WINETRICKS_TMP"/*.cab` do - try_cabextract -d "$WINDIR"/system32 -L -F '*.dll' "$x" + try_cabextract -d "$SYSTEM32_DLLS" -L -F '*.dll' "$x" done # For now, not needed, but when Wine starts preferring our builtin dll over native it will be. @@ -1254,7 +1364,7 @@ load_d3dxof() { helper_directx_dl try_cabextract -d "$WINETRICKS_TMP" -L -F 'dxnt.cab' "$WINETRICKS_CACHE"/$DIRECTX_NAME - try_cabextract -d "$WINDIR"/system32 -L -F 'd3dxof.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'd3dxof.dll' "$WINETRICKS_TMP/dxnt.cab" override_dlls native d3dxof } @@ -1265,9 +1375,9 @@ load_devenum() { helper_directx_dl try_cabextract -d "$WINETRICKS_TMP" -L -F 'dxnt.cab' "$WINETRICKS_CACHE/$DIRECTX_NAME" - try_cabextract -d "$WINDIR"/system32 -L -F 'devenum.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'devenum.dll' "$WINETRICKS_TMP/dxnt.cab" - try $WINE regsvr32 devenum + try $WINE regsvr32 devenum.dll override_dlls native devenum } @@ -1278,7 +1388,7 @@ load_dinput8() { helper_directx_dl try_cabextract -d "$WINETRICKS_TMP" -L -F 'dxnt.cab' "$WINETRICKS_CACHE"/$DIRECTX_NAME - try_cabextract -d "$WINDIR"/system32 -L -F 'dinput8.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dinput8.dll' "$WINETRICKS_TMP/dxnt.cab" try $WINE regsvr32 dinput8 @@ -1295,34 +1405,37 @@ load_dirac() { #---------------------------------------------------------------- load_directmusic() { -# Untested. Based off http://bugs.winehq.org/show_bug.cgi?id=4805 +# Untested. Based off http://bugs.winehq.org/show_bug.cgi?id=4805 and http://bugs.winehq.org/show_bug.cgi?id=24911 helper_directx_dl try_cabextract -d "$WINETRICKS_TMP" -L -F dxnt.cab "$WINETRICKS_CACHE"/$DIRECTX_NAME - try_cabextract -d "$WINDIR"/system32 -L -F 'dmband.dll' "$WINETRICKS_TMP/dxnt.cab" - try_cabextract -d "$WINDIR"/system32 -L -F 'dmcompos.dll' "$WINETRICKS_TMP/dxnt.cab" - try_cabextract -d "$WINDIR"/system32 -L -F 'dmime.dll' "$WINETRICKS_TMP/dxnt.cab" - try_cabextract -d "$WINDIR"/system32 -L -F 'dmloader.dll' "$WINETRICKS_TMP/dxnt.cab" - try_cabextract -d "$WINDIR"/system32 -L -F 'dmscript.dll' "$WINETRICKS_TMP/dxnt.cab" - try_cabextract -d "$WINDIR"/system32 -L -F 'dmstyle.dll' "$WINETRICKS_TMP/dxnt.cab" - try_cabextract -d "$WINDIR"/system32 -L -F 'dmsynth.dll' "$WINETRICKS_TMP/dxnt.cab" - try_cabextract -d "$WINDIR"/system32 -L -F 'dmusic.dll' "$WINETRICKS_TMP/dxnt.cab" - try_cabextract -d "$WINDIR"/system32 -L -F 'dmusic32.dll' "$WINETRICKS_TMP/dxnt.cab" - try_cabextract -d "$WINDIR"/system32 -L -F 'dswave.dll' "$WINETRICKS_TMP/dxnt.cab" - try_cabextract -d "$WINDIR"/system32 -L -F 'streamci.dll' "$WINETRICKS_TMP/dxnt.cab" - - try $WINE regsvr32 dmband - try $WINE regsvr32 dmcompos - try $WINE regsvr32 dmime - try $WINE regsvr32 dmloader - try $WINE regsvr32 dmscript - try $WINE regsvr32 dmstyle - try $WINE regsvr32 dmsynth - try $WINE regsvr32 dmusic - try $WINE regsvr32 dswave - - override_dlls native dmband dmcompos dmime dmloader dmscript dmstyle dmsynth dmusic dmusic32 dswave streamci - + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'devenum.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dmband.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dmcompos.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dmime.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dmloader.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dmscript.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dmstyle.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dmsynth.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dmusic.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dmusic32.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dswave.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'streamci.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'quartz.dll' "$WINETRICKS_TMP/dxnt.cab" + + try $WINE regsvr32 devenum.dll + try $WINE regsvr32 dmband.dll + try $WINE regsvr32 dmcompos.dll + try $WINE regsvr32 dmime.dll + try $WINE regsvr32 dmloader.dll + try $WINE regsvr32 dmscript.dll + try $WINE regsvr32 dmstyle.dll + try $WINE regsvr32 dmsynth.dll + try $WINE regsvr32 dmusic.dll + try $WINE regsvr32 dswave.dll + try $WINE regsvr32 quartz.dll + + override_dlls native devenum dmband dmcompos dmime dmloader dmscript dmstyle dmsynth dmusic dmusic32 dswave streamci quartz } #---------------------------------------------------------------- @@ -1331,11 +1444,11 @@ load_directplay() { helper_directx_dl try_cabextract -d "$WINETRICKS_TMP" -L -F dxnt.cab "$WINETRICKS_CACHE"/$DIRECTX_NAME - try_cabextract -d "$WINDIR"/system32 -L -F 'dplaysvr.exe' "$WINETRICKS_TMP/dxnt.cab" - try_cabextract -d "$WINDIR"/system32 -L -F 'dplayx.dll' "$WINETRICKS_TMP/dxnt.cab" - try_cabextract -d "$WINDIR"/system32 -L -F 'dpnet.dll' "$WINETRICKS_TMP/dxnt.cab" - try_cabextract -d "$WINDIR"/system32 -L -F 'dpnhpast.dll' "$WINETRICKS_TMP/dxnt.cab" - try_cabextract -d "$WINDIR"/system32 -L -F 'dpwsockx.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dplaysvr.exe' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dplayx.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dpnet.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dpnhpast.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dpwsockx.dll' "$WINETRICKS_TMP/dxnt.cab" try $WINE regsvr32 dplayx.dll try $WINE regsvr32 dpnet.dll @@ -1393,6 +1506,9 @@ load_directx9() { try $WINE "$WINETRICKS_TMP_WIN"/DXSETUP.exe unset_winver + + # reenable mscoree, or other installs may fail, see issue 25 + override_dlls builtin,native mscoree } #---------------------------------------------------------------- @@ -1430,10 +1546,10 @@ load_dcom98() { # Avoid "err:setupapi:SetupDefaultQueueCallbackA copy error 5 ..." # Those messages are suspect, probably shouldn't be err's. - rm -f "$WINDIR"/system32/ole32.dll - rm -f "$WINDIR"/system32/olepro32.dll - rm -f "$WINDIR"/system32/oleaut32.dll - rm -f "$WINDIR"/system32/rpcrt4.dll + rm -f "$SYSTEM32_DLLS"/ole32.dll + rm -f "$SYSTEM32_DLLS"/olepro32.dll + rm -f "$SYSTEM32_DLLS"/oleaut32.dll + rm -f "$SYSTEM32_DLLS"/rpcrt4.dll # Normally only need to override ole32, but overriding advpack # as well gets us the correct exit status. @@ -1455,22 +1571,41 @@ load_dcom98() { #---------------------------------------------------------------- +load_dmsynth() { + helper_directx_dl + + try_cabextract -d "$WINETRICKS_TMP" -L -F dxnt.cab "$WINETRICKS_CACHE"/$DIRECTX_NAME + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dmsynth.dll' "$WINETRICKS_TMP/dxnt.cab" + + try $WINE regsvr32 dmsynth.dll + + override_dlls native dmsynth + +} + +#---------------------------------------------------------------- + load_dotnet11() { DOTNET_INSTALL_DIR="$WINDIR/Microsoft.NET/Framework/v1.1.4322" - # If this is just a dependency check, don't re-install - if test $PACKAGE != dotnet11 && test -d "$DOTNET_INSTALL_DIR" + # Wine now provides some fake dll's here that conflict. + # So check for a file that Wine should never provide, to determine if the install folder is Wine's fake one, or a real one. + # If real, rm -rf it: + if test $PACKAGE != dotnet11 && test -f "$DOTNET_INSTALL_DIR/ndpsetup.ico" then echo "prerequisite dotnet11 already installed, skipping" return + else + rm -rf "$DOTNET_INSTALL_DIR" fi # need corefonts, else installer crashes load_corefonts - # Wine tries to help Mono, which breaks .Net. Can't we all just play nice... - try $WINE reg delete "HKLM\Software\Microsoft\.NETFramework\policy\v2.0" /f - try $WINE reg delete "HKLM\Software\Microsoft\.NETFramework" /v InstallRoot /f + # Wine tries to help Mono, which breaks .Net. However, this key isn't in older Wine versions (notably 1.2), and deleting fails if the key isn't present. + # Can't we all just play nice.. + $WINE reg delete "HKLM\Software\Microsoft\.NETFramework\policy\v2.0" /f || true + $WINE reg delete "HKLM\Software\Microsoft\.NETFramework" /v InstallRoot /f || true # http://www.microsoft.com/downloads/details.aspx?FamilyId=262D25E3-F589-4842-8157-034D1E7CF3A3 download dotnet11 http://download.microsoft.com/download/a/a/c/aac39226-8825-44ce-90e3-bf8203e74006/dotnetfx.exe 16a354a2207c4c8846b617cbc78f7b7c1856340e @@ -1513,11 +1648,12 @@ load_dotnet20() { set_winver win2k # See http://kegel.com/wine/l_intl-sh.txt for how l_intl.nls was generated download dotnet20 http://kegel.com/wine/l_intl.nls 0d2e3f025bcdf852b192c9408a361ac2659fa249 - try cp -f "$WINETRICKS_CACHE"/dotnet20/l_intl.nls "$WINDIR/system32/" + try cp -f "$WINETRICKS_CACHE"/dotnet20/l_intl.nls "$SYSTEM32_DLLS" - # Wine tries to help Mono, which breaks .Net. Can't we all just play nice... - try $WINE reg delete "HKLM\Software\Microsoft\.NETFramework\policy\v2.0" /f - try $WINE reg delete "HKLM\Software\Microsoft\.NETFramework" /v InstallRoot /f + # Wine tries to help Mono, which breaks .Net. However, this key isn't in older Wine versions (notably 1.2), and deleting fails if the key isn't present. + # Can't we all just play nice.. + $WINE reg delete "HKLM\Software\Microsoft\.NETFramework\policy\v2.0" /f || true + $WINE reg delete "HKLM\Software\Microsoft\.NETFramework" /v InstallRoot /f || true # http://www.microsoft.com/downloads/details.aspx?FamilyID=0856eacb-4362-4b0d-8edd-aab15c5e04f5 download dotnet20 http://download.microsoft.com/download/5/6/7/567758a3-759e-473e-bf8f-52154438565a/dotnetfx.exe a3625c59d7a2995fb60877b5f5324892a1693b2a @@ -1528,7 +1664,16 @@ load_dotnet20() { try $WINE "$WINETRICKS_CACHE"/dotnet20/dotnetfx.exe /q /c:"install.exe /q" fi unset_winver + + # We can't stop installing dotnet20 in win2K mode until wine supports + # reparse/junction points + # (see http://bugs.winehq.org/show_bug.cgi?id=10467#c57 ) + # so for now just remove that file. + # See http://bugs.winehq.org/show_bug.cgi?id=16577 + # This affects Victoria 2 demo, see http://forum.paradoxplaza.com/forum/showthread.php?p=11523967 + rm -f "$SYSTEM32_DLLS"/msvc?80.dll } + #---------------------------------------------------------------- load_dotnet20sp2() { @@ -1539,11 +1684,12 @@ load_dotnet20sp2() { #set_winver win2k # See http://kegel.com/wine/l_intl-sh.txt for how l_intl.nls was generated download dotnet20 http://kegel.com/wine/l_intl.nls 0d2e3f025bcdf852b192c9408a361ac2659fa249 - try cp -f "$WINETRICKS_CACHE"/dotnet20/l_intl.nls "$WINDIR/system32/" + try cp -f "$WINETRICKS_CACHE"/dotnet20/l_intl.nls "$SYSTEM32_DLLS" - # Wine tries to help Mono, which breaks .Net. Can't we all just play nice... - try $WINE reg delete "HKLM\Software\Microsoft\.NETFramework\policy\v2.0" /f - try $WINE reg delete "HKLM\Software\Microsoft\.NETFramework" /v InstallRoot /f + # Wine tries to help Mono, which breaks .Net. However, this key isn't in older Wine versions (notably 1.2), and deleting fails if the key isn't present. + # Can't we all just play nice.. + $WINE reg delete "HKLM\Software\Microsoft\.NETFramework\policy\v2.0" /f || true + $WINE reg delete "HKLM\Software\Microsoft\.NETFramework" /v InstallRoot /f || true # http://www.microsoft.com/downloads/details.aspx?familyid=5B2C0358-915B-4EB5-9B1D-10E506DA9D0F download dotnet20 http://download.microsoft.com/download/c/6/e/c6e88215-0178-4c6c-b5f3-158ff77b1f38/NetFx20SP2_x86.exe 22d776d4d204863105a5db99e8b8888be23c61a7 @@ -1590,7 +1736,7 @@ load_dotnet30() { for lang in ar cs da de el es fi fr he it jp ko nb nl pl pt-BR pt-PT ru \ sv tr zh-CHS zh-CHT do - ln -sf "${WINDIR}/system32/spupdsvc.exe" "${LANGPACKS_BASE_PATH}/dotnetfx3langpack${lang}.exe" + ln -sf "${SYSTEM32_DLLS}/spupdsvc.exe" "${LANGPACKS_BASE_PATH}/dotnetfx3langpack${lang}.exe" done # Don't do this for dotnet30! See http://bugs.winehq.org/show_bug.cgi?id=24349#c4 @@ -1653,7 +1799,24 @@ load_dxsdk_nov2006() { download . http://download.microsoft.com/download/9/e/5/9e5bfc66-a621-4e0d-8bfe-6688058c3f00/dxsdk_aug2006.exe load_vcrun6 # for mfc42u echo "Be patient, the 'installing new services' step at the end takes about five minutes" - try $WINE "$WINETRICKS_CACHE"/dxsdk_aug2006.exe $WINETRICKS_QUIET + # Yes, they really mixed cabextract and unzip into one package... + cd "$WINETRICKS_TMP" + try_cabextract "$WINETRICKS_CACHE"/dxsdk_aug2006.exe + try_unzip dxsdk.exe + try $WINE Setup.exe $WINETRICKS_QUIET +} + +#---------------------------------------------------------------- + +load_dsound() { + helper_directx_dl + + try_cabextract -d "$WINETRICKS_TMP" -L -F dxnt.cab "$WINETRICKS_CACHE"/$DIRECTX_NAME + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'dsound.dll' "$WINETRICKS_TMP/dxnt.cab" + + try $WINE regsvr32 dsound.dll + + override_dlls native dsound } #---------------------------------------------------------------- @@ -1673,7 +1836,7 @@ _EOF_ #---------------------------------------------------------------- load_eadm() { - download . http://akamai.cdn.ea.com/eamaster/u/f/eaonline/eadm/eadm-installer.exe 6b3d1a328af2d44033c24b84444992f56107b27f + download . http://akamai.cdn.ea.com/eamaster/u/f/eaonline/eadm/eadm-installer.exe 9f87ad485f82b7ef290613b94912dede79f5f48c load_adobeair try $WINE "$WINETRICKS_CACHE"/eadm-installer.exe $WINETRICKS_S } @@ -1706,13 +1869,91 @@ load_eufonts() { #---------------------------------------------------------------- +load_fakechinese() { + load_wenquanyi + # Loads Wenquanyi fonts and sets aliases for Microsoft Chinese fonts + # Aliases to set: + # Microsoft JhengHei --> WenQuanYi Micro Hei + # Microsoft YaHei --> WenQuanYi Micro Hei + # SimHei --> WenQuanYi Micro Hei + + cat > "$WINETRICKS_TMP"/faketraditionalchinese.reg <<_EOF_ +REGEDIT4 + +[HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\FontSubstitutes] +"Microsoft JhengHei"="WenQuanYi Micro Hei" +"Microsoft YaHei"="WenQuanYi Micro Hei" +"SimHei"="WenQuanYi Micro Hei" + +_EOF_ + + try_regedit "$WINETRICKS_TMP_WIN"\\faketraditionalchinese.reg +} + +#---------------------------------------------------------------- + +load_fakejapanese() { + load_takao + # Loads Takao fonts and sets aliases for MS Gothic and MS PGothic, mainly for Japanese language support + # Aliases to set: + # MS Gothic --> TakaoGothic + # MS PGothic --> TakaoPGothic + # MS Mincho --> TakaoMincho + # MS PMincho --> TakaoPMincho + # These aliases were taken from what was listed in Ubuntu's fontconfig definitions. + + cat > "$WINETRICKS_TMP"/fakejapanese.reg <<_EOF_ +REGEDIT4 + +[HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\FontSubstitutes] +"MS Gothic"="TakaoGothic" +"MS PGothic"="TakaoPGothic" +"MS Mincho"="TakaoMincho" +"MS PMincho"="TakaoPMincho" + +_EOF_ + + try_regedit "$WINETRICKS_TMP_WIN"\\fakejapanese.reg +} + +#---------------------------------------------------------------- + +load_fakekorean() { + load_baekmuk + # Loads Baekmuk fonts and sets as an alias for Gulim, Dotum, and Batang for Korean language support + # Aliases to set: + # Gulim --> Baekmuk Gulim + # GulimChe --> Baekmuk Gulim + # Batang --> Baekmuk Batang + # BatangChe --> Baekmuk Batang + # Dotum --> Baekmuk Dotum + # DotumChe --> Baekmuk Dotum + + cat > "$WINETRICKS_TMP"/fakekorean.reg <<_EOF_ +REGEDIT4 + +[HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\FontSubstitutes] +"Gulim"="Baekmuk Gulim" +"GulimChe"="Baekmuk Gulim" +"Batang"="Baekmuk Batang" +"BatangChe"="Baekmuk Batang" +"Dotum"="Baekmuk Dotum" +"DotumChe"="Baekmuk Dotum" + +_EOF_ + + try_regedit "$WINETRICKS_TMP_WIN"\\fakekorean.reg +} + +#---------------------------------------------------------------- + load_firefox() { - download . "http://releases.mozilla.org//pub/mozilla.org/firefox/releases/3.6.10/win32/en-US/Firefox%20Setup%203.6.10.exe" b1be5982250d1f3009d597d58b7e06009d716cee "Firefox Setup 3.6.10.exe" + download . "http://releases.mozilla.org//pub/mozilla.org/firefox/releases/3.6.12/win32/en-US/Firefox%20Setup%203.6.12.exe" c10562f70de6e0dc656a949931ef9f479623fcd6 "Firefox Setup 3.6.12.exe" if [ "$WINETRICKS_QUIET"x = ""x ] then - try $WINE "$WINETRICKS_CACHE"/"Firefox Setup 3.6.10.exe" + try $WINE "$WINETRICKS_CACHE"/"Firefox Setup 3.6.12.exe" else - try $WINE "$WINETRICKS_CACHE"/"Firefox Setup 3.6.10.exe" -ms + try $WINE "$WINETRICKS_CACHE"/"Firefox Setup 3.6.12.exe" -ms fi } @@ -1728,7 +1969,7 @@ load_ffdshow() { load_flash() { # If this is just a dependency check, don't re-install - if test $PACKAGE != flash && test -f "$WINDIR"/system32/Macromed/Flash/flashplayer.xpt + if test $PACKAGE != flash && test -f "$SYSTEM32_DLLS"/Macromed/Flash/flashplayer.xpt then echo "prerequisite flash already installed, skipping" return @@ -1742,7 +1983,7 @@ load_flash() { # 2008-04-01: old version sha1sum f4dd1c0c715b791db2c972aeba90d3b78372996a # 2008-04-18: new version sha1sum 04ac79c4f1eb1e1ca689f27fa71f12bb5cd11cc2 # Version 10 http://fpdownload.macromedia.com/get/flashplayer/current/install_flash_player_ax.exe - # 2008-11-27: 10 sha1sum 7f6850ae815e953311bb94a8aa9d226f97a646dd + # 2008-11-27: sha1sum 7f6850ae815e953311bb94a8aa9d226f97a646dd # 2009-02-27: sha1sum 86745020a25edc9695a1a6a4d59eae375665a0b3 # 2009-07-31: sha1sum 11a81ad1b19344c28b1e1249169f15dfbd2a04f5 # 2009-12-09: sha1sum f4ec0e95099e354fd01cd3bb27c202f54932dc70 @@ -1750,7 +1991,9 @@ load_flash() { # 2010-03-15: sha1sum 901b53ebe26c62c0bd7fc7dc400552ce335685bb # 2010-06-24: sha1sum 6de519569137ec2ba3a4eed59f4052c4d944869c # 2010-08-11: sha1sum bd3a91fe450a800dbbc8d070159dc0a599043652 - download . http://fpdownload.macromedia.com/get/flashplayer/current/install_flash_player_ax.exe bd3a91fe450a800dbbc8d070159dc0a599043652 + # 2010-10-21: sha1sum c8bc6b4ead9538aeba24c9a5908dc1912ad443c7 + # 2010-11-04: sha1sum 58412bcc83e349be50cafe0e1c46e19088620866 +download . http://fpdownload.macromedia.com/get/flashplayer/current/install_flash_player_ax.exe 58412bcc83e349be50cafe0e1c46e19088620866 if [ $WINETRICKS_QUIET ] then try $WINE "$WINETRICKS_CACHE"/install_flash_player_ax.exe /install @@ -1768,7 +2011,9 @@ load_flash() { # 2010-03-16: sha1sum e2fe55927c4068b0a07636742814682c0a2aa0fe # 2010-06-24: sha1sum a419339ada03076ea0a197b28011b87055c45478 # 2010-08-11: sha1sum cb011ab4c74d222c8ddb48171a8aa3b5380f8d5a - download . http://fpdownload.macromedia.com/get/flashplayer/current/install_flash_player.exe cb011ab4c74d222c8ddb48171a8aa3b5380f8d5a + # 2010-10-21: sha1sum 26985ca9f8f9c9926d807b591a28cdf2cc35a76a + # 2010-11-04: sha1sum 09f2491c5bec7286155234f4e6e1af70c7cef78f +download . http://fpdownload.macromedia.com/get/flashplayer/current/install_flash_player.exe 09f2491c5bec7286155234f4e6e1af70c7cef78f if [ $WINETRICKS_QUIET ] then try $WINE "$WINETRICKS_CACHE"/install_flash_player.exe /install @@ -1914,13 +2159,13 @@ load_gecko() { GECKO_SHA1SUM=9a49fc691740596517e381b47096a4bdf19a87d8 ;; wine-1.1.2[789]*|wine-1.1.[34]*|wine-1.2*|wine-1.3|wine-1.3.[01]|wine-1.3.[0]-*) - GECKO_DIR="$WINDIR/system32" + GECKO_DIR="$SYSTEM32_DLLS" GECKO_VERSION=1.0.0 GECKO_ARCH=-x86 GECKO_SHA1SUM=afa22c52bca4ca77dcb9edb3c9936eb23793de01 ;; *) - GECKO_DIR="$WINDIR/system32" + GECKO_DIR="$SYSTEM32_DLLS" GECKO_VERSION=1.1.0 GECKO_ARCH=-x86 GECKO_SHA1SUM=1b6c637207b6f032ae8a52841db9659433482714 @@ -2013,14 +2258,14 @@ load_gecko_dbg() { GECKO_SHA1SUM=a9b58d3330f8c78524fe4683f348302bfce96ff4 ;; wine-1.1.2[789]*|wine-1.1.[34]*|wine-1.2*|wine-1.3|wine-1.3.[01]|wine-1.3.[01]-*) - GECKO_DIR="$WINDIR/system32" + GECKO_DIR="$SYSTEM32_DLLS" GECKO_VERSION=1.0.0 GECKO_ARCH=-x86 GECKO_EXTENSION=cab GECKO_SHA1SUM=2de16b443826295f646cd5d54313ca421fd71210 ;; *) - GECKO_DIR="$WINDIR/system32" + GECKO_DIR="$SYSTEM32_DLLS" GECKO_VERSION=1.1.0 GECKO_ARCH=-x86 GECKO_EXTENSION=tar.bz2 @@ -2088,7 +2333,7 @@ load_gdiplus() { # Showing that isn't useful, so always use /q. try $WINE "$WINETRICKS_CACHE"/WindowsXP-KB975337-x86-ENU.exe /extract:$WINETRICKS_TMP_WIN /q # And then make it globally available. - try cp "$WINETRICKS_TMP/asms/10/msft/windows/gdiplus/gdiplus.dll" "$WINDIR"/system32/ + try cp "$WINETRICKS_TMP/asms/10/msft/windows/gdiplus/gdiplus.dll" "$SYSTEM32_DLLS" # For some reason, native,builtin isn't good enough...? override_dlls native gdiplus @@ -2109,7 +2354,7 @@ load_gfw() { download . http://download.microsoft.com/download/E/6/A/E6A04295-D2A8-40D0-A0C5-241BFECD095E/W2KSP4_EN.EXE fadea6d94a014b039839fecc6e6a11c20afa4fa8 cd "$WINETRICKS_TMP" try_cabextract "$WINETRICKS_CACHE"/W2KSP4_EN.EXE i386/msasn1.dl_ - try cp msasn1.dll "$WINDIR"/system32 + try cp msasn1.dll "$SYSTEM32_DLLS" try rm -rf i386 cd "$olddir" } @@ -2147,7 +2392,7 @@ _EOF_ load_glut() { download . http://www.xmission.com/~nate/glut/glut-3.7.6-bin.zip fb4731885c05b3cf2c79e85aabe8fc9949616ef4 try_unzip -o $WINETRICKS_UNIXQUIET -d "$DRIVE_C" "$WINETRICKS_CACHE"/glut-3.7.6-bin.zip - try cp "$DRIVE_C"/glut-3.7.6-bin/glut32.dll "$WINDIR"/system32 + try cp "$DRIVE_C"/glut-3.7.6-bin/glut32.dll "$SYSTEM32_DLLS" warn "If you want to compile glut programs, add c:/glut-3.7.6-bin to LIB and INCLUDE" } @@ -2160,6 +2405,8 @@ load_hosts() { # Some apps depend on these files, but they're not implemented in wine. # Fortunately, empty files in the correct location satisfy those apps. # See http://bugs.winehq.org/show_bug.cgi?id=12076 + + # It's in system32 for both win32/win64 mkdir -p "$WINDIR"/system32/drivers/etc touch "$WINDIR"/system32/drivers/etc/hosts touch "$WINDIR"/system32/drivers/etc/services @@ -2180,24 +2427,17 @@ _EOF_ #---------------------------------------------------------------- -load_ie6() { - if test "$WINE" = "" - then - echo "No need to install ie6 on real windows" - return 0 - fi +load_ie6_full() { + download . http://browsers-us.mirrors.zensoft.net/ie/win32/6.0/ie60.exe 8e483db28ff01a7cabd39147ab6c59753ea1f533 - # If this is just a dependency check, don't re-install - if test $PACKAGE != ie6 && test -f "$WINDIR"/system32/plugin.ocx - then - echo "prerequisite ie6 (or ie7) already installed, skipping" - return - fi + cd "$WINETRICKS_TMP" + try_unzip "$WINETRICKS_CACHE"/ie60.exe + cd "IE 6.0 Full" load_msls31 # Unregister Wine IE - if [ ! -f "$WINDIR"/system32/plugin.ocx ] + if [ ! -f "$SYSTEM32_DLLS"/plugin.ocx ] then try $WINE iexplore -unregserver fi @@ -2209,8 +2449,78 @@ load_ie6() { mv "$programfilesdir_unix"/"Internet Explorer"/iexplore.exe "$programfilesdir_unix"/"Internet Explorer"/iexplore.exe.bak for dll in itircl itss jscript mlang mshtml msimtf shdoclc shdocvw shlwapi urlmon do - test -f "$WINDIR"/system32/$dll.dll && - mv "$WINDIR"/system32/$dll.dll "$WINDIR"/system32/$dll.dll.bak + test -f "$SYSTEM32_DLLS"/$dll.dll && + mv "$SYSTEM32_DLLS"/$dll.dll "$SYSTEM32_DLLS"/$dll.dll.bak + done + + # The installer doesn't want to install iexplore.exe in XP mode. + set_winver win2k + + # Workaround http://bugs.winehq.org/show_bug.cgi?id=21009 + # See also http://code.google.com/p/winezeug/issues/detail?id=78 + rm -f "$SYSTEM32_DLLS"/browseui.dll "$SYSTEM32_DLLS"/inseng.dll + + $WINE ie6setup.exe + + # IE6 exits with 194 to signal a reboot + status=$? + case $status in + 0|194) ;; + *) die ie6 installation failed + esac + + # Work around DLL registration bug until ierunonce/RunOnce/wineboot is fixed + # FIXME: whittle down this list + cd "$SYSTEM32_DLLS" + for i in actxprxy.dll browseui.dll browsewm.dll cdfview.dll ddraw.dll \ + dispex.dll dsound.dll iedkcs32.dll iepeers.dll iesetup.dll \ + imgutil.dll inetcomm.dll inseng.dll isetup.dll jscript.dll laprxy.dll \ + mlang.dll mshtml.dll mshtmled.dll msi.dll msident.dll \ + msoeacct.dll msrating.dll mstime.dll msxml3.dll occache.dll \ + ole32.dll oleaut32.dll olepro32.dll pngfilt.dll quartz.dll \ + rpcrt4.dll rsabase.dll rsaenh.dll scrobj.dll scrrun.dll \ + shdocvw.dll shell32.dll urlmon.dll vbscript.dll webcheck.dll \ + wshcon.dll wshext.dll asctrls.ocx hhctrl.ocx mscomct2.ocx \ + plugin.ocx proctexe.ocx tdc.ocx webcheck.dll wshom.ocx + do + $WINE regsvr32 /i $i > /dev/null 2>&1 + done + + # Set windows version back to user's default. Leave at win2k for better rendering (is there a bug for that?) + unset_winver +} + +load_ie6() { + if test "$WINE" = "" + then + echo "No need to install ie6 on real windows" + return 0 + fi + + # If this is just a dependency check, don't re-install + if test $PACKAGE != ie6 && test -f "$SYSTEM32_DLLS"/plugin.ocx + then + echo "prerequisite ie6 (or ie7) already installed, skipping" + return + fi + + load_msls31 + + # Unregister Wine IE + if [ ! -f "$SYSTEM32_DLLS"/plugin.ocx ] + then + try $WINE iexplore -unregserver + fi + + # Change the override to the native so we are sure we use and register them + override_dlls native,builtin iexplore.exe itircl itss jscript mlang mshtml msimtf shdoclc shdocvw shlwapi urlmon + + # Remove the fake dlls, if any + mv "$programfilesdir_unix"/"Internet Explorer"/iexplore.exe "$programfilesdir_unix"/"Internet Explorer"/iexplore.exe.bak + for dll in itircl itss jscript mlang mshtml msimtf shdoclc shdocvw shlwapi urlmon + do + test -f "$SYSTEM32_DLLS"/$dll.dll && + mv "$SYSTEM32_DLLS"/$dll.dll "$SYSTEM32_DLLS"/$dll.dll.bak done # The installer doesn't want to install iexplore.exe in XP mode. @@ -2227,7 +2537,7 @@ load_ie6() { # Workaround http://bugs.winehq.org/show_bug.cgi?id=21009 # See also http://code.google.com/p/winezeug/issues/detail?id=78 - rm -f "$WINDIR"/system32/browseui.dll "$WINDIR"/system32/inseng.dll + rm -f "$SYSTEM32_DLLS"/browseui.dll "$SYSTEM32_DLLS"/inseng.dll # Silent install recipe from: # http://www.axonpro.sk/japo/info/MS/SILENT%20INSTALL/Unattended-Silent%20Installation%20Switches%20for%20Windows%20Apps.htm @@ -2246,7 +2556,7 @@ load_ie6() { # Work around DLL registration bug until ierunonce/RunOnce/wineboot is fixed # FIXME: whittle down this list - cd "$WINDIR"/system32/ + cd "$SYSTEM32_DLLS" for i in actxprxy.dll browseui.dll browsewm.dll cdfview.dll ddraw.dll \ dispex.dll dsound.dll iedkcs32.dll iepeers.dll iesetup.dll \ imgutil.dll inetcomm.dll inseng.dll isetup.dll jscript.dll laprxy.dll \ @@ -2271,7 +2581,7 @@ load_ie6() { load_ie7() { # Unregister Wine IE - if [ ! -f "$WINDIR"/system32/plugin.ocx ] + if [ ! -f "$SYSTEM32_DLLS"/plugin.ocx ] then try $WINE iexplore -unregserver fi @@ -2285,8 +2595,8 @@ load_ie7() { # Remove the fake dlls from the existing WINEPREFIX for dll in itircl itss jscript mshtml msimtf shdoclc shdocvw shlwapi urlmon do - test -f "$WINDIR"/system32/$dll.dll && - mv "$WINDIR"/system32/$dll.dll "$WINDIR"/system32/$dll.dll.bak + test -f "$SYSTEM32_DLLS"/$dll.dll && + mv "$SYSTEM32_DLLS"/$dll.dll "$SYSTEM32_DLLS"/$dll.dll.bak done # See http://bugs.winehq.org/show_bug.cgi?id=16013 @@ -2294,8 +2604,8 @@ load_ie7() { download . http://winezeug.googlecode.com/svn/trunk/winetricks_files/winetest.cat ac8f50dd54d011f3bb1dd79240dae9378748449f # Put a dummy catalog file in place - mkdir -p "$WINDIR"/system32/catroot/\{f750e6c3-38ee-11d1-85e5-00c04fc295ee\} - try cp -f "$WINETRICKS_CACHE"/winetest.cat "$WINDIR"/system32/catroot/\{f750e6c3-38ee-11d1-85e5-00c04fc295ee\}/oem0.cat + mkdir -p "$SYSTEM32_DLLS"/catroot/\{f750e6c3-38ee-11d1-85e5-00c04fc295ee\} + try cp -f "$WINETRICKS_CACHE"/winetest.cat "$SYSTEM32_DLLS"/catroot/\{f750e6c3-38ee-11d1-85e5-00c04fc295ee\}/oem0.cat # Install download . http://download.microsoft.com/download/3/8/8/38889DC1-848C-4BF2-8335-86C573AD86D9/IE7-WindowsXP-x86-enu.exe d39b89c360fbaa9706b5181ae4718100687a5326 @@ -2308,7 +2618,7 @@ load_ie7() { # Work around DLL registration bug until ierunonce/RunOnce/wineboot is fixed # FIXME: whittle down this list - cd "$WINDIR"/system32/ + cd "$SYSTEM32_DLLS" for i in actxprxy.dll browseui.dll browsewm.dll cdfview.dll ddraw.dll \ dispex.dll dsound.dll iedkcs32.dll iepeers.dll iesetup.dll \ imgutil.dll inetcomm.dll inseng.dll isetup.dll jscript.dll laprxy.dll \ @@ -2337,7 +2647,7 @@ load_ie7() { load_ie8() { # Unregister Wine IE - if [ ! -f "$WINDIR"/system32/plugin.ocx ] + if [ ! -f "$SYSTEM32_DLLS"/plugin.ocx ] then try $WINE iexplore -unregserver fi @@ -2353,8 +2663,8 @@ load_ie8() { # Remove the fake dlls from the existing WINEPREFIX for dll in browseui.dll inseng.dll itircl itss jscript msctf mshtml shdoclc shdocvw shlwapi urlmon do - test -f "$WINDIR"/system32/$dll.dll && - mv "$WINDIR"/system32/$dll.dll "$WINDIR"/system32/$dll.dll.bak + test -f "$SYSTEM32_DLLS"/$dll.dll && + mv "$SYSTEM32_DLLS"/$dll.dll "$SYSTEM32_DLLS"/$dll.dll.bak done # See http://bugs.winehq.org/show_bug.cgi?id=16013 @@ -2362,8 +2672,8 @@ load_ie8() { download . http://winezeug.googlecode.com/svn/trunk/winetricks_files/winetest.cat ac8f50dd54d011f3bb1dd79240dae9378748449f # Put a dummy catalog file in place - mkdir -p "$WINDIR"/system32/catroot/\{f750e6c3-38ee-11d1-85e5-00c04fc295ee\} - try cp -f "$WINETRICKS_CACHE"/winetest.cat "$WINDIR"/system32/catroot/\{f750e6c3-38ee-11d1-85e5-00c04fc295ee\}/oem0.cat + mkdir -p "$SYSTEM32_DLLS"/catroot/\{f750e6c3-38ee-11d1-85e5-00c04fc295ee\} + try cp -f "$WINETRICKS_CACHE"/winetest.cat "$SYSTEM32_DLLS"/catroot/\{f750e6c3-38ee-11d1-85e5-00c04fc295ee\}/oem0.cat # FIXME: According to http://www.wine-reviews.net/wine-reviews/microsoft/internet-explorer-8-on-linux-with-wine.html # may also need native msctf, msimtf, and uxtheme @@ -2381,7 +2691,7 @@ load_ie8() { # Work around DLL registration bug until ierunonce/RunOnce/wineboot is fixed # FIXME: whittle down this list - cd "$WINDIR"/system32/ + cd "$SYSTEM32_DLLS" for i in actxprxy.dll browseui.dll browsewm.dll cdfview.dll ddraw.dll \ dispex.dll dsound.dll iedkcs32.dll iepeers.dll iesetup.dll \ imgutil.dll inetcomm.dll isetup.dll jscript.dll laprxy.dll \ @@ -2418,16 +2728,27 @@ load_jet40() { #---------------------------------------------------------------- load_kde() { - download . http://www.winkde.org/pub/kde/ports/win32/installer/kdewin-installer-gui-0.9.6-5.exe f612945e094390d7bc0e4f8840d308ef2b00f86e + download . http://www.winkde.org/pub/kde/ports/win32/installer/kdewin-installer-gui-0.9.7-0.exe 9fe2f13b76375e70e780ce6850d0de35b08b4ec3 mkdir -p "$programfilesdir_unix/kde" - try cp "$WINETRICKS_CACHE"/kdewin-installer-gui-0.9.6-5.exe "$programfilesdir_unix/kde" + try cp "$WINETRICKS_CACHE"/kdewin-installer-gui-0.9.7-0.exe "$programfilesdir_unix/kde" cd "$programfilesdir_unix/kde" - try $WINE "$programfilesdir_win\\kde\\kdewin-installer-gui-0.9.6-5.exe" + try $WINE "$programfilesdir_win\\kde\\kdewin-installer-gui-0.9.7-0.exe" cd "$olddir" } #---------------------------------------------------------------- +load_l3codecx() { + helper_directx_dl + + try_cabextract -d "$WINETRICKS_TMP" -L -F dxnt.cab "$WINETRICKS_CACHE"/$DIRECTX_NAME + try_cabextract -d "$SYSTEM32_DLLS" -L -F l3codecx.ax "$WINETRICKS_TMP/dxnt.cab" + + try $WINE regsvr32 l3codecx.ax +} + +#---------------------------------------------------------------- + load_liberation() { # http://www.redhat.com/promo/fonts/ case `uname -s` in @@ -2514,7 +2835,7 @@ load_mfc40() { # See http://support.microsoft.com/kb/122244 download . http://download.microsoft.com/download/ole/ole2v/3.5/w351/en-us/ole2v.exe c6cac71f32405ccb09c6f375e0738e6e13f073e4 try_unzip -o $WINETRICKS_UNIXQUIET -d "$WINETRICKS_TMP" "$WINETRICKS_CACHE"/ole2v.exe - try cp -f "$WINETRICKS_TMP"/MFC40.DLL "$WINDIR"/system32/ + try cp -f "$WINETRICKS_TMP"/MFC40.DLL "$SYSTEM32_DLLS" rm -rf "$WINETRICKS_TMP"/* } @@ -2624,8 +2945,8 @@ load_msi2() { set_winver win98 # Avoid "err:setupapi:SetupDefaultQueueCallbackA copy error 5 ..." - rm -f "$WINDIR"/system32/msi.dll - rm -f "$WINDIR"/system32/msiexec.exe + rm -f "$SYSTEM32_DLLS"/msi.dll + rm -f "$SYSTEM32_DLLS"/msiexec.exe WINEDLLOVERRIDES="msi,msiexec.exe=n" try $WINE "$WINETRICKS_CACHE"/InstMSIA.exe $WINETRICKS_QUIET @@ -2644,7 +2965,7 @@ load_mshflxgd() { # May 2009: bd8aa796e16e5f213414af78931e0379d9cbe292 download . http://activex.microsoft.com/controls/vb6/MSHFLXGD.CAB bd8aa796e16e5f213414af78931e0379d9cbe292 try_cabextract --directory="$WINETRICKS_TMP" "$WINETRICKS_CACHE"/MSHFLXGD.CAB - try cp -f "$WINETRICKS_TMP"/[Mm][Ss][Hh][Ff][Ll][Xx][Gg][Dd].[Oo][Cc][Xx] "$WINDIR"/system32 + try cp -f "$WINETRICKS_TMP"/[Mm][Ss][Hh][Ff][Ll][Xx][Gg][Dd].[Oo][Cc][Xx] "$SYSTEM32_DLLS" } #---------------------------------------------------------------- @@ -2653,7 +2974,7 @@ load_msls31() { # Install native Microsoft Line Services (needed by e-Sword, possibly only when using native riched20) download . http://download.microsoft.com/download/WindowsInstaller/Install/2.0/W9XMe/EN-US/InstMsiA.exe e739c40d747e7c27aacdb07b50925b1635ee7366 try_cabextract --directory="$WINETRICKS_TMP" "$WINETRICKS_CACHE"/InstMsiA.exe - try cp -f "$WINETRICKS_TMP"/msls31.dll "$WINDIR"/system32 + try cp -f "$WINETRICKS_TMP"/msls31.dll "$SYSTEM32_DLLS" } #---------------------------------------------------------------- @@ -2665,7 +2986,7 @@ load_msmask() { # May 2009: 30e55679e4a13fe4d9620404476f215f93239292 download . http://activex.microsoft.com/controls/vb6/MSMASK32.CAB 30e55679e4a13fe4d9620404476f215f93239292 try_cabextract --directory="$WINETRICKS_TMP" "$WINETRICKS_CACHE"/MSMASK32.CAB - try cp -f "$WINETRICKS_TMP"/[Mm][Ss][Mm][Aa][Ss][Kk]32.[Oo][Cc][Xx] "$WINDIR"/system32/msmask32.ocx + try cp -f "$WINETRICKS_TMP"/[Mm][Ss][Mm][Aa][Ss][Kk]32.[Oo][Cc][Xx] "$SYSTEM32_DLLS"/msmask32.ocx try $WINE regsvr32 msmask32.ocx } @@ -2685,7 +3006,7 @@ load_msscript() { # http://www.microsoft.com/downloads/details.aspx?familyid=d7e31492-2595-49e6-8c02-1426fec693ac download . http://download.microsoft.com/download/d/2/a/d2a7430c-6d5b-48e9-96c4-3c751be7bffe/sct10en.exe fd9f2f23357ab11ae70682d6864f7e9f188adf2a try_cabextract --directory="$WINETRICKS_TMP" "$WINETRICKS_CACHE"/sct10en.exe - try cp -f "$WINETRICKS_TMP"/msscript.ocx "$WINDIR"/system32 + try cp -f "$WINETRICKS_TMP"/msscript.ocx "$SYSTEM32_DLLS" try $WINE regsvr32 msscript.ocx } @@ -2705,7 +3026,7 @@ load_msxml3() { load_msxml4() { # If this is just a dependency check, don't re-install - if test $PACKAGE != msxml4 && test -f "$WINDIR"/system32/msxml4.dll + if test $PACKAGE != msxml4 && test -f "$SYSTEM32_DLLS"/msxml4.dll then echo "prerequisite msxml4 already installed, skipping" return @@ -2724,7 +3045,7 @@ load_msxml4() { load_msxml6() { # If this is just a dependency check, don't re-install - if test $PACKAGE != msxml6 && test -f "$WINDIR"/system32/msxml6.dll + if test $PACKAGE != msxml6 && test -f "$SYSTEM32_DLLS"/msxml6.dll then echo "prerequisite msxml6 already installed, skipping" return @@ -2741,6 +3062,13 @@ load_msxml6() { #---------------------------------------------------------------- +load_nvidiasdk95() { + download . http://developer.download.nvidia.com/SDK/9.5/NVIDIA_SDK_9.52.0324.0405.exe + try $WINE "$WINETRICKS_CACHE"/NVIDIA_SDK_9.52.0324.0405.exe +} + +#---------------------------------------------------------------- + load_ogg() { # flac, ogg, speex, vorbis, ogm source, ogg source # see following URLs for more info @@ -2802,7 +3130,7 @@ load_pdh() { download . http://download.microsoft.com/download/platformsdk/Redist/5.0.2195.2668/NT4/EN-US/pdhinst.exe f42448660def8cd7f42b34aa7bc7264745f4425e try_cabextract --directory="$WINETRICKS_TMP" "$WINETRICKS_CACHE"/pdhinst.exe try_unzip -o $WINETRICKS_UNIXQUIET -d "$WINETRICKS_TMP" "$WINETRICKS_TMP"/pdh.exe - try cp -f "$WINETRICKS_TMP"/x86/Pdh.Dll "$WINDIR"/system32/pdh.dll + try cp -f "$WINETRICKS_TMP"/x86/Pdh.Dll "$SYSTEM32_DLLS"/pdh.dll } #---------------------------------------------------------------- @@ -2924,7 +3252,7 @@ load_quartz() { helper_directx_dl try_cabextract -d "$WINETRICKS_TMP" -L -F dxnt.cab "$WINETRICKS_CACHE"/$DIRECTX_NAME - try_cabextract -d "$WINDIR"/system32 -L -F 'quartz.dll' "$WINETRICKS_TMP/dxnt.cab" + try_cabextract -d "$SYSTEM32_DLLS" -L -F 'quartz.dll' "$WINETRICKS_TMP/dxnt.cab" try $WINE regsvr32 quartz.dll @@ -2937,6 +3265,8 @@ load_quartz() { load_quicktime72() { echo "Quicktime needs gdiplus..." load_gdiplus + echo "Quicktime needs vcrun2005..." + load_vcrun2005 # http://www.apple.com/support/downloads/quicktime72forwindows.html download quicktime72 'http://wsidecar.apple.com/cgi-bin/nph-reg3rdpty2.pl/product=14402&cat=59&platform=osx&method=sa/QuickTimeInstaller.exe' bb89981f10cf21de57b9453e53cf81b9194271a9 @@ -2965,6 +3295,39 @@ load_quicktime72() { #---------------------------------------------------------------- +load_quicktime76() { + echo "Quicktime needs gdiplus..." + load_gdiplus + echo "Quicktime needs vcrun2005..." + load_vcrun2005 + + # http://www.apple.com/quicktime/download/ + download quicktime76 'http://appldnld.apple.com/QuickTime/061-8938.20100915.Qts3T/QuickTimeInstaller.exe' 38e33492ea1200abeda87256872e5a3dd47e584f + unset QUICKTIME_QUIET + if test "$WINETRICKS_QUIET"x != x + then + QUICKTIME_QUIET="/qn" # ISSETUPDRIVEN=0 + fi + # set vista mode to inhibit directdraw overlay use that blacks the screen + set_winver vista + try $WINE "$WINETRICKS_CACHE"/quicktime76/QuickTimeInstaller.exe ALLUSERS=1 DESKTOP_SHORTCUTS=0 QTTaskRunFlags=0 QTINFO.BISQTPRO=1 SCHEDULE_ASUW=0 REBOOT_REQUIRED=No $QUICKTIME_QUIET > /dev/null 2>&1 + if test "$WINETRICKS_QUIET"x = x + then + echo "You probably want to select Advanced / Safe Mode in the Quicktime control panel" + try $WINE control "$programfilesdir_win\\QuickTime\\QTSystem\\QuickTime.cpl" + fi + + unset_winver + # user might want to set vista mode himself, or run + # wine control ".wine/drive_c/Program Files/QuickTime/QTSystem/QuickTime.cpl" + # and pick Advanced / Safe Mode (gdi only). + # We could probably force that by overwriting QuickTime.qtp + # (probably in Program Files/QuickTime/QTSystem/QuickTime.qtp) + # but the format isn't known, so we'd have to override all other settings, too. +} + +#---------------------------------------------------------------- + volnum() { case "$OS" in "Windows_NT") @@ -2998,7 +3361,7 @@ load_riched20() { # http://support.microsoft.com/?kbid=249973 download . http://download.microsoft.com/download/winntsp/Patch/RTF/NT4/EN-US/Q249973i.EXE f0b7663f15dbd31410435483ba832318c7a70470 try_cabextract --directory="$WINETRICKS_TMP" "$WINETRICKS_CACHE"/Q249973i.EXE - try cp -f "$WINETRICKS_TMP"/riched??.dll "$WINDIR"/system32 + try cp -f "$WINETRICKS_TMP"/riched??.dll "$SYSTEM32_DLLS" override_dlls native,builtin riched20 riched32 rm -rf "$WINETRICKS_TMP"/* @@ -3015,7 +3378,7 @@ load_riched30() { # http://www.microsoft.com/downloads/details.aspx?displaylang=en&FamilyID=CEBBACD8-C094-4255-B702-DE3BB768148F download . http://download.microsoft.com/download/WindowsInstaller/Install/2.0/W9XMe/EN-US/InstMsiA.exe e739c40d747e7c27aacdb07b50925b1635ee7366 try_cabextract --directory="$WINETRICKS_TMP" "$WINETRICKS_CACHE"/InstMsiA.exe - try cp -f "$WINETRICKS_TMP"/riched20.dll "$WINDIR"/system32 + try cp -f "$WINETRICKS_TMP"/riched20.dll "$SYSTEM32_DLLS" override_dlls native,builtin riched20 rm -rf "$WINETRICKS_TMP"/* @@ -3025,7 +3388,7 @@ load_riched30() { load_richtx32() { download . http://activex.microsoft.com/controls/vb6/richtx32.cab da404b566df3ad74fe687c39404a36c3e7cadc07 - try_cabextract "$WINETRICKS_CACHE"/richtx32.cab -d "$WINDIR"/system32 -F RichTx32.Ocx + try_cabextract "$WINETRICKS_CACHE"/richtx32.cab -d "$SYSTEM32_DLLS" -F RichTx32.Ocx try $WINE regsvr32 RichTx32.ocx } @@ -3034,7 +3397,7 @@ load_richtx32() { load_secur32(){ # http://www.microsoft.com/downloads/details.aspx?familyid=c4e408d7-6716-4a12-ad3a-8029667f5c84 download . http://download.microsoft.com/download/6/9/5/69501788-B62F-44D8-933F-B6FAA576CA87/Windows2000-KB959426-x86-ENU.EXE bf930a4d2982165a0793465bb255d494ba5b4cf7 - try_cabextract "$WINETRICKS_CACHE"/Windows2000-KB959426-x86-ENU.EXE -d "$WINDIR"/system32 -F secur32.dll + try_cabextract "$WINETRICKS_CACHE"/Windows2000-KB959426-x86-ENU.EXE -d "$SYSTEM32_DLLS" -F secur32.dll override_dlls native,builtin secur32 } @@ -3045,9 +3408,8 @@ load_safari() { download . http://appldnld.apple.com.edgesuite.net/content.info.apple.com/Safari5/061-7138.20100607.Y7U87/SafariSetup.exe e56d5d79d9cfbb85ac46ac78aa497d7f3d8dbc3d cd "$WINETRICKS_CACHE" # Workaround http://bugs.winehq.org/show_bug.cgi?id=21146 - # FIXME: is this localized? - try mkdir -p "$DRIVE_C/users/$USER/Application Data/Apple Computer/Preferences" - cat > "$DRIVE_C/users/$USER/Application Data/Apple Computer/Preferences/com.apple.Safari.plist" <<_EOF_ + try mkdir -p "$appdata_unix/Apple Computer/Preferences" + cat > "$appdata_unix/Apple Computer/Preferences/com.apple.Safari.plist" <<_EOF_ @@ -3080,8 +3442,9 @@ load_shockwave() { # 2010-01-23 sha1sum: 4a837d238c28c5f345d73f105711f20c6d059273 # 2010-05-15 sha1sum: bdce02afc82233801e84137e78c2c5fe574db253 # 2010-09-02 sha1sum: fed20eccc29fec2f64162b7265343514d43884bc + # 2010-11-03 sha1sum: 2ff28665543e80f3bd4ff1933ac05ec9314aaac6 - download . http://fpdownload.macromedia.com/get/shockwave/default/english/win95nt/latest/sw_lic_full_installer.msi fed20eccc29fec2f64162b7265343514d43884bc + download . http://fpdownload.macromedia.com/get/shockwave/default/english/win95nt/latest/sw_lic_full_installer.msi 2ff28665543e80f3bd4ff1933ac05ec9314aaac6 try $WINE msiexec /i "$WINETRICKS_CACHE"/sw_lic_full_installer.msi $WINETRICKS_QUIET } @@ -3113,13 +3476,56 @@ load_tahoma() { #---------------------------------------------------------------- +load_takao() { + # The Takao font provides Japanese glyphs. May also be needed with fakejapanese function above. + # See http://launchpad.net/takao-fonts for project page + download . http://launchpad.net/takao-fonts/003.02/003.02.01/+download/takao-fonts-ttf-003.02.01.zip 4f636d5c7c1bc16b96ea723adb16838cfb6df059 + cp -f $WINETRICKS_CACHE/takao-fonts-ttf-003.02.01.zip $WINETRICKS_TMP + try_unzip -d $WINETRICKS_TMP $WINETRICKS_TMP/takao-fonts-ttf-003.02.01.zip + try cp -f "$WINETRICKS_TMP"/takao-fonts-ttf-003.02.01/*.ttf "$winefontsdir" + + register_font TakaoGothic.ttf "TakaoGothic" + register_font TakaoPGothic.ttf "TakaoPGothic" + register_font TakaoMincho.ttf "TakaoMincho" + register_font TakaoPMincho.ttf "TakaoPMincho" + register_font TakaoExGothic.ttf "TakaoExGothic" + register_font TakaoExMincho.ttf "TakaoExMincho" +} + +#---------------------------------------------------------------- + +load_unifont() { + # The GNU Unifont provides glyphs for just about everything in common language. It is intended for multilingual usage. + # See http://unifoundry.com/unifont.html for project page + download . http://unifoundry.com/unifont-5.1.20080907.zip bb8a3960dc0a96aa305de28312ea8a0ab64123d2 + cp -f $WINETRICKS_CACHE/unifont-5.1.20080907.zip $WINETRICKS_TMP + try_unzip -d $WINETRICKS_TMP $WINETRICKS_TMP/unifont-5.1.20080907.zip + try cp -f "$WINETRICKS_TMP"/unifont-5.1.20080907.ttf "$winefontsdir/unifont.ttf" + + register_font unifont.ttf "Unifont" + + cat > "$WINETRICKS_TMP"/unifont.reg <<_EOF_ +REGEDIT4 + +[HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\FontSubstitutes] +"Arial Unicode MS"="Unifont" + +_EOF_ + + try_regedit "$WINETRICKS_TMP_WIN"\\unifont.reg +} + +#---------------------------------------------------------------- + +#---------------------------------------------------------------- + load_urlmon() { # This is an updated urlmon from IE 6.0 # See http://www.microsoft.com/downloads/details.aspx?familyid=85BB441A-5BB1-4A82-86EC-A249AF287513 # (Works for Dolphin Smalltalk, see http://bugs.winehq.org/show_bug.cgi?id=8258) download . http://download.microsoft.com/download/8/2/0/820faffc-3ea0-4914-bca3-584235964ded/Q837251.exe bcc79b92ac3c06c4de3692672c3d70bdd36be892 try_cabextract --directory="$WINETRICKS_TMP" "$WINETRICKS_CACHE/Q837251.exe" - try cp -f "$WINETRICKS_TMP"/URLMON.DLL "$WINDIR"/system32/urlmon.dll + try cp -f "$WINETRICKS_TMP"/URLMON.DLL "$SYSTEM32_DLLS"/urlmon.dll override_dlls native,builtin urlmon } @@ -3127,7 +3533,7 @@ load_usp10() { # http://www.microsoft.com/downloads/details.aspx?familyid=cebbacd8-c094-4255-b702-de3bb768148f download . http://download.microsoft.com/download/WindowsInstaller/Install/2.0/W9XMe/EN-US/InstMsiA.exe e739c40d747e7c27aacdb07b50925b1635ee7366 try_cabextract --directory="$WINETRICKS_TMP" "$WINETRICKS_CACHE"/InstMsiA.exe - try cp -f "$WINETRICKS_TMP"/usp10.dll "$WINDIR"/system32 + try cp -f "$WINETRICKS_TMP"/usp10.dll "$SYSTEM32_DLLS" override_dlls native,builtin usp10 } @@ -3135,7 +3541,9 @@ load_usp10() { load_utorrent() { # Torrent client supported on Windows,Mac OSX, Linux through WINE - download . http://download.utorrent.com/2.0.2/utorrent.exe dfec781877aa86afa941d512c3fc9e95c2b2bdea + # Oct 2010 sha1sum 8382b8a7bc625d68b6efe18a7b9e5488dc0119ee + # Nov 6 2010 sha1sum 263a91693d0976473cd321cd6f1b0103a814f3adx + download . http://download.utorrent.com/2.0.4/utorrent.exe 263a91693d0976473cd321cd6f1b0103a814f3ad try cp -f "$WINETRICKS_CACHE"/utorrent.exe "$WINDIR"/utorrent.exe warn "utorrent is now installed to $WINDIR/utorrent.exe" @@ -3148,7 +3556,7 @@ load_vb2run() { # See ftp://ftp.microsoft.com/Softlib/index.txt download . ftp://ftp.microsoft.com/Softlib/MSLFILES/VBRUN200.EXE ac0568b73ee375408778e9b505df995f79ab907e try_unzip -o $WINETRICKS_UNIXQUIET -d "$WINETRICKS_TMP" "$WINETRICKS_CACHE"/VBRUN200.EXE - try cp -f "$WINETRICKS_TMP/VBRUN200.DLL" "$WINDIR"/system32/ + try cp -f "$WINETRICKS_TMP/VBRUN200.DLL" "$SYSTEM32_DLLS" } @@ -3158,7 +3566,7 @@ load_vb3run() { # See http://support.microsoft.com/kb/196285 download . http://download.microsoft.com/download/vb30/utility/1/w9xnt4/en-us/vb3run.exe 518fcfefde9bf680695cadd06512efadc5ac2aa7 try_unzip -o $WINETRICKS_UNIXQUIET -d "$WINETRICKS_TMP" "$WINETRICKS_CACHE"/vb3run.exe - try cp -f "$WINETRICKS_TMP/Vbrun300.dll" "$WINDIR"/system32/ + try cp -f "$WINETRICKS_TMP/Vbrun300.dll" "$SYSTEM32_DLLS" } @@ -3168,8 +3576,8 @@ load_vb4run() { # See http://support.microsoft.com/kb/196286 download . http://download.microsoft.com/download/vb40ent/sample27/1/w9xnt4/en-us/vb4run.exe 83e968063272e97bfffd628a73bf0ff5f8e1023b try_unzip -o $WINETRICKS_UNIXQUIET -d "$WINETRICKS_TMP" "$WINETRICKS_CACHE"/vb4run.exe - try cp -f "$WINETRICKS_TMP/Vb40032.dll" "$WINDIR"/system32/ - try cp -f "$WINETRICKS_TMP/Vb40016.dll" "$WINDIR"/system32/ + try cp -f "$WINETRICKS_TMP/Vb40032.dll" "$SYSTEM32_DLLS" + try cp -f "$WINETRICKS_TMP/Vb40016.dll" "$SYSTEM32_DLLS" } @@ -3197,10 +3605,10 @@ load_vbrun60() { fi # Delete some fake DLLs to ensure that the installer overwrites them. - rm -f "$WINDIR"/system32/comcat.dll - rm -f "$WINDIR"/system32/oleaut32.dll - rm -f "$WINDIR"/system32/olepro32.dll - rm -f "$WINDIR"/system32/stdole2.tlb + rm -f "$SYSTEM32_DLLS"/comcat.dll + rm -f "$SYSTEM32_DLLS"/oleaut32.dll + rm -f "$SYSTEM32_DLLS"/olepro32.dll + rm -f "$SYSTEM32_DLLS"/stdole2.tlb # Exits with status 43 for some reason? $WINE "$WINETRICKS_CACHE"/vbrun60sp6.exe $WINETRICKS_QUIET @@ -3217,7 +3625,7 @@ load_vcrun6() { # Load the Visual C++ 6 runtime libraries, including the elusive mfc42u.dll # If this is just a dependency check, don't re-install - if test $PACKAGE != vcrun6 && test -f "$WINDIR"/system32/mfc42u.dll + if test $PACKAGE != vcrun6 && test -f "$SYSTEM32_DLLS"/mfc42u.dll then echo "prerequisite vcrun6 already installed, skipping" return @@ -3236,11 +3644,11 @@ load_vcrun6() { mv "$WINETRICKS_TMP"/vcredist.exe "$WINETRICKS_CACHE" fi # Delete some fake dlls to avoid vcredist installer warnings - rm -f "$WINDIR"/system32/comcat.dll - rm -f "$WINDIR"/system32/msvcrt.dll - rm -f "$WINDIR"/system32/oleaut32.dll - rm -f "$WINDIR"/system32/olepro32.dll - rm -f "$WINDIR"/system32/stdole2.tlb + rm -f "$SYSTEM32_DLLS"/comcat.dll + rm -f "$SYSTEM32_DLLS"/msvcrt.dll + rm -f "$SYSTEM32_DLLS"/oleaut32.dll + rm -f "$SYSTEM32_DLLS"/olepro32.dll + rm -f "$SYSTEM32_DLLS"/stdole2.tlb # vcredist still exits with status 43. Anyone know why? $WINE "$WINETRICKS_CACHE"/vcredist.exe @@ -3252,7 +3660,7 @@ load_vcrun6() { # And then some apps need mfc42u.dll, dunno what right way # is to get it, vcredist doesn't install it by default? - try_cabextract "$WINETRICKS_CACHE"/vcredist.exe -d "$WINDIR"/system32/ -F mfc42u.dll + try_cabextract "$WINETRICKS_CACHE"/vcredist.exe -d "$SYSTEM32_DLLS" -F mfc42u.dll override_dlls native,builtin msvcrt @@ -3273,11 +3681,11 @@ load_vcrun6sp6() { fi # Delete some fake dlls to avoid vcredist installer warnings - try rm -f "$WINDIR"/system32/comcat.dll - try rm -f "$WINDIR"/system32/msvcrt.dll - try rm -f "$WINDIR"/system32/oleaut32.dll - try rm -f "$WINDIR"/system32/olepro32.dll - try rm -f "$WINDIR"/system32/stdole2.tlb + try rm -f "$SYSTEM32_DLLS"/comcat.dll + try rm -f "$SYSTEM32_DLLS"/msvcrt.dll + try rm -f "$SYSTEM32_DLLS"/oleaut32.dll + try rm -f "$SYSTEM32_DLLS"/olepro32.dll + try rm -f "$SYSTEM32_DLLS"/stdole2.tlb # vcredist still exits with status 43. Anyone know why? $WINE "$WINETRICKS_CACHE"/vcredistsp6.exe @@ -3289,7 +3697,7 @@ load_vcrun6sp6() { # And then some apps need mfc42u.dll, dunno what right way # is to get it, vcredist doesn't install it by default? - try_cabextract "$WINETRICKS_CACHE"/vcredistsp6.exe -d "$WINDIR"/system32/ -F mfc42u.dll + try_cabextract "$WINETRICKS_CACHE"/vcredistsp6.exe -d "$SYSTEM32_DLLS" -F mfc42u.dll override_dlls native,builtin msvcrt } @@ -3302,7 +3710,7 @@ load_vcrun2003() { echo "Installing BZFlag (which comes with the Visual C++ 2003 runtimes)" download . $SOURCEFORGE/bzflag/BZEditW32_1.6.5_Installer.exe bdd1b32c4202fd77e6513fd507c8236888b09121 try $WINE "$WINETRICKS_CACHE"/BZEditW32_1.6.5_Installer.exe $WINETRICKS_S - try cp "$programfilesdir_unix/BZEdit1.6.5"/m*71* "$WINDIR"/system32/ + try cp "$programfilesdir_unix/BZEdit1.6.5"/m*71* "$SYSTEM32_DLLS" } #---------------------------------------------------------------- @@ -3805,7 +4213,7 @@ load_windowscodecs() { download . http://download.microsoft.com/download/f/f/1/ff178bb1-da91-48ed-89e5-478a99387d4f/wic_x86_enu.exe 53c18652ac2f8a51303deb48a1b7abbdb1db427f # Avoid a file existence check. - rm -f "$WINDIR"/system32/windowscodecs.dll + rm -f "$SYSTEM32_DLLS"/windowscodecs.dll override_dlls native,builtin windowscodecs # Always run the WIC installer in passive mode. @@ -3820,7 +4228,7 @@ load_windowscodecs() { load_winhttp() { # See https://www.microsoft.com/downloads/en/details.aspx?FamilyID=3ee866a0-3a09-4fdf-8bdb-c906850ab9f2 download . http://download.microsoft.com/download/5/d/8/5d802926-6bab-45fa-b96e-bee15413523b/Windows2000-KB842773-x86-ENU.EXE e676d47e065a314bbf1d15b096a67aede6b0539a - try_cabextract -d "$WINDIR"/system32/ -L -F winhttp.dll "$WINETRICKS_CACHE"/Windows2000-KB842773-x86-ENU.EXE + try_cabextract -d "$SYSTEM32_DLLS" -L -F winhttp.dll "$WINETRICKS_CACHE"/Windows2000-KB842773-x86-ENU.EXE override_dlls native,builtin winhttp } @@ -3832,7 +4240,7 @@ load_wininet() { # See http://www.microsoft.com/downloads/details.aspx?familyid=6DEE32AB-B618-4FB3-9A45-CDD08162E167 download . http://download.microsoft.com/download/ie5/Update/1/WIN98/EN-US/3725.exe b048e0b4e303298de3317b16f7008c43ca71ddfe try_cabextract --directory="$WINETRICKS_TMP" "$WINETRICKS_CACHE/3725.exe" - try cp -f "$WINETRICKS_TMP"/Wininet.dll "$WINDIR"/system32/wininet.dll + try cp -f "$WINETRICKS_TMP"/Wininet.dll "$SYSTEM32_DLLS"/wininet.dll override_dlls native,builtin wininet } @@ -3918,7 +4326,7 @@ load_wenquanyi() { load_wsh57() { # If this is just a dependency check, don't re-install - if test $PACKAGE != wsh56 && test $PACKAGE != wsh57 && test -f "$WINDIR"/system32/scrrun.dll + if test $PACKAGE != wsh56 && test $PACKAGE != wsh57 && test -f "$SYSTEM32_DLLS"/scrrun.dll then echo "prerequisite wsh57 already installed, skipping" return @@ -3927,7 +4335,7 @@ load_wsh57() { # See also http://www.microsoft.com/downloads/details.aspx?FamilyID=47809025-D896-482E-A0D6-524E7E844D81&displaylang=en download . http://download.microsoft.com/download/4/4/d/44de8a9e-630d-4c10-9f17-b9b34d3f6417/scripten.exe b15c6a834b7029e2dfed22127cf905b06857e6f5 - try_cabextract -d "$WINDIR"/system32 "$WINETRICKS_CACHE"/scripten.exe + try_cabextract -d "$SYSTEM32_DLLS" "$WINETRICKS_CACHE"/scripten.exe # Wine doesn't provide the other dll's (yet?) override_dlls native,builtin jscript.dll @@ -3965,11 +4373,11 @@ load_xact() { try_cabextract -d "$WINETRICKS_TMP" -L -F '*_xaudio_*x86*' "$WINETRICKS_CACHE"/$DIRECTX_NAME for x in `ls "$WINETRICKS_TMP"/*.cab` do - try_cabextract -d "$WINDIR"/system32 -L -F '*.dll' "$x" + try_cabextract -d "$SYSTEM32_DLLS" -L -F '*.dll' "$x" done # xactengine?_?.dll, xaudio?_?.dll - register - for x in `ls "$WINDIR"/system32/xactengine* "$WINDIR"/system32/xaudio*` + for x in `ls "$SYSTEM32_DLLS"/xactengine* "$SYSTEM32_DLLS"/xaudio*` do try $WINE regsvr32 `basename $x` done @@ -3977,6 +4385,20 @@ load_xact() { #---------------------------------------------------------------- +load_xinput() { + helper_directx_dl ; + + # xinput1_1.dll xinput1_2.dll xinput1_3.dll xinput9_1_0.dll + try_cabextract -d "$WINETRICKS_TMP" -L -F '*_xinput_*x86*' "$WINETRICKS_CACHE"/$DIRECTX_NAME + for x in `ls "$WINETRICKS_TMP"/*.cab` + do + try_cabextract -d "$SYSTEM32_DLLS" -L -F '*.dll' "$x" + done + +} + +#---------------------------------------------------------------- + load_xvid() { # xvid load_vcrun6 @@ -3984,12 +4406,6 @@ load_xvid() { try $WINE "$WINETRICKS_CACHE"/Xvid-1.2.2-07062009.exe $WINETRICKS_SILENT } -#---------------------------------------------------------------- - -print_version() { - echo "$VERSION" -} - #--------- Main program ----------------------------------------- # On Solaris, choose more modern commands (needed for id -u). @@ -3998,22 +4414,9 @@ SunOS) PATH="/usr/xpg6/bin:/usr/xpg4/bin:$PATH" ;; esac -case "$1" in --V|--version) - echo "Winetricks version $VERSION. (C) 2007-2010 Dan Kegel et al. LGPL." - exit 0 - ;; -esac - detect_menu detect_sudo -GUI=0 -case x"$1" in -x) GUI=1 ;; -x-h|x--help|xhelp) usage ; exit 1 ;; -esac - case "$OS" in "Windows_NT") ;; @@ -4060,6 +4463,10 @@ then programfilesdir_x86_unix="${programfilesdir_unix}" fi +# localized, and different across Windows versions: +appdata_win="`unset WINEDEBUG; WINEDLLOVERRIDES=mshtml= $WINE cmd.exe /c echo "%AppData%" | tr -d '\015'`" +appdata_unix="`unset WINEDEBUG; $XXXPATH -u "$appdata_win" | tr -d '\015' `" + # (Fixme: get fonts path from SHGetFolderPath # See also http://blogs.msdn.com/oldnewthing/archive/2003/11/03/55532.aspx) # @@ -4083,6 +4490,12 @@ else die "No sha1sum utility available." fi +# Warn the user if on win(e)64, since a lot of winetricks is broken for it +if [ "$ARCH" = "win64" ] +then + echo "You're using a 64-bit WINEPREFIX, most of winetricks hasn't been fixed for win64 yet. You can force a 32-bit WINEPREFIX by using WINEARCH=win32." +fi + while test "$1" != "" do PACKAGE=$1 @@ -4098,10 +4511,14 @@ do ;; -v) set -x;; 7zip|7-zip) load_7zip;; + abiword) load_abiword;; adobeair) load_adobeair;; + amstream) load_amstream;; + l3codecx) load_l3codecx;; art2kmin|art2k7min) load_art2kmin;; atmlib) load_atmlib;; autohotkey|ahk) load_autohotkey;; + baekmuk) load_baekmuk;; cmake) load_cmake;; comctl32.ocx) load_comctl32ocx;; comctl32|cc580) load_cc580;; @@ -4114,7 +4531,10 @@ do d3dx9) load_d3dx9;; d3dx9_26) load_d3dx9_xx 26;; d3dx9_28) load_d3dx9_xx 28;; + d3dx9_31) load_d3dx9_xx 31;; + d3dx9_35) load_d3dx9_xx 35;; d3dx9_36) load_d3dx9_xx 36;; + d3dx9_42) load_d3dx9_xx 42;; d3dx10) load_d3dx10;; d3dxof) load_d3dxof;; dcom98) load_dcom98;; @@ -4133,10 +4553,15 @@ do dotnet20sp2) load_dotnet20sp2; load_fontfix;; dotnet3|dotnet30) load_dotnet30; load_fontfix;; dotnet35) load_dotnet35; load_fontfix;; + dmsynth) load_dmsynth;; droid) load_droid;; + dsound) load_dsound;; dxsdk_nov2006) load_dxsdk_nov2006;; eadm) load_eadm;; eufonts) load_eufonts;; + fakechinese) load_fakechinese;; + fakejapanese) load_fakejapanese;; + fakekorean) load_fakekorean;; ffdshow) load_ffdshow;; firefox|firefox3) load_firefox;; flash) load_flash;; @@ -4153,6 +4578,7 @@ do glsl-enable) load_glsl_enable;; glut) load_glut;; hosts) load_hosts;; + ie6_full) load_ie6_full;; ie6) load_ie6;; ie7) load_ie7;; ie8) load_ie8;; @@ -4178,6 +4604,7 @@ do msxml3) load_msxml3;; msxml4) load_msxml4;; msxml6) load_msxml6;; + nvidiasdk95) load_nvidiasdk95;; ogg) load_ogg;; ole2) load_ole2;; openwatcom|watcom) load_openwatcom;; @@ -4190,6 +4617,7 @@ do python-comtypes|pythoncom|python-com|pythoncomtypes) load_python_comtypes;; quartz) load_quartz;; quicktime72) load_quicktime72;; + quicktime76) load_quicktime76;; riched20) load_riched20;; riched30) load_riched30;; richtx32) load_richtx32;; @@ -4198,6 +4626,8 @@ do shockwave) load_shockwave;; steam) load_steam;; tahoma) load_tahoma;; + takao) load_takao;; + unifont) load_unifont;; urlmon) load_urlmon;; usp10) load_usp10;; utorrent) load_utorrent;; @@ -4235,12 +4665,14 @@ do jscript|wsh56js) load_wsh56js;; wsh56vb) load_wsh56vb;; xact|xactengine|x3daudio|xapofx) load_xact;; + xinput) load_xinput;; xvid) load_xvid;; allcodecs|allvcodecs) load_vcrun6; load_ffdshow; load_xvid;; - allfonts) load_corefonts; load_droid; load_eufonts; load_liberation; load_lucida; load_tahoma; load_wenquanyi;; + allfonts) load_corefonts; load_droid; load_eufonts; load_liberation; load_lucida; load_tahoma; load_fakechinese; load_fakejapanese; load_fakekorean; load_unifont;; alldlls=builtin) override_all_dlls;; alldlls=default) override_no_dlls;; + cjkfonts) load_fakechinese; load_fakejapanese; load_fakekorean; load_unifont;; ddr=gdi) set_ddr gdi;; ddr=opengl) set_ddr opengl;; dsoundbug9612) load_dsoundbug9612;; @@ -4256,7 +4688,6 @@ do nocrashdialog) disable_crashdialog;; orm=backbuffer|backbuffer) set_orm backbuffer;; orm=fbo|fbo) set_orm fbo;; - orm=pbuffer|pbuffer) set_orm pbuffer;; rtlm=auto) set_rtlm auto;; rtlm=disabled) set_rtlm disabled;; rtlm=readdraw) set_rtlm readdraw;; @@ -4274,7 +4705,6 @@ do sound=disabled|sound=) set_sound_driver "";; strictdrawordering=enabled) set_sdo enabled;; strictdrawordering=disabled) set_sdo disabled;; - version) print_version;; videomemorysize=512) set_videomemorysize 512;; videomemorysize=1024) set_videomemorysize 1024;; videomemorysize=default) set_videomemorysize default;; @@ -4285,6 +4715,7 @@ do npm-repack) npm_repack;; psm=on) set_psm enabled;; psm=off) set_psm disabled;; + vd=*) arg=`echo $PACKAGE | sed 's/vd=//'`; set_virtualdesktop $arg ;; vsm-hard) set_vsm hardware;; winver=nt40|nt40) set_winver nt40;; winver=win98|win98) set_winver win98;; diff --git a/wisotool b/wisotool index 92eb093..8f46078 100644 --- a/wisotool +++ b/wisotool @@ -12,8 +12,9 @@ #---- Constants ------------------------------------------------- # Name of this version of wisotool (YYYYMMDD) -VERSION=20100731 +VERSION=20101106 +# Run a windows command without triggering wine's mshtml's gecko install dialog early_wine() { WINEDLLOVERRIDES=mshtml= $WINE "$@" @@ -29,18 +30,16 @@ case "$OS" in esac WINE="" WINESERVER=true - WINEPREFIX="${WINEPREFIX:-$HOME/.wine}" DRIVE_C="C:/" XXXPATH=cygpath ;; *) WINE=${WINE:-wine} WINEVERSION=`$WINE --version` - WINESERVER=${WINESERVER:-wineserver} + WINESERVER=${WINESERVER:-`which wineserver`} WINEPREFIX="${WINEPREFIX:-$HOME/.wine}" DRIVE_C="$WINEPREFIX/dosdevices/c:" XXXPATH="early_wine winepath" - # FIXME: does id work on mac/solaris? USERID=`id -u` ;; esac @@ -76,12 +75,15 @@ case "$WISOTOOL_CACHE_WIN" in then WISOTOOL_CACHE_SYMLINK="$WINEPREFIX"/dosdevices/${letter}: ln -sf "$WISOTOOL_CACHE" "$WISOTOOL_CACHE_SYMLINK" + WISOTOOL_CACHE_WIN=${letter}: break fi done ;; esac +# Make sure USERNAME is set. +# (USERNAME isn't quite a standard - some Unixes set LOGNAME instead.) USERNAME=${USERNAME:-$LOGNAME} # Overridden for windows @@ -291,6 +293,10 @@ regedit() { die oops, bug, please report } +wineserver() { + die oops, bug, please report +} + try_cabextract() { # Not always installed, but shouldn't be fatal unless it's being used CABEXTRACT="`which cabextract 2>/dev/null`" @@ -302,13 +308,27 @@ try_cabextract() { try $CABEXTRACT "$@" } +try_unrar() { + # Not always installed, but shouldn't be fatal unless it's being used + UNRAR="`which unrar 2>/dev/null`" + if test ! -x "$UNRAR" + then + die "Cannot find unrar. Please install it (e.g. 'sudo apt-get install unrar' or 'sudo yum install unrar'). For cygwin, you can get it at http://gnuwin32.sourceforge.net/packages/unrar.htm" + fi + + try $UNRAR "$@" +} + cabextract() { die oops, bug, please report } -# At some point, make the return value controllable by a global -# commandline option so we can see if we still need the workaround. # Usage: workaround_wine_bug bugnumber [good-wineversion-shell-pattern] +# False (nonzero status) on Windows. +# True (zero status) on Wine unless good-wineversion-shell-pattern is set +# and matches the current wine version. +# For debugging: if you want to skip a bug's workaround, put the bug number in the +# environment variable WISOTOOL_BLACKLIST to disable it. workaround_wine_bug() { if test "$WINE" = "" @@ -316,7 +336,6 @@ workaround_wine_bug() echo No need to work around wine bug $1 on windows return 1 fi - echo "Checking $WINEVERSION against $2" if test "$2" != "" then # Using shell patterns in a variable with case is tricky, need to use eval @@ -324,13 +343,13 @@ workaround_wine_bug() case $WINEVERSION in $2) echo No need to work around wine bug $1 in wine $WINEVERSION return 1 - ;; + ;; esac " eval "$checkcode" fi case $1 in - "$WISOTOOL_BLACKLIST") + "$WISOTOOL_BLACKLIST") echo wine bug $1 workaround blacklisted, skipping return 1 ;; @@ -382,7 +401,7 @@ download() { # zero size - bad download? rm "$cache/$file" fi - if test "$nosizecheck" != "" || test ! -f "$cache/$file" + if test "$nosizecheck" != "" || test ! -f "$cache/$file" || test "$WISOTOOL_CONTINUE_DOWNLOAD" then cd "$cache" # Mac folks tend to have curl rather than wget @@ -426,10 +445,11 @@ download() { esac cd "$olddir" - fi - if [ "$3"x != ""x ] - then - verify_sha1sum $3 "$cache/$file" + + if [ "$3"x != ""x ] + then + verify_sha1sum $3 "$cache/$file" + fi fi } @@ -513,7 +533,7 @@ iso_mount() warn "You don't seem to have an iso in $WISOTOOL_CACHE/$PACKAGE. Please insert the disk so I can prepare one for you." load_iso dd fi - + if test "$WINE" = "" then load_vcdmount @@ -527,8 +547,9 @@ iso_mount() do for ISO_MOUNT_LETTER in e f g h i j k do + echo "$WISOTOOL_MOUNT_LETTER_IGNORE" | grep -q "$ISO_MOUNT_LETTER" && continue ISO_MOUNT_ROOT=/cygdrive/$ISO_MOUNT_LETTER - if find $ISO_MOUNT_ROOT -iname 'setup*' -o -iname '*.exe' -o -iname '*.msi' + if find $ISO_MOUNT_ROOT -iname 'setup*' -o -iname '*.exe' -o -iname '*.msi' then break 2 fi @@ -640,7 +661,7 @@ mds_umount() then die "cdemu is not installed, can't mount .mds files!" fi - + # Initialize cdemu, if not already: # FIXME: Not sure this is 100% accurate... @@ -719,11 +740,11 @@ load_iso() { # Copy disc to .iso file, display progress every 5 seconds # Use conv=noerror,sync to replace unreadable blocks with zeroes case $method in - dd) + dd) dd if=$dev of="$WISOTOOL_CACHE"/temp.iso bs=2048 conv=noerror,sync & pid=$! ;; - ddrescue) + ddrescue) if test "`which ddrescue`" = "" then die "Please install ddrescue first." @@ -746,7 +767,7 @@ load_iso() { # FIXME: can't handle spaces in "$WISOTOOL_CACHE" sum=`sha1sum "$WISOTOOL_CACHE"/temp.iso | awk '{print $1}'` echo "Sha1sum of iso is $sum" - + mv "$WISOTOOL_CACHE"/temp.iso "$WISOTOOL_CACHE"/$sum.iso if test "$key" != "" then @@ -755,7 +776,7 @@ load_iso() { fi # Note: if you haven't written the verb for this disc yet, - # the .iso won't be moved to the right directory. + # the .iso won't be moved to the right directory. # So when writing a new verb, first run 'sh wisotool load', # then write just the verblist_add part (including sha1sum), then # run 'sh wisotool migrate' to move the iso into the right directory, @@ -768,7 +789,9 @@ load_iso() { #---------------------------------------------------------------- ahk_do() { - echo "$@" | sed "s/\$/ /" > "$WISOTOOL_TMP"/tmp.ahk + load_autohotkey + CR=`printf \\\\r` + echo "$@" | sed "s/\$/$CR/" > "$WISOTOOL_TMP"/tmp.ahk $WINE "$programfilesdir_unix/AutoHotkey/AutoHotkey.exe" "$WISOTOOL_TMP_WIN"\\tmp.ahk } @@ -891,8 +914,6 @@ verblist_init verblist_add 3dmark2000 "3DMark2000 (MadOnion.com, 2000) [download]" 3dmark2000_v11_100308.exe load_3dmark2000() { - load_autohotkey - # http://www.futuremark.com/download/3dmark2000/ if ! test -f "$WISOTOOL_CACHE/$PACKAGE/3dmark2000_v11_100308.exe" then @@ -923,7 +944,8 @@ load_3dmark2000() { ControlClick Button4 ; Finish " - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\MadOnion.com\3DMark2000" REM possible wine cmd bug: "3dmark2000" aborts, but ".\3dmark2000" works .\3DMark2000 @@ -936,8 +958,6 @@ __EOF__ verblist_add 3dmark2001 "3DMark2001 (MadOnion.com, 2001) [download]" 3dmark2001se_330_100308.exe load_3dmark2001() { - load_autohotkey - # http://www.futuremark.com/download/3dmark2001/ if ! test -f "$WISOTOOL_CACHE/$PACKAGE"/3dmark2001se_330_100308.exe then @@ -970,7 +990,6 @@ load_3dmark2001() { verblist_add 3dmark03 "3D Mark 03 (Futuremark, 2003) [download]" 3DMark03_v360_1901.exe load_3dmark03() { - load_autohotkey # http://www.futuremark.com/benchmarks/3dmark03/download/ if ! test -f "$WISOTOOL_CACHE/$PACKAGE/3DMark03_v360_1901.exe" @@ -982,6 +1001,7 @@ load_3dmark03() { warn "Don't use mouse while this installer is running. Sorry..." # This old installer doesn't seem to be scriptable the usual way, so spray and pray. ahk_do " + SetTitleMatchMode, 2 run 3DMark03_v360_1901.exe Sleep 4000 ; Welcome @@ -997,7 +1017,7 @@ load_3dmark03() { ; Begin install Send {Enter} ; Wait for install to finish - Sleep 35000 + WinWait 3DMark03, Registration ; Purchase later Send {Tab} Send {Tab} @@ -1008,7 +1028,8 @@ load_3dmark03() { Send {Tab} Send {Enter} " - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Futuremark\3DMark03" 3DMark03 __EOF__ @@ -1019,7 +1040,6 @@ __EOF__ verblist_add 3dmark05 "3D Mark 05 (Futuremark, 2005) [download]" 3DMark05_v130_1901.exe load_3dmark05() { - load_autohotkey # http://www.futuremark.com/download/3dmark05/ if ! test -f "$WISOTOOL_CACHE/$PACKAGE/3DMark05_v130_1901.exe" @@ -1051,7 +1071,8 @@ load_3dmark05() { warn "You must run the app with the -nosysteminfo option to avoid a crash on startup" ARGS="-nosysteminfo" fi - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Futuremark\3DMark05" 3DMark05 $ARGS __EOF__ @@ -1062,8 +1083,6 @@ __EOF__ verblist_add 3dmark06 "3D Mark 06 (Futuremark, 2006) [download]" 3DMark06_v120_1901.exe load_3dmark06() { - load_autohotkey - # http://www.futuremark.com/benchmarks/3dmark06/download/ if ! test -f "$WISOTOOL_CACHE/$PACKAGE/3DMark06_v120_1901.exe" then @@ -1112,7 +1131,8 @@ load_3dmark06() { ARGS="-nosysteminfo" fi - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Futuremark\3DMark06" 3DMark06 $ARGS __EOF__ @@ -1123,31 +1143,31 @@ __EOF__ verblist_add algodoo_demo "Algodoo Demo (Algoryx, 2009) [download]" Algodoo_1_7_1-Win32.exe load_algodoo_demo() { - load_autohotkey - download $PACKAGE http://www.algodoo.com/download/Algodoo_1_7_1-Win32.exe + download $PACKAGE http://www.algodoo.com/download/Algodoo_1_7_1-Win32.exe caa73e73669a8787652a6bed123bbe2682152f12 cd "$WISOTOOL_CACHE/$PACKAGE" ahk_do " run, Algodoo_1_7_1-Win32.exe SetTitleMatchMode, 2 winwait, Algodoo - send {Enter} + send {Enter} winwait, Algodoo, License - send {Tab}a{Space}{Enter} + send {Tab}a{Space}{Enter} winwait, Algodoo, Destination - send {Enter} + send {Enter} winwait, Algodoo, shortcuts - send {Enter} + send {Enter} winwait, Algodoo, Select Additional Tasks - send {Enter} + send {Enter} winwait, Algodoo, Ready to Install - send {Enter} + send {Enter} winwait, Algodoo, Completing - send {Space}{Tab}{Space}{Tab}{Space}{Enter} ; decline to run app or view tutorials + send {Space}{Tab}{Space}{Tab}{Space}{Enter} ; decline to run app or view tutorials " cd "$olddir" - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Algodoo" algodoo __EOF__ @@ -1155,151 +1175,9 @@ __EOF__ #---------------------------------------------------------------- -verblist_add aa3 "Americas Army 3 (U.S. Army, Ubisoft, 2009) [download]" aa3.tar - -load_aa3() { - # This verb is special. It's forked from load_steam_app(), for two reasons: - # A) the installer has an extra window to accept the EULA - # B) the game doesn't actually need Steam to run. Once it's installed with Steam, - # you can move the $steam_dir/steamapps/common/america's army 3 folder to C:\aa3 - # and it'll run fine (after installing the necessary winetricks workarounds). - # So, we'll install with Steam if the files aren't cached, then tar them up. Future - # 'installs', will unpack the tar to C:\aa3 (and winetricks/create .bat file). - - if [ ! -f "$WISOTOOL_CACHE/$PACKAGE/$PACKAGE.tar" ] - then - if [ ! "$STEAM_USER" -a ! -f "$WISOTOOL_CACHE"/STEAM_USER ] - then - die "You need to set STEAM_USER variable in your environment or put it in "$WISOTOOL_CACHE"/STEAM_USER" - elif [ ! "$STEAM_USER" -a -f "$WISOTOOL_CACHE"/STEAM_USER ] - then - STEAM_USER=`cat "$WISOTOOL_CACHE"/STEAM_USER` - fi - - if [ ! "$STEAM_PASS" -a ! -f "$WISOTOOL_CACHE"/STEAM_PASS ] - then - die "You need to set STEAM_PASS variable in your environment or put it in "$WISOTOOL_CACHE"/STEAM_PASS" - elif [ ! "$STEAM_PASS" -a -f "$WISOTOOL_CACHE"/STEAM_PASS ] - then - STEAM_PASS=`cat "$WISOTOOL_CACHE"/STEAM_PASS` - fi - - steam_dir="$programfilesdir_unix/Steam" - - load_autohotkey - test -f "$steam_dir/Steam.exe" || try sh $WINETRICKS -q steam - - app_id="13140" - game_title="America's Army 3" - game_cache_file="aa3_public_client.ncf" - game_folder="america's army 3" - - cd "$steam_dir" - sleep 5 - ahk_do " - run, Steam.exe -login $STEAM_USER $STEAM_PASS - Winwait, Steam - Updating,,60 - Loop - { - SetTitleMatchMode, Slow - IfWinExist, Steam - Updating - sleep 10000 - IfWinNotExist, Steam - Updating - break - } - sleep 30000 - run, steam://install/$app_id - - ; Info screen, disk space required, etc. - winwait, Install - $game_title - winactivate, Install - $game_title - ; FIXME: How long should this take? - sleep 10000 - send {enter} - sleep 10000 - - ; Install shortcuts? - winwait, Install - $game_title - winactivate, Install - $game_title - ; FIXME: How long should this take? - sleep 10000 - send {enter} - sleep 10000 - - ; Accept EULA? - winwait, Install - $game_title - winactivate, Install - $game_title - ; FIXME: How long should this take? - sleep 10000 - send {enter} - sleep 10000 - - ; Here, it's getting the .gcf/.ncf files. This is normally quick, but can take a long time. - ; Most finish in a few seconds, but the Total War demos takes a couple minutes. - ; So, we'll exit AHK, then wait for all the game files to be present, - ; before continuing the install. - exit - " - - # FIXME: Is this a long enough sleep? - sleep 30 - - ahk_do " - winwait, Install - $game_title - winactivate, Install - $game_title - ; FIXME: How long should this take? - sleep 10000 - send {enter} - " - - dl_log="$steam_dir/logs/download_log.txt" - while true - do - grep "SetHasAllLocalContent(true) called for $app_id" "$dl_log" && break - sleep 15 - done - - sleep 30 - $WINE Steam.exe -shutdown - mkdir -p "$WISOTOOL_CACHE/$PACKAGE" - cd "steamapps/common/$game_folder" - tar -cf "$WISOTOOL_CACHE/$PACKAGE/$PACKAGE.tar" . - cd .. - mv "$game_folder" "$DRIVE_C/aa3" - else - mkdir -p "$DRIVE_C/$PACKAGE" - cd "$DRIVE_C/$PACKAGE" - tar -xf "$WISOTOOL_CACHE/$PACKAGE/$PACKAGE.tar" - fi - -if workaround_wine_bug 17630 -then - sh "$WINETRICKS" -q d3dx10 -fi - -if workaround_wine_bug 22501 -then - sh "$WINETRICKS" -q vcrun2005 -fi - -if workaround_wine_bug 23660 -then - sh "$WINETRICKS" -q d3dx9 -fi - -cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ -cd "c:\\aa3\\Binaries" -AA3Game.exe -__EOF__ - -} - -#---------------------------------------------------------------- - verblist_add msaoe_demo "Age of Empires Demo (Microsoft, 1997) [download]" MSAoE.exe load_msaoe_demo() { - load_autohotkey download $PACKAGE http://download.microsoft.com/download/aoe/Trial/1.0/WIN98/EN-US/MSAoE.exe 23630a65ce4133038107f3175f8fc54a914bc2f3 cd "$WISOTOOL_CACHE/$PACKAGE" @@ -1317,7 +1195,8 @@ load_msaoe_demo() { " cd "$olddir" - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Microsoft Games\Age of Empires Trial" empires __EOF__ @@ -1325,66 +1204,120 @@ __EOF__ #---------------------------------------------------------------- -verblist_add apb "APB: All Points Bulletin (Electronic Arts, 2010)" APB_North_America_Installer.exe +verblist_add aoe3_demo "Age of Empires III (Microsoft, 2005) [download]" aoe3trial.exe -load_apb() { - load_autohotkey +load_aoe3_demo() { - download $PACKAGE http://rtworlds.http.internapcdn.net/rtworlds/NA/APB/BETA/INSTALLER/1.1.0.538715/APB_North_America_Installer.exe c40071616096becb72f10a2e7721ef340c48ad4e + download $PACKAGE "http://download.microsoft.com/download/a/5/2/a525997e-8423-435b-b694-08118d235064/aoe3trial.exe" \ + 2b0a123243092d79f910db5691d99d469f7c17c3 - sh "$WINETRICKS" -q dotnet20 + if workaround_wine_bug 24897 + then + try sh "$WINETRICKS" -q msxml4 + fi cd "$WISOTOOL_CACHE/$PACKAGE" - if workaround_wine_bug 23527 + ahk_do " + SetTitleMatchMode, 2 + run aoe3trial.exe + WinWait,Empires,Welcome + Sleep 500 + ControlClick Button1 ; Next + WinWait,Empires,Please + Sleep 500 + ControlClick Button4 ; Next + WinWait,Empires,Complete + Sleep 500 + ControlClick Button4 ; Finish + WinWaitClose + " + + if workaround_wine_bug 24911 then - sh "$WINETRICKS" -q gdiplus + # On some systems, only quartz is needed? + # appdb says that l3codecx is also needed? + try sh "$WINETRICKS" -q devenum dmsynth quartz fi + if workaround_wine_bug 24912 + then + # kill off lingering installer + ahk_do " + SetTitleMatchMode, 2 + WinKill,Empires + " + # or should we just do wineserver -k, like fable_tlc does? + PID=`ps augxw | grep IDriver | grep -v grep | awk '{print $2}'` + kill $PID + fi + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Microsoft Games\\Age of Empires III Trial" +age3.exe +__EOF__ +} + +#---------------------------------------------------------------- + +verblist_add anno1404_demo "Anno 1404 Demo (Ubisoft, 2009) [download]" DawnofDiscovery_Demo_US_2009_06_15_18_22.zip + +load_anno1404_demo() { + if ! test -f "$WISOTOOL_CACHE/$PACKAGE/DawnofDiscovery_Demo_US_2009_06_15_18_22.zip" + then + mkdir -p "$WISOTOOL_CACHE/$PACKAGE" + die "Please download demo from http://www.filefront.com/thankyou.php?f=13908918 and place it in $WISOTOOL_CACHE/$PACKAGE" + fi + + mkdir -p "$WISOTOOL_TMP/$PACKAGE" + cd "$WISOTOOL_TMP/$PACKAGE" + try unzip "$WISOTOOL_CACHE/$PACKAGE"/DawnofDiscovery_Demo_US_2009_06_15_18_22.zip + try cd "Anno1404_Demo_US_2009_06_15_18_22" ahk_do " - SetTitleMatchMode, 2 - run, APB_North_America_Installer.exe - winwait, Installer language, Please select the language you would like the installer to run in - sleep 1000 - controlclick, Button1, Installer language, Please select the language you would like the installer to run in - winwait, APB North America v1.1.0.538715, Welcome to the APB All Points Bulletin Setup Wizard - sleep 1000 - controlclick, Button2, APB North America v1.1.0.538715, Welcome to the APB All Points Bulletin Setup Wizard - winwait, APB North America v1.1.0.538715, Please review the license terms before installing APB All Points Bulletin. - sleep 1000 - controlclick, Button4, APB North America v1.1.0.538715, Please review the license terms before installing APB All Points Bulletin. - sleep 1000 - controlclick, Button2, APB North America v1.1.0.538715, Please review the license terms before installing APB All Points Bulletin. - winwait, APB North America v1.1.0.538715, Third Party Library List - sleep 1000 - controlclick, Button5, APB North America v1.1.0.538715, Third Party Library List - sleep 1000 - controlclick, Button2, APB North America v1.1.0.538715, Third Party Library List - winwait, APB North America v1.1.0.538715, System Check - sleep 1000 - controlclick, Button2, APB North America v1.1.0.538715, System Check - winwait, APB North America v1.1.0.538715, Results of the system scan. - sleep 1000 - controlclick, Button2, APB North America v1.1.0.538715, Results of the system scan. - winwait, APB North America v1.1.0.538715, Choose the folder in which to install APB All Points Bulletin. - sleep 1000 - controlclick, Button2, APB North America v1.1.0.538715, Choose the folder in which to install APB All Points Bulletin. - winwait, APB North America v1.1.0.538715, APB All Points Bulletin will be installed in C:\Program Files\Realtime Worlds\APB North America. Is this okay? - sleep 1000 - controlclick, Button1, APB North America v1.1.0.538715, APB All Points Bulletin will be installed in C:\Program Files\Realtime Worlds\APB North America. Is this okay? - winwait, APB North America v1.1.0.538715, Choose a Start Menu folder for the APB All Points Bulletin shortcuts. - sleep 1000 - controlclick, Button2, APB North America v1.1.0.538715, Choose a Start Menu folder for the APB All Points Bulletin shortcuts. - winwait, APB North America v1.1.0.538715, Setup was completed successfully. - sleep 1000 - controlclick, Button2, APB North America v1.1.0.538715, Setup was completed successfully. - winwait, APB North America v1.1.0.538715, The APB Launcher has been installed. - sleep 1000 - controlclick, Button2, APB North America v1.1.0.538715, The APB Launcher has been installed. - ; Runs after install. However, also crashes in current (1.2-rc6) wine. For now, kill both, just in case... - process, close, APBLauncher.exe - process, close, BugReport.exe + run, setup.exe + SetTitleMatchMode, 2 + winwait, , Welcome to the InstallShield Wizard for Dawn of Discovery (Demo) + ControlClick, Button3 ; Next + winwait, , Licence Agreement + ControlClick, Button2 ; Accept + ControlClick, Button6 ; Next + winwait, , Setup Type + ControlClick Button4 ; Next + winwait, , Select Options + ControlClick Button6 ; Next + winwait, Question + ControlClick Button2 ; No + winwait, , InstallShield Wizard completed + Controlclick Button4 ; Finish " + + if workaround_wine_bug 22762 + then + if test -f "$DRIVE_C/users/$USERNAME/Application Data/Ubisoft/Anno1404Demo/Config/Engine.ini" + then + cd "$DRIVE_C/users/$USERNAME/Application Data/Ubisoft/Anno1404Demo/Config/" + mv Engine.ini oldEngine.ini + sed '/LanguageTAG/s,eng,usa,; + /DirectXVersion/s,0,9,' oldEngine.ini > Engine.ini + else + mkdir -p "$DRIVE_C/users/$USERNAME/Application Data/Ubisoft/Anno1404Demo/Config/" + cat > "$DRIVE_C/users/$USERNAME/Application Data/Ubisoft/Anno1404Demo/Config/Engine.ini" <<__EOF__ + +9 +usa + +__EOF__ + fi + fi + + cd "$olddir" + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Ubisoft\\Related Designs\\Dawn of Discovery (Demo)" +Anno4.exe +__EOF__ } #---------------------------------------------------------------- @@ -1392,8 +1325,6 @@ load_apb() { verblist_add assassinscreed "Assassins Creed (Ubisoft, 2008)" a62112860423b32bf3ea77df6f5fe0b60c772de2.iso load_assassinscreed() { - load_autohotkey - if workaround_wine_bug 22392 then # Don't hang at a dialog box when Detection crashes @@ -1426,7 +1357,8 @@ load_assassinscreed() { # Should run AssassinsCreed_Launcher.exe, but that fails on Wine # Should give option to run AssassinsCreed_Dx10.exe, but that fails on Wine - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Ubisoft\Assassin's Creed" AssassinsCreed_Dx9.exe __EOF__ @@ -1438,28 +1370,18 @@ verblist_add avatar_demo "James Camerons Avatar The Game Demo (Ubisoft, 2009) load_avatar_demo() { - load_autohotkey - if ! test -f "$WISOTOOL_CACHE/$PACKAGE/Avatar_The_Game_Demo.exe" - then - mkdir -p "$WISOTOOL_CACHE/$PACKAGE" - die "You must first download the demo from http://www.bigdownload.com/games/james-camerons-avatar-the-game/pc/james-camerons-avatar-the-game-demo/ and place the exe in $WISOTOOL_CACHE/$PACKAGE" - fi + download $PACKAGE http://gamedaily.newaol.com/pub/Avatar_The_Game_Demo.exe 8d8e4c82312962706bd2620406d592db4f0fa9c1 if workaround_wine_bug 23094 then - try sh winetricks -q vcrun2005 + try sh "$WINETRICKS" -q vcrun2005 fi mkdir -p "$WISOTOOL_TMP/$PACKAGE" - cd "$WISOTOOL_CACHE/$PACKAGE" + cd "$WISOTOOL_TMP/$PACKAGE" + try_unrar x "$WISOTOOL_CACHE/$PACKAGE/Avatar_The_Game_Demo.exe" ahk_do " SetTitleMatchMode, 2 - run, Avatar_The_Game_Demo.exe - winwait, WinRAR, Install - send $WISOTOOL_TMP_WIN\\$PACKAGE - controlclick, Button2 - winwaitclose, WinRAR - sleep 1000 run, setup.exe winwait, Language controlclick, Button1 @@ -1470,17 +1392,25 @@ load_avatar_demo() controlclick, Button2 winwait, AVATAR, setup type controlclick, Button2 - ;Strange CRC error workaround. Will check this out. Stay tuned. - sleep 1000 - ifwinactive, CRC Error + ; Strange CRC error workaround. Will check this out. Stay tuned. + loop { - controlclick, Button5 + ifwinexist, CRC Error + { + winactivate, CRC Error + controlclick, Button3, CRC Error ; ignore + } + ifwinexist, AVATAR, Complete + { + controlclick, Button4 + break + } + sleep 1000 } - winwait, AVATAR, Complete - controlclick, Button4 " cd "$olddir" - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Ubisoft\Demo\James Cameron's AVATAR - THE GAME (Demo)\bin" "AvatarDemo.exe" __EOF__ @@ -1496,8 +1426,6 @@ verblist_add baldursgate2 "Baldurs Gate 2 - Shadows of Amn (Bioware, 2000) 94ed41768949c89a1a6479305f00a9cee1d2dcd5.iso load_baldursgate2() { - load_autohotkey - # Possible wine bug: cd is still in use, even if wine eject is used. Workaround it by # copying all the cd's to a directory, and running the installer from there. # You still need the first CD mounted at the end, however... @@ -1517,10 +1445,10 @@ load_baldursgate2() { sleep 5 try cp -r "$ISO_MOUNT_ROOT"/* "$WISOTOOL_TMP"/$PACKAGE/tempcd fi - + # Will perform a full install, so no cd's needed iso_mount "$WISOTOOL_CACHE"/$PACKAGE/cc9359dce1a7be6c64bb6f8e6dea6d14d4a5f716.iso - + ahk_do " SetTitleMatchMode, 2 run "$WISOTOOL_TMP"/$PACKAGE/tempcd/setup.exe @@ -1579,13 +1507,13 @@ load_baldursgate2() { exit" cd - try rm "$WISOTOOL_TMP/baldurs_gate_2_patch.exe" - + if workaround_wine_bug 22482 then sh "$WINETRICKS" -q ddr=opengl warn "Enabling 3d acceleration in BGConfig.exe will improve performance." fi - + if workaround_wine_bug 22493 then warn "Enabling 3d acceleration in BGConfig.exe will improve performance." @@ -1599,15 +1527,125 @@ load_baldursgate2() { #---------------------------------------------------------------- +verblist_add batman_arkham_asylum_demo "Batman: Arkham Asylum Demo (Warner/Eidos/Enix 2009) (size: 2.0 GB)[download]" BMDemo_installer.exe + +load_batman_arkham_asylum_demo() { + download $PACKAGE http://cdn2.netops.eidosinteractive.com/batmanarkhamasylum/BMDemo_installer.exe 7582c87cc3983016c7fbf2104999df087ecce7a6 + + cd "$WISOTOOL_CACHE/$PACKAGE" + + ahk_do " + run BMDemo_installer.exe + SetTitleMatchMode, 2 + WinWait, Batman: Arkham Asylum Demo, Select Language + WinActivate + Send {Enter} + WinWait, Batman: Arkham Asylum Demo, Install Demo + WinActivate + Send {Tab} + Send {Enter} + WinWait, Batman: Arkham Asylum Demo, Welcome + WinActivate + Send {Enter} + WinWait, Batman: Arkham Asylum Demo, License Agreement + WinActivate + Send +!a + Send {Enter} + Loop { + Sleep (1000) + IfWinExist, Batman: Arkham Asylum Demo, System Check Results + { + Sleep (300) + WinActivate + Send {Enter} + break + } + IfWinExist, Batman: Arkham Asylum Demo, Your computer fails to meet + { + Sleep (300) + Send +!o + } + IfWinExist, Batman: Arkham Asylum Demo, Setup has detected + { + Sleep (300) + Send +!o ; I'm not sure about this keystroke sequence + } + } + WinWait, Batman: Arkham Asylum Demo, Setup Type + WinActivate + Send {Enter} + + Loop + { + IfWinExist, NVIDIA, license + { + Sleep (500) + WinActivate + Send +!a ; license agreement + Send +!n ; next + } + IfWinExist, NVIDIA, finish + { + WinActivate + Send +!f ; finish + } + IfWinExist, DXSETUP.exe - Error + { + Send {Enter} ; DirectX9 Redistributable trying to install managed components, failing, but that's ok + } + IfWinExist, Fatal Error + { + Send {Enter} ; PhysX installer exploded because wsh not installed, or dotnet30 not installed, probably ok + } + Process, Exist, BmLauncher.exe ; BmLauncher automatically starts after installation finished. + retVal = %ErrorLevel% + if retVal != 0 + { + Process, Close, BmLauncher.exe ; kill BmLauncher + break + } + Sleep (2000) + } + " + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Eidos\\Batman Arkham Asylum Demo\\Binaries" +ShippingPC-BmGame.exe +__EOF__ + + if workaround_wine_bug 6971 + then + warn "The mouse is still broken in wine, but winetricks mwo=force will make the game much more playable, try it." + fi + if workaround_wine_bug 20651 + then + download $PACKAGE http://www.glio.net/UserEngine.ini + download $PACKAGE http://www.glio.net/UserInput.ini + download $PACKAGE http://www.glio.net/UserGame.ini + configdir="$DRIVE_C/users/$USERNAME/My Documents/Eidos/Batman Arkham Asylum Demo/BmGame/Config" + mkdir -p "$configdir" + cp "$WISOTOOL_CACHE/$PACKAGE"/*.ini "$configdir" + fi + if workaround_wine_bug 24471 + then + sh "$WINETRICKS" mmdevapi=disabled + fi +} + +#-------------------------------------------------------------------------------------- + +# Sadly, the SHA1SUM varies! +# FIXME: change load function to call it by its volume label instead; right now you have to rename it manually. + verblist_add bfbc2 "Battlefield Bad Company 2 (EA, 2010)" \ - 9ec587f1eda0f8bf13f485526e3c46e4f9d477a6.iso + BFBC2.iso load_bfbc2() { - load_autohotkey exedir="$programfilesdir_x86_unix/Electronic Arts/Battlefield Bad Company 2" - iso_mount "$WISOTOOL_CACHE"/$PACKAGE/9ec587f1eda0f8bf13f485526e3c46e4f9d477a6.iso - BFBC2_KEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/9ec587f1eda0f8bf13f485526e3c46e4f9d477a6.txt | tr -d -` + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/BFBC2.iso + BFBC2_KEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/BFBC2.txt | tr -d -` ahk_do " SetTitleMatchMode, 2 run ${ISO_MOUNT_LETTER}:setup.exe @@ -1655,7 +1693,7 @@ load_bfbc2() { then mv BFBC2/settings.ini BFBC2/oldsettings.ini sed 's,DxVersion=auto,DxVersion=9,; - s,Fullscreen=true,Fullscreen=false,' BFBC2/oldsettings.ini > BFBC2/settings.ini + s,Fullscreen=true,Fullscreen=false,' BFBC2/oldsettings.ini > BFBC2/settings.ini else mkdir -p BFBC2 echo "[Graphics]" > BFBC2/settings.ini @@ -1663,12 +1701,13 @@ load_bfbc2() { fi fi cd "$olddir" - + if workaround_wine_bug 22961 then warn "If you get a Securom 'No CD/DVD error', check your mount settings. See http://bugs.winehq.org/show_bug.cgi?id=22961 for more info." fi - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Electronic Arts\\Battlefield Bad Company 2" BFBC2Game.exe __EOF__ @@ -1684,17 +1723,25 @@ __EOF__ # mds: 391042ea19b4eace5d532dbade10931ebbc4def6 # mdf: deaf00ebee6e73aecf38f704c3f516008a68d888 verblist_add bioshock "Bioshock (2K Games, 2007)" \ - 391042ea19b4eace5d532dbade10931ebbc4def6.mds + 391042ea19b4eace5d532dbade10931ebbc4def6.mds \ + deaf00ebee6e73aecf38f704c3f516008a68d888.iso load_bioshock() { - load_autohotkey - # Bioshock needs MSVCP80.dll to run, which Wine doesn't have yet. if workaround_wine_bug 22501 then sh "$WINETRICKS" -q vcrun2005 fi - + + # If .iso is present, use it rather than the .mds (.mds is still flaky, maybe we should just get rid of mds support) + # FIXME: 'wisotool ls' only shows apps as loaded if all files present, so we need a way to + # tell it either iso or mds is ok. + if test -f "$WISOTOOL_CACHE"/$PACKAGE/deaf00ebee6e73aecf38f704c3f516008a68d888.iso + then + load_bioshock_iso + return 0 + fi + # Will perform a full install, so no cd's needed mds_mount "$WISOTOOL_CACHE/$PACKAGE/391042ea19b4eace5d532dbade10931ebbc4def6.mds" @@ -1705,7 +1752,7 @@ load_bioshock() { # Don't trim the hyphen's "-", the installer won't proceed without them. BIOSHOCK_KEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/391042ea19b4eace5d532dbade10931ebbc4def6.txt` - + ahk_do " SetTitleMatchMode, 2 run ${ISO_MOUNT_LETTER}:setup.exe @@ -1754,7 +1801,7 @@ load_bioshock() { winwait, Activation Successful Sleep 1000 Controlclick, Button3, Activation Successful - " || ( wineserver -k ; warn "Bioshock failed to install properly, likely the Securom check failed" ) + " || ( $WINESERVER -k ; warn "Bioshock failed to install properly, likely the Securom check failed" ) # According to the AppDB, 1.1 may have problems with Wine. For now, don't run it. # FIXME: Test and if there's a Wine bug, file one/put this in an if workaround_wine_bug(). @@ -1782,16 +1829,97 @@ load_bioshock() { sh "$WINETRICKS" -q mwo=force fi + if workaround_wine_bug 23884 + then + sh "$WINETRICKS" -q d3dx9_36 + fi + mds_umount } +# sub-verb of bioshock which is used if the user loads from a .iso instead of .mds +# Doesn't quite work yet unless you have the cd mounted :-( +load_bioshock_iso() +{ + + BIOSHOCK_KEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/deaf00ebee6e73aecf38f704c3f516008a68d888.txt` + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/deaf00ebee6e73aecf38f704c3f516008a68d888.iso + + ahk_do " + SetTitleMatchMode, 2 + run ${ISO_MOUNT_LETTER}:setup.exe + winwait, BioShock - InstallShield Wizard, Choose Setup Language + sleep 2000 + ControlClick, Button3, BioShock - InstallShield Wizard, Choose Setup Language + ControlClick, Button3, BioShock - InstallShield Wizard, Choose Setup Language ; Installer seems fidgety + winwait, BioShock - InstallShield Wizard, Welcome to the InstallShield Wizard for BioShock + sleep 1000 + ControlClick, Button1, BioShock - InstallShield Wizard, Welcome to the InstallShield Wizard for BioShock + winwait, BioShock - InstallShield Wizard, Please read the following license agreement carefully + sleep 1000 + ControlClick, Button5, BioShock - InstallShield Wizard, Please read the following license agreement carefully + sleep 1000 + ControlClick, Button2, BioShock - InstallShield Wizard, Please read the following license agreement carefully + winwait, BioShock - InstallShield Wizard, Select the setup type to install + sleep 1000 + ControlClick, Button2, BioShock - InstallShield Wizard, Select the setup type to install + winwait, BioShock - InstallShield Wizard, Click Install to begin the installation + ControlClick, Button1, BioShock - InstallShield Wizard, Click Install to begin the installation + Loop + { + ; Detect if Securom likes the mounted ISO or not. If so, continue the install. If not, exit since the install will fail. + SetTitleMatchMode, Slow + IfWinExist, BioShock, The InstallShield Wizard has successfully installed BioShock + break + IfWinExist, Bioshock, Please insert the original + { + exit 1 + } + sleep 10000 + } + sleep 1000 + ControlClick, Button6, BioShock - InstallShield Wizard, The InstallShield Wizard has successfully installed BioShock + sleep 1000 + ControlClick, Button4, BioShock - InstallShield Wizard, The InstallShield Wizard has successfully installed BioShock + winwait, Welcome, &Next + Sleep 1000 + ControlClick, Button2, Welcome, &Next + winwait, Enter your serial number, &Activate + Sleep 1000 + ControlClick, Edit1, Enter your serial number, &Activate + send {Raw}$BIOSHOCK_KEY + Sleep 1000 + ControlClick, Button1, Enter your serial number, &Activate + winwait, Activation Successful + Sleep 1000 + Controlclick, Button3, Activation Successful + " || ( $WINESERVER -k ; warn "Bioshock failed to install properly, likely the Securom check failed" ) + + iso_umount + + if workaround_wine_bug 6971 + then + sh "$WINETRICKS" -q mwo=force + fi + + if workaround_wine_bug 23884 + then + sh "$WINETRICKS" -q d3dx9_36 + fi + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\2K Games\\BioShock\\Builds\\Release" +bioshock.exe +__EOF__ +} + #---------------------------------------------------------------- verblist_add bioshock_demo "Bioshock Demo (2K Games, 2007)" \ nzd_BioShockPC.zip load_bioshock_demo() { - load_autohotkey download $PACKAGE http://us.download.nvidia.com/downloads/nZone/demos/nzd_BioShockPC.zip 7a19186602cec5210e4505b58965e8c04945b3cf cd "$DRIVE_C" rm -rf bioshock-temp @@ -1832,11 +1960,55 @@ load_bioshock_demo() { #---------------------------------------------------------------- +verblist_add bladekitten_demo "Blade Kitten Demo (Krome Studios Pty Ltd., 2010) [download]" BladeKittenDemoInstall.exe + +load_bladekitten_demo() { + if ! test -f "$WISOTOOL_CACHE/$PACKAGE/BladeKittenDemoInstall.exe" + then + download $PACKAGE "http://downloads.megagames.com/download.php?file=BladeKittenDemoInstall.exe" 8c41706ff3ad029317e5eb6853c34732498d97c7 + cd "$WISOTOOL_CACHE/$PACKAGE" + mv 'download.php?file=BladeKittenDemoInstall.exe' "BladeKittenDemoInstall.exe" + fi + + mkdir "$WISOTOOL_TMP/BladeKittenDemo" + cp "$WISOTOOL_CACHE/$PACKAGE"/BladeKittenDemoInstall.exe "$WISOTOOL_TMP"/BladeKittenDemo + cd "$WISOTOOL_TMP"/BladeKittenDemo + ahk_do " + SetTitleMatchMode, 3 + run BladeKittenDemoInstall.exe + WinWait "Blade Kitten Demo Install Package" + ControlClick Button2 ; Install + WinWait "Blade Kitten Demo", Next + ControlClick Button1 + WinWait "Blade Kitten Demo", Cost + ControlClick Button1 ; Next + WinWait "Blade Kitten Demo", ready + ControlClick Button1 ; Next + ; Note - If you are running an older version of wine the installer may appear to hang for 6-10 minutes at this point + WinWait "Blade Kitten Demo", Complete + ControlClick Button1 ; Close + " + mv "$WISOTOOL_TMP/BladeKittenDemo" "$DRIVE_C/Program Files" + + if workaround_wine_bug 24681 + then + set_app_winver BladeKitten_Demo.exe win2k + fi + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Krome Studios\\Blade Kitten Demo" +BladeKitten_Demo.exe +__EOF__ + +} + +#---------------------------------------------------------------- + verblist_add blur "Blur (Activision, 2010)" \ 30fdaf3aad82be846f26b7908c703598d5c3443d.iso load_blur() { - load_autohotkey iso_mount "$WISOTOOL_CACHE"/$PACKAGE/30fdaf3aad82be846f26b7908c703598d5c3443d.iso ahk_do " @@ -1858,26 +2030,30 @@ load_blur() { winwait, Blur, Setup Type sleep 1000 send {Enter} + winwaitclose, Blur + ; the installer still has a bit of stuff to do after that window closes + sleep 10000 " - # Installer seems to crash at end on Win7 and Wine - # Wait for last file to be created(Blur.exe?), then kill wineserver - # and do the d3dx physx install by using winetricks. - while [ ! -f "$programfilesdir_x86_unix"/Activision/Blur*/Blur.exe ] - do - sleep 5 - done - # Sleep for 30 seconds to ensure that all files have been created - # before killing the wineserver. - sleep 30 - wineserver -k - - # We killed the wineserver before(or during) the d3dx9 and physx install - # so use winetricks to install them. The game runs without the physx trick - # but frame rate improves with physx. - try sh "$WINETRICKS" -q d3dx9 physx iso_umount - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ -cd "$programfilesdir_x86_win\Activision\Blur*" + + # FIXME: The installer didn't install physx (does it on windows? If so, file wine bug). + # The game runs without the physx trick but frame rate improves with physx. + try sh "$WINETRICKS" -q physx + + if workaround_wine_bug 24509 + then + warn "Game will crash on first run (which is in full screen). On second run, it will go to windowed mode. Workaround this by defaulting to a 1024x768 window." + try mkdir -p "$appdata_unix/bizarre creations/blur" + cat > "$appdata_unix/bizarre creations/blur/settings.xml" <<__EOF__ + + +__EOF__ + + fi + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\Activision\Blur(TM)" "Blur.exe" __EOF__ } @@ -1888,14 +2064,11 @@ verblist_add braid_demo "Braid Demo (Number None, 2009) [download]" braid_win load_braid_demo() { - load_autohotkey - if ! test -f "$WISOTOOL_CACHE/$PACKAGE/braid_windows_r3.exe" then - download $PACKAGE "http://www.playgreenhouse.com/php/public/tracking/downloads.php?sku=NNONE-000001-01&platform=win" 7ea08ddbf5f2fb2f38057d930389b5af7d737e2c + download $PACKAGE http://download.instantaction.com/games/pgh_legacy/braid_windows_r3.exe 7ea08ddbf5f2fb2f38057d930389b5af7d737e2c fi cd "$WISOTOOL_CACHE/$PACKAGE" - mv downloads.php* braid_windows_r3.exe 2>/dev/null ahk_do " SetTitleMatchMode, 2 run, braid_windows_r3.exe @@ -1908,7 +2081,7 @@ load_braid_demo() winwait, Setup, Finishing installation sleep 5000 ; Workaround_winebug 21761 - ifwinactive, Setup, ShellExecuteEx failed + ifwinactive, Setup, ShellExecuteEx failed { controlclick, Button1 } @@ -1921,12 +2094,13 @@ load_braid_demo() then try sh "$WINETRICKS" -q d3dx9_36 fi - - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Braid" braid.exe __EOF__ -} +} #---------------------------------------------------------------- @@ -1934,13 +2108,16 @@ verblist_add braid "Braid (Number None, 2009) [download]" braid_windows_r3.ex load_braid() { - load_autohotkey - + if ! test -f "$WISOTOOL_CACHE/$PACKAGE/braid-key.txt" + then + mkdir -p "$WISOTOOL_CACHE/$PACKAGE" + die "Please enter your registration key into $WISOTOOL_CACHE/$PACKAGE/braid-key.txt" + fi BRAID_KEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/braid-key.txt` if ! test -f "$WISOTOOL_CACHE/$PACKAGE/braid_windows_r3.exe" then - download $PACKAGE "http://www.playgreenhouse.com/php/public/tracking/downloads.php?sku=NNONE-000001-01&platform=win" 7ea08ddbf5f2fb2f38057d930389b5af7d737e2c + download $PACKAGE http://download.instantaction.com/games/pgh_legacy/braid_windows_r3.exe 7ea08ddbf5f2fb2f38057d930389b5af7d737e2c fi cd "$WISOTOOL_CACHE/$PACKAGE" mv downloads.php* braid_windows_r3.exe 2>/dev/null @@ -1956,7 +2133,7 @@ load_braid() winwait, Setup, Finishing installation sleep 5000 ; Workaround_winebug 21761 - ifwinactive, Setup, ShellExecuteEx failed + ifwinactive, Setup, ShellExecuteEx failed { controlclick, Button1 } @@ -1968,15 +2145,15 @@ load_braid() then try sh "$WINETRICKS" -q d3dx9_36 fi - - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Braid\" "braid.exe" __EOF__ # Enter the key cd "$DRIVE_C" - ls ahk_do " SetTitleMatchMode, 2 run, run-$PACKAGE.bat @@ -1985,15 +2162,61 @@ __EOF__ winwait, Enter Registration send {RAW}$BRAID_KEY controlclick, Button1 + sleep 5000 + ; FIXME: Desktop resolution isn't reset after exit + process, close, braid.exe " - sleep 5 - # FIXME: use right wineserver - wineserver -k cd "$olddir" -} +} #---------------------------------------------------------------- +verblist_add cod_demo "Call of Duty (Activision, 2003) [download]" Call_Of_Duty_Demo.exe + +load_cod_demo() { + download $PACKAGE "http://gamedaily.newaol.com/pub/Call_Of_Duty_Demo.exe" 1c480a1e64a80f7f97fd0acd9582fe190c64ad8e + + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + SetTitleMatchMode, 2 + run Call_Of_Duty_Demo.exe + WinWait,Call of Duty Single Player Demo,Welcome + ControlClick Button1 ; I Agree + WinWait,Call of Duty Single Player Demo,License + ControlClick Button4 ; Next + WinWait,Call of Duty Single Player Demo,System + ControlClick Button4 ; Next + WinWait,Call of Duty Single Player Demo,Location + ControlClick Button1 ; Next + WinWait,Call of Duty Single Player Demo,Select + ControlClick Button1 ; Next + WinWait,Call of Duty Single Player Demo,Start + ControlClick Button1 ; Install + WinWait,Create Shortcut + ControlClick Button1 ; Yes + WinWait,Call of Duty Single Player Demo, Complete + ControlClick Button1 ; Finish + " + + if workaround_wine_bug 21558 + then + # Work around a buffer overflow - not really Wine's fault + setvar="@if not defined %__GL_ExtensionStringVersion% then echo \"If you get a buffer overflow error, set __GL_ExtensionStringVersion=17700 before starting Wine. See http://bugs.winehq.org/show_bug.cgi?id=21558.\"" + else + setvar= + fi + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +$setvar +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Call of Duty Single Player Demo" +CoDSP.exe +__EOF__ + +} + +#---------------------------------------------------------------- + + verblist_add codmw2 "Call of Duty Modern Warfare 2 (Activision, 2009) [broken]" \ 6f572261ed954733806daf5b42edf92b3127cd14.iso \ 3c6e63504d41df4bdb2d4c57f4c5fc7b810d7df8.iso @@ -2001,7 +2224,6 @@ verblist_add codmw2 "Call of Duty Modern Warfare 2 (Activision, 2009) [br load_codmw2() { warn "This verb isn't quite ready for prime time." - load_autohotkey test -f "$programfilesdir_x86_unix"/Steam/Steam.exe || try sh $WINETRICKS -q steam # Get user's key @@ -2013,7 +2235,7 @@ load_codmw2() SetTitleMatchMode, 2 Run, Steam.exe -login $STEAMUSER $STEAMPW -install ${ISO_MOUNT_LETTER}: - ; Uncomment these lines if you haven't activated this game via steam on this account before. + ; Uncomment these lines if you haven't activated this game via steam on this account before. ;winwait, Activation ;MouseMove, 30, 400 ;Click @@ -2037,27 +2259,226 @@ load_codmw2() ahk_do " SetTitleMatchMode, 2 Send {Enter} - ; Need to wait for install to finish. This isn't the way to do it. Ideally we could watch some log file. - ; The last file created seems to be - ; Program Files/Steam/steamapps/call of duty modern warfare 2 content.ncf - ; so wait for that and then another 20 seconds, say. + ; Need to wait for install to finish. This isn't the way to do it. Ideally we could watch some log file. + ; The last file created seems to be + ; Program Files/Steam/steamapps/call of duty modern warfare 2 content.ncf + ; so wait for that and then another 20 seconds, say. winwait, ahk_class USurface_, Install - ; Now that install has finished, say [don't start app] and [finish]. + ; Now that install has finished, say [don't start app] and [finish]. Send {Space} Send {Enter} - ; Now wait for the main steam interface to pop up, and close it + ; Now wait for the main steam interface to pop up, and close it winwait, ahk_class USurface_, Steam WinClose - ; If you choose to start the game above, you could wait for it to be ready to play here. + ; If you choose to start the game above, you could wait for it to be ready to play here. ;winwait, ahk_class USurface_8390, Ready ;Send {Tab} # select Close ;Send {Enter} - ;winwait, Steam Login + ;winwait, Steam Login ;WinClose " iso_umount - + +} + +#---------------------------------------------------------------- + +verblist_add cod4mw_demo "Call of Duty 4 Modern Warfare (Activision, 2007) [download]" CoD4MWDemoSetup_v2.exe + +load_cod4mw_demo() { + download $PACKAGE "http://gamedaily.newaol.com/pub/CoD4MWDemoSetup_v2.exe" 690a5f789a44437ed10784acfdd6418ca4a21886 + + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + SetTitleMatchMode, 2 + run CoD4MWDemoSetup_v2.exe + WinWait,Modern Warfare,Welcome + ControlClick Button1 ; Next + WinWait,Modern Warfare, License + ControlClick Button5 ; accept + ControlClick Button2 ; Next + WinWait,Modern Warfare, System Requirements + ControlClick Button1 ; Next + ControlClick Button4 ; Next + WinWait,Modern Warfare, Typical + ControlClick Button4 ; License + ControlClick Button1 ; Next + WinWait,Question, shortcut + ControlClick Button1 ; Yes + WinWait,Microsoft DirectX Setup, license + ControlClick Button1 ; Yes + WinWait,Modern Warfare, finished + ControlClick Button1 ; Finished + " + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Activision\\Call of Duty 4 - Modern Warfare Demo" +iw3sp.exe +__EOF__ + +} + +#---------------------------------------------------------------- + +verblist_add cnc2 "Command and Conquer Tiberian Sun & Firestorm (Westwood, 2000), [download]" OfficialCnCTiberianSun.rar + +load_cnc2() +{ + if ! test -f "$WISOTOOL_CACHE/$PACKAGE/OfficialCncTiberianSun.rar" + then + download $PACKAGE http://na.llnet.cnc3tv.ea.com/u/f/eagames/cnc3/cnc3tv/Classic/OfficialCnCTiberianSun.rar 591aabd639fb9f2d2476a2150f3c00b1162674f5 + fi + + cd "$WISOTOOL_CACHE/$PACKAGE" + + try_unrar x OfficialCnCTiberianSun.rar "$programfilesdir_x86_unix" + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\EA Games\\Command & Conquer The First Decade\\Command & Conquer(tm) Tiberian Sun(tm)\\SUN" +Game.exe +__EOF__ + +} + +#---------------------------------------------------------------- + +verblist_add civ4 "Civilization IV (Firaxis Games, 2005) [broken-wine-drm]" 6633e9cfbe06aa292b33fb38ce0779faf5a379bb.iso 231eee984062c9acadd336b4c0852fac829b76a8.iso + +load_civ4() { + if workaround_wine_bug 219 + then + warn "This game's DRM is not supported by Wine :-( but try patch 3.19 or later, it's said to remove the DRM" + fi + + if workaround_wine_bug 6856 + then + try sh "$WINETRICKS" -q msxml3 + fi + if workaround_wine_bug 11675 + then + try sh "$WINETRICKS" -q d3dx9_36 + fi + + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/6633e9cfbe06aa292b33fb38ce0779faf5a379bb.iso + + cd "$ISO_MOUNT_ROOT" + ahk_do " + run ${ISO_MOUNT_LETTER}:autorun.exe + SetTitleMatchMode, 2 + winwait, Civilization 4 + ControlClick Button3, Civilization 4 + winwait, Civilization 4 - InstallShield Wizard, Welcome + ControlClick &Next >, Civilization 4 + winwait, Civilization 4, I &accept the terms of the license agreement + ControlClick I &accept, Civilization 4 + ControlClick &Next >, Civilization 4 + winwait, Civilization 4 - InstallShield Wizard, Express Install + ControlClick &Next >, Civilization 4 + winwait, Civilization 4 - InstallShield Wizard, begin installation + ControlClick &Install, Civilization 4 + winwait, Setup Needs The Next Disk + " + iso_umount + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/231eee984062c9acadd336b4c0852fac829b76a8.iso + ahk_do " + SetTitleMatchMode, 2 + ControlClick OK, Setup Needs The Next Disk + winwait, Civilization 4, Xfire + ControlClick No, Civilization 4 + ControlClick &Next >, Civilization 4 + winwait, Setup Needs The Next Disk + " + iso_umount + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/6633e9cfbe06aa292b33fb38ce0779faf5a379bb.iso + ahk_do " + SetTitleMatchMode, 2 + ControlClick OK, Setup Needs The Next Disk + winwait, Sid Meier's Civilization 4 - InstallShield Wizard, InstallShield Wizard Complete + ControlClick Finish, Sid Meier's Civilization 4 - InstallShield Wizard + " + + download $PACKAGE http://www.firaxis.com/downloads/Patch/Civ4v161.exe 4712e96ef34dcc5aa961d2b75f49ada8bd6b0d92 + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + SetTitleMatchMode, 2 + run Civ4v161.exe + winwait, Civilization 4 + ControlClick &Next >, Sid Meier's Civilization 4 - InstallShield Wizard + winwait, Civilization 4, Xfire + ControlClick No, Civilization 4 + ControlClick &Next >, Civilization 4 + winwait, Civilization 4, Update Complete + " + if workaround_wine_bug 6856 + then + try sh "$WINETRICKS" -q msxml3 + fi + if workaround_wine_bug 11675 + then + try sh "$WINETRICKS" -q d3dx9_36 + fi + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Firaxis Games\\Sid Meier's Civilization 4" +Civilization4.exe +__EOF__ +} + +#---------------------------------------------------------------- + +verblist_add civ4_demo "Civilization IV Demo (Firaxis Games, 2005) [download]" Civilization4_Demo.zip + +load_civ4_demo() +{ + if ! test -f "$WISOTOOL_CACHE/$PACKAGE/Civilization4_Demo.zip" + then + mkdir -p "$WISOTOOL_CACHE/$PACKAGE" + die "Please download demo from http://download.cnet.com/Civilization-IV-demo/3000-7489_4-10465206.html and place it in $WISOTOOL_CACHE/$PACKAGE" + fi + + mkdir -p "$WISOTOOL_TMP" + cd "$WISOTOOL_CACHE/$PACKAGE" + try unzip Civilization4_Demo.zip -d "$WISOTOOL_TMP" + cd "$WISOTOOL_TMP/$PACKAGE" + chmod +x setup.exe + ahk_do " + SetTitleMatchMode, 2 + run, setup.exe + winwait, Choose Setup Language + sleep 1000 + Send {enter} + winwait, Civilization 4, Welcome + ControlClick &Next >, Civilization 4 + winwait, Civilization 4, I &accept the terms of the license agreement + ControlClick I &accept, Civilization 4 + ControlClick &Next >, Civilization 4 + winwait, Civilization 4, Express Install + ControlClick &Next >, Civilization 4 + winwait, Civilization 4, begin installation + ControlClick &Install, Civilization 4 + winwait, Civilization 4, InstallShield Wizard Complete + ControlClick Finish, Civilization 4 + winwaitclose + " + cd "$olddir" + + if workaround_wine_bug 6856 + then + try sh "$WINETRICKS" -q msxml3 + fi + if workaround_wine_bug 6856 # part 2, still need to file a bug + then + try sh "$WINETRICKS" -q d3dx9_26 + fi + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Firaxis Games\\Sid Meier's Civilization 4 Demo" +Civilization4.exe +__EOF__ } #---------------------------------------------------------------- @@ -2066,11 +2487,9 @@ verblist_add cnc3_demo "Command and Conquer 3 Demo (EA, 2007) [download]" CnC load_cnc3_demo() { - load_autohotkey - if ! test -f "$WISOTOOL_CACHE/$PACKAGE/CnC3Demo.exe" then - download $PACKAGE http://largedownloads.ea.com/pub/demos/CommandandConquer3/CnC3Demo.exe f6af21eba2d17eb6d8bb6a131b501b41c3a7eaf7 + download $PACKAGE http://largedownloads.ea.com/pub/demos/CommandandConquer3/CnC3Demo.exe f6af21eba2d17eb6d8bb6a131b501b41c3a7eaf7 fi cd "$WISOTOOL_CACHE/$PACKAGE" @@ -2100,7 +2519,8 @@ load_cnc3_demo() " cd "$olddir" - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Electronic Arts\\Command & Conquer 3 Tiberium Wars Demo" CNC3Demo.exe __EOF__ @@ -2112,8 +2532,6 @@ verblist_add cnc4 "Command and Conquer 4 (EA, 2010) [broken-wine-drm]" f3308e load_cnc4() { - load_autohotkey - iso_mount "$WISOTOOL_CACHE"/$PACKAGE/f3308e6d3a93e7b5dd2643631404e97b66a0c262.iso cd "$WISOTOOL_CACHE/$PACKAGE" @@ -2133,7 +2551,8 @@ load_cnc4() iso_umount # Bypass the game's launcher: see AppDB - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: "$programfilesdir_x86_win\\Electronic Arts\\Command & Conquer 4 Tiberian Twilight\\Data\\CNC4.game" -config "$programfilesdir_x86_win\\Electronic Arts\\Command & Conquer 4 Tiberian Twilight\\CNC4_English.SkuDef" __EOF__ @@ -2146,7 +2565,6 @@ verblist_add darknesswithin2_demo "Darkness Within 2 Demo (Zoetrope Interacti load_darknesswithin2_demo() { - load_autohotkey if ! test -f "$WISOTOOL_CACHE/$PACKAGE/DarknessWithin2Demo.exe" then mkdir -p "$WISOTOOL_CACHE/$PACKAGE" @@ -2187,7 +2605,8 @@ load_darknesswithin2_demo() fi # you have to cd to the directory containing DarkLineage.exe before running it - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Iceberg Interactive\Darkness Within 2 Demo" "DarkLineage.exe" __EOF__ @@ -2201,11 +2620,9 @@ verblist_add daytona_usa_evolutions "Daytona USA Evolutions (Sega, 1997)" dayto load_daytona_usa_evolutions() { # Refuses to run on anything newer... sh "$WINETRICKS" -q win98 - - load_autohotkey - + download $PACKAGE http://www2.sega.co.jp/download/pc/daytonae/daytonev.exe 65c51766e01b582c15200afb0fd569e0ec5ca1ac - + # Installer starts by extracting files, but doesn't seem to be a zip file or a cab file. I tried a few cli arguments, # but had no luck. It's only 60 MB extracted, so just extract it fresh each time. cd "$WISOTOOL_CACHE/$PACKAGE" @@ -2254,7 +2671,8 @@ load_daytona_usa_evolutions() { warn "Gives an error when closing the game, seems safe to ignore." - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$DRIVE_C\SEGA\DAYTONA USA Evolution Demo CD" "DAYTONA USA Evolution Demo CD.exe" __EOF__ @@ -2265,11 +2683,9 @@ __EOF__ verblist_add dc2ba "Doras Carnival 2: Boardwalk Adventure (Nickelodeon, 2008)" InstallDorasCarnival2BoardwalkAdventure.exe load_dc2ba() { - load_autohotkey - # http://www.nickjr.com/games/p-doras-carnival-2-adventure.jhtml download $PACKAGE http://downloadcdn.shockwave.com/pub/doras-carnival-2-boardwalk-adventure/InstallDorasCarnival2BoardwalkAdventure.exe a02559c4d8236581f2ee0e51a1a11f67a901eaba - + if workaround_wine_bug 23749 then sh "$WINETRICKS" -q ie6 @@ -2304,7 +2720,8 @@ load_dc2ba() { sleep 5 killall winefile.exe -cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Shockwave.com\\Dora's Carnival 2 - Boardwalk Adventure" "Dora's Carnival 2 - Boardwalk Adventure.exe" __EOF__ @@ -2322,7 +2739,6 @@ verblist_add deadspace "Dead Space (EA, 2008)" \ abf250df77bfa96c74e7bcd0343d381a4f327a26.iso load_deadspace() { - load_autohotkey DEADSPACEKEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/abf250df77bfa96c74e7bcd0343d381a4f327a26.txt | tr -d -` if workaround_wine_bug 23324 @@ -2339,7 +2755,7 @@ load_deadspace() { ahk_do " SetTitleMatchMode, 2 ; note: if this is the second run, the installer skips the registration code prompt - run, ${ISO_MOUNT_LETTER}:EASetup.exe + run, ${ISO_MOUNT_LETTER}:EASetup.exe winwait, Dead send {Enter} winwait, Dead, Registration Code @@ -2370,12 +2786,148 @@ load_deadspace() { " iso_umount - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Electronic Arts\\Dead Space" Dead Space.exe __EOF__ } +#---------------------------------------------------------------- + +verblist_add demolition_company_demo "Demolition Company demo [download]" DemolitionCompanyDemoEN.exe + +load_demolition_company_demo() +{ + if ! test -f "$WISOTOOL_CACHE/$PACKAGE/DemolitionCompanyDemoEN.exe" + then + mkdir -p "$WISOTOOL_CACHE/$PACKAGE" + die "Download the demo from http://www.demolitioncompany-thegame.com/demo.php and put it in $WISOTOOL_CACHE/$PACKAGE" + fi + + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + SetTitleMatchMode, 2 + run, DemolitionCompanyDemoEN.exe + winwait, Setup - Demolition, This will install + sleep 1000 + controlclick, TNewButton1, Setup - Demolition, This will install + winwait, Setup - Demolition, License Agreement + sleep 1000 + controlclick, TNewRadioButton1, Setup - Demolition, License Agreement + sleep 1000 + controlclick, TNewButton2, Setup - Demolition, License Agreement + winwait, Setup - Demolition, Setup Type + sleep 1000 + controlclick, TNewButton2, Setup - Demolition, Setup Type + winwait, Setup - Demolition, Ready to Install + sleep 1000 + controlclick, TNewButton2, Setup - Demolition, Ready to Install + winwait, Setup - Demolition, Completing + sleep 1000 + controlclick, TNewButton2, Setup - Demolition, Completing + " + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cd "$programfilesdir_x86_win\\Demolition Company Demo\\" +DemolitionCompany.exe +__EOF__ +} + +#---------------------------------------------------------------- + +verblist_add desperados2 "Desperados 2 (Atari, 2006)" ff13e7c5a96c70a24f91528915ea4ff375b0193e.iso + +load_desperados2() +{ + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/ff13e7c5a96c70a24f91528915ea4ff375b0193e.iso + ahk_do " + SetTitleMatchMode, 2 + Run, ${ISO_MOUNT_LETTER}:Setup.exe + WinWait, Desperados 2, Choose Setup Language + WinActivate + ControlClick Button3 ; next + WinWait, Desperados 2, License Agreement + WinActivate + ControlClick Button3 ; accept eula + ControlClick Button1 ; next + WinWait, Desperados 2, Choose Destination Location + ControlClick Button1 ; next + WinWait, Desperados 2, Select Program Folder + WinActivate + ControlClick Button2 ; next + WinWait, Desperados 2, Ready to Install + WinActivate + ControlClick Button1 ; install + WinWait, Desperados 2, InstallShield Wizard Complete + ControlCLick Button1 ; untick shortcut + ControlClick Button2 ; untick directx setup + ControlClick Button4 ; finish, also combo breaker + WinWait, Desperados ; flashy autorun thingy + MouseMove 103, 417 ; x marks the spot + Click ; exit + WinWaitClose + " + iso_umount + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Atari\\Desperados 2" +Desperados2.exe +__EOF__ +} + +#---------------------------------------------------------------- + +verblist_add deusex2_demo "Deus Ex 2 Demo [download]" dxiw_demo.zip +load_deusex2_demo() +{ + if ! test -f "$WISOTOOL_CACHE/$PACKAGE/dxiw_demo.zip" + then + download $PACKAGE http://www.techpowerup.com/downloads/1730i/dxiw_demo.zip ccae48fb046d912b3714ea1b4be4294e74bb3092 + fi + + mkdir -p "$WISOTOOL_TMP/$PACKAGE" + cd "$WISOTOOL_CACHE/$PACKAGE" + try unzip dxiw_demo.zip -d "$WISOTOOL_TMP/$PACKAGE" + cd "$WISOTOOL_TMP/$PACKAGE" + chmod +x setup.exe + ahk_do " + SetTitleMatchMode, 2 + run, setup.exe + winwait, Deus Ex - Invisible War Demo - InstallShield + winwaitclose + winwait, Deus Ex - Invisible War Demo + send {Tab}{Enter} + winwait, Deus Ex - Invisible War Demo - InstallShield + send n + winwait, Deus Ex - Invisible War Demo, license + send an + winwait, Deus Ex - Invisible War Demo, setup type + send n + winwait, Deus Ex - Invisible War Demo, install + send i + winwait, Question, ; Readme? + send n + winwait, Question, ; Play now? + send n + winwait, Deus Ex - Invisible War Demo, install ; Done + send {Enter} + winwaitclose + " + + cd "$olddir" + + if workaround_wine_bug 6971 + then + warn "This game suffers from The Mouse Bug, see http://wiki.winehq.org/Bug6971 for tips" + fi + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Deus Ex - Invisible War Demo\\System\\" +DX2.exe +__EOF__ +} #---------------------------------------------------------------- @@ -2386,8 +2938,7 @@ verblist_add diablo2 "Diablo II (Blizzard, 2000)" \ e20efb1ea60e58b4a25275a00571aabfe3ab4511.iso load_diablo2() { - warn "You must have already done 'wisotool load=YOURKEY' on the install disc, and 'wisotool load' on the other two discs." - load_autohotkey + warn "You must have already done 'wisotool load=YOURKEY' on the install disc, and 'wisotool load' on the other three discs." download diablo2 http://ftp.blizzard.com/pub/diablo2/patches/PC/D2Patch_113c.exe c78761bfb06999a9788f25a23a1ed30260ffb8ab # Force clean-ish install @@ -2448,7 +2999,8 @@ load_diablo2() { warn "When starting the game, be patient, wait until the menu appears. The game seems to hang if it looses focus, see bug 14456, you may need to set winecfg to virtual desktop." - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Diablo II" "Diablo II.exe" __EOF__ @@ -2459,8 +3011,6 @@ __EOF__ verblist_add dragonage "Dragon Age: Origins (Bioware / EA, 2009)" 705a6b06d0dd807bf62b4391d278649d728ebda4.iso load_dragonage() { - load_autohotkey - # Get user's key DRAGONAGEKEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/705a6b06d0dd807bf62b4391d278649d728ebda4.txt | tr -d -` @@ -2496,7 +3046,7 @@ load_dragonage() { exit 0 " iso_umount - + if workaround_wine_bug 22307 then warn "Turn off frame buffer effects to avoid blurry cut scenes. See http://bugs.winehq.org/show_bug.cgi?id=22307" @@ -2514,7 +3064,8 @@ load_dragonage() { warn "If you still see flickering, try applying the patch from http://bugs.winehq.org/show_bug.cgi?id=23081" fi - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Dragon Age" bin_ship\\daorigins.exe __EOF__ @@ -2522,18 +3073,285 @@ __EOF__ #---------------------------------------------------------------- +verblist_add dts "Death to Spies (1C Company / Haggard Games, 2007)" 3cf30e69986e00794a4ee581a35f3319f82a82dd.iso + +load_dts() { + + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/3cf30e69986e00794a4ee581a35f3319f82a82dd.iso + + ahk_do " + Run, ${ISO_MOUNT_LETTER}:Death_to_Spies_Setup.exe + SetTitleMatchMode, 2 + WinWait, Death to Spies + WinActivate + ControlClick TNewButton1 ; next + WinWait, , Select Destination Location + ControlClick TNewButton3 ; next + WinWait, , Select Start Menu Folder + ControlClick TNewButton4 ; next + WinWait, , Select Additional Tasks + ControlClick TNewCheckListBox1 ; uncheck shortcut + ControlClick TNewButton4 ; next + WinWait, , Ready to Install + ControlClick TNewButton4 ; next + WinWait, Microsoft ; direct x + WinActivate + ControlClick Button6 ; cancel + WinWait, Death to Spies + WinActivate + ControlClick TNewButton4 ; finish + " + iso_umount + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Aspyr\\Death to Spies Moment of Truth" +Truth.exe +__EOF__ +} + +#---------------------------------------------------------------- + +verblist_add eve "EVE Online Tyrannis (CCP Games, 2010) [download]" EVE_Premium_Setup_177290_m.exe + +load_eve() { + # FIXME: download function should avoid checksumming huge old files + test -s "$WISOTOOL_CACHE/$PACKAGE/EVE_Premium_Setup_177290_m.exe" || + download $PACKAGE "http://content.eveonline.com/EVE_Premium_Setup_177290_m.exe" 92624334ed5a431c1b516161ecf7280882b388f6 + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + run, EVE_Premium_Setup_177290_m.exe + WinWait, EVE Online Installer + WinActivate + send {Enter} ; Next + WinWait, EVE,License Agreement + WinActivate + send {Enter} ; Next + WinWait, EVE,Choose Install + WinActivate + send {Enter} ; Install + WinWait, EVE,Installation Complete + WinActivate + send {Enter} ; next + WinWait, EVE,Installation Complete + WinActivate + Send {Tab}{Tab}{Tab} ; select Launch + Send {Space} ; untick Launch + Send {Enter} ; Finish + WinWaitClose + " + if workaround_wine_bug 18221 + then + sh "$WINETRICKS" -q corefonts + fi + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\CCP\\EVE" +eve.exe +__EOF__ +} + +#---------------------------------------------------------------- + +verblist_add ewj_demo "Earthworm Jim demo (Shiny Entertainment, 1996) [download]" + +load_ewj_demo() { +# http://appdb.winehq.org/objectManager.php?sClass=application&iId=4233 + if ! test -f "$WISOTOOL_CACHE/$PACKAGE/ewjdemo.exe" + then + mkdir -p "$WISOTOOL_CACHE/$PACKAGE" + die "Please download the demo from http://download.cnet.com/Earthworm-Jim-demo/3000-2099_4-10000793.html and put it in $WISOTOOL_CACHE/$PACKAGE" + fi + + # FIXME: If the user is on a 32-bit OS and has vm.mmap_min_addr=0, they can use Wine to extract the files. + # So we should try that if arj is not installed. + if ! [ -x `which arj` ] + then + die "You need to install the `arj` utility to extract the demo files. (e.g., sudo apt-get install arj or sudo yum install arj)" + else + mkdir -p "$WISOTOOL_TMP/$PACKAGE" + cd "$WISOTOOL_TMP/$PACKAGE" + arj e "$WISOTOOL_CACHE/$PACKAGE/ewjdemo.exe" + mkdir -p "$DRIVE_C/ewj_demo" + cd "$DRIVE_C/ewj_demo" + arj e "$WISOTOOL_TMP/$PACKAGE/EWJFILES.EXE" + fi + + if workaround_wine_bug 19531 + then + warn "Sound does not work in Windows NT+ mode. It does in win98 mode, but then locks up the game. See http://bugs.winehq.org/show_bug.cgi?id=19531" + else + sh "$WINETRICKS" win98 + fi + +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cd "$DRIVE_C\\ewj_demo" +WORM.EXE +__EOF__ + +} + +#---------------------------------------------------------------- + +# Sadly, the SHA1SUM of the first disc varies! +# FIXME: change load function to call it by its volume label instead; right now you have to rename it manually. + +verblist_add fable_tlc "Fable: The Lost Chapters (Microsoft, 2005)" \ + FABLE_DISC_1.iso \ + 755eaa37cd52c1171339d2dae11979147cf62080.iso \ + ed977f38acac7a09b8b6fdcc64a68933076d0cd4.iso \ + 2aa5c8c55d38a4113da4c3ca60d9e69ed2a0d941.iso + +load_fable_tlc() { + + KEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/FABLE_DISK_1.txt | tr -d -` + + if workaround_wine_bug 657 + then + try sh "$WINETRICKS" -q mfc42 + fi + + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/FABLE_DISK_1.iso + ahk_do " + SetTitleMatchMode, 2 + run, ${ISO_MOUNT_LETTER}:setup.exe + WinWait,Fable,Welcome + Sleep 500 + ControlClick Button1 ; Next + WinWait,Fable,Please + Sleep 500 + ControlClick Button4 ; Next + WinWait,Fable,Product Key + Sleep 500 + Send $KEY + Send {Enter} + WinWait,Fable,Disk 2 + " + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/ed977f38acac7a09b8b6fdcc64a68933076d0cd4.iso + ahk_do " + SetTitleMatchMode, 2 + WinWait,Fable,Disk 2 + Sleep 500 + ControlClick Button2 ; Retry + WinWait,Fable,Disk 3 + " + + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/755eaa37cd52c1171339d2dae11979147cf62080.iso + ahk_do " + SetTitleMatchMode, 2 + WinWait,Fable,Disk 3 + Sleep 500 + ControlClick Button2 ; Retry + WinWait,Fable,Disk 4 + " + + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/e435cfeb975e596db1bf953170462e3b81c41396.iso + ahk_do " + SetTitleMatchMode, 2 + WinWait,Fable,Disk 4 + Sleep 500 + ControlClick Button2 ; Retry + WinWait,Fable,Disk 1 + WinKill + " + + # Now tell game what the real disc is so user can insert disc 1 and run the game! + cat > "$WISOTOOL_TMP"/$PACKAGE.reg <<_EOF_ +REGEDIT4 + +[HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Installer\UserData\S-1-5-18\Products\D3BE9C3CAF4226447B48E06CAACF2DDD\InstallProperties] +"InstallSource"="D:\\" + +_EOF_ + try_regedit "$WISOTOOL_TMP_WIN"\\$PACKAGE.reg + + # Also accept EULA + cat > "$WISOTOOL_TMP"/$PACKAGE.reg <<_EOF_ +REGEDIT4 + +[HKEY_CURRENT_USER\Software\Microsoft\Microsoft Games\Fable TLC] +"FIRSTRUN"=dword:00000001 + +_EOF_ + try_regedit "$WISOTOOL_TMP_WIN"\\$PACKAGE.reg + + if workaround_wine_bug 24912 + then + # kill off lingering installer + ahk_do " + SetTitleMatchMode, 2 + WinKill,Fable + " + $WINESERVER -k + fi + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Microsoft Games\\Fable - The Lost Chapters" +Fable.exe +__EOF__ + + if workaround_wine_bug 24941 + then + try sh "$WINETRICKS" -q devenum quartz wmp9 + fi + + if workaround_wine_bug 24942 + then + sh "$WINETRICKS" -q d3dx9_36 + fi +} + +#---------------------------------------------------------------- + +verblist_add fallout3 "Fallout 3 Windows Live Version (Bethesda, 2009)" 4994dca9fa2e105ea592899644f48d754338663f.iso + +load_fallout3() +{ + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/4994dca9fa2e105ea592899644f48d754338663f.iso + + if workaround_wine_bug 23532 + then + try "$WINETRICKS" -q xlive + fi + + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + SetTitleMatchMode, 2 + run, ${ISO_MOUNT_LETTER}:setup.exe + winwait, Fallout 3, Welcome + controlclick, Button1 + winwait, Fallout 3, License Agreement + controlclick, Button3 + controlclick, Button1 + winwait, Fallout 3, Setup Type + controlclick, Button4 + winwait, Fallout 3, Ready to Install + controlclick, Button1 + winwait, Fallout 3, InstallShield Wizard Complete + controlclick, Button1 + controlclick, Button2 + controlclick, Button3 + " + +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Bethesda Softworks\\Fallout 3" +"Fallout3.exe" +__EOF__ +} +#---------------------------------------------------------------- + verblist_add fallout3_goty "Fallout 3: Game of the Year Edition (Bethesda, 2009)" 379e2daa9bdd1aaf1cb152c1d9f8181f8f24e01b.iso \ f131e45dba66ed2c98dd7a1e04cc1114b7c5e4b6.iso load_fallout3_goty() { # http://appdb.winehq.org/objectManager.php?sClass=version&iId=14322 - load_autohotkey - iso_mount "$WISOTOOL_CACHE"/$PACKAGE/379e2daa9bdd1aaf1cb152c1d9f8181f8f24e01b.iso ahk_do " Run, ${ISO_MOUNT_LETTER}:Setup.exe - SetTitleMatchMode, 2 + SetTitleMatchMode, 2 winwait, Fallout 3 - InstallShield Wizard, Welcome to the InstallShield Wizard for Fallout 3 sleep 1000 controlclick, Button1, Fallout 3 - InstallShield Wizard, Welcome to the InstallShield Wizard for Fallout 3 @@ -2577,13 +3395,14 @@ load_fallout3_goty() { sleep 1000 controlclick, Button4, Fallout 3 - DLC EN - InstallShield Wizard, InstallShield Wizard Complete " - + if workaround_wine_bug 23532 then try "$WINETRICKS" -q xlive fi - -cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Bethesda Softworks\\Fallout 3" "Fallout3.exe" __EOF__ @@ -2592,12 +3411,92 @@ __EOF__ #---------------------------------------------------------------- -verblist_add fifa10 "Fifa 10 (EA, 2009)" 2038b86319862e1177912949e9f826f333571c48.iso +verblist_add fallout_nv "Fallout New Vegas (Bethesda, 2010)" f603dfc0343ea4257d04946e1cac8c06dfe8707d.iso + +load_fallout_nv() +{ + warn "You'll need to have STEAM_USER/STEAM_PASS set in your environment or in $WISOTOOL_CACHE. You'll also need your cd-key for Fallout New Vegas already added to your Steam Account." + + if [ ! "$STEAM_USER" -a ! -f "$WISOTOOL_CACHE"/STEAM_USER ] + then + die "You need to set STEAM_USER variable in your environment or put it in "$WISOTOOL_CACHE"/STEAM_USER" + elif [ ! "$STEAM_USER" -a -f "$WISOTOOL_CACHE"/STEAM_USER ] + then + STEAM_USER=`cat "$WISOTOOL_CACHE"/STEAM_USER` + fi + + if [ ! "$STEAM_PASS" -a ! -f "$WISOTOOL_CACHE"/STEAM_PASS ] + then + die "You need to set STEAM_PASS variable in your environment or put it in "$WISOTOOL_CACHE"/STEAM_PASS" + elif [ ! "$STEAM_PASS" -a -f "$WISOTOOL_CACHE"/STEAM_PASS ] + then + STEAM_PASS=`cat "$WISOTOOL_CACHE"/STEAM_PASS` + fi + + steam_dir="$programfilesdir_unix/Steam" + + # Game uses Steam to install itself + try sh $WINETRICKS -q steam + + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/f603dfc0343ea4257d04946e1cac8c06dfe8707d.iso + + cd "$steam_dir" + + # Run Steam, let it update. Then, in a separate thread, run the installer. + ahk_do " + SetTitleMatchMode, 2 + SetControlDelay -1 + run, Steam.exe -login $STEAM_USER $STEAM_PASS + Winwait, Steam - Update News + ; Close all windows, prevent conflicts with later controlclick's + winclose, Steam - Update News + winclose, Steam + " + + ahk_do " + SetTitleMatchMode, 2 + SetControlDelay -1 + Run, Steam.exe -install I:\\ + ; Install Fallout New Vegas + winwait, Install - Fallout- New Vegas + send, {Enter} + ; Shortcuts + sleep 10000 + winwait, Install - Fallout- New Vegas + send, {Enter} + ; Installing... + sleep 10000 + winwait, Install - Fallout- New Vegas + send, {Enter} + " + + # Wait for install to finish + dl_log="$steam_dir/logs/download_log.txt" + while true + do + grep "SetHasAllLocalContent(true) called for 22380" "$dl_log" && break + sleep 15 + done + + ahk_do " + send {Enter} + sleep 1000 + run, Steam.exe -shutdown + " + +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Steam" +Steam.exe -login $STEAM_USER $STEAM_PASS -applaunch 22380 +__EOF__ +} + +#---------------------------------------------------------------- + +verblist_add fifa10 "Fifa 10 (EA, 2009)" 2038b86319862e1177912949e9f826f333571c48.iso load_fifa10() { # http://appdb.winehq.org/objectManager.php?sClass=version&iId=14322 - load_autohotkey - iso_mount "$WISOTOOL_CACHE"/$PACKAGE/2038b86319862e1177912949e9f826f333571c48.iso # Get user's key @@ -2610,11 +3509,11 @@ load_fifa10() { # FIXME: What is it on Windows? fifatitle="FIFA 10" fi - + ahk_do " Run, ${ISO_MOUNT_LETTER}:AutoRun.exe - SetTitleMatchMode, 2 + SetTitleMatchMode, 2 winwait, FIFA 10, View the readme file sleep 1000 controlclick, Button1, FIFA 10, View the readme file @@ -2649,7 +3548,8 @@ load_fifa10() { controlclick, Button14, Product Registration, Please log into your EA Master Account to continue. " -cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\EA Sports\\FIFA 10" "FIFA10.exe" __EOF__ @@ -2657,18 +3557,81 @@ __EOF__ } #---------------------------------------------------------------- - + +verblist_add fifa11_demo "FIFA 11 Demo (EA Sports, 2010) [download]" fifa11_pc_demo_NA.zip + +load_fifa11_demo() +{ + # From http://www.easportsfootball.co.uk/news/item/file/FIFA-11-Demo-Release?om_u=2255229429&om_i=_BMknsPB8Usvnmr + download $PACKAGE http://static.cdn.ea.com/fifa/u/f/fifa11_pc_demo_NA.zip c3a66284bffb985f31b11e477dade50c0d4cac52 + + mkdir "$WISOTOOL_TMP/$PACKAGE" + try unzip -d "$WISOTOOL_TMP/$PACKAGE" "$WISOTOOL_CACHE/$PACKAGE/fifa11_pc_demo_NA.zip" + cd "$WISOTOOL_TMP/$PACKAGE" + + ahk_do " + SetTitleMatchMode, 2 + run, EASetup.exe + winwait, Microsoft Visual C++ 2008, This wizard will guide you + sleep 1000 + controlclick, Button12, Microsoft Visual C++ 2008, This wizard will guide you + winwait, Microsoft Visual C++ 2008, License Terms + sleep 1000 + controlclick, Button11, Microsoft Visual C++ 2008, License Terms + sleep 1000 + controlclick, Button8, Microsoft Visual C++ 2008, License Terms + winwait, Microsoft Visual C++ 2008, Setup Complete + sleep 2000 + controlclick, Button2, Microsoft Visual C++ 2008, Setup Complete + ; It doesn't seem to take the first click, so try a second time.. + sleep 2000 + controlclick, Button2, Microsoft Visual C++ 2008, Setup Complete + ; There are two license agreements...one is for Directx + winwait, FIFA 11, I &accept the terms in the End User License Agreement + sleep 1000 + controlclick, Button1, FIFA 11, I &accept the terms in the End User License Agreement + sleep 1000 + controlclick, Button3, FIFA 11, I &accept the terms in the End User License Agreement + winwait, FIFA 11, I &accept the terms in the End User License Agreement + sleep 1000 + controlclick, Button1, FIFA 11, I &accept the terms in the End User License Agreement + sleep 1000 + controlclick, Button3, FIFA 11, I &accept the terms in the End User License Agreement + winwait, FIFA 11, Ready to install FIFA 11 + sleep 1000 + controlclick, Button1, FIFA 11, Ready to install FIFA 11 + winwait, FIFA 11, Click the Finish button to exit the Setup Wizard. + sleep 1000 + controlclick, Button5, FIFA 11, Click the Finish button to exit the Setup Wizard. + sleep 1000 + controlclick, Button1, FIFA 11, Click the Finish button to exit the Setup Wizard. + " + +if workaround_wine_bug 22161 +then + sh "$WINETRICKS" -q d3dx9_36 +fi + +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\EA Sports\\FIFA 11 Demo\\Game" +"fifa.exe" +__EOF__ + +} + +#---------------------------------------------------------------- + verblist_add fifaonline3_beta "FIFA Online 3 Beta (EA Sports, 2010) [download]" FIFAOnlineSetup.exe load_fifaonline3_beta() { - load_autohotkey if ! test -f "$WISOTOOL_CACHE/$PACKAGE/FIFAOnlineSetup.exe" then mkdir -p "$WISOTOOL_CACHE"/$PACKAGE die "Download the FIFAOnlineSetup.exe from http://fifa-online.easports.com/web/beta/welcome \ - and place it in $WISOTOOL_CACHE/$PACKAGE" + and place it in $WISOTOOL_CACHE/$PACKAGE" fi cd "$WISOTOOL_CACHE/$PACKAGE" @@ -2707,23 +3670,40 @@ load_fifaonline3_beta() sleep 10 killall "NFE.exe" - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ c: cd \Program Files\\EA Sports\\FIFA Online Launch.exe __EOF__ + # Download audio commentary + cd "$DRIVE_C" + ahk_do " + SetTitleMatchMode, 2 + run, cmd /c run-$PACKAGE.bat + winwait, EA SPORTS, Download Commentary + controlclick, Button1, EA SPORTS, Download Commentary + " + + # Wait for download to finish again and game to start + while [ `ps a | grep NFE.exe | grep -v grep | wc -l` != "1" ] + do + sleep 5 + done + + # Dont kill game immediately + sleep 10 + killall "NFE.exe" + cd "$olddir" } #---------------------------------------------------------------- - + verblist_add fifa10_demo "Fifa 10 Demo (EA, 2009)" fifa10_pc_demo_ec.exe load_fifa10_demo() { - load_autohotkey - download $PACKAGE "http://gamedaily.newaol.com/pub/fifa10_pc_demo_ec.exe" 96200d4962fd6c34715c448ba22f00edd3d70cd6 - + # The installer is a self extracting rar file. Make cleanups easy by using $WISOTOOL_TMP mkdir "$WISOTOOL_TMP/fifa10" cd "$WISOTOOL_TMP/fifa10" @@ -2770,19 +3750,123 @@ load_fifa10_demo() { sleep 1000 controlclick, Button1, $fifatitle Setup, Click the Finish button to exit the Setup Wizard. " -cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\EA Sports\\FIFA 10 - Demo" FIFA10Demo.exe __EOF__ } #---------------------------------------------------------------- - + +verblist_add ffvii_demo "Final Fantasy VII (Square Enix, 1998)" ff7demo.zip + +load_ffvii_demo() { + download $PACKAGE "http://software-files-l.cnet.com/s/software/89/10/18/ff7demo.zip?e=1284462275&h=47913b28b2f4a0274af12447d1359776&lop=link&ptype=1901&ontid=7538&siteId=4&edId=3&spi=bc2f47421050036bcf32c99124aba9c2&pid=891018&psid=10020419&fileName=ff7demo.zip" 79a555cd1874410a93952486e511bb8492e82a56 ff7demo.zip + + mkdir "$programfilesdir_x86_unix/ffvii_demo" + cd "$programfilesdir_x86_unix/ffvii_demo" + try unzip "$WISOTOOL_CACHE/$PACKAGE/ff7demo.zip" + + if workaround_wine_bug 9220 + then + warn "Doesn't work very well, see http://bugs.winehq.org/show_bug.cgi?id=9220" + fi + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_unix/ffvii_demo" +ff7demo.exe +__EOF__ + +} + + +#---------------------------------------------------------------- + +verblist_add ffxiv_beta "Final Fantasy XIV Beta (Square Enix, 2010)" ffxivsetup.exe + +load_ffxiv_beta() { + # e6e615e5886c17e744fc4aba7b267e7e3dcbdb52 ffxivsetup.exe + if ! test -f "$WISOTOOL_CACHE/$PACKAGE/ffxivsetup.exe" + then + mkdir -p "$WISOTOOL_CACHE"/$PACKAGE + die "Register for the beta and download ffxivsetup.exe from https://dev-na.ffxiv.com/ \ + and place it in $WISOTOOL_CACHE/$PACKAGE" + fi + + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + SetTitleMatchMode, 2 + run, ffxivsetup.exe + winwait, FINAL FANTASY XIV Beta Version, Select a region and language + sleep 1000 + controlclick, Button2, FINAL FANTASY XIV Beta Version, Select a region and language + ; It forces Directx Install :-( + winwait, FINAL FANTASY XIV Beta Version, A new version of DirectX is required for installation + sleep 1000 + controlclick, Button2, FINAL FANTASY XIV Beta Version, A new version of DirectX is required for installation + winwait, Installing Microsoft(R) DirectX(R), Welcome to setup for DirectX + sleep 1000 + controlclick, Button1, Installing Microsoft(R) DirectX(R), Welcome to setup for DirectX + sleep 1000 + controlclick, Button4, Installing Microsoft(R) DirectX(R), Welcome to setup for DirectX + winwait, Installing Microsoft(R) DirectX(R), This install package will search for updated DirectX + sleep 1000 + Controlclick, Button4, Installing Microsoft(R) DirectX(R), This install package will search for updated DirectX + winwait, Installing Microsoft(R) DirectX(R), Installation Complete + sleep 1000 + controlclick, Button5, Installing Microsoft(R) DirectX(R), Installation Complete + winwait, FINAL FANTASY XIV Beta Version, The InstallShield Wizard will install FINAL FANTASY + sleep 1000 + Controlclick, Button1, FINAL FANTASY XIV Beta Version, The InstallShield Wizard will install FINAL FANTASY + winwait, FINAL FANTASY XIV Beta Version, Please shut down any antivirus + sleep 1000 + ControlClick, Button1, FINAL FANTASY XIV Beta Version, Please shut down any antivirus + winwait, FINAL FANTASY XIV Beta Version, License Agreement + sleep 1000 + Controlclick, Button5, FINAL FANTASY XIV Beta Version, License Agreement + sleep 1000 + Controlclick, Button2, FINAL FANTASY XIV Beta Version, License Agreement + winwait, FINAL FANTASY XIV Beta Version, To install to this folder + sleep 1000 + controlclick, Button1, FINAL FANTASY XIV Beta Version, To install to this folder + winwait, FINAL FANTASY XIV Beta Version, Start Copying Files + sleep 1000 + controlclick, Button1, FINAL FANTASY XIV Beta Version, Start Copying Files + winwait, FINAL FANTASY XIV Beta Version, InstallShield Wizard Complete + sleep 1000 + Controlclick, Button1, FINAL FANTASY XIV Beta Version, InstallShield Wizard Complete + sleep 1000 + Controlclick, Button4, FINAL FANTASY XIV Beta Version, InstallShield Wizard Complete + " + + if workaround_wine_bug 24358 + then + sh "$WINETRICKS" winhttp + warn "You'll want to forward ports TCP/UDP 55296-55551 and UDP 443 to your computer to speed up the download. See also http://bugs.winehq.org/show_bug.cgi?id=24358" + fi + + if workaround_wine_bug 24375 + then + sh "$WINETRICKS" -q ie6 + fi + +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\SquareEnix\\FINAL FANTASY XIV Beta Version" +ffxivboot.exe +__EOF__ + +} + +#---------------------------------------------------------------- + verblist_add ffxivbench "Final Fantasy XIV Benchmark (Square Enix, 2010)" FFXIVBenchmark.zip load_ffxivbench() { - download $PACKAGE http://uk.download.nvidia.com/nzone/international/benchmarks/ffxiv/FFXIVBenchmark.zip 9c2406540306575bdc738c439e59f54eb44304a8 - + download $PACKAGE http://uk.download.nvidia.com/nzone/international/benchmarks/ffxiv/FFXIVBenchmark.zip 9c2406540306575bdc738c439e59f54eb44304a8 + cd "$programfilesdir_x86_unix" try unzip "$WISOTOOL_CACHE/$PACKAGE/FFXIVBenchmark.zip" @@ -2804,12 +3888,14 @@ LOOP=0 __EOF__ cat > "$DRIVE_C/run-$PACKAGE-low.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\FFXIVBenchmark\\data" copy config.low config.ini /y FFXivWinBenchmark.exe __EOF__ cat > "$DRIVE_C/run-$PACKAGE-high.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\FFXIVBenchmark\\data" copy config.high config.ini /y FFXivWinBenchmark.exe @@ -2821,16 +3907,241 @@ then fi } - + #---------------------------------------------------------------- - + +verblist_add fm10_demo "Football Manager 2010 demo (Sony, 2009)" Setup_FM2010_Vanilla_Demo.exe + +load_fm10_demo() { + if ! test -f "$WISOTOOL_CACHE/$PACKAGE/Setup_FM2010_Vanilla_Demo.exe" + then + mkdir -p "$WISOTOOL_CACHE/$PACKAGE" + die "Download the demo from http://www.mirrorfootball.co.uk/football-manager-2010/ and put it in $WISOTOOL_CACHE/$PACKAGE" + fi + + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + run, Setup_FM2010_Vanilla_Demo.exe + winwait, Football Manager 2010 Demo + sleep 1000 + ; Buttons have no names, and there is no visible window text. Additionally, the windows don't close. :-( + ; Lastly, controlclick doesn't work, even with coordinates. Luckily, mousemove + click does + mousemove, 550, 400 + Click + sleep 2000 + mousemove, 400, 325 + click + sleep 1000 + mousemove, 550, 400 + click + sleep 2000 + mousemove, 550, 400 + click + sleep 2000 + mousemove, 550, 400 + click + ; Wants directx. Cancel. Convienent, so we know when the install is done. + winwait, Installing Microsoft + winclose + winwait, Football Manager 2010 Demo + sleep 1000 + mousemove, 550, 400 + click + " + + if workaround_wine_bug 24417 + then + sh "$WINETRICKS" -q d3dx9_36 + fi + +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cd $programfilesdir_x86_win\\Sports Interactive\\Football Manager 2010 Demo +fm.exe +__EOF__ + +} + +# http://www.futurepinball.com/ +verblist_add futurepinball "Future Pinball (Christopher Leathley, 2008) [download]" + +load_futurepinball() { + download $PACKAGE "http://members.iinet.net.au/~cleathley/downloads/FuturePinballSetup_v1.9.20081225.exe" 1d7f445c03ea508b8144cd56961c6d59136c2b1b + + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + SetTitleMatchMode, 2 + Run, FuturePinballSetup_v1.9.20081225.exe + WinWait, Setup, Welcome to the Future + sleep 1000 + ControlClick, TButton1 + WinWait, Setup, License Agreement + sleep 1000 + ControlClick, TRadioButton1 ; accept + sleep 1000 + ;ControlClick, TButton2 ; next + send {Enter} + WinWait, Setup, Select Destination Location + sleep 1000 + ControlClick, TButton3 + WinWait, Folder Does Not Exist + sleep 1000 + ControlClick, Button1 + WinWait, Setup, Select Start Menu Folder + sleep 1000 + ControlClick, TButton4 + WinWait, Setup, Select Additional Tasks + sleep 1000 + ControlClick, x53 y163 + ControlClick, TButton4 + WinWait, Setup, Ready to Install + sleep 1000 + ControlClick, TButton4 + WinWait, Setup, Completing the Future Pinball + sleep 1000 + send {Space} ; do not launch + ControlClick, TButton4 ; finish + " + if workaround_wine_bug 8780 + then + try "$WINETRICKS" -q wsh56vb dcom98 + fi + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "\\Games\\Future Pinball" +"Future Pinball.exe" +__EOF__ +} + +#---------------------------------------------------------------- + +verblist_add gothic4_demo "Gothic 4 demo (Jowood/Dreamcatcher Games, 2010) [download] (broken)" ArcaniA_Gothic4_Demo_Setup.zip +# http://appdb.winehq.org/objectManager.php?sClass=version&iId=21507 + +load_gothic4_demo() { + download $PACKAGE http://gamedaily.newaol.com/pub/ArcaniA_Gothic4_Demo_Setup.zip + + try mkdir -p "$WISOTOOL_TMP/$PACKAGE" + cd "$WISOTOOL_TMP/$PACKAGE" + try unzip "$WISOTOOL_CACHE/$PACKAGE"/ArcaniA_Gothic4_Demo_Setup.zip + + ahk_do " + Settitlematchmode, 2 + run, ArcaniA_Gothic4_Demo_Setup.exe + winwait, Select Setup Language + sleep 1000 + controlclick, TNewButton1, Select Setup Language + winwait, Setup - ArcaniA, Welcome to the + sleep 1000 + controlclick, TNewButton1, Setup - ArcaniA, Welcome to the + winwait, Setup - ArcaniA, License Agreement + sleep 1000 + controlclick, TNewRadioButton1, Setup - ArcaniA, License Agreement + sleep 1000 + controlclick, TNewButton2, Setup - ArcaniA, License Agreement + winwait, Setup - ArcaniA, Select Destination Location + sleep 1000 + controlclick, TNewButton3, Setup - ArcaniA, Select Destination Location + winwait, Setup - ArcaniA, Select Components + sleep 1000 + controlclick, TNewButton3, Setup - ArcaniA, Select Components + winwait, Setup - ArcaniA, Select Start Menu + sleep 1000 + controlclick, TNewButton4, Setup - ArcaniA, Select Start Menu + winwait, Setup - ArcaniA, Select Additional + sleep 1000 + controlclick, TNewButton4, Setup - ArcaniA, Select Additional + winwait, Setup - ArcaniA, Ready to Install + sleep 1000 + controlclick, TNewButton4, Setup - ArcaniA, Ready to Install + winwait, Setup - ArcaniA, Information + sleep 1000 + controlclick, TNewButton4, Setup - ArcaniA, Information + winwait, Setup - ArcaniA, Completing + sleep 1000 + ; The two checkboxes share the same button id. App/Wine bug? + mousemove, 190, 155 + click + sleep 1000 + mousemove, 190, 180 + click + sleep 1000 + controlclick, TNewButton4, Setup - ArcaniA, Completing + " + +if workaround_wine_bug 21939 +then + sh "$WINETRICKS" -q wmp9 +fi + +if workaround_wine_bug 24250 +then + sh "$WINETRICKS" -q vcrun2008 +fi + +if workaround_wine_bug 7065 +then + warn "Game has Securom protection, doesn't work in Wine yet." +fi + +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cd $programfilesdir_x86_win\\JoWooD Entertainment AG\\ArcaniA - Gothic 4 Demo +Arcania.exe +__EOF__ + +} + +#---------------------------------------------------------------- + +verblist_add grand_ages_rome_demo "Grand Ages: Rome demo (Kalypso, 2009) " GrandAgesRome-EU-XL-Demo.exe +# http://appdb.winehq.org/objectManager.php?sClass=application&iId=9378 + +load_grand_ages_rome_demo() { + download $PACKAGE http://gamedaily.newaol.com/pub/GrandAgesRome-EU-XL-Demo.exe 175c0dcdd6eb7c2b928f4ece0f775772ae94d8cf + + if workaround_wine_bug 24819 + then + sh "$WINETRICKS" -q gameux=disabled + $WINESERVER -w + fi + + cd "$WISOTOOL_CACHE/$PACKAGE" + + ahk_do " + Settitlematchmode, 2 + run, GrandAgesRome-EU-XL-Demo.exe + winwait, Installer Language + sleep 1000 + controlclick, Button1, Installer Language + winwait, Grand Ages, Welcome to the + sleep 1000 + controlclick, Button2, Grand Ages, Welcome to the + winwait, Grand Ages, Press Page Down + sleep 1000 + controlclick, Button2, Grand Ages, Press Page Down + winwait, Grand Ages, Please select installation type + sleep 1000 + controlclick, Button2, Grand Ages, Please select installation type + winwait, Grand Ages, Completing the Grand Ages Rome Demo + sleep 1000 + controlclick, Button4, Grand Ages, Completing the Grand Ages Rome Demo + sleep 100 + controlclick, Button2, Grand Ages, Completing the Grand Ages Rome Demo + " + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cd $programfilesdir_x86_win\\Kalypso\\Grand Ages Rome Demo +Rome Demo.exe +__EOF__ + +} + +#---------------------------------------------------------------- + verblist_add gta_vc "Grand Theft Auto: Vice City (Rockstar, 2003) " \ e98c2d323dd0494989a844442586dc2d48fba8f9.iso \ d31f5c35cc63d804a7ffdb212f550681b97ee5b3.iso load_gta_vc() { - load_autohotkey - iso_mount "$WISOTOOL_CACHE"/$PACKAGE/e98c2d323dd0494989a844442586dc2d48fba8f9.iso ahk_do " SetTitleMatchMode, 2 @@ -2872,7 +4183,7 @@ load_gta_vc() { send {enter} " iso_umount - + if workaround_wine_bug 22414 then try "$WINETRICKS" -q quartz @@ -2880,15 +4191,13 @@ load_gta_vc() { } #---------------------------------------------------------------- - + verblist_add half_life_goty "Half Life: Game of the Year Edition (Sierra, 2000) " \ dc32c16bca6c19f14e3501e3be3e4a157ddbee20.iso load_half_life_goty() { - load_autohotkey - iso_mount "$WISOTOOL_CACHE"/$PACKAGE/dc32c16bca6c19f14e3501e3be3e4a157ddbee20.iso - + ahk_do " SetTitleMatchMode, 2 Run, ${ISO_MOUNT_LETTER}:Setup.exe @@ -2925,11 +4234,11 @@ load_half_life_goty() { Sleep 1000 ControlClick, Button4, Setup Complete, Setup has finished installing Half-Life on your computer. " - + # The key is put in on first run: HALF_LIFE_GOTY_KEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/dc32c16bca6c19f14e3501e3be3e4a157ddbee20.txt` cd $DRIVE_C/SIERRA/Half-Life - + # Forcefully closing the process later will screw up the screen resolution, so store the user's current resolution so we can restore it later: current_res=`xrandr -q | awk -F'current' -F',' 'NR==1 {gsub("( |current)","");print $2}'` @@ -2951,6 +4260,66 @@ load_half_life_goty() { #---------------------------------------------------------------- +verblist_add hordsoforcs2_demo "Hordes of Orcs 2 Demo (Freeverse, 2010) [download]" HoO2Demo.exe + +load_hordsoforcs2_demo() { + if ! test -f "$WISOTOOL_CACHE/$PACKAGE"/HoO2Demo.exe + then + mkdir -p "$WISOTOOL_CACHE/$PACKAGE" + die "Please visit http://www.fileplanet.com/216619/download/Hordes-of-Orcs-2-Demo, download HoO2Demo.exe, and place it in directory $WISOTOOL_CACHE/$PACKAGE" + fi + # FIXME: check sha1sum 1ba26d35697e359f89a30915140e471fadc675da + + cd "$WISOTOOL_CACHE/$PACKAGE" + + ahk_do " + SetTitleMatchMode, 2 + run HoO2Demo.exe + WinWait,Orcs + sleep 500 + ControlFocus, Button1, Hordes ; Next + sleep 500 + Send {Enter} + WinWait,Orcs,conditions + sleep 500 + ControlFocus, Button4, Hordes, agree + sleep 500 + Send {Space} + sleep 500 + ControlFocus, Button1, Hordes ; Next + sleep 500 + Send {Enter} + WinActivate,Orcs,files + sleep 500 + ControlFocus Button1, Hordes ; Next + sleep 500 + Send {Enter} + WinWait,Orcs,exist + sleep 500 + ControlFocus, Button1, Hordes ; Yes + sleep 500 + Send {Enter} + WinActivate,Orcs,T + sleep 500 + ControlFocus, Button1, Hordes ; Start + sleep 500 + Send {Enter} + WinWait,Orcs,E + sleep 500 + ControlFocus, Button2, successfully + sleep 500 + Send {Space} + " + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Hordes of Orcs 2 Demo" +HoO2.exe +__EOF__ +} + +#---------------------------------------------------------------- + hbpdemoexe=Release_HBP_demo_PC_DD_DEMO_FINAL_348428.exe verblist_add hphbp_demo "Harry Potter & The Half Blood Prince Demo (EA, 2009) [download]" $hbpdemoexe @@ -2960,8 +4329,6 @@ load_hphbp_demo() ""|"C") die "Harry Potter won't install in the Posix locale; please do 'export LANG=en_US.UTF-8' or something like that" ;; esac - load_autohotkey - if ! test -f "$WISOTOOL_CACHE/$PACKAGE/$hbpdemoexe" then download $PACKAGE http://largedownloads.ea.com/pub/demos/HarryPotter/Release_HBP_demo_PC_DD_DEMO_Final_348428.exe dadc1366c3b5e641454aa337ad82bc8c5082bad2 @@ -2991,7 +4358,8 @@ load_hphbp_demo() # Not sure I trust putting \U2122 in a batch file, so use a wild card to cd to the right dir. # Have to "cd pc" as next command, or the wildcard expansion fails on wine? # Have to be in the pc directory for the app to find its files. - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd $programfilesdir_x86_win\\Electronic Arts\\Harry Potter and the Half-Blood Prince* Demo cd pc hp6_demo.exe @@ -3008,7 +4376,6 @@ load_hphbp() ""|"C") die "Harry Potter won't install in the Posix locale; please do 'export LANG=en_US.UTF-8' or something like that" ;; esac - load_autohotkey iso_mount "$WISOTOOL_CACHE"/$PACKAGE/9590f4c4bf2d5e819014cd9b03a5d5408ae2cd7d.iso HPHBP_KEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/9590f4c4bf2d5e819014cd9b03a5d5408ae2cd7d.txt | tr -d -` ahk_do " @@ -3032,7 +4399,8 @@ load_hphbp() " $WINESERVER -w iso_umount - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd $programfilesdir_x86_win\Electronic Arts\Harry Potter and the Half-Blood Prince* cd pc hp6.exe @@ -3041,12 +4409,10 @@ __EOF__ #---------------------------------------------------------------- -verblist_add hegemonypom_demo "Hegemony: Philip of Macedon Demo (Longbow Games, 2010) [download]" Hegemony_Philip_of_Macedon_Installer.exe +verblist_add hegemonypom_demo "Hegemony: Philip of Macedon Demo (Longbow Games, 2010) [download]" Hegemony_Philip_of_Macedon_Installer.exe load_hegemonypom_demo() { - load_autohotkey - mkdir -p "$WISOTOOL_CACHE/$PACKAGE" cd "$WISOTOOL_CACHE/$PACKAGE" @@ -3070,6 +4436,26 @@ load_hegemonypom_demo() controlclick, Button2 winwait, Hegemony, shortcuts controlclick, Button2 + + Loop + { + ; Work around wine bug 24484 + IfWinExist, Log message, IKnownFolderManager + { + send {Enter} + } + ; Work around wine bug 21261 + IfWinExist, Log message, Games Explorer + { + send {Enter} + } + IfWinExist, Hegemony, has been installed + { + break + } + Sleep (2000) + } + winwait, Hegemony, has been installed controlclick, Button4 controlclick, Button2 @@ -3088,18 +4474,13 @@ load_help() { #---------------------------------------------------------------- -honexe=HoNClient-1.0.0.1.exe +honexe=HoNClient-1.0.12.1.exe verblist_add hon "Heroes of Newerth (S2 Games, 2010) [download]" \ $honexe load_hon() { - load_autohotkey - - if ! test -f "$WISOTOOL_CACHE/$PACKAGE/$honexe" - then - download $PACKAGE http://dl2.heroesofnewerth.com/$honexe - fi + download $PACKAGE http://dl.heroesofnewerth.com/$honexe 27236eca37ac7b90fe80feaf9b2c0f8eb0e49701 cd "$WISOTOOL_CACHE/$PACKAGE" ahk_do " @@ -3120,7 +4501,8 @@ load_hon() " cd "$olddir" - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Heroes of Newerth" hon.exe __EOF__ @@ -3128,10 +4510,9 @@ __EOF__ #---------------------------------------------------------------- -verblist_add hod3_jp_demo "The House of the Dead 3 - Japanese - Demo (SEGA, 2005) [download]" hod3_trial.exe +verblist_add hod3_jp_demo "The House of the Dead 3 - Japanese - Demo (SEGA, 2005) (broken in wine-1.3.3?) [download]" hod3_trial.exe load_hod3_jp_demo() { - load_autohotkey if ! test -f "$WISOTOOL_CACHE/$PACKAGE/hod3_trial.exe" then download $PACKAGE http://www2.sega.co.jp/download/pc/hod3/hod3_trial.exe f616ac945bcbb5b897d24f3ce568c0f528801d05 @@ -3154,8 +4535,31 @@ load_hod3_jp_demo() { winwait, THE HOUSE OF THE DEAD 3 send {Enter} ; Installer crashes before putting up finished dialog, but app seems okay anyway + Loop + { + IfWinExist, THE HOUSE OF THE DEAD 3,Finish + { + WinActivate + Send {Enter} ; Finish (I hope, needs testing) + } + Process, Exist, hod3_trial.exe ; BmLauncher automatically starts after installation finished. + retVal = %ErrorLevel% + if retVal == 0 + { + ; installer has crashed or exited + break + } + ; work around hang on wine + if FileExist(\"$programfilesdir_x86_win\\SEGA\\THE HOUSE OF THE DEAD3_JP_TRIAL\\hod3launch.exe\") + { + Sleep (10000) + break + } + Sleep (2000) + } " cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\SEGA\\THE HOUSE OF THE DEAD3_JP_TRIAL" hod3launch.exe __EOF__ @@ -3163,14 +4567,67 @@ __EOF__ #---------------------------------------------------------------- +verblist_add kq1vga "King Quest I VGA (AGD Interactive, 2009) [download]" Kq1vga40.exe + +# http://www.agdinteractive.com/games/kq1/download/download.html +# http://agdinteractive.com/countdl.php?action=download&game=11 +# See also http://en.wikipedia.org/wiki/AGD_Interactive + +load_kq1vga() { + download $PACKAGE http://www.glorianon.com/agdi/Kq1vga40.exe 68627cf51391a7000ba671253421b47dc2d57005 + + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + run Kq1vga40.exe + WinWait, King's Quest I Install Program - Welcome + Send {Enter} + WinWait, King's Quest I Install Program - Information + Send {Enter} + WinWait, King's Quest I Install Program - Agreement + ;Click 248, 275 ; check agree + ;Send !n ; Next + Send {Up}{Up}{Up}{Space} ; check agree + Send {Tab}{Enter} ; Next + WinWait, King's Quest I Install Program - Directory + Send {Enter} + IfNotExist, C:\\Program Files\\AGD Interactive\\King's Quest I + { + WinWait, King's Quest I Install Program, Do you want it to be created + Send {Enter} + } + WinWait, King's Quest I Install Program - Confirmation + Send {Enter} + WinWait, King's Quest I Install Program - End + ;Sleep 1000 + ;Click 184, 232 ; don't start game + ;Send {Esc} + ; Couldn't find a portable way to not start game, so let it start, then kill it + Send !x ; Exit + WinWait King's Quest I Launcher + WinClose + " + if workaround_wine_bug 23892 + then + ahk_do " + winwait Adventure Game Studio + send {Enter} + " + fi + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\AGD Interactive\\King's Quest I" +Kq1vga.exe +__EOF__ +} + +#---------------------------------------------------------------- + verblist_add lhp_demo "LEGO Harry Potter Demo [Years 1-4] (Travellers Tales / WB, 2010) [download]" LEGOHarryPotterDEMO.exe load_lhp_demo() { - load_autohotkey - case "$LANG" in - *UTF-8*) ;; + *UTF-8*|*utf8*) ;; *) die "This installer fails in non-utf-8 locales. Try doing export LANG=en_US.UTF-8" esac @@ -3200,7 +4657,8 @@ load_lhp_demo() warn "If you have sound problems, try switching to OSS sound in winecfg" fi - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\WB Games\\LEGO*" LEGOHarryPotterDEMO.exe __EOF__ @@ -3208,13 +4666,206 @@ __EOF__ #---------------------------------------------------------------- +verblist_add lol "League of Legends (Riot Games, 2009)" LeagueofLegends.exe + +load_lol() +{ +# http://appdb.winehq.org/objectManager.php?sClass=version&iId=19141 +# http://www.leagueoflegends.com/ + + # Outer installer, fetches the latest client + if ! test -f "${WISOTOOL_CACHE}/${PACKAGE}/LeagueofLegends.exe" + then + download ${PACKAGE} http://l3cdn.riotgames.com/Installer/ProdSource.06_29_2010/LeagueofLegends.exe 89cb958c6430c7840c377b61cae7939a0d276249 + fi + + # Holy crap this is broken under Wine! Prepare for a workaround orgy + if workaround_wine_bug 20296 + then + warn "You'll need a patch from http://bugs.winehq.org/show_bug.cgi?id=20296 to avoid a crash when starting LoL" + fi + + if workaround_wine_bug 21870 + then + sh "$WINETRICKS" -q secur32 + fi + + if workaround_wine_bug 22152 + then + export GC_DONT_GC=1 + fi + + if workaround_wine_bug 24019 'wine-1.3.[2-9]|wine-1.3.1[0-9]' # fixed in wine-1.3.2 + then + # Avoid crash in downloader + warn "Please apply patch from wine bug 24019" + fi + + if workaround_wine_bug 24020 + then + # Avoid crash in downloader + sh "$WINETRICKS" -q vcrun2008 + fi + + if workaround_wine_bug 24025 + then + warn "The installer's background will be white. Known wine bug, no workaround yet. See http://bugs.winehq.org/show_bug.cgi?id=24025" + fi + + if ! test -d "$WISOTOOL_CACHE/$PACKAGE/LeagueofLegends" + then + cd "${WISOTOOL_CACHE}/${PACKAGE}" + ahk_do " + settitlematchmode, 2 + run, LeagueofLegends.exe + winwait, League of Legends Downloader, Where would you like to save League of Legends? + sleep 1000 + ; It doesn't always register this click... + while true + { + ifwinexist, League of Legends Downloader, Where would you like to save League of Legends? + { + sleep 1000 + controlclick, Static21, League of Legends Downloader, Where would you like to save League of Legends? + } + else + break + } + ; After it finishing download, move the files from $DRIVE_C/users/$LOGNAME/Desktop to $WISOTOOL_CACHE/$PACKAGE + winwaitclose, League of Legends Downloader + process, close, setup.exe + process, close, PMB.exe + " + # Cache the game files. Assumes that the Desktop directory is under C:\users\$USERNAME or the equivalent on Windows + # FIXME: Make this more generic(move out of this function, so others can use it) / test on XP and Vista+ + WINEDESKTOP="`$WINE cmd /c echo %USERPROFILE% | tr -d '\r' | sed 's,\\\\,\\\\\\\\,g'`" + DESKTOPDIR="`$XXXPATH -u $WINEDESKTOP`/Desktop" + mv "$DESKTOPDIR/LeagueofLegends" "$WISOTOOL_CACHE/$PACKAGE/" + fi + + cd "$WISOTOOL_CACHE/$PACKAGE/LeagueofLegends" + ahk_do " + settitlematchmode, 2 + run, Setup.exe + winwait, League of Legends, Welcome to the InstallShield Wizard + sleep 1000 + controlclick, Button1, League of Legends, Welcome to the InstallShield Wizard + winwait, League of Legends, I &accept the terms of the license agreement + sleep 1000 + controlclick, Button3, League of Legends, I &accept the terms of the license agreement + sleep 1000 + controlclick, Button1, League of Legends, I &accept the terms of the license agreement + winwait, League of Legends, Please select a setup type + sleep 1000 + controlclick, Button4, League of Legends, Please select a setup type + winwait, League of Legends, Click Install to begin + sleep 1000 + controlclick, Button1, League of Legends, Click Install to begin + winwait, League of Legends, Click Finish to exit the wizard + sleep 1000 + controlclick, Button1, League of Legends, Click Finish to exit the wizard + sleep 1000 + controlclick, Button4, League of Legends, Click Finish to exit the wizard + " + + if workaround_wine_bug 24015 + then + sh "$WINETRICKS" -q ie6 + fi + +cat > "${DRIVE_C}/run-${PACKAGE}.bat" << __EOF__ +C: +cd "C:\\Riot Games\\League of Legends" +lol.launcher.exe +__EOF__ + +set -x + # Run once to accept EULA and start autoupdater + rm -f "$DRIVE_C/Riot Games/League of Legends/patcher_lib.log" + cd "$DRIVE_C" + ahk_do " + SetTitleMatchMode, 2 + run, run-$PACKAGE.bat + winwait, League of Legends Launcher,Accept + send {Enter} + " + log="$DRIVE_C/Riot Games/League of Legends/patcher_lib.log" + # Wait for autoupdate to start + while true + do + sleep 5 + tail -n 2 "$log" + if test -f "$log" && ! tail -n 2 "$log" | grep "to .PATCHER_STATE_ALLTASKSCOMPLETE" + then + echo Downloader started + break + fi + done + + # Wait for autoupdate to finish + while true + do + sleep 5 + tail -n 2 "$log" + if tail -n 2 "$log" | grep "to .PATCHER_STATE_ALLTASKSCOMPLETE" + then + echo Downloader finished + break + fi + done + + ahk_do " + SetTitleMatchMode, 2 + winwait, League of Legends Launcher + winclose + " +} + +verblist_add lol_standalone "League of Legends standalone client (Riot Games, 2009)" 'StandAlone_9_21_2010_NA(with%20sse2%20fix).rar' + +load_lol_standalone() { + download ${PACKAGE} "http://l3cdn.riotgames.com/Installer/lol/StandAlone_9_21_2010_NA(with%20sse2%20fix).rar" 571f8fbb5bff31fe94f3f08280cb0ff6e432bde5 + mkdir -p "$DRIVE_C/Riot Games" + cd "$DRIVE_C/Riot Games" + try_unrar x "$WISOTOOL_CACHE/$PACKAGE/StandAlone_9_21_2010_NA(with%20sse2%20fix).rar" + +cat > "${DRIVE_C}/run-${PACKAGE}.bat" << __EOF__ +C: +cd "C:\\Riot Games\\StandAlone_9_21_2010_NA" +lol.launcher.exe +__EOF__ + + # Holy crap this is broken under Wine! Prepare for a workaround orgy + if workaround_wine_bug 20296 + then + warn "You'll need a patch from http://bugs.winehq.org/show_bug.cgi?id=20296 to avoid a crash when starting LoL" + fi + if workaround_wine_bug 21870 + then + warn "Please apply patch attached to bug 21870, or client will crash on start." + fi + if workaround_wine_bug 24102 # fixed in wine-1.3.3, but wine-1.3.3 crashes in secur32 on start? wine-1.3.1 is ok... + then + # Crashes on startup in wine below 1.3.3 without this + sh "$WINETRICKS" -q d3dx9_36 + fi + if workaround_wine_bug 24015 + then + sh "$WINETRICKS" -q ie6_full + fi + if workaround_wine_bug 24432 + then + sh "$WINETRICKS" -q vcrun2005 + fi +} + +#---------------------------------------------------------------- + verblist_add lotsn "Launch of the Screaming Narwhal (Telltale Games / Lucasarts, 2009)" LaunchOfTheScreamingNarwhal_Setup.exe load_lotsn() { - load_autohotkey - - if ! test -f "${WISOTOOL_CACHE}/${PACKAGE}/LaunchOfTheScreamingNarwhal_Setup.exe" + if ! test -f "${WISOTOOL_CACHE}/${PACKAGE}/LaunchOfTheScreamingNarwhal_Setup.exe" then download ${PACKAGE} http://www.telltalegames.com/demo/launchofthescreamingnarwhal 8a9292d89fd5e7efe58e63dcfc84a05bf08ff1d6 LaunchOfTheScreamingNarwhal_Setup.exe fi @@ -3243,6 +4894,7 @@ load_lotsn() cd "${olddir}" cat > "${DRIVE_C}/run-${PACKAGE}.bat" << __EOF__ +${programfilesdrive}: cd "${programfilesdir_x86_win}\\Telltale Games\\Tales of Monkey Island\\Launch of the Screaming Narwhal" MonkeyIsland101.exe __EOF__ @@ -3256,11 +4908,73 @@ __EOF__ #---------------------------------------------------------------- +verblist_add lp2bench "Lost Planet 2 Benchmark (Capcom, 2010)" LostPlanet2_Benchmark.zip + +load_lp2bench() +{ + # http://news.bigdownload.com/2010/08/16/lost-planet-2-pc-due-out-on-october-15-benchmark-test-released/ + + if ! test -f "${WISOTOOL_CACHE}/${PACKAGE}/LostPlanet2_Benchmark.zip" + then + download ${PACKAGE} http://gamedaily.newaol.com/pub/LostPlanet2_Benchmark.zip 2c9862adc81974a61a450a1865cd60decd82587c + fi + + cd "${WISOTOOL_CACHE}/${PACKAGE}/" + + if ! test -f "${WISOTOOL_CACHE}/${PACKAGE}/LostPlanet2_Benchmark.exe" + then + try unzip "$WISOTOOL_CACHE/$PACKAGE"/LostPlanet2_Benchmark.zip + fi + + ahk_do " + SetTitleMatchMode, 2 + run LostPlanet2_Benchmark.exe + winwait, LOST PLANET 2 Benchmark + sleep 1000 + controlclick, Button1, LOST PLANET 2 Benchmark + winwait, LOST PLANET 2 Benchmark, Capcom and NVIDIA have worked + sleep 1000 + controlclick, Button1, LOST PLANET 2 Benchmark, Capcom and NVIDIA have worked + winwait, LOST PLANET 2 Benchmark, license agreement + sleep 1000 + controlclick, Button3, LOST PLANET 2 Benchmark, license agreement + sleep 1000 + controlclick, Button5, LOST PLANET 2 Benchmark, license agreement + winwait, LOST PLANET 2 Benchmark, Destination Folder + sleep 1000 + controlclick, Button1, LOST PLANET 2 Benchmark, Destination Folder + winwait, LOST PLANET 2 Benchmark, Ready to Install + sleep 1000 + controlclick, Button1, LOST PLANET 2 Benchmark, Ready to Install + winwait, LOST PLANET 2 Benchmark, InstallShield Wizard Completed + sleep 1000 + controlclick, Button3, LOST PLANET 2 Benchmark, InstallShield Wizard Completed + sleep 1000 + controlclick, Button1, LOST PLANET 2 Benchmark, InstallShield Wizard Completed + " + if workaround_wine_bug 21939 + then + sh "$WINETRICKS" -q wmp9 + fi + +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\CAPCOM\\LOST PLANET 2 Benchmark Version" +.\LP2DX9.exe +__EOF__ + + if workaround_wine_bug 24043 + then + warn "Benchmark crashes on launch, see http://bugs.winehq.org/show_bug.cgi?id=24043" + fi + +} + +#---------------------------------------------------------------- + verblist_add lswcs "Lego Star Wars Complete Saga (Lucasarts, 2009)" dc5db10e2ad2892ba40015d3856d1d29dc55893a.iso load_lswcs() { - load_autohotkey - iso_mount "$WISOTOOL_CACHE"/$PACKAGE/dc5db10e2ad2892ba40015d3856d1d29dc55893a.iso ahk_do " run ${ISO_MOUNT_LETTER}:setup.exe @@ -3268,7 +4982,7 @@ load_lswcs() { winwait, Choose Setup Language send {Enter} winwait, LEGO, License Agreement - send a{Enter} + send a{Enter} winwait, LEGO, method ControlClick Easy Installation sleep 1000 @@ -3276,11 +4990,11 @@ load_lswcs() { " # Installer crashes at end (http://bugs.winehq.org/show_bug.cgi?id=22529) but this doesn't seem to hurt. # Wait for all processes to exit, else unmount will fail - # FIXME: use right wineserver - wineserver -w + $WINESERVER -w iso_umount - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\LucasArts\\LEGO Star Wars - The Complete Saga" LEGOStarWarsSaga.exe __EOF__ @@ -3298,8 +5012,6 @@ verblist_add manhole "The Manhole Masterpiece Edition (Cyan, 1994)" \ load_manhole() { cd $WISOTOOL_TMP - load_autohotkey - iso_mount "$WISOTOOL_CACHE"/$PACKAGE/39aea1267c2b2b22a7d5c1e9f86ea1f4461457e3.iso mkdir -p "$DRIVE_C"/manhole try cp -r "$ISO_MOUNT_ROOT"/* "$DRIVE_C"/manhole @@ -3318,24 +5030,28 @@ verblist_add masseffect2 "Mass Effect 2 (BioWare, 2010)" \ 49d1f9b85203049d52a8e34b92cd7d4b96e0c8be.iso load_masseffect2() { - load_autohotkey iso_mount "$WISOTOOL_CACHE"/$PACKAGE/4b817d67c8b7e8e7bc33f8cb6047210ab554fef6.iso ME2_KEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/4b817d67c8b7e8e7bc33f8cb6047210ab554fef6.txt | tr -d -` if workaround_wine_bug 22091 then warn "Will probably hang at end of installer. If a crash dialog comes up, you can kill it, it's done." - #try sh "$WINETRICKS" -q nocrashdialog + try sh "$WINETRICKS" -q nocrashdialog fi - if workaround_wine_bug 23126 + if workaround_wine_bug 23126 "wine-1.3.[0-9]*" then try sh "$WINETRICKS" -q vcrun2005 fi - if workaround_wine_bug 23125 + if workaround_wine_bug 23125 "wine-1.3.[0-9]*" then try sh "$WINETRICKS" d3dx10 fi + if workaround_wine_bug 23151 + then + warn "Disabling glsl to workaround wine bug 23151. Users of nvidia cards will get weird effects without this. If you're on ATI/Intel, you can revert this with 'winetricks glsl-enable'" + try sh "$WINETRICKS" -q glsl-disable + fi if workaround_wine_bug 22919 then try sh "$WINETRICKS" -q physx @@ -3369,15 +5085,26 @@ load_masseffect2() { send {Enter} ; Some installs may not get to this point due to an installer hang/crash (bug 22919) ; The hang/crash happens after the Physx install but does not seem to affect gameplay - ; TODO: work around this by waiting in some other way for install to finish - winwait, Mass Effect, Finish - winkill, Mass Effect + loop + { + ifwinexist, Mass Effect, Finish + { + winkill, Mass Effect + break + } + Process, exist, Installer.exe + me2pid = %ErrorLevel% + if me2pid = 0 + break + sleep 1000 + } " if workaround_wine_bug 6971 then echo "See http://appdb.winehq.org/objectManager.php?sClass=version&iId=19125 for info on how to patch wine to work around bug 6971" fi cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Mass Effect 2\Binaries" MassEffect2.EXE __EOF__ @@ -3389,39 +5116,43 @@ __EOF__ verblist_add masseffect2_demo "Mass Effect 2 (BioWare, 2010)" MassEffect2DemoEN.exe load_masseffect2_demo() { - load_autohotkey - - file="$WISOTOOL_CACHE/$PACKAGE/MassEffect2DemoEN.exe" - if ! test -f "$file" - then - download ${PACKAGE} http://masseffect.bioware.com/cdn/A/ME2_DEMO/MassEffect2DemoEN.exe cda9a25387a98e29772b3ccdcf609f87188285e2 - fi + download ${PACKAGE} http://masseffect.bioware.com/cdn/A/ME2_DEMO/MassEffect2DemoEN.exe cda9a25387a98e29772b3ccdcf609f87188285e2 if workaround_wine_bug 22091 then warn "Will probably hang at end of installer. If a crash dialog comes up, you can kill it, it's done." - #try sh "$WINETRICKS" -q nocrashdialog + try sh "$WINETRICKS" -q nocrashdialog fi - if workaround_wine_bug 23126 + if workaround_wine_bug 23126 "wine-1.3.[0-9]*" then try sh "$WINETRICKS" -q vcrun2005 fi - if workaround_wine_bug 23125 + if workaround_wine_bug 23125 "wine-1.3.[0-9]*" then try sh "$WINETRICKS" d3dx10 fi + if workaround_wine_bug 23151 + then + warn "Disabling glsl to workaround wine bug 23151. Users of nvidia cards will get weird effects without this. If you're on ATI/Intel, you can revert this with 'winetricks glsl-enable'" + try sh "$WINETRICKS" -q glsl-disable + fi if workaround_wine_bug 22919 then try sh "$WINETRICKS" -q physx fi mkdir -p "$WISOTOOL_TMP/$PACKAGE" - # FIXME: use ln -fs on linux, cp on windows - cp "$WISOTOOL_CACHE/$PACKAGE/MassEffect2DemoEN.exe" "$WISOTOOL_TMP" + case "$OS" in + "Windows_NT") + cp "$WISOTOOL_CACHE/$PACKAGE/MassEffect2DemoEN.exe" "$WISOTOOL_TMP" ;; + *) + ln -sf "$WISOTOOL_CACHE/$PACKAGE/MassEffect2DemoEN.exe" "$WISOTOOL_TMP" ;; + esac + cd "$WISOTOOL_TMP" ahk_do " SetTitleMatchMode, 2 - run, $WISOTOOL_TMP_WIN\\MassEffect2DemoEN.exe + run, MassEffect2DemoEN.exe winwait, Mass Effect 2 Demo Sleep 1000 send {Enter} @@ -3436,15 +5167,26 @@ load_masseffect2_demo() { ControlClick, Button2 ; Some installs may not get to this point due to an installer hang/crash (bug 22919) ; The hang/crash happens after the Physx install but does not seem to affect gameplay - ; TODO: work around this by waiting in some other way for install to finish - winwait, Mass Effect 2 Demo, Finish - winkill + loop + { + ifwinexist, Mass Effect, Finish + { + winkill, Mass Effect + break + } + Process, exist, Installer.exe + me2pid = %ErrorLevel% + if me2pid = 0 + break + sleep 1000 + } " if workaround_wine_bug 6971 then echo "See http://appdb.winehq.org/objectManager.php?sClass=version&iId=19125 for info on how to patch wine to work around bug 6971" fi cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Mass Effect 2 Demo\\Binaries" MassEffect2.EXE __EOF__ @@ -3453,11 +5195,32 @@ __EOF__ #---------------------------------------------------------------- +verblist_add maxmagicmarker_demo "Download: Max & the Magic Marker Demo (2010) [download]" max_demo_pc.zip + +load_maxmagicmarker_demo() { + + download $PACKAGE http://www.maxandthemagicmarker.com/maxdemo/max_demo_pc.zip 1a79c583ff40e7b2cf05d18a89a806fd6b88a5d1 + + try mkdir "$programfilesdir_x86_unix"/$PACKAGE + cd "$programfilesdir_x86_unix"/$PACKAGE + try unzip "$WISOTOOL_CACHE/$PACKAGE"/max_demo_pc.zip + # Work around bug in game?! + mv "max and the magic markerdemo pc" "max and the magic markerdemo pc"_Data + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\$PACKAGE" +max and the magic markerdemo pc.exe +__EOF__ +} + +#---------------------------------------------------------------- + verblist_add metro2033 "Metro 2033 (THQ, 2010)" 3de89e07449c2573cd4a334b0cd7da012a98f97c.iso load_metro2033() { warn "You'll need to have STEAM_USER/STEAM_PASS set in your environment or in $WISOTOOL_CACHE. You'll also need your cd-key for Metro 2033 already added to your Steam Account." - + if [ ! "$STEAM_USER" -a ! -f "$WISOTOOL_CACHE"/STEAM_USER ] then die "You need to set STEAM_USER variable in your environment or put it in "$WISOTOOL_CACHE"/STEAM_USER" @@ -3476,8 +5239,6 @@ load_metro2033() { steam_dir="$programfilesdir_unix/Steam" - load_autohotkey - # Game uses Steam to install itself try sh $WINETRICKS -q steam @@ -3496,7 +5257,7 @@ load_metro2033() { winclose, Steam - Update News winclose, Steam " - + ahk_do " Run, Steam.exe -install I:\\ ; Install Metro 2033 @@ -3511,7 +5272,7 @@ load_metro2033() { winwait, Install - Metro 2033 send, {Enter} " - + # Wait for install to finish dl_log="$steam_dir/logs/download_log.txt" while true @@ -3528,7 +5289,8 @@ load_metro2033() { warn "You'll need the Xinput2 patch from http://bugs2.winehq.org/attachment.cgi?id=29313 to be able to use the mouse." -cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Steam" Steam.exe -login $STEAM_USER $STEAM_PASS -applaunch 43110 __EOF__ @@ -3537,12 +5299,107 @@ __EOF__ #---------------------------------------------------------------- +verblist_add mise "Monkey Island: Special Edition (LucasArts, 2009)" SecretOfMonkeyIslandSE_ddsetup.zip + +load_mise() { + # Archive SHA1SUM 2e32458698c9ec7ebce94ae5c57531a3fe1dbb9e + if [ ! -f "$WISOTOOL_CACHE/$PACKAGE/SecretOfMonkeyIslandSE_ddsetup.zip" ] + then + mkdir -p "$WISOTOOL_CACHE/$PACKAGE" + die "Download the game from http://www.direct2drive.com/8241/product/Buy-The-Secret-of-Monkey-Island(R):-Special-Edition-Download and place in $WISOTOOL_CACHE/$PACKAGE. Place the activation code in activationcode.txt in that directory, too." + fi + + if workaround_wine_bug 22161 + then + # Doesn't crash, but you only get a black screen and a flood of d3dx fixme's without native d3dx9_36 + sh "$WINETRICKS" -q d3dx9_36 + fi + + if workaround_wine_bug 24545 + then + # Game wants to install directx, but we delete it. It really only needs xact for x3daudio?_?.dll + sh "$WINETRICKS" -q xact + fi + + if workaround_wine_bug 24547 + then + # It really does need vcrun2005, for msvp80.dll (and potentially one stub from msvcr80) + sh "$WINETRICKS" -q vcrun2005 + fi + + cd "$WISOTOOL_TMP" + mkdir $PACKAGE + cd $PACKAGE + + # Don't extract DirectX/dotnet35 installers, they just take up extra time and aren't needed. Luckily, MISE copes well and just skips them if they are missing: + try unzip "$WISOTOOL_CACHE/$PACKAGE"/SecretOfMonkeyIslandSE_ddsetup.zip -x DirectX* dotnet* + + ahk_do " + SetTitleMatchMode, 2 + run, setup.exe + WinWait, The Secret of Monkey Island, This wizard will guide you + sleep 1000 + ControlClick, Button2 + WinWait, The Secret of Monkey Island, License Agreement + sleep 1000 + ControlSend, RichEdit20A1, {CTRL}{END} + sleep 1000 + ControlClick, Button4 + sleep 1000 + ControlClick, Button2 + WinWait, The Secret of Monkey Island, Setup Type + sleep 1000 + ControlClick, Button2 + WinWait, The Secret of Monkey Island, Click Finish + sleep 1000 + ControlClick, Button2 + " + + cd "$olddir" + + # Activate + if test -f "$WISOTOOL_CACHE"/$PACKAGE/activationcode.txt + then + MISE_KEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/activationcode.txt` + ahk_do " + SetTitleMatchMode, 2 + run, $programfilesdir_x86_win\\LucasArts\\The Secret of Monkey Island Special Edition\\MISE.exe + winwait, Product Activation + ControlClick, Edit1 ; Activation Code + send $MISE_KEY + ControlClick Button4 ; Activate Online + winwait, Product Activation, SUCCESSFUL + winClose + " + elif test -f "$WISOTOOL_CACHE"/$PACKAGE/unlockcode.txt + then + MISE_KEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/unlockcode.txt` + ahk_do " + SetTitleMatchMode, 2 + run, $programfilesdir_x86_win\\LucasArts\\The Secret of Monkey Island Special Edition\\MISE.exe + winwait, Product Activation + ControlClick, Edit3 ; Unlock Code + send $MISE_KEY + ControlClick Button6 ; Activate manual + winwait, Product Activation, SUCCESSFUL + winClose + " + fi + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\LucasArts\\The Secret of Monkey Island Special Edition" +MISE.exe +__EOF__ + +} + +#---------------------------------------------------------------- + verblist_add moh_beta "Medal of Honor: Beta (EA, 2010) [download]" MOHMP_Beta_PC_Client_R2_550504_Installer.zip load_moh_beta() { - load_autohotkey - # Archive SHA1SUM 7585700202ec305017038be4f1cb8ee1b43c24a2 file="$WISOTOOL_CACHE/$PACKAGE/MOHMP_Beta_PC_Client_R2_550504_Installer.zip" test -f "$file" || file="$WISOTOOL_CACHE/$PACKAGE/MOH-MPBetaClient_R2550504_Installer.zip" @@ -3557,7 +5414,7 @@ load_moh_beta() cd "$WISOTOOL_TMP/$PACKAGE" ahk_do " SetTitleMatchMode, 2 - run, setup.exe + run, setup.exe winwait, Medal of Honor, will install controlclick, Button1 winwait, Medal of Honor, License @@ -3583,20 +5440,21 @@ load_moh_beta() then mv "Medal of Honor MP Beta"/settings.ini "Medal of Honor MP Beta"/oldsettings.ini sed 's,DxVersion=auto,DxVersion=9,; - s,Fullscreen=true,Fullscreen=false,' "Medal of Honor MP Beta"/oldsettings.ini > "Medal of Honor MP Beta"/settings.ini + s,Fullscreen=true,Fullscreen=false,' "Medal of Honor MP Beta"/oldsettings.ini > "Medal of Honor MP Beta"/settings.ini else mkdir -p "Medal of Honor MP Beta" echo "[Graphics]" > "Medal of Honor MP Beta"/settings.ini echo "DxVersion=9" >> "Medal of Honor MP Beta"/settings.ini fi fi - + cd "$olddir" # fixme: Try to find a way to script this? warn "After you sign up at http://medalofhonor.com/beta, you will receive a beta key which you will need to enter the first time you run the game." - - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Electronic Arts\\Medal of Honor MP Beta" MoHMPGame.exe __EOF__ @@ -3613,7 +5471,6 @@ load_morrowind() { # FIXME: Only supports the main installer, and the construction set (which follows automatically) # eventually should support the expansions as well - load_autohotkey iso_mount "$WISOTOOL_CACHE"/$PACKAGE/c8368ed30d3f3fcd7fccf8bffcfcdf0a6d4cb68b.iso ahk_do " @@ -3657,9 +5514,9 @@ load_morrowind() { winwait, Information, You have installed Windows XP, which includes DirectX 8.1 sleep 1000 ControlClick, Button1 - + exit 0" - + sleep 30s iso_umount cd "$olddir" @@ -3672,8 +5529,7 @@ verblist_add mnbw_demo "Mount & Blade Warband Demo (Taleworlds, 2010) [download] load_mnbw_demo() { - load_autohotkey - if ! test -f "${WISOTOOL_CACHE}/${PACKAGE}/${mnbw_demo_exe}" + if ! test -f "${WISOTOOL_CACHE}/${PACKAGE}/${mnbw_demo_exe}" then download ${PACKAGE} http://download.taleworlds.com/${mnbw_demo_exe} fi @@ -3692,6 +5548,7 @@ load_mnbw_demo() " cd "${olddir}" cat > "${DRIVE_C}/run-${PACKAGE}.bat" << __EOF__ +${programfilesdrive}: cd "${programfilesdir_x86_win}\\Mount&Blade Warband" mb_warband.exe __EOF__ @@ -3700,12 +5557,34 @@ __EOF__ #---------------------------------------------------------------- +verblist_add nd23_saw_demo "Nancy Drew 23: Shadow at the Waters Edge Demo (Her Interactive, 2010)" SAW_demo1.zip + +load_nd23_saw_demo() { + # http://www.herinteractive.com/Mystery_Games/Nancy_Drew/Shadow_at_the_Waters_Edge/pc + download $PACKAGE http://www.herinteractive.com/games/saw/SAW_demo1.zip 29975be19c99f7707c4da218b60e2ed0d70bf4a7 + + cd "$DRIVE_C" + mkdir $PACKAGE + cd $PACKAGE + try unzip "$WISOTOOL_CACHE/$PACKAGE"/SAW_demo1.zip + + if workaround_wine_bug 24754 + then + try sh "$WINETRICKS" -q d3dx9_36 + fi + cat > "${DRIVE_C}/run-${PACKAGE}.bat" << __EOF__ +c: +cd "${PACKAGE}" +Shadow.exe +__EOF__ +} + +#---------------------------------------------------------------- + verblist_add nfsps_demo "Need For Speed: Pro Street Demo (EA, 2007)" nfsps_pcdemo.exe load_nfsps_demo() { - load_autohotkey - if ! test -f "$WISOTOOL_CACHE/$PACKAGE/ps_pcdemo.exe" then download $PACKAGE http://largedownloads.ea.com/pub/demos/NFS/prostreet/nfsps_pcdemo.exe 9cf74563d28c29a40920e0c0644c2da6e8e2a888 @@ -3738,7 +5617,8 @@ load_nfsps_demo() controlclick, Button4 " cd "$olddir" - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Electronic Arts\\Need for Speed ProStreet Demo" nfsdemo.exe __EOF__ @@ -3750,8 +5630,6 @@ verblist_add nfsshift "Need For Speed: Shift (EA, 2009)" 83d3b7499742ccf77da1 load_nfsshift() { - load_autohotkey - if workaround_wine_bug 23324 then msvcrun_me_harder=" @@ -3767,7 +5645,7 @@ load_nfsshift() ahk_do " SetTitleMatchMode, 2 ; note: if this is the second run, the installer skips the registration code prompt - run, ${ISO_MOUNT_LETTER}:EASetup.exe + run, ${ISO_MOUNT_LETTER}:EASetup.exe ; Not sure which of two or three dialogs happens next loop { @@ -3822,7 +5700,8 @@ load_nfsshift() " # Need path on shift.exe, see bug 23319 - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Electronic Arts\\Need for Speed SHIFT" .\shift.exe __EOF__ @@ -3834,8 +5713,6 @@ verblist_add nfsshift_demo "Need For Speed: SHIFT Demo (EA, 2009) [download]" load_nfsshift_demo() { - load_autohotkey - if ! test -f "$WISOTOOL_CACHE/$PACKAGE/NFSSHIFTPCDEMO.exe" then download $PACKAGE http://cdn.needforspeed.com/data/downloads/shift/NFSSHIFTPCDEMO.exe 7b267654d08c54f15813f2917d9d74ec40905db7 @@ -3845,12 +5722,13 @@ load_nfsshift_demo() # FIXME: use ln -s on Linux (in case user has run 'winetricks sandbox'), # but run the package from the cache on Windows cp "$WISOTOOL_CACHE/$PACKAGE/NFSSHIFTPCDEMO.exe" "$WISOTOOL_TMP" + cd "$WISOTOOL_TMP" ahk_do " SetTitleMatchMode, 2 SetTitleMatchMode, slow - run, $WISOTOOL_TMP_WIN\\NFSSHIFTPCDEMO.exe + run, NFSSHIFTPCDEMO.exe winwait, WinRAR - send $WISOTOOL_TMP_WIN\\$PACKAGE + send $PACKAGE ControlClick, Button2 winwait, SHIFT, View the readme controlclick, Button1 @@ -3890,7 +5768,8 @@ load_nfsshift_demo() controlclick, Button1 " cd "$olddir" - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Electronic Arts\\Need for Speed SHIFT Demo" shiftdemo.exe __EOF__ @@ -3902,8 +5781,6 @@ verblist_add oblivion "Elder Scrolls: Oblivion (Bethesda Game Studios, 2006)" load_oblivion() { - load_autohotkey - iso_mount "$WISOTOOL_CACHE"/$PACKAGE/0c6826d55029e7b64150ebe804220284962657e1.iso ahk_do " @@ -3924,7 +5801,8 @@ load_oblivion() controlclick, Button3 " iso_umount - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Bethesda Softworks Oblivion\\Oblivion" Oblivion.exe __EOF__ @@ -3937,8 +5815,6 @@ verblist_add orangebox "Orange Box (Valve, 2007) " \ b86c9297cc4c56e98f8c3f3e489091ffa4b4a11d.iso load_orangebox() { - load_autohotkey - test -f "$programfilesdir_x86_unix"/Steam/Steam.exe || try sh $WINETRICKS -q steam # Have to log in before you can install orangebox! $WINE 'c:\Program Files\Steam\Steam' -login $STEAMUSER $STEAMPW @@ -3987,17 +5863,53 @@ load_orangebox() { " iso_umount - # FIXME: how to tell when update is done? Probably have to launch all games once + # FIXME: how to tell when update is done? Probably have to launch all games once # the the commandline option to exit immediately. } #---------------------------------------------------------------- +verblist_add osmos_demo "Osmos demo (Hemisphere Games, 2009) [download]" OsmosDemo_Installer_1.5.6.exe + +load_osmos_demo() { + + download $PACKAGE http://gamedaily.newaol.com/pub/OsmosDemo_Installer_1.5.6.exe 7568f97100a73985a0fd625b63b205f4477578e8 + + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + SetTitleMatchMode, 2 + run OsmosDemo_Installer_1.5.6.exe + winwait, Osmos Demo Setup, License Agreement + sleep 500 + controlclick, Button2, Osmos Demo Setup, License Agreement + winwait, Osmos Demo Setup, Choose Install Location + sleep 500 + controlclick, Button2, Osmos Demo Setup, Choose Install Location + winwait, Osmos Demo Setup, Choose Start Menu Folder + sleep 500 + controlclick, Button2, Osmos Demo Setup, Choose Start Menu Folder + winwait, Osmos Demo Setup, Installation Complete + sleep 500 + controlclick, Button2, Osmos Demo Setup, Installation Complete + " + + if workaround_wine_bug 24416 + then + sh "$WINETRICKS" -q vcrun2005 + fi + +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\OsmosDemo" +OsmosDemo.exe +__EOF__ +} + +#---------------------------------------------------------------- + verblist_add pcmark04 "PC Mark 04 (Futuremark, 2004) [download]" PCMark04_v130_installer.exe load_pcmark04() { - load_autohotkey - # http://www.futuremark.com/download/pcmark04/ if ! test -f "$WISOTOOL_CACHE/$PACKAGE/PCMark04_v130_installer.exe" then @@ -4043,7 +5955,8 @@ load_pcmark04() { warn "You may need to apply the patch from bug 22402 to avoid a crash in the tumbling blocks test." fi - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Futuremark\PCMark04" PCMark04 __EOF__ @@ -4054,8 +5967,6 @@ __EOF__ verblist_add pcmark05 "PC Mark 05 (Futuremark, 2005) [download]" PCMark05_v120_1901.exe load_pcmark05() { - load_autohotkey - # http://www.futuremark.com/download/pcmark05/ if ! test -f "$WISOTOOL_CACHE/$PACKAGE/PCMark05_v120_1901.exe" then @@ -4099,7 +6010,8 @@ load_pcmark05() { Send {Enter} " - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Futuremark\PCMark05" PCMark05 __EOF__ @@ -4111,8 +6023,6 @@ __EOF__ #verblist_add passmark7 "Performance Test 7 (Passmark, 2010) [download]" petst.exe load_passmark7() { - load_autohotkey - # http://www.passmark.com/download/pt_download.htm if ! test -f "$WISOTOOL_CACHE/$PACKAGE/petst.exe" then @@ -4134,8 +6044,7 @@ verblist_add pscs5 "Photoshop CS5 Demo (Adobe, 2010)" \ load_pscs5() { - load_autohotkey - try cd "$WISOTOOL_CACHE/$PACKAGE/" + try cd "$WISOTOOL_CACHE/$PACKAGE" if [ ! -f "$WISOTOOL_CACHE/$PACKAGE/Photoshop_12_LS1.7z" ] then die "You must download Photoshop CS5 trial files and put them in $WISOTOOL_CACHE/$PACKAGE" @@ -4151,15 +6060,15 @@ load_pscs5() { try Photoshop_12_LS1.exe /s /x /d . try cd "Adobe CS5" - + if workaround_wine_bug 22679 then try sh "$WINETRICKS" -q msxml3 fi warn "Try not to have anything else running, cs5 will complain if firefox is running, and the mouse clicks here are sensitive" - - # Doesn't have clickable buttons, resorting to window positions. May break on non standard dpi settings. + + # Doesn't have clickable buttons, resorting to window positions. May break on non standard dpi settings. # Not sure how to detect when the window changes. They all have the same title, and no text is visible to AHK. # As a dirty workaround, may try detecting the color on the left side which shows the menu. The current step is darker # than the rest. @@ -4199,7 +6108,7 @@ load_pscs5() { " try cd .. # Remove installer temp files: - try cd "$WISOTOOL_CACHE/$PACKAGE/" + try cd "$WISOTOOL_CACHE/$PACKAGE" try rm -rf "Photoshop CS5 Read Me.pdf" "Adobe CS5" try cd "$olddir" } @@ -4208,7 +6117,7 @@ verblist_add pscs5_pickle "Photoshop CS5 Demo (Adobe, 2010)" load_pscs5_pickle() { warn "This will tar up Photoshop CS5's files from a Windows install, along with needed registry entries, for use in wine with load_pscs5_unpickle()" - + if [ ! -d "$programfilesdir_x86_win/Adobe/Adobe Photoshop CS5/" ] then load_pscs5 @@ -4225,7 +6134,7 @@ load_pscs5_pickle() { try cd cs5_temp try sleep 1 # Potential race condition, caught me a couple times - + # First, the registry entries: try reg.exe export HKLM\\Software\\Adobe adobe_cs5.reg @@ -4238,17 +6147,17 @@ load_pscs5_pickle() { try cd ../"Program Files" try cp -r "$programfilesdir_x86_unix/Adobe" . try cd ../userhome - try cp -r "$userprofile_unix/Application Data/Adobe" . + try cp -r "$appdata_unix/Adobe" . try cd .. try cp "$system32_unix/odbc32.dll" . try cp "$system32_unix/odbcint.dll" . - + try cd "$WISOTOOL_TMP"/cs5_temp try tar -c -f "$olddir/adobe_cs5.tar" * try cd .. try rm -rf cs5_temp try cd "$olddir" - + } verblist_add pscs5_unpickle "Photoshop CS5 Demo (Adobe, 2010)" \ @@ -4256,9 +6165,9 @@ verblist_add pscs5_unpickle "Photoshop CS5 Demo (Adobe, 2010)" \ load_pscs5_unpickle() { warn "This will install Photoshop CS5's files from a Windows install made with pscs5_pickle()" - + # Install dependencies: - try sh "$WINETRICKS" -q gdiplus ie6 msxml3 vcrun2005sp1 vcrun2008 + try sh "$WINETRICKS" -q gdiplus ie6 msxml3 vcrun2005sp1 vcrun2008 try cd "$WISOTOOL_TMP" try tar xf "$WISOTOOL_CACHE/$PACKAGE/adobe_cs5.tar" @@ -4267,14 +6176,14 @@ load_pscs5_unpickle() { try mv "$WISOTOOL_TMP/Program Files/Adobe" . try cd "Common Files" try mv "$WISOTOOL_TMP/Common Files/Adobe" . - try cd "$DRIVE_C/users/$USER/Application Data/" + try cd "$appdata_win/" try mv "$WISOTOOL_TMP/userhome"/* . try cd "$WINDIR/system32" try mv "$WISOTOOL_TMP/odbc32.dll" . try mv "$WISOTOOL_TMP/odbcint.dll" . try $WINE regsvr32 odbc32.dll try $WINE regsvr32 odbcint.dll - + warn "Do not report bugs to wine with an installation done this way. Wait until the installer bugs are fixed or have patches to workaround them!" warn "On the first run, it will tell you your trial has 0 days left. On the second run and after, it will say 30 days." } @@ -4284,11 +6193,9 @@ load_pscs5_unpickle() { verblist_add plantsvszombies "Plants vs. Zombies (PopCap Games, 2009) [download]" PlantsVsZombiesSetup.exe load_plantsvszombies() { - load_autohotkey - if ! test -f "$WISOTOOL_CACHE/plantsvszombies/PlantsVsZombiesSetup.exe" then - download plantsvszombies "http://downloads.popcap.com/www/popcap_downloads/PlantsVsZombiesSetup.exe" fcae7b8c63d9a5b5f6ed783232bc5f612fd5c963 + download plantsvszombies "http://downloads.popcap.com/www/popcap_downloads/PlantsVsZombiesSetup.exe" c46979be135ef1c486144fa062466cdc51b740f5 fi cd "$WISOTOOL_CACHE/plantsvszombies" @@ -4303,7 +6210,8 @@ load_plantsvszombies() { ControlClick, x309 y278, Plants vs. Zombies Installation Complete!,,,, Pos " - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\PopCap Games\Plants vs. Zombies" PlantsVsZombies __EOF__ @@ -4311,12 +6219,99 @@ __EOF__ #---------------------------------------------------------------- +verblist_add pop2008 "Prince of Persia (Ubisoft, 2008)" e65acd04baaf84481b79589b795edb144d24d1b5.iso + +load_pop2008() +{ + iso_mount "$WISOTOOL_CACHE/$PACKAGE/e65acd04baaf84481b79589b795edb144d24d1b5.iso" + ahk_do " + SetTitleMatchMode, 2 + run, ${ISO_MOUNT_LETTER}:Setup.exe + winwait, Prince of Persia, Language + sleep 1000 + ControlClick, Button3 + winwait, Prince of Persia, Welcome + sleep 1000 + ControlClick, Button1 + winwait, Prince of Persia, License + sleep 1000 + ControlClick, Button5 + sleep 1000 + ControlClick, Button2 + winwait, Prince of Persia, Click Install + sleep 1000 + ControlClick, Button1 + winwait, Prince of Persia, Click Finish + sleep 1000 + ControlClick, Button4 + " + + iso_umount + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Ubisoft\\Prince of Persia" +Prince of Persia.exe +__EOF__ +} + + +#---------------------------------------------------------------- + +verblist_add popfs "Prince of Persia The Forgotten Sands (Ubisoft, 2010)" \ +bab557c2a75ad67fd1a10804ecd2fb5e5890f03e.iso + +load_popfs() +{ + iso_mount "$WISOTOOL_CACHE/$PACKAGE/bab557c2a75ad67fd1a10804ecd2fb5e5890f03e.iso" + ahk_do " + SetTitleMatchMode, 2 + run, ${ISO_MOUNT_LETTER}:Setup.exe + winwait, Prince of Persia, Language + ControlClick, Button3 + winwait, Prince of Persia, Welcome + ControlClick, Button1 + winwait, Prince of Persia, License + ControlClick, Button5 + ControlClick, Button2 + winwait, Prince of Persia, Click Install + ControlClick, Button1 + ;Avoid error when creating desktop shortcut + Loop + { + IfWinActive, Prince of Persia, Click Finish + break + IfWinExist, Prince of Persia, desktop shortcut + { + ControlClick, Button1, Prince of Persia, desktop shortcut + break + } + sleep 5000 + } + winwait, Prince of Persia, Click Finish + ControlClick, Button4 + " + iso_umount + +if workaround_wine_bug 24346 +then + sh "$WINETRICKS" -q dsoundbug9612 +fi + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Ubisoft\\Prince of Persia The Forgotten Sands" +Prince of Persia.exe +__EOF__ +} + +#---------------------------------------------------------------- + verblist_add popsot "Prince of Persia Sands of Time (Ubisoft, 2003)" \ a55dc7459b0e8b40b49c16e62761932c90b6ede2.iso load_popsot() { - load_autohotkey iso_mount "$WISOTOOL_CACHE/$PACKAGE/a55dc7459b0e8b40b49c16e62761932c90b6ede2.iso" ahk_do " SetTitleMatchMode, 2 @@ -4354,11 +6349,10 @@ POP_Demo_Eng.exe load_popsot_demo() { - load_autohotkey if ! test -f "$WISOTOOL_CACHE/$PACKAGE/POP_Demo_Eng.exe" && ! test -f "$WISOTOOL_CACHE/$PACKAGE/pop_demo_eng.exe" then mkdir -p "$WISOTOOL_CACHE/$PACKAGE" - warn "You must manually download the Prince of Persia Sands of Time Demo to $WISOTOOL_CACHE/$PACKAGE/pop_demo_eng.exe; expected sha1sum ed62f4da1f898c661ca09bd4e3a22e4a983a822b" + die "You must manually download the Prince of Persia Sands of Time Demo to $WISOTOOL_CACHE/$PACKAGE/pop_demo_eng.exe; expected sha1sum ed62f4da1f898c661ca09bd4e3a22e4a983a822b" fi cd "$WISOTOOL_CACHE/$PACKAGE" ahk_do " @@ -4393,7 +6387,7 @@ load_popsot_demo() } winwait, Prince of Persia, View the Readme ControlClick, Button1, Prince of Persia, View the Readme - ControlClick, Finish, Prince of Persia, View the Readme + ControlClick, Finish, Prince of Persia, View the Readme " cd "$olddir" warn "Once you're in the Prince of Persia game, turn off fog or you won't be able to see anything (see wine bug 17423 for explanation, but this isn't a wine bug)" @@ -4405,16 +6399,15 @@ verblist_add procycling08_demo "Pro Cycling Manager 2008 Demo (Cyanide, 2008) [d load_procycling08_demo() { - load_autohotkey # FIXME sha1sum 008b91a16c388c9965faaeaaa8242409b9db56b9 # FIXME homepage http://www.cycling-manager.com/ if ! test -f "$WISOTOOL_CACHE/$PACKAGE/ProCyclingManager08_Demo.exe" then mkdir -p "$WISOTOOL_CACHE/$PACKAGE" - warn "Please download the game to $WISOTOOL_CACHE/$PACKAGE/ProCyclingManager08_Demo.exe from e.g. http://www.fileplanet.com/189566/download/Pro-Cycling-Manager---Tour-de-France-2008---Demo , sha1sum should be 008b91a16c388c9965faaeaaa8242409b9db56b9" + die "Please download the game to $WISOTOOL_CACHE/$PACKAGE/ProCyclingManager08_Demo.exe from e.g. http://www.fileplanet.com/189566/download/Pro-Cycling-Manager---Tour-de-France-2008---Demo , sha1sum should be 008b91a16c388c9965faaeaaa8242409b9db56b9" fi - cd $WISOTOOL_CACHE/$PACKAGE + cd "$WISOTOOL_CACHE/$PACKAGE" ahk_do " SetTitleMatchMode, 2 run, ProCyclingManager08_Demo.exe @@ -4447,13 +6440,12 @@ verblist_add proevolution2010_demo "Pro Evolution Soccer 2010 Demo (Konami, 2009 load_proevolution2010_demo() { # http://appdb.winehq.org/objectManager.php?sClass=version&iId=18148 - load_autohotkey if ! test -f "$WISOTOOL_CACHE/$PACKAGE/PES2010_PC_DEMO_Setup.exe" then download $PACKAGE http://gamedaily.newaol.com/pub/PES2010_PC_DEMO_Setup.exe a1c913c367f121adf5f6e4104c76ab48f8d9457e fi - cd $WISOTOOL_CACHE/$PACKAGE + cd "$WISOTOOL_CACHE/$PACKAGE" ahk_do " SetTitleMatchMode, 2 run, PES2010_PC_DEMO_Setup.exe @@ -4479,11 +6471,70 @@ load_proevolution2010_demo() if workaround_wine_bug 23104 then - try sh "$WINETRICKS" -q d3dx9 + try sh "$WINETRICKS" -q d3dx9_36 fi + +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\KONAMI\\Pro Evolution Soccer 2010 DEMO" +pes2010.exe +__EOF__ + } +#---------------------------------------------------------------- +verblist_add proevolution2011_demo "Pro Evolution Soccer 2011 Demo (Konami, 2010) [download][broken on wine]" PES2011_Demo.exe + +load_proevolution2011_demo() +{ + # http://appdb.winehq.org/objectManager.php?sClass=version&iId=18148 + # http://www.bigdownload.com/games/pro-evolution-soccer-2011/pc/pro-evolution-soccer-2011-demo/ + download $PACKAGE http://gamedaily.newaol.com/pub/PES2011_Demo.exe 48e281177651637f549fb0ee5b8c4f91affb809a + + if workaround_wine_bug 24438 + then + warn "Installer probably won't work, see http://bugs.winehq.org/show_bug.cgi?id=24438" + fi + + # Copied from 2010, the first few dialogs are the same, but can't test all of it because of bug 24438. + + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + SetTitleMatchMode, 2 + run, PES2011_Demo.exe + winwait, Pro Evolution Soccer 2011 DEMO - InstallShield Wizard, WARNING: This program is protected + sleep 1000 + ControlClick, Button1, Pro Evolution Soccer 2011 DEMO - InstallShield Wizard, WARNING: This program is protected ; Next + winwait, Pro Evolution Soccer 2011 DEMO - InstallShield Wizard, Please read the following + sleep 1000 + ControlClick, Button3, Pro Evolution Soccer 2011 DEMO - InstallShield Wizard, Please read the ; Accept license + sleep 1000 + ControlClick, Button5, Pro Evolution Soccer 2011 DEMO - InstallShield Wizard, Please read the following license ; Next + winwait, Pro Evolution Soccer 2011 DEMO - InstallShield Wizard, Click Next to install to this folder + sleep 1000 + ControlClick, Button1, Pro Evolution Soccer 2011 DEMO - InstallShield Wizard, Click Next to install to this folder ; Next + winwait, Pro Evolution Soccer 2011 DEMO - InstallShield Wizard, The wizard is ready to begin installation + sleep 1000 + ControlClick, Button1, Pro Evolution Soccer 2011 DEMO - InstallShield Wizard, The wizard is ready to begin installation. ; Install + winwait, Pro Evolution Soccer 2011 DEMO - InstallShield Wizard, InstallShield Wizard Completed + sleep 1000 + ControlClick, Button1, Pro Evolution Soccer 2011 DEMO - InstallShield Wizard, InstallShield Wizard Completed ; Finished + " + cd "$olddir" + + if workaround_wine_bug 23104 + then + sh "$WINETRICKS" d3dx9_36 + fi + +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\KONAMI\\Pro Evolution Soccer 2011 DEMO" +pes2011demo.exe +__EOF__ + +} #---------------------------------------------------------------- @@ -4493,12 +6544,18 @@ verblist_add rom "Runes of Magic (Frogster Interactive, 2009) [download]" \ load_rom() { - load_autohotkey - if ! test -f "$WISOTOOL_CACHE/$PACKAGE/Runes_of_Magic_3.0.1.2153.part1.exe" || ! test -f "$WISOTOOL_CACHE/$PACKAGE/Runes_of_Magic_3.0.1.2153.part2.rar" then download $PACKAGE http://frogster.vo.llnwd.net/o9/FOG/rom/Runes_of_Magic_3.0.1.2153_two.exe/Runes_of_Magic_3.0.1.2153.part1.exe 3263660262c6411f179e80c5ef0906c783d7bb08 download $PACKAGE http://frogster.vo.llnwd.net/o9/FOG/rom/Runes_of_Magic_3.0.1.2153_two.exe/Runes_of_Magic_3.0.1.2153.part2.rar 569dee9c375fa50394958daa9f8d8a1b02bb9b11 + + fi + if ! test -f "$WISOTOOL_CACHE/$PACKAGE/cached/ROMSetup.exe" + then + # Pre-extract files, if unrar is available + mkdir -p "$WISOTOOL_CACHE/$PACKAGE/cached" + cd "$WISOTOOL_CACHE/$PACKAGE/cached" + try_unrar e ../Runes_of_Magic_3.0.1.2153.part1.exe fi # manual updates from http://forum.runesofmagic.com/showthread.php?t=79267 download $PACKAGE http://frogster.vo.llnwd.net/o9/patch/en/patch_3.0.1.2153.en_3.0.1.2172.en.exe 817391606fd1c05ad6194a06b21f6a5632cacf4f @@ -4507,43 +6564,114 @@ load_rom() download $PACKAGE http://frogster.vo.llnwd.net/o9/patch/en/patch_3.0.1.2178.en_3.0.1.2181.en.exe c449510566108dfc29882e6229cf716f232102df download $PACKAGE http://frogster.vo.llnwd.net/o9/patch/en/patch_3.0.1.2181.en_3.0.1.2192.en.exe d5afc10ff1126c3dabafa02b4681f411aa689c57 download $PACKAGE http://frogster.vo.llnwd.net/o9/patch/en/patch_3.0.1.2192.en_3.0.1.2199.en.exe 542ac3b4d0fc4434aadfb784a46868f1815351da + download $PACKAGE http://frogster.vo.llnwd.net/o9/patch/en/patch_3.0.1.2199.en_3.0.2.2189.en.exe c5f6115aeb2e4627dd0428c0024f177dca6f067c + download $PACKAGE http://frogster.vo.llnwd.net/o9/patch/en/patch_3.0.2.2189.en_3.0.2.2213.en.exe bf3183406bcb848826301bba33775a6dfb611859 + download $PACKAGE http://frogster.vo.llnwd.net/o9/patch/en/patch_3.0.2.2213.en_3.0.2.2214.en.exe d576596086395ea83cb8c1422877c81ed45a90c9 + download $PACKAGE http://frogster.vo.llnwd.net/o9/patch/en/patch_3.0.2.2214.en_3.0.3.2231.en.exe af3f74030f371ef9bc4cfcecf4a9ad1159f28136 + download $PACKAGE http://frogster.vo.llnwd.net/o9/patch/en/patch_3.0.3.2231.en_3.0.3.2241.en.exe e46dbb3d2699ddc34a7885a16224c79f80657749 + download $PACKAGE http://frogster.vo.llnwd.net/o9/patch/en/patch_3.0.3.2241.en_3.0.3.2246.en.exe 17c49fb1381fb6927a19ed58ef210abd98c3e89f + download $PACKAGE http://frogster.vo.llnwd.net/o9/patch/en/patch_3.0.3.2246.en_3.0.3.2250.en.exe 6484b2d8b23c1c7389f2f9a38681ecda84d856a4 + download $PACKAGE http://frogster.vo.llnwd.net/o9/patch/en/patch_3.0.3.2250.en_3.0.4.2237.en.exe a34b20828303cdeaa649b503d0eee915b7a808b3 + download $PACKAGE http://frogster.vo.llnwd.net/o9/patch/en/patch_3.0.4.2237.en_3.0.4.2261.en.exe 511bf0281a7f87e9912fcf52649307eec5b7d315 + download $PACKAGE http://frogster.vo.llnwd.net/o9/patch/en/patch_3.0.4.2261.en_3.0.4.2263.en.exe 8d01ef99ae2a72e36d9de2b6d021bc3bbd3cd246 cd "$WISOTOOL_CACHE/$PACKAGE" + patches=`ls patch*.exe` ahk_do " SetTitleMatchMode, 2 - run, Runes_of_Magic_3.0.1.2153.part1.exe + ; Pre-extracting makes it a lot easier to debug this script! + ifexist, cached\\ROMSetup.exe + run, cached\\ROMSetup.exe + else + run, Runes_of_Magic_3.0.1.2153.part1.exe winwait, Runes of Magic, This will install + sleep 2000 ControlClick, TNewButton1 winwait, Runes of Magic, License - ControlClick, TNewRadioButton1 - ControlClick, TNewButton2 + sleep 1000 + ControlClick, TNewRadioButton1 ; Accept + loop + { + ; FIXME find some simpler way of making this reliable on vista + ifwinexist, Runes of Magic, License + ControlClick, TNewButton2 ; Next + sleep 1000 + ifwinexist, Runes of Magic, Destination + break + } winwait, Runes of Magic, Destination - ControlClick, TNewButton3 + ;ControlClick, TNewButton3 + send {Enter} winwait, Runes of Magic, shortcuts - ControlClick, TNewButton4 + ;ControlClick, TNewButton4 + send {Enter} winwait, Runes of Magic, Additional Tasks - ControlClick, TNewButton4 + ;ControlClick, TNewButton4 + send {Enter} winwait, Runes of Magic, Ready - ControlClick, TNewButton4 + ;ControlClick, TNewButton4 + send {Enter} winwait, Runes of Magic, finished - ControlClick, TNewCheckListBox1 - ControlClick, TNewButton4 - winwait, Territory - send {Esc} - ; Don't let it autoupdate - winkill + sleep 1000 + ;ControlClick, TNewCheckListBox1 + send {Space} ; don't start + ;ControlClick, TNewButton4 + send {Enter} ; finish + ;winwait, Territory # not needed anymore? + ;send {Esc} + ; Don't let it autoupdate (not needed anymore?) + winkill " - # FIXME: use right wineserver and/or find nicer way to finish - wineserver -k + # Let installer finish normally + $WINESERVER -w + # Create settings file so patches can find game. Normally this is created on first run of game. + # Use funny tr and | to avoid embedded carriage returns, some editors strip them + mkdir -p "$DRIVE_C/users/$USERNAME/My Documents/Runes of Magic" + tr '|' '\015' > "$DRIVE_C/users/$USERNAME/My Documents/Runes of Magic/GameSettings.ini" <<_EOF_ +[Install]| +GamePath=$programfilesdir_x86_win\\Runes of Magic\\| +_EOF_ - cd "$WISOTOOL_CACHE"/$PACKAGE - for patch in patch_* + for patch in $patches do + echo Running $patch ahk_do " - run $patch + run $patch,,, patchpid SetTitleMatchMode, 2 - winwait, RomUpdate - winwaitclose, RomUpdate + loop + { + ; patch might exit before we notice it + process, exist, %patchpid% + if ErrorLevel = 0 + break + ;ifwinexist, Find game path + ;{ + ; send {Enter} + ; winwait, Browse for Folder + ; ; these coordinates are brittle and only work on empty wine + ; MouseMove, 76,145 ; on + next to Program Files + ; Click + ; MouseMove, 115,207 ; select Runes of Magic + ; Click + ; send {Enter} + ; winwaitclose + ;} + ifwinexist, Error + winwaitclose + ; Older updaters use title "RomUpdate" + ifwinexist, RomUpdate + { + winwaitclose + break + } + ; Newer updaters use title "Runes of Magic U" (no fooling) + ifwinexist, Runes of Magic U + { + winwaitclose + break + } + sleep 1000 + } " done @@ -4557,8 +6685,9 @@ load_rom() try sh "$WINETRICKS" -q ie6 fi - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ -cd "$programfilesdir_x86_win\Runes of Magic" + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Runes of Magic" "Runes of Magic.exe" __EOF__ @@ -4570,8 +6699,6 @@ __EOF__ verblist_add re5bench "Resident Evil 5 Benchmark (Capcom, 2009) [download]" nzd_ResidentEvil5_Benchmark.exe load_re5bench() { - load_autohotkey - if ! test -f "$WISOTOOL_CACHE/$PACKAGE/nzd_ResidentEvil5_Benchmark.exe" then download $PACKAGE http://download.nvidia.com/downloads/nZone/demos/nzd_ResidentEvil5_Benchmark.exe 041492b9af138f67e7acf97fbd8e926dda59ab12 @@ -4580,7 +6707,7 @@ load_re5bench() { cd "$WISOTOOL_CACHE/$PACKAGE" ahk_do " run nzd_ResidentEvil5_Benchmark.exe - WinWait ahk_class MsiDialogCloseClass + WinWait ahk_class MsiDialogCloseClass Sleep 1000 Send {Enter} ; ControlClick Button1 ; Next. Doesn't work? @@ -4591,9 +6718,25 @@ load_re5bench() { ControlClick Button1 ; Next WinWait ahk_class MsiDialogCloseClass, Ready ControlClick Button1 ; Install - WinWait ahk_class MsiDialogCloseClass, Completed - ControlClick Button3 ; Uncheck Launch - ControlClick Button1 ; Finish + Loop + { + ; Only shows up on older Wine versions (e.g., 1.2. Disabling gameux.dll does not help + IfWinExist, GameExplorerInstall + { + ControlClick, Button1, GameExplorerInstall + Winwait, ahk_class MsiDialogCloseClass, Completed + ControlClick Button3 ; Uncheck Launch + ControlClick Button1 ; Finish + break + } + IfWinExist, ahk_class MsiDialogCloseClass, Completed + { + ControlClick Button3 ; Uncheck Launch + ControlClick Button1 ; Finish + break + } + sleep 5000 + } " if workaround_wine_bug 21939 @@ -4603,7 +6746,8 @@ load_re5bench() { # Should run launcher.exe, but that requires .net and doesn't run on Wine # Should give choice of running RE5DX10.EXE, but that requires dx10, which doesn't work on Wine yet - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\CAPCOM\RESIDENT EVIL 5 Benchmark Version" RE5DX9.EXE __EOF__ @@ -4611,11 +6755,47 @@ __EOF__ #---------------------------------------------------------------- +verblist_add riseofnations_demo "Rise of Nations Trial (Microsoft/Big Huge Games 2003) [download]" RiseOfNationsTrial.exe + +load_riseofnations_demo() { + + if ! test -f "$WISOTOOL_CACHE/$PACKAGE"/RiseOfNationsTrial.exe + then + mkdir -p "$WISOTOOL_CACHE/$PACKAGE" + die "Please visit http://download.cnet.com/Rise-of-Nations-Trial-Version/3000-7562_4-10730812.html, download RiseOfNationsTrial.exe, and place it in directory $WISOTOOL_CACHE/$PACKAGE" + fi + # FIXME: check sha1sum 33cbf1ebc0a93cb840f6296d8b529f6155db95ee + + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + SetTitleMatchMode, 2 + run RiseOfNationsTrial.exe + WinWait,Rise Of Nations Trial Setup + sleep 2500 + ControlClick CButtonClassName2 + WinWait,Rise Of Nations Trial Setup, installed + sleep 2500 + ControlClick CButtonClassName7 + " + + if workaround_wine_bug 9027 + then + try sh "$WINETRICKS" -q directmusic + fi + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd $programfilesdir_x86_win\\Microsoft Games\\Rise of Nations Trial +nations.exe +__EOF__ + +} +#---------------------------------------------------------------- +#---------------------------------------------------------------- + verblist_add quake3 "Quake 3 (ID Software, 1999)" 4d2102a8df3c1fea237f2a6a141346c436614d5e.iso load_quake3() { - load_autohotkey - iso_mount "$WISOTOOL_CACHE"/$PACKAGE/4d2102a8df3c1fea237f2a6a141346c436614d5e.iso ahk_do " Run ${ISO_MOUNT_LETTER}:Setup.exe @@ -4642,14 +6822,54 @@ load_quake3() { #---------------------------------------------------------------- +verblist_add sammax304_demo "Sam & Max: The Devils Playhouse - Beyond the Alley of the Dolls (Telltale Games, 2010) [download]" SamMax304_v02.18_unlockable_securom_pa_BigDownload.exe + +load_sammax304_demo() { + if ! test -f "$WISOTOOL_CACHE/$PACKAGE"/SamMax304_v02.18_unlockable_securom_pa_BigDownload.exe + then + download $PACKAGE "http://gamedaily.newaol.com/pub/SamMax304_BigDownload.exe.zip" 5d3cefcf0c654d3646105e14cb3d06c61feb32f3 + cd "$WISOTOOL_CACHE/$PACKAGE" + try unzip SamMax304_BigDownload.exe.zip + rm -f SamMax304_BigDownload.exe.zip + fi + + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + SetTitleMatchMode, 2 + run SamMax304_v02.18_unlockable_securom_pa_BigDownload.exe + WinWait,Sam and Max Beyond the Alley of the Dolls Setup,Welcome + ControlClick Button2 ; Next + WinWait,Sam and Max Beyond the Alley of the Dolls Setup,DirectX + ControlClick Button2 ; Next - Directx check defaulted + WinWait,Sam and Max Beyond the Alley of the Dolls Setup,License + ControlClick Button2 ; Agree + WinWait,Sam and Max Beyond the Alley of the Dolls Setup,Location + ControlClick Button2 ; Install + WinWait,Sam and Max Beyond the Alley of the Dolls Setup,Finish + ControlClick Button4 ; Uncheck Play Now + ControlClick Button2 ; Finish + " + + if workaround_wine_bug 24250 + then + try sh "$WINETRICKS" -q vcrun2005 + fi + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Telltale Games\\Sam and Max - The Devil's Playhouse\\Beyond the Alley of the Dolls" +SamMax304.exe +__EOF__ +} + +#---------------------------------------------------------------- + verblist_add sega_rally_2 "Sega Rally 2 (Sega, 1999)" rally2.exe # http://appdb.winehq.org/objectManager.php?sClass=application&iId=6961 -load_sega_rally_2() { - load_autohotkey - +load_sega_rally_2() { download $PACKAGE http://www2.sega.co.jp/download/pc/rally2/rally2.exe 1c0560c9f7d22343511a8ad46dbe606c6c7417c9 - + # Installer starts by extracting files, but doesn't seem to be a zip file or a cab file. I tried a few cli arguments, # but had no luck. It's only 60 MB extracted, so just extract it fresh each time. cd "$WISOTOOL_CACHE/$PACKAGE" @@ -4696,7 +6916,8 @@ load_sega_rally_2() { warn "The game is unplayable due to http://bugs.winehq.org/show_bug.cgi?id=22668. No known workaround." fi -cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Sega\SEGA RALLY 2 DEMO" "SEGA RALLY 2 DEMO.exe" __EOF__ @@ -4708,7 +6929,6 @@ __EOF__ verblist_add 7million "7Million (Deep Silver, 2009) [download] [broken on wine]" 7Million_0_17_0-full.exe load_7million() { - load_autohotkey download $PACKAGE http://content.deepsilver.com/kochmedia/downloads/7million/de-uk/7Million_0_17_0-full.exe 99d496817367216180c4b3a59180361c23348e1e cd "$WISOTOOL_CACHE/$PACKAGE" @@ -4737,6 +6957,7 @@ load_7million() { " cd "$olddir" cat > "$DRIVE_C/run-$PACKAGE.bat" << __EOF__ +${programfilesdrive}: cd "users\\$LOGNAME\Local Settings\Application Data\7Million" 7million __EOF__ @@ -4751,7 +6972,6 @@ __EOF__ verblist_add secondlife_beta "Second Life Viewer - Beta [Download]" Second_Life_2-1-0-207030_Setup.exe load_secondlife_beta() { - load_autohotkey download $PACKAGE http://download.cloud.secondlife.com/Viewer-2-1/Second_Life_2-1-0-207030_Setup.exe cd "$WISOTOOL_CACHE/$PACKAGE" @@ -4759,15 +6979,16 @@ load_secondlife_beta() { SetTitleMatchMode, 2 run, Second_Life_2-1-0-207030_Setup.exe winwait, Installer Language - send {Enter} + send {Enter} winwait, Installation Folder - send {Enter} + send {Enter} winwait, Second Life, Start Second Life now - send {Tab}{Enter} + send {Tab}{Enter} " cd "$olddir" - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd $programfilesdir_x86_win\\SecondLifeViewer2 SecondLife.exe __EOF__ @@ -4775,12 +6996,39 @@ __EOF__ #---------------------------------------------------------------- +verblist_add segabass "Sega Bass Fishing 2 (SEGA/Activision, 2001) [requires disc]" + +load_segabass() { + # Can't make a .iso of this disc, so assume the disc is in drive d: + ahk_do " + SetTitleMatchMode, 2 + run d:setup.exe + winwait, SEGA Bass Fishing, License + send a + sleep 1000 + send {Enter} + winwait, SEGA Bass Fishing, Destination + send {Enter} + winwait, SEGA Bass Fishing, Ready + send {Enter} + winwait, SEGA Bass Fishing, Complete + send {Enter} + winwaitclose + " + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\SEGA\\Sega Bass Fishing" +BassFishing.exe +__EOF__ +} + +#---------------------------------------------------------------- + verblist_add sims3 "The Sims 3 (EA, 2009)" 8a82a067f3bb8f68d034a06954e9a16ea381958a.iso load_sims3() { - load_autohotkey - - if workaround_wine_bug 22350 + # Launcher needs .net. (But you don't need the launcher to play the game, so this may be overkill.) + if false && workaround_wine_bug 22350 then try sh "$WINETRICKS" -q dotnet20 fi @@ -4789,7 +7037,7 @@ load_sims3() { then try sh "$WINETRICKS" -q d3dx9_36 fi - + # Get user's key KEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/8a82a067f3bb8f68d034a06954e9a16ea381958a.txt | tr -d -` @@ -4840,7 +7088,8 @@ load_sims3() { # FIXME: apply next patch, too - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Electronic Arts\\The Sims 3\\Game\\Bin" TS3.EXE __EOF__ @@ -4851,8 +7100,6 @@ __EOF__ verblist_add singularity "Singularity (Activision, 2010)" cfbba29fa8db1b9f87a90ea2f54c63026757c13d.iso load_singularity() { - load_autohotkey - # Get user's key KEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/cfbba29fa8db1b9f87a90ea2f54c63026757c13d.txt | tr -d -` @@ -4915,7 +7162,8 @@ _EOF_ try_regedit "$WISOTOOL_TMP_WIN"\\dof.reg fi -cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Activision\Singularity(TM)\Binaries" Singularity.exe __EOF__ @@ -4927,15 +7175,13 @@ verblist_add splitsecond_demo "Split Second Demo (Black Rock Studios, 2010) [ load_splitsecond_demo() { - load_autohotkey - if test ! -f "$WISOTOOL_CACHE/$PACKAGE"/SplitSecond*.exe then mkdir -p "$WISOTOOL_CACHE/$PACKAGE" die "You must download the demo to $WISOTOOL_CACHE/$PACKAGE before running this script. See http://www.fileplanet.com/212404/210000/fileinfo/Split/Second-Demo" fi - if workaround_wine_bug 22774 + if workaround_wine_bug 22774 "wine-1.3.[0-9]*" then echo "On wine, install takes an extra 7 minutes at the end, please be patient." fi @@ -4966,14 +7212,15 @@ load_splitsecond_demo() winwait, Split, Game features ControlClick, Button2, Split, Game features winwait, Split, start copying - ControlClick, Button1, Split, start copying + ControlClick, Button1, Split, start copying winwait, Split, completed ControlClick, Button1, Split, completed ControlClick, Button4, Split, completed " cd "$olddir" - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Disney Interactive Studios\\Split Second Demo" SplitSecondDEMO.exe __EOF__ @@ -4986,9 +7233,7 @@ verblist_add splitsecond "Split Second (Black Rock Studios, 2010) [wine bug 2 load_splitsecond() { - load_autohotkey - - if workaround_wine_bug 22774 + if workaround_wine_bug 22774 "wine-1.3.[0-9]*" then echo "On wine, install takes an extra 7 minutes at the end, please be patient." fi @@ -5031,7 +7276,8 @@ load_splitsecond() " iso_umount - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Disney Interactive Studios\\Split Second" SplitSecond.exe __EOF__ @@ -5044,7 +7290,6 @@ verblist_add spore "Spore (EA, 2008)" d08d1985d3161661d4f0ded30a0d11e705f2fcc load_spore() { - load_autohotkey iso_mount "$WISOTOOL_CACHE"/$PACKAGE/d08d1985d3161661d4f0ded30a0d11e705f2fcc2.iso SPORE_KEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/d08d1985d3161661d4f0ded30a0d11e705f2fcc2.txt | tr -d -` ahk_do " @@ -5075,7 +7320,8 @@ load_spore() controlclick, Button4 " iso_umount - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Electronic Arts\\SPORE\\Sporebin" SporeApp.exe __EOF__ @@ -5087,10 +7333,11 @@ verblist_add ssdd2 "SpongeBob SquarePants Diner Dash 2 (Nickelodeon/Big Fish, load_ssdd2() { - load_autohotkey # Main page: http://arcade.nick.com/nick/gameinfo.jsp?s=SpongeBobDinerDash2 - download $PACKAGE http://nickdownloads.shockwave.com/InstallSpongeBobDinerDash2.exe 8407dae2c062ce62b38408eeac3a9f95be202b96 - + # old: 8407dae2c062ce62b38408eeac3a9f95be202b96 + # 27 Oct 2010: 440c4f2e9484ba150782cae8754ff8eaaad3b01e + download $PACKAGE http://nickdownloads.shockwave.com/InstallSpongeBobDinerDash2.exe 440c4f2e9484ba150782cae8754ff8eaaad3b01e + if workaround_wine_bug 23749 then sh "$WINETRICKS" -q ie6 @@ -5125,20 +7372,118 @@ load_ssdd2() sleep 5 killall winefile.exe -cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\Nick Arcade\\SpongeBob SquarePants Diner Dash 2" "SpongeBob SquarePants Diner Dash 2.exe" __EOF__ } - + +#---------------------------------------------------------------- + +verblist_add sonicdxb_demo "Sonic Adventure Deluxe Trial B (Sega, 2003) [download]" sadx_trial_b.exe + +load_sonicdxb_demo() { + # http://sega.jp/pc/sonicdx/ + # http://sega.jp/pc/sonicdx/trial.shtml + if ! test -f "$WISOTOOL_CACHE/$PACKAGE/sadx_trial_b.exe" + then + download $PACKAGE 'http://sega.jp/cgi-bin/link.cgi?url=sadx_trial_b' f76fc33d3cb1b062437e03ba4e0687be07d903ad + mv "$WISOTOOL_CACHE"/$PACKAGE/'link.cgi?url=sadx_trial_b' "$WISOTOOL_CACHE/$PACKAGE/sadx_trial_b.exe" + fi + + # Switch to Japanese locale so freedesktop.org menu item works + # (This works for Scott, at least) + OLDLANG=${LANG} + export LANG=ja_JP.utf8 + + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + run, sadx_trial_b.exe + WinWait ahk_class SONIC_DX_PC_LC_B + ControlClick, x450 y90 + WinWait ahk_class #32770 + ControlClick, Button3 + ControlClick, Button1 + WinWait ahk_class #32770 + ControlClick, Button1 + WinWait ahk_class #32770 + ControlClick, Button1 + WinWaitActive ahk_class SONIC_DX_PC_LC_G_B + ControlClick, x450 y130 + " + LANG=${OLDLANG} + +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Sega\\SONICADVENTUREDX_DEMO_B" +sonic.exe +__EOF__ + +} + +#---------------------------------------------------------------- + +verblist_add stalker_pripyat_bench "S.T.A.L.K.E.R Call of Pripyat benchmark (GSC Game World, 2009) [download]" stkcop-bench-setup.exe + +load_stalker_pripyat_bench() { + # FIXME: There's a much faster download at + # http://www.bigdownload.com/games/stalker-call-of-pripyat/pc/stalker-call-of-pripyat-benchmark + # Should we direct users to download from there manually? + download $PACKAGE http://files.gsc-game.com/st/bench/stkcop-bench-setup.exe 8691c3f289ecd0521bed60ffd46e65ad080206e0 + + cd "$WISOTOOL_CACHE/$PACKAGE" + + # FIXME: a bit fragile, if you're browsing the web while installing, it sometimes gets stuck. + ahk_do " + SetTitleMatchMode, 2 + run stkcop-bench-setup.exe + WinWait,Setup - Call Of Pripyat Benchmark,Pripyat + sleep 1000 + ControlClick TNewButton1 ; Next + WinWait,Setup - Call Of Pripyat Benchmark,License + sleep 1000 + ControlClick TNewRadioButton1 ; accept + sleep 1000 + ControlClick TNewButton2 ; Next + WinWait,Setup - Call Of Pripyat Benchmark,Destination + sleep 1000 + ControlClick TNewButton3 ; Next + WinWait,Setup - Call Of Pripyat Benchmark,shortcuts + sleep 1000 + ControlClick TNewButton4 ; Next + WinWait,Setup - Call Of Pripyat Benchmark,tasks + sleep 1000 + send {Enter} + WinWait,Setup - Call Of Pripyat Benchmark,ready + sleep 1000 + ControlClick, TNewButton4 ; Next (nah, who reads doc?) + WinWait,Setup - Call Of Pripyat Benchmark,finished + sleep 1000 + Send {Space} ; uncheck launch + sleep 1000 + ControlClick TNewButton4 ; Finish + " + + if workaround_wine_bug 24868 + then + sh "$WINETRICKS" d3dx9_31 d3dx9_42 + fi + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Call Of Pripyat Benchmark" +Benchmark.exe +__EOF__ +} + #---------------------------------------------------------------- verblist_add starcraft "Starcraft Battle Chest (Blizzard, 1998)" 8d6cc11bc76b8af22868a95e17e0282277e9c53c.iso 966bae1f2e2035e066139e78137e623c92838254.iso load_starcraft() { - warn "You must have already done 'wisotool load=YOURKEY' on the install disc, and 'wisotool load' on the other disc." - load_autohotkey + warn "You must have already done 'wisotool load=YOURKEY' on the install disc, and 'wisotool load' on the other disc." # Force clean-ish install test -d "$programfilesdir_unix/StarCraft" && rm -rf "$programfilesdir_unix/StarCraft" @@ -5176,27 +7521,29 @@ load_starcraft() { #---------------------------------------------------------------- -verblist_add starcraft2 "Starcraft II (Blizzard, 2010)" 044bf7a83b0fc7086a4f89b44ea44d74af320059.iso +verblist_add starcraft2 "Starcraft II (Blizzard, 2010)" Installer Tome 1.MPQE Installer UI 1.MPQ Installer UI 2.MPQE Installer.app Installer.exe # http://appdb.winehq.org/objectManager.php?sClass=version&iId=20882 load_starcraft2() { - load_autohotkey load_gecko + for x in "Installer Tome 1.MPQE" "Installer UI 1.MPQ" "Installer UI 2.MPQE" "Installer.app" "Installer.exe" + do + if ! test -f "$WISOTOOL_CACHE/$PACKAGE/$x" + then + mkdir -p "$WISOTOOL_CACHE/$PACKAGE" + die "Please download the installer files using the Blizzard downloader from https://us.battle.net/account/management/sc2/download.html?gameRegion=NA&lang=en-US&platform=win and put them in $WISOTOOL_CACHE/$PACKAGE" + fi + done + # Force clean-ish install test -d "$programfilesdir_unix/StarCraft II" && rm -rf "$programfilesdir_unix/StarCraft II" - iso_mount "$WISOTOOL_CACHE"/$PACKAGE/044bf7a83b0fc7086a4f89b44ea44d74af320059.iso - - if workaround_wine_bug 23824 - then - warn "The installer may not run, see http://bugs.winehq.org/show_bug.cgi?id=23824. No known workaround yet." - fi - + cd "$WISOTOOL_CACHE/$PACKAGE" ahk_do " SetTitleMatchMode, 2 - run ${ISO_MOUNT_LETTER}:Installer.exe + run, Installer.exe winwait, StarCraft II Installer ControlClick, x300 y200 winwait, End User License Agreement @@ -5216,7 +7563,8 @@ load_starcraft2() { winclose " -cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\StarCraft II" "StarCraft II.exe" __EOF__ @@ -5227,7 +7575,6 @@ verblist_add sto "Star Trek Online (Cryptic, 2010)" f891dab46d05d771e0 load_sto() { - load_autohotkey iso_mount "$WISOTOOL_CACHE"/$PACKAGE/f891dab46d05d771e0123a1e7ec969f3601064a6.iso # Note: http://www.startrekonline.com/download shows how to download the # client using bittorrent. If the iso is not present, we should try that path. @@ -5257,7 +7604,7 @@ load_sto() ControlClick, Button2 winwait, Star Trek, Launch ControlClick, Button2 - " + " iso_umount # FIXME: register using the key that came with the DVD? # FIXME: log in and download patch? @@ -5308,7 +7655,7 @@ load_stfu() { # Patch to 1.2 # FIXME: add a commandline option to disable patching in general - # URL from http://www.lucasfiles.com/index.php?s=&action=download&id=1537&agree=true + # URL from http://www.lucasfiles.com/index.php?s=&action=download&id=1537&agree=true # See also http://www.forceunleashed.net/news/force-unleashed-patch-1-2/ download stfu http://xfer.lfnetwork.com/lucasfiles.com/downloads/1537/SWTFU_PC_EF_1.2_Update.exe cfd8043c4b86f4dc0ff0acd4c108b11c4b76e716 cd "$WISOTOOL_CACHE/stfu" @@ -5321,13 +7668,15 @@ load_stfu() { send {Enter} " - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\StarCraft II Beta" "StarCraft II.exe" __EOF__ # Should start SWTFU Launcher.exe, but that doesn't run in Wine? - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Aspyr\Star Wars The Force Unleashed" SWTFU.exe __EOF__ @@ -5339,8 +7688,6 @@ verblist_add sf4bench "Street Fighter 4: Benchmark (CAPCOM, 2009) [download]" St load_sf4bench() { - load_autohotkey - if ! test -f "$WISOTOOL_CACHE/$PACKAGE/StreetFighterIV_Benchmark.exe" then download $PACKAGE http://gamedaily.newaol.com/pub/StreetFighterIV_Benchmark.exe f7754210308b3a0ff2bb3be3a62b22767519ca62 @@ -5349,7 +7696,7 @@ load_sf4bench() cd "$WISOTOOL_CACHE"/$PACKAGE ahk_do " - SetTitleMatchmode, 2 + SetTitleMatchmode, 2 run, StreetFighterIV_Benchmark.exe winwait, Choose controlclick, Button1 @@ -5412,27 +7759,28 @@ __EOF__ cd "$olddir" -cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\CAPCOM\\STREETFIGHTERIV_BENCHMARK" StreetFighterIV_Benchmark.exe __EOF__ } +#---------------------------------------------------------------- + verblist_add smbx "Super Mario Bros. X (Indie, 2009) [download]" smbx122.exe load_smbx() { - load_autohotkey - # Download URL embedded in http://www.supermariobrothers.org/downloads/smbx122.html download $PACKAGE http://www.tehgamez.com/a/smbx122.exe 269eb60d502e57fdfae9c3601ad9ee22801cb5d1 # This winetricks verb doesn't work on Windows yet, but that's ok-ish, Windows comes with vb6 runtime - sh "$WINETRICKS" -q vb6run + sh "$WINETRICKS" -q vb6run if workaround_wine_bug 23821 then # http://www.supermariobrothers.org/forums/viewtopic.php?f=8&t=6711 - # claims this works + # claims this works sh "$WINETRICKS" -q quartz fi @@ -5464,7 +7812,8 @@ load_smbx() { Send {Space} ; Don't run game Send {Enter} " - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +C: cd C:\\SMBX smbx.exe __EOF__ @@ -5472,52 +7821,199 @@ __EOF__ #---------------------------------------------------------------- +verblist_add timezattack_demo "Timez Attack Demo (BigBrainz, 2005) [download]" Win_TimezAttackFreeInstaller.exe + +load_timezattack_demo() { + download $PACKAGE http://s3.amazonaws.com/BigBrainz/Win_TimezAttackFreeInstaller.exe aa30905e064c1f28949b56a8ab5ffe1ffa86618c + + cd "$WISOTOOL_CACHE/$PACKAGE" + # autohotkey can't read any text from this one :-( + ahk_do " + settitlematchmode, 2 + run, Win_TimezAttackFreeInstaller.exe + winwait, Setup + send {Enter} + sleep 5000 + send {Tab}{Tab}{Space}{Tab}{Tab}{Tab}{Enter} + sleep 5000 + send {Enter} + sleep 5000 + send {Enter} + sleep 40000 ; fixme: wait for last file to be created + send {Enter} + sleep 5000 + ControlClick TkChild14 ; uncheck (start game). fixme: cannot uncheck + send {Enter} + sleep 2000 + " + # fixme: only works on linux + killall TimezAttack.exe + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +C: +cd C:\\TimezAttack +TimezAttack.app\\TimezAttack.exe +__EOF__ + + if workaround_wine_bug 24537 + then + sh "$WINETRICKS" -q corefonts + fi +} + +#---------------------------------------------------------------- + +verblist_add tlr_demo "The Last Remnant Demo (Square Enix, 2009) [download]" d96a2ebbd15c3d03286d1b8b5601e7038cab46b1.iso + +load_tlr_demo() { +# http://appdb.winehq.org/objectManager.php?sClass=version&iId=15997 +# http://news.bigdownload.com/2009/02/26/download-the-last-remnant-demo/ + + if ! test -f "$WISOTOOL_CACHE"/$PACKAGE/TheLastRemnant_PC_Demo.zip + then + download $PACKAGE http://gamedaily.newaol.com/pub/TheLastRemnant_PC_Demo.zip 86b093eec133393ef47bb1dcd268b38b12927899 + fi + + cd "$WISOTOOL_TMP" + try unzip "$WISOTOOL_CACHE/$PACKAGE/TheLastRemnant_PC_Demo.zip" + cd "The Last Remnant Trial Version" + + ahk_do " + settitlematchmode, 2 + run, setup.exe + winwait, The Last Remnant Trial Version, Please close all unnecessary running + sleep 1000 + controlclick, Button1, The Last Remnant Trial Version, Please close all unnecessary running + winwait, The Last Remnant Trial Version, Welcome to the InstallShield Wizard + sleep 1000 + controlclick, Button1, The Last Remnant Trial Version, Welcome to the InstallShield Wizard + winwait, The Last Remnant Trial Version, License Agreement + sleep 1000 + controlclick, Button5, The Last Remnant Trial Version, License Agreement + sleep 1000 + controlclick, Button2, The Last Remnant Trial Version, License Agreement + winwait, The Last Remnant Trial Version, Choose Destination Location + sleep 1000 + controlclick, Button1, The Last Remnant Trial Version, Choose Destination Location + winwait, The Last Remnant Trial Version, The wizard is ready to begin installation. + sleep 1000 + controlclick, Button1, The Last Remnant Trial Version, The wizard is ready to begin installation. + winwait, The Last Remnant Trial Version, InstallShield Wizard Complete + sleep 1000 + controlclick, Button4, The Last Remnant Trial Version, InstallShield Wizard Complete + " + + # FIXME: When running, the window has the wrong size. Wine or app bug? +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\SquareEnix\\The Last Remnant Trial Version\\Binaries" +TLRDemo.exe +__EOF__ + + warn "The mouse seems broken, see bug 6971 for possible workarounds (mwo={force,disabled,enabled} didn't work for me)." +} + +#---------------------------------------------------------------- + +verblist_add tmnationsforever "TrackMania Nations Forever (Nadeo, 2009) [download]" tmnationsforever_setup.exe + +load_tmnationsforever() { + if workaround_wine_bug 20915 + then + warn "Gameplay and sound may be very choppy on some machines :-(" + fi + + download $PACKAGE "http://files.trackmaniaforever.com/tmnationsforever_setup.exe" cab0cf66db0471bc2674a3b1aebc35de0bca6ed0 + + cd "$WISOTOOL_CACHE/$PACKAGE" + + ahk_do " + SetTitleMatchMode, 2 + run tmnationsforever_setup.exe + WinWait,Select Setup Language,language + Sleep 1000 + ControlClick TNewButton1 ; OK + WinWait,Setup - TmNationsForever,Welcome + Sleep 1000 + ControlClick TNewButton1 ; Next + WinWait,Setup - TmNationsForever,License + Sleep 1000 + ControlClick TNewRadioButton1 ; Accept + Sleep 1000 + ControlClick TNewButton2 ; Next + WinWait,Setup - TmNationsForever,Where + Sleep 1000 + ControlClick TNewButton3 ; Next + WinWait,Setup - TmNationsForever,shortcuts + Sleep 1000 + ControlClick TNewButton4 ; Next + WinWait,Setup - TmNationsForever,perform + Sleep 1000 + ControlClick TNewButton4 ; Next + WinWait,Setup - TmNationsForever,installing + Sleep 1000 + ControlClick TNewButton4 ; Install + WinWait,Setup - TmNationsForever,finished + Sleep 1000 + ControlFocus, TNewCheckListBox1, TmNationsForever, finished + Sleep 1000 + Send {Space} ; don't start game + ControlClick TNewButton4 ; Finish + " + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\TmNationsForever" +TmForever.exe +__EOF__ +} + +#---------------------------------------------------------------- + verblist_add twfc "Transformers: War for Cybertron (Activision, 2010)" d96a2ebbd15c3d03286d1b8b5601e7038cab46b1.iso load_twfc() { - load_autohotkey - iso_mount "$WISOTOOL_CACHE"/$PACKAGE/d96a2ebbd15c3d03286d1b8b5601e7038cab46b1.iso - + KEY=`cat "$WISOTOOL_CACHE"/$PACKAGE/d96a2ebbd15c3d03286d1b8b5601e7038cab46b1.txt | tr -d -` - + ahk_do " - run ${ISO_MOUNT_LETTER}:setup.exe - SetTitleMatchMode, 2 - winwait, Activision, Select the language for the installation - sleep 1000 - controlclick, Button1, Activision, Select the language for the installation - winwait, Transformers, Press NEXT to verify your key - sleep 1000 - send $KEY - send {Enter} - winwait, Keycode Check, The Keycode you entered appears to be valid - sleep 1000 - send {Enter} - winwait, Transformers, The InstallShield Wizard will install Transformers - sleep 1000 - controlclick, Button1, Transformers, The InstallShield Wizard will install Transformers - winwait, Transformers, License Agreement - sleep 1000 - controlclick, Button5, Transformers, License Agreement - sleep 1000 - controlclick, Button2, Transformers, License Agreement - winwait, Transformers, Minimum System Requirements - sleep 1000 - controlclick, Button1, Transformers, Minimum System Requirements - winwait, Transformers, Select the setup type to install - sleep 1000 - controlclick, Button4, Transformers, Select the setup type to install - - ; Installer exits silently. Prevent an early umount: - sleep 5000 - Loop - { - ifwinexist, Transformers - sleep 15000 - else - break - } + run ${ISO_MOUNT_LETTER}:setup.exe + SetTitleMatchMode, 2 + winwait, Activision, Select the language for the installation + sleep 1000 + controlclick, Button1, Activision, Select the language for the installation + winwait, Transformers, Press NEXT to verify your key + sleep 1000 + send $KEY + send {Enter} + winwait, Keycode Check, The Keycode you entered appears to be valid + sleep 1000 + send {Enter} + winwait, Transformers, The InstallShield Wizard will install Transformers + sleep 1000 + controlclick, Button1, Transformers, The InstallShield Wizard will install Transformers + winwait, Transformers, License Agreement + sleep 1000 + controlclick, Button5, Transformers, License Agreement + sleep 1000 + controlclick, Button2, Transformers, License Agreement + winwait, Transformers, Minimum System Requirements + sleep 1000 + controlclick, Button1, Transformers, Minimum System Requirements + winwait, Transformers, Select the setup type to install + sleep 1000 + controlclick, Button4, Transformers, Select the setup type to install + + ; Installer exits silently. Prevent an early umount: + sleep 5000 + Loop + { + ifwinexist, Transformers + sleep 15000 + else + break + } " iso_umount @@ -5525,8 +8021,9 @@ load_twfc() { then sh "$WINETRICKS" mwo=force fi - -cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Activision\Transformers - War for Cybertron\Binaries" TWFC.exe __EOF__ @@ -5535,11 +8032,102 @@ __EOF__ #---------------------------------------------------------------- +verblist_add tropico3_demo "Tropico 3 Demo (Kalypso Media GmbH, 2009) [download]" Tropico3Demo.exe + +load_tropico3_demo() { + if ! test -f "$WISOTOOL_CACHE/$PACKAGE"/Tropico3Demo.exe + then + mkdir -p "$WISOTOOL_CACHE/$PACKAGE" + die "Please visit http://www.fileshack.com/file_download.x/15191 or http://www.tropico3.com/?p=downloads, download Tropico3Demo.exe, and place it in directory $WISOTOOL_CACHE/$PACKAGE" + fi + # FIXME: check sha1sum e031749db346ac3a87a675787c81eb1ca8cb5909 + + if workaround_wine_bug 24819 + then + sh "$WINETRICKS" gameux=disabled + $WINESERVER -w + fi + + cd "$WISOTOOL_CACHE/$PACKAGE" + + ahk_do " + SetTitleMatchMode, 2 + run Tropico3Demo.exe + WinWait,Installer Language,select + sleep 1000 + ControlClick Button1 ; OK + WinWait,Tropico,Welcome + sleep 1000 + ControlClick Button2 ; Next + WinWait,Tropico,License + sleep 1000 + ControlClick Button2 ; Agree + WinWait,Tropico,Typical + sleep 1000 + ControlClick Button2 ; Next + WinWait,Tropico,Completing + sleep 1000 + ControlClick Button4 ; Uncheck Run Now + ControlClick Button2 ; Finish + " + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Kalypso\\Tropico 3 Demo" +Tropico3 Demo.exe +__EOF__ + + if workaround_wine_bug 16328 + then + # 20540 is a dup of 16328, but it describes the problem nicely + warn "seawater is invisible due to wine bug 20540, work around this by applying the patch from http://bugs.winehq.org/show_bug.cgi?id=16328#c180" + fi + + if workaround_wine_bug 24845 + then + sh "$WINETRICKS" mmdevapi=disabled + fi +} + +#---------------------------------------------------------------- + +verblist_add typingofthedead_demo "Typing of the Dead Demo (Sega, 1999) [download]" Tod_e_demo.exe + +load_typingofthedead_demo() { + download $PACKAGE "http://downloads.pcworld.com/pub/new/fun_and_games/other/tod-demo.zip" 96fe3edb2431210932af840e29c59bce6b7fc80f + + cd "$WISOTOOL_CACHE/$PACKAGE" + mkdir "$WISOTOOL_TMP/tod-demo" + cp tod-demo.zip "$WISOTOOL_TMP/tod-demo" + cd "$WISOTOOL_TMP/tod-demo" + unzip tod-demo.zip + rm tod-demo.zip + + ahk_do " + SetTitleMatchMode, 2 + run SETUP.EXE + WinWait,InstallShield Wizard,where + sleep 1000 + ControlClick Button1 ; Next + WinWait,InstallShield Wizard,icons + sleep 1000 + ControlClick Button2 ; Next + ; installer crashes here? + Sleep 20000 + " + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\SEGA\\TOD-Demo" +Tod_e_demo.exe +__EOF__ +} + +#---------------------------------------------------------------- + verblist_add unigine_heaven "Unigen Heaven 2 Benchmark (Unigen, 2010) [download]" Unigine_Heaven-2.0.msi load_unigine_heaven() { - load_autohotkey - if ! test -f "$WISOTOOL_CACHE/$PACKAGE/Unigine_Heaven-2.0.msi" then warn "This download is slow, you may want to do a manual download from http://downloads.guru3d.com/Unigine-Heaven-DirectX-11-benchmark-2.0-download-2414.html instead" @@ -5550,7 +8138,7 @@ load_unigine_heaven() { cd "$WISOTOOL_CACHE/$PACKAGE" ahk_do " run msiexec /i Unigine_Heaven-2.0.msi - WinWait ahk_class MsiDialogCloseClass + WinWait ahk_class MsiDialogCloseClass Sleep 1000 Send {Enter} WinWait ahk_class MsiDialogCloseClass, License @@ -5583,7 +8171,8 @@ load_unigine_heaven() { # Should start Heaven.exe, but that doesn't run in Wine # Should give option to run Heaven_gl.bat (even works in Wine) # or the dx10 or dx11 versions (doesn't). - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Unigine\Heaven" cmd /c Heaven_d3d9.bat __EOF__ @@ -5591,19 +8180,297 @@ __EOF__ #---------------------------------------------------------------- +verblist_add vegas "Rainbow Six: Vegas (Ubisoft, 2006) [broken-wine-drm]" \ + be7cf72572708e9776af73c9bec8ee07952385af.iso \ + abd625abe57c7a9ffe5083e69ddc9f2a978c9e84.iso + +load_vegas() { + if workaround_wine_bug 7065 + then + warn "This game's DRM is not supported by wine" + fi + + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/be7cf72572708e9776af73c9bec8ee07952385af.iso + + ahk_do " + SetTitleMatchMode, 2 + Run, ${ISO_MOUNT_LETTER}:setup.exe + WinWait, Choose Setup Language + WinActivate + ControlClick Button1 ; OK + WinWait, , Welcome + WinActivate + ControlClick Button1 ; next + WinWait, , License Agreement + WinActivate + ControlClick Button3 ; accept eula + ControlClick Button1 ; next + WinWait, , Choose Destination Location + WinActivate + ControlClick Button4 ; next + WinWait, , Ready to Install + WinActivate + ControlClick Button1 ; install + WinWait, Setup Needs The Next Disk + WinActivate + " + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/abd625abe57c7a9ffe5083e69ddc9f2a978c9e84.iso + + ahk_do " + SetTitleMatchMode, 2 + Send {Enter} + WinWait, Microsoft DirectX Setup + WinActivate + ControlClick Button2 ; no + WinWait, , It is STRONGLY recommended that you install the latest DirectX runtimes + WinActivate + ControlClick Button1 ; ok + WinWait, Microsoft DirectX Setup + WinActivate + ControlClick Button2 ; No + WinWait, , Installation Completed + ControlClick Button1 ; untick desktop icon + ControlClick Button2 ; untick registration + ControlClick Button4 ; finish + WinWait, Detection + WinActivate + ControlClick Button1 ; quit + Sleep 1000 ; does not detect system properly, wait for warning popup and quit + Send {Enter} ; quit + " + iso_umount + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cd "$programfilesdir_x86_win\\Ubisoft\\Tom Clancy's Rainbow Six Vegas\\Binaries" +R6Vegas_Launcher.exe +__EOF__ +} + + +#---------------------------------------------------------------- + +verblist_add vegas2 "Rainbow Six: Vegas 2 (Ubisoft, 2008) [broken-wine-drm]" \ + e720e914eeb98dbd2ec140d15d32ce6317e24f86.iso \ + 1430fdaa49165d1bed439ddffa65e9fa2af4d498.iso + +load_vegas2() { + if workaround_wine_bug 219 + then + warn "This game's DRM is not supported by wine" + fi + + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/e720e914eeb98dbd2ec140d15d32ce6317e24f86.iso + + ahk_do " + SetTitleMatchMode, 2 + Run, ${ISO_MOUNT_LETTER}:setup.exe + WinWait, Tom Clancy + WinActivate + ControlClick Button3 ; next + WinWait, , Welcome + WinActivate + ControlClick Button1 ; next + WinWait, , License Agreement + WinActivate + ControlClick Button5 ; accept eula + ControlClick Button2 ; next + WinWait, , Ready to Install + WinActivate + ControlClick Button1 ; install + WinWait, Setup Needs The Next Disk + WinActivate + " + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/1430fdaa49165d1bed439ddffa65e9fa2af4d498.iso + + ahk_do " + SetTitleMatchMode, 2 + Send {Enter} + WinWait, Detection + WinActivate + ControlClick Button1 ; close + WinWait, Setup Needs The Next Disk + WinActivate + " + + iso_mount "$WISOTOOL_CACHE"/$PACKAGE/e720e914eeb98dbd2ec140d15d32ce6317e24f86.iso + ahk_do " + SetTitleMatchMode, 2 + Send {Enter} + WinWait, , Installation Completed + WinActivate + ControlClick Button4 ; finish + " + iso_umount + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +cd "$programfilesdir_x86_win\\Ubisoft\\Tom Clancy's Rainbow Six Vegas 2\\Binaries" +R6Vegas2_Launcher.exe +__EOF__ +} + +#---------------------------------------------------------------- + +verblist_add victoria2_demo "Victoria 2 Demo (Paradox Interactive, 2010) [download]" + +load_victoria2_demo() { + # download zip file via torrent from http://www.gamershell.com/download_62070.shtml + if ! test -f "$WISOTOOL_CACHE/$PACKAGE/Victoria2_Demo.zip" + then + mkdir -p "$WISOTOOL_CACHE/$PACKAGE" + die "Download Victoria2_Demo.zip from http://www.gamershell.com/download_62070.shtml and place in $WISOTOOL_CACHE/$PACKAGE" + fi + # FIXME: check sha1sum 20bac88a3ace1010e4fb116d72baf95e92976b39 + # or better, check sha1sum of extracted .exe, since different + # sources add their own readme in the .zip file + mkdir -p "$WISOTOOL_TMP"/$PACKAGE/ + cd "$WISOTOOL_TMP"/$PACKAGE/ + try unzip "$WISOTOOL_CACHE/$PACKAGE"/Victoria2_Demo.zip + + # Clean up old temp files from installer extractor (it leaves them around) + rm -rf temp_files_for_v2 + + # Run installer -- the ifwinactive statements are due to things that may not appear in Win7 + ahk_do " + SetTitleMatchMode, 2 + run, Victoria2_Demo.exe + winwait, WinRAR + ControlClick, Button2, WinRAR + winwait, InstallShield, Welcome to the + sleep 1000 + ControlClick, Button1, InstallShield, Welcome to the + winwait, InstallShield, License Agreement + sleep 1000 + ControlClick, Button2, InstallShield, License Agreement + winwait, InstallShield, Setup will install + sleep 1000 + ControlClick, Button1, InstallShield, Setup will install + winwait, InstallShield, Setup will add program icons + sleep 1000 + ControlClick, Button2, InstallShield, Setup will add program icons + WinWait, InstallShield, Setup is performing + WinWaitClose, InstallShield, Setup is performing + loop + { + ifwinexist, Microsoft Visual C++, Please read the following license + { + winactivate, Microsoft Visual C++, Please read the following license + sleep 1000 + ControlClick, Button1, Microsoft Visual C++, Please read the following license + WinWaitClose, Microsoft Visual C++ + WinWaitClose, Microsoft Visual C++ + WinWaitClose, Microsoft Visual C++ + } + ifwinexist, DirectX, Welcome to setup for DirectX + { + sleep 1000 + ControlClick, Button6, DirectX, Welcome to setup for DirectX + WinWaitClose, DirectX, Welcome to setup for DirectX + } + ifwinexist, InstallShield, InstallShield Wizard Complete + { + sleep 1000 + break + } + sleep 100 + } + ControlClick, Button1, InstallShield, InstallShield Wizard Complete + ControlClick, Button2, InstallShield, InstallShield Wizard Complete + ControlClick, Button4, InstallShield, InstallShield Wizard Complete + winwaitclose, InstallShield, InstallShield Wizard Complete + " + if workaround_wine_bug 24422 + then + sh "$WINETRICKS" -q d3dx9_36 + fi + if workaround_wine_bug 24217 + then + sh "$WINETRICKS" -q dsoundbug9612 + fi + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Paradox Interactive\\Victoria 2 - DEMO" +v2demo.exe +__EOF__ +} + +#---------------------------------------------------------------- + +verblist_add vf2_demo "Virtua Fighter 2 demo (Sega, 1997) [download]" vf2_demo.exe + +load_vf2_demo() +{ + if ! test -f "$WISOTOOL_CACHE/$PACKAGE/vf2_demo.exe" + then + download $PACKAGE http://www.sega.com/support/pcdownloads/vf2_demo/vf2_demo.exe efd34dd079cdfd7b2ccc195b584d7ca10ec7e82b + fi + + mkdir -p "$WISOTOOL_TMP/$PACKAGE" + cd "$WISOTOOL_CACHE/$PACKAGE" + try unzip vf2_demo.exe -d "$WISOTOOL_TMP/$PACKAGE" + cd "$WISOTOOL_TMP/$PACKAGE" + + # installer refuses to run in Windows NT 5 or higher, so set win98 mode + # FIXME: undo this when verb is done + case "$OS" in + "Windows_NT") + export __COMPAT_LAYER=Win95 + ;; + *) + sh $WINETRICKS win98 + ;; + esac + + chmod +x SETUP.EXE + ahk_do " + SetTitleMatchMode, 2 + run, setup.exe + winwait, Welcome, Virtua + send {Enter} + winwait, Get Destination Path + send {Enter} ; accept default path + winwait, Setup + send {Enter} ; yes, create or replace + winwaitclose ; wait for error message window to go away + winwaitclose, Get Destination Path + winwait, Setup, Play + send E ; Don't play + winwaitclose + " + + cd "$olddir" + + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +C: +cd C:\\SEGA\\VF2DEMO +rem FIXME: __COMPAT_LAYER seems to be needed for XP, but breaks vista +set __COMPAT_LAYER=Win95 +VF2DEMO.exe +__EOF__ + + case "$OS" in + "Windows_NT") + warn "$PACKAGE requires an 8 or 16 bit display, so change desktop settings before running. Also, on Windows XP, you'll need to set C:\\SEGA\\VF2DEMO\VF2DEMO.exe to Win95 mode." + ;; + *) + warn "$PACKAGE requires an 8 or 16 bit display. On Linux, try pressing CTRL+ALT+F1, and running 'startx -- :1 -depth 16'. " + ;; + esac +} + +#---------------------------------------------------------------- + verblist_add wog "World of Goo demo (2D Boy, 2008) [download]" WorldOfGooDemo.1.0.exe load_wog() { - load_autohotkey - if ! test -f "$WISOTOOL_CACHE/wog/WorldOfGooDemo.1.0.exe" then # Get temporary download location download wog "http://www.worldofgoo.com/dl2.php?lk=demo&filename=WorldOfGooDemo.1.0.exe" - URL=`cat "$WISOTOOL_CACHE/wog/dl2.php?lk=demo&filename=WorldOfGooDemo.1.0.exe" | + URL=`cat "$WISOTOOL_CACHE/wog/dl2.php?lk=demo&filename=WorldOfGooDemo.1.0.exe" | grep WorldOfGooDemo.1.0.exe | sed 's,.*http,http,;s,".*,,'` rm "$WISOTOOL_CACHE/wog/dl2.php?lk=demo&filename=WorldOfGooDemo.1.0.exe" - + download wog "$URL" e61d8253b9fe0663cb3c69018bb3d2ec6152d488 fi @@ -5621,7 +8488,8 @@ load_wog() { ControlClick, Make me dirty right now, World of Goo Setup, Thank you send {Enter} " - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\WorldOfGooDemo" WorldOfGoo.exe __EOF__ @@ -5632,8 +8500,6 @@ __EOF__ verblist_add wowtrial "World of Warcraft trial(Blizzard, 2009)" TryWoW.exe load_wowtrial() { - load_autohotkey - download $PACKAGE https://www.worldofwarcraft.com/downloads/files/pc/enUS/TryWoW.exe 832866b591ea20fa2e5d30c36dcca92aec9ea36a ahk_do " @@ -5663,7 +8529,6 @@ verblist_add wowbc "World of Warcraft: Battle Chest (Blizzard, 2008)" \ c874f5bc676eef8e60d3d232fe6db185c4632fb3.iso load_wowbc() { - load_autohotkey test -f "$WINDIR"/utorrent.exe || try sh $WINETRICKS utorrent case "$LANG" in @@ -5678,8 +8543,8 @@ load_wowbc() { download $PACKAGE "http://a.wirebrain.de/wow/torrent/WoW-3.3.0.10958-3.3.0.11159-x86-Win-enUS.torrent" b7ad37a75713f6d8e578558ca1e321927192c6c6 download $PACKAGE "http://a.wirebrain.de/wow/torrent/WoW-3.3.0.11159-to-3.3.2.11403-enUS-patch.torrent" f73763541197fecdcca9b9f8cf91e83cde989a49 download $PACKAGE "http://uk1.files.alexsmith.im/enUS/WoW-3.3.2.11403-to-3.3.3.11685-enUS-patch.exe" ce73a0a8aa9f6eaf00b5e7cd0a34eb928738fd36 - download $PACKAGE "http://uk1.files.alexsmith.im/enUS/WoW-3.3.3.11685-to-3.3.3.11723-enUS-patch.exe" - download $PACKAGE "http://uk1.files.alexsmith.im/enUS/WoW-3.3.3.11723-to-3.3.5.12213-enUS-patch.exe" + download $PACKAGE "http://uk1.files.alexsmith.im/enUS/WoW-3.3.3.11685-to-3.3.3.11723-enUS-patch.exe" + download $PACKAGE "http://uk1.files.alexsmith.im/enUS/WoW-3.3.3.11723-to-3.3.5.12213-enUS-patch.exe" cd "$WISOTOOL_CACHE/$PACKAGE" patch1=`stat -Lc%s WoW-3.2.0-enUS-patch.exe` @@ -5690,7 +8555,7 @@ load_wowbc() { patch6=`stat -Lc%s WoW-3.3.3.11685-to-3.3.3.11723-enUS-patch.exe` patch7=`stat -Lc%s WoW-3.3.3.11723-to-3.3.5.12213-enUS-patch.exe` - if [ $patch5 -ne 128600432 ] || [ $patch6 -ne 4959280 ] || [ $patch7 -ne 24886168 ] + if [ $patch5 -ne 128600432 ] || [ $patch6 -ne 4959280 ] || [ $patch7 -ne 24886168 ] then die "Failed to download patch 3.3.3.11685, or patch 3.3.3.11723, or patch 3.3.5.12213" fi @@ -5704,7 +8569,7 @@ load_wowbc() { do try $WINE utorrent "/DIRECTORY" "$UT_WINPATH" "$UT_WINPATH\\$torrent" & done - + # Start uTorrent, have it wait until all downloads are finished ahk_do " SetTitleMatchMode, 2 @@ -5757,7 +8622,7 @@ load_wowbc() { send {Enter} winwait, Manage ControlClick, Button2 - Loop + Loop { ; World Of Warcraft directory is created as .temp, then renamed when done ifExist, C:\Program Files\World of Warcraft\Logs\Burning Crusade Install Log.html @@ -5778,14 +8643,14 @@ load_wowbc() { WoW-3.3.2.11403-to-3.3.3.11685-enUS-patch.exe\ WoW-3.3.3.11685-to-3.3.3.11723-enUS-patch.exe\ WoW-3.3.3.11723-to-3.3.5.12213-enUS-patch.exe - + do ahk_do " run "$WISOTOOL_CACHE"/$PACKAGE/$file SetTitleMatchMode, 2 winwait, Blizzard Updater - IfWinExist, Blizzard Updater, unable to start ;Exit if patch is already applied + IfWinExist, Blizzard Updater, unable to start ;Exit if patch is already applied { ControlClick, Button1, Blizzard Updater, unable to start exit @@ -5814,7 +8679,8 @@ load_wowbc() { echo "Patched $file" sleep 5 done - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\\World of Warcraft" Wow.exe __EOF__ @@ -5822,502 +8688,107 @@ __EOF__ #---------------------------------------------------------------- -# Generic GOG.com installer -# Usage: game_id game_title [other_files,size [reader_control [run_command [download_id [install_dir [installer_size_and_sha1]]]]]] -# game_id -# Used for main installer name and download url. -# game_title -# Used for AutoHotKey and installation path in bat script. -# other_files -# Extra installer files, in one string, space-separated. -# reader_control -# If set, the control id of the configuration pannel checkbox controling -# Adobe Reader installation. -# Some games don't have it, some games do with different ids. -# run_command -# Used for bat script, relative to installation path. -# download_id -# For games which download url doesn't match their game_id -# install_dir -# If different from game_title -# installer_size_and_sha1 -# exe file SHA1. -_load_gog() -{ - load_autohotkey +verblist_add zootycoon2_demo "Zoo Tycoon 2 demo (Microsoft, 2004) [download]" Zoo2Trial.exe - game_id="$1" - game_title="$2" - other_files="$3" - reader_control="$4" - run_command="$5" - download_id="$6" - install_dir="$7" - installer_size_and_sha1="$8" +load_zootycoon2_demo() { + download $PACKAGE "http://download.microsoft.com/download/9/f/6/9f6a95f0-f34a-4312-9749-77b81d3de245/Zoo2Trial.exe" 60ad1bb34351f97b579c58234b926055f7979126 - if [ "$download_id"x = ""x ] - then - download_id="$game_id" - fi - if [ "$install_dir"x = ""x ] - then - install_dir="$game_title" - fi - - installer_path="$WISOTOOL_CACHE/$PACKAGE" - mkdir -p "$installer_path" - auth_path="$WISOTOOL_CACHE/gog_auth" - mkdir -p "$auth_path" - installer="setup_$game_id.exe" - cookie="$auth_path/cookie.txt" - - if test "$installer_size_and_sha1"x == ""x - then - files="$installer $other_files" - else - files="$installer,$installer_size_and_sha1 $other_files" - fi - - file_id=0 - for file_and_size_and_sha1 in $files - do - case "$file_and_size_and_sha1" in - *,*,*) - sha1sum=`echo $file_and_size_and_sha1 | sed "s/.*,//"` - minsize=`echo $file_and_size_and_sha1 | sed 's/[^,]*,\([^,]*\),.*/\1/'` - file=`echo $file_and_size_and_sha1 | sed 's/,.*//'` - ;; - *,*) - sha1sum="" - minsize=`echo $file_and_size_and_sha1 | sed 's/.*,//'` - file=`echo $file_and_size_and_sha1 | sed 's/,.*//'` - ;; - *) - sha1sum="" - minsize=1 - file=$file_and_size_and_sha1 - ;; - esac - file_path="$installer_path/$file" - if ! test -s "$file_path" || test `stat -Lc%s "$file_path"` -lt $minsize - then - if ! grep "GOGcom_usr" "$cookie" > /dev/null 2>&1 - then - login_file="$auth_path/login.txt" - password_file="$auth_path/password.txt" - if ! test -f "$login_file" -a -f "$password_file" - then - die "Please put your GOG.com login in '$login_file' and password in '$password_file' or put '$file' in '$installer_path'." - fi - if ! grep "@" "$login_file" > /dev/null 2>&1 - then - die "$login_file must contain your GOG.com login, which is an e-mail address (as opposed to account name)." - fi - base_url="https://www.gog.com" - login_url="/en/login/ajax/" - next_url="$WISOTOOL_TMP/gog_redir_url" - post_data="$WISOTOOL_TMP/gog_post_data" - login="`url_encode < \"$login_file\"`" - status=$? - if test $status -ne 0 - then - die "Note: login escaping failed with status $status. Aborting" - fi - password="`url_encode < \"$password_file\"`" - status=$? - if test $status -ne 0 - then - die "Note: password escaping failed with status $status. Aborting" - fi - # Note: just write login & password to a file so they don't appear in "ps" - echo "a=check&t=old&u=$login&p=$password&r=frontpage" > "$post_data" - if test -x "`which wget 2>/dev/null`" - then - try wget -O "$next_url" --save-cookies "$cookie" --post-file "$post_data" "$base_url$login_url" - try wget -O /dev/null --load-cookies "$cookie" --save-cookies "$cookie" "$base_url`cat \"$next_url\"`" - else - try curl -o "$next_url" --cookie-jar "$cookie" --data "@$post_data" "$base_url$login_url" - try curl -o /dev/null --cookie "$cookie" --cookie-jar "$cookie" "$base_url`cat \"$next_url\"`" - fi - rm -f "$post_data" - rm -f "$next_url" - fi - nosizecheck=1 - download "$PACKAGE" "https://www.gog.com/en/download/game/$download_id/$file_id" "" "$file" "$cookie" - unset nosizecheck - check_sha1=1 - filesize=`stat -Lc%s "$file_path"` - if test $minsize -gt 1 -a $filesize -ne $minsize - then - check_sha1="" - warn "Expected file size $minsize, please report new size $filesize." - fi - if test "$check_sha1" != "" -a "$sha1sum"x != ""x - then - verify_sha1sum "$sha1sum" "$file_path" - fi - fi - file_id=`expr $file_id + 1` - done - - cd "$installer_path" + cd "$WISOTOOL_CACHE/$PACKAGE" ahk_do " - run $installer - WinWait, Setup - $game_title, Start installation - ControlGet, checkbox_state, Checked,, TCheckBox1 ; EULA - if (checkbox_state != 1) { - ControlClick, TCheckBox1 - } - if (\"$reader_control\") { - ControlClick, TMCoPShadowButton1 ; Options - Loop, 10 - { - ControlGet, visible, Visible,, $reader_control - if (visible) - { - break - } - Sleep, 1000 - } - ControlGet, checkbox_state, Checked,, $reader_control ; Unckeck Adobe/Foxit Reader - if (checkbox_state != 0) { - ControlClick, $reader_control - } - } - ControlClick, TMCoPShadowButton2 ; Start Installation - WinWait, Setup - $game_title, Exit Installer - ControlClick, TMCoPShadowButton1 ; Exit Installer + ; Uses winwaitactive, because the windows appear and immediately after another window + ; gets in the way, then disappears after a second or so + SetTitleMatchMode, 2 + run Zoo2Trial.exe + winwaitclose, APPMESSAGE + winwaitactive, Zoo Tycoon 2 Trial, AUTORUN + sleep 1000 + controlclick, CButtonClassName1, Zoo Tycoon 2 Trial, AUTORUN + winwaitclose, APPMESSAGE + winwaitactive, Zoo Tycoon 2 Trial, INSTALLTYPE + ; 1 second was not enough. + sleep 3000 + controlclick, CButtonClassName1, Zoo Tycoon 2 Trial, INSTALLTYPE + winwaitactive, Zoo Tycoon 2 Trial, COMPLETE + winclose, Zoo Tycoon 2 Trial, COMPLETE " - - if [ "$run_command"x != ""x ] - then - cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ -cd "$programfilesdir_x86_win\\GOG.com\\$install_dir" -$run_command + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\Microsoft Games\\Zoo Tycoon 2 Trial Version" +zt2demoretail.exe __EOF__ +} + +#---------------------------------------------------------------- + +# Generic Positech installer +_load_positech() +{ + dl_path="$1" + hash_sum="$2" + installer_name="$3" + window_title="$4" + installed_dir="$5" + installed_exe="$6" + download $PACKAGE $dl_path $hash_sum + cd "$WISOTOOL_CACHE/$PACKAGE" + ahk_do " + run, $installer_name + WinWait, $window_title + WinActivate + ControlClick TNewButton1 ; Next + WinWait, $window_title,Select Destination + WinActivate + ControlClick TNewButton3 ; Next + WinWait, $window_title,Select Start + WinActivate + ControlClick TNewButton4 ; Next + WinWait, $window_title,Ready to Install + WinActivate + ControlClick TNewButton4 ; Install + WinWait, $window_title,Completing + WinActivate + Send {Space} ; Untick launch + ControlClick TNewButton4 ; Finish + " + cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: +cd "$programfilesdir_x86_win\\$installed_dir" +$installed_exe +__EOF__ +} + +verblist_add gsb_demo "Gratuitous Space Battles demo (Positech Games, 2009) [download]" GSBDemoInstaller.exe + +load_gsb_demo() { + _load_positech "http://www.positech.co.uk/gratuitousspacebattles/downloads/GSBDemoInstaller.exe" 83dab80aa3bb94aa886c94b2cb68fa54558fe563 "GSBDemoInstaller.exe" "Setup - Gratuitous Space Battles Demo" "Gratuitous Space Battles Demo" "GSBDemo.exe" + if workaround_wine_bug 22393 + then + sh "$WINETRICKS" -q d3dx9_36 + fi + if workaround_wine_bug 24395 + then + warn "If the game crashes with 'Error initializing output device. ..\src\GUI_Sounds.cpp 661', try disabling pulseaudio, and post a comment to bug 24395 saying whether it helped." fi } -verblist_add dukenukem3d_gog "Duke Nukem 3D (GOG.com)" setup_duke3d.exe +verblist_add democracy2_demo "Democracy2 demo (Positech Games, 2007) [download]" Democracy2Demo.exe -load_dukenukem3d_gog() -{ - _load_gog "duke3d" "Duke Nukem 3D" "" "TsCheckBox2" "DOSBOX\\dosbox.exe -conf dosboxDuke3D.conf -noconsole -c \"exit\"" "duke_nukem_3d_atomic_edition" "" "28863130,0b86cb60aa2549a46b1bf099a5b544d198ccebaa" +load_democracy2_demo() { + _load_positech "http://www.positech.co.uk/democracy2/Democracy2Demo.exe" 117cb63119adb3f79034ee3fcf641629dc825615 "Democracy2Demo.exe" "Setup - Democracy 2 Demo" "Democracy2 Demo" "Democracy2.exe" } -verblist_add dukenukemmp_gog "Duke Nukem Manhattan Project (GOG.com)" setup_duke_nukem_manhattan_project.exe +verblist_add kudos2_demo "Kudos 2 demo (Positech Games, 2008) [download]" Kudos2DemoInstaller.exe -load_dukenukemmp_gog() -{ - _load_gog "duke_nukem_manhattan_project" "Duke Nukem - Manhattan Project" "" "TsCheckBox2" "DukeNukemMP.exe" "" "" "212465575,ffabbc2e96c2c85c4fe8c519afdde2a5226e5ce6" +load_kudos2_demo() { + _load_positech "http://www.positech.co.uk/kudos2/Kudos2DemoInstaller.exe" 31abe5a4ce10eb111e0306c8c1b5570f2fd43f33 "Kudos2DemoInstaller.exe" "Setup - Kudos 2 Demo" "Kudos 2 Demo" "Kudos2Demo.exe" } -verblist_add ut2004_gog "Unreal Tournament 2004 (GOG.com)" setup_ut2004.exe setup_ut2004-1.bin setup_ut2004-2.bin +verblist_add rocklegend_demo "Rock Legend demo (Positech Games, 2007) [download]" RockLegendDemo.exe -load_ut2004_gog() -{ - _load_gog "ut2004" "Unreal Tournament 2004" "setup_ut2004-1.bin,2097510656,77a17856d77545e7930471a3fe3ce210a649edcd setup_ut2004-2.bin,3010009,f327498d0e1f6332d25c18629d277435a6c292da" "TsCheckBox2" "system\\ut2004.exe" "unreal_tournament_2004_ece" "" "2489303,67dfcf2ffa74123436d2cbc010e21d48860ea995" +load_rocklegend_demo() { + _load_positech "http://www.positech.co.uk/rocklegend/RockLegendDemo.exe" b9f090d2e6a9e7be860a52c339d599e3c7bfe516 "RockLegendDemo.exe" "Setup - Kudos Rock Legend Demo" "Kudos Rock Legend Demo" "KudosRockLegendDemo.exe" } -verblist_add abes_oddysee_gog "Abes Oddysee (GOG.com)" AbeWin.exe setup_abes_oddysee.exe - -load_abes_oddysee_gog() -{ - _load_gog "abes_oddysee" "Abe's Oddysee" "" "TsCheckBox2" "AbeWin.exe" "oddworld_abes_oddysee" "" "380905004,848b41ac4aaea0e13e5d609bcdc6fe4c9db2368f" -} - -verblist_add abes_exoddus_gog "Abes Exoddus (GOG.com)" Exoddus.exe setup_abes_exoddus.exe - -load_abes_exoddus_gog() -{ - _load_gog "abes_exoddus" "Abe's Exoddus" "" "TsCheckBox2" "Exoddus.exe" "oddworld_abes_exoddus" "" "625840158,a8f110038c387afa59b0277c2f68dd5e4c27478c" -} - -verblist_add beyond_good_and_evil_gog "Beyond Good and Evil (GOG.com)" setup_beyond_good_and_evil.exe - -load_beyond_good_and_evil_gog() -{ - _load_gog "beyond_good_and_evil" "Beyond Good and Evil" "" "TsCheckBox2" "gogwrap.exe GOGBEYONDGOODANDEVIL" "" "" "1544566386,cba7c1647c217cfa2db4f770bee35be88b2f08c6" -} - -verblist_add far_cry_gog "Far Cry (GOG.com)" setup_far_cry.exe setup_far_cry-1.bin setup_far_cry-2.bin - -load_far_cry_gog() -{ - _load_gog "far_cry" "Far Cry" "setup_far_cry-1.bin,2097392384,01819fd08cda4ba5ace4731858e79ef0f5fceca6 setup_far_cry-2.bin,437651497,3796bbd0cb626496fe7cfdd930061821e931fcb5" "TsCheckBox2" "Bin32\\FarCry.exe" "" "" "2607407,0ed9a8976868d2aac1b66a2e216c3d7acac1c3c9" -} - -verblist_add descent_1_2_gog "Descent and Descent 2 (GOG.com)" setup_descent_1_2.exe - -load_descent_1_2_gog() -{ - # XXX: this installs 2 games, how should bat script be ? - _load_gog "descent_1_2" "Descent and Descent 2" "" "TsCheckBox5" "" "descent_1_descent_2" "" "577588226,a8f64b537bb3c58aab5955ab92a3e9f6831024fe" -} - -verblist_add descent_3_gog "Descent 3 (GOG.com)" setup_descent_3.exe - -load_descent_3_gog() -{ - _load_gog "descent_3" "Descent 3 and Mercenary Expansion" "" "TsCheckBox4" "Descent 3.exe" "descent_3_expansion" "Descent 3" "837442501,41342901910aa3d973ef0778cbc9f0d43d5713e9" -} - -verblist_add evil_genius_gog "Evil Genius (GOG.com)" setup_evil_genius.exe - -load_evil_genius_gog() -{ - _load_gog "evil_genius" "Evil Genius" "" "TsCheckBox2" "ReleaseExe\\EvilGeniusExeStub-Release.exe" "" "" "1394559416,d0bc345e44cd202daa4243315fbb529c042174e0" -} - -verblist_add psychonauts_gog "Psychonauts (GOG.com)" setup_psychonauts.exe - -load_psychonauts_gog() -{ - _load_gog "psychonauts" "Psychonauts" "setup_psychonauts-1.bin,2097627392,ba141083b6ac3d82b6e9bf72332d8876c7566378 setup_psychonauts-2.bin,765732413,bef1f8b19c2700e7c81d9aa8a21358266eafe8c9" "TsCheckBox2" "Psychonauts.exe" "" "" "2372340,04f3d2bfb36bb4d7bf5f2800837e218f6a034f4b" -} - -verblist_add ut_goty_gog "Unreal Tournament GOTY (GOG.com)" setup_ut_goty.exe - -load_ut_goty_gog() -{ - # XXX: Installer window contains: "Unreal Tournament", 2 spaces, a long dash, 1 space "Game Of The Year Edition" - _load_gog "ut_goty" "Unreal Tournament " "" "TsCheckBox2" "gogwrap.exe GOGUT" "unreal_tournament_goty" "Unreal Tournament GOTY" "336712863,bd464862181f9a4386e3d10bee616277ecf7e060" -} - -verblist_add unreal_gold_gog "Unreal Gold Edition (GOG.com)" setup_unreal_gold.exe - -load_unreal_gold_gog() -{ - _load_gog "unreal_gold" "Unreal Gold" "" "TsCheckBox2" "gogwrap.exe GOGUNREAL" "" "" "251958142,189709657792ec89f534b52f31dbe3aba2c6040b" -} - -verblist_add unreal_2_se_gog "Unreal 2: The awakening Special Edition (GOG.com)" setup_unreal2_se.exe - -load_unreal_2_se_gog() -{ - # \x96 is ansi-1250 for "en dash" - _load_gog "unreal2_se" "Unreal 2 `echo -e '\x96'` The Awakening Special Edition" "" "TsCheckBox4" "gogwrap.exe GOGUNREAL2" "unreal_2_the_awakening_se" "" "1312187483,0a685f43eb4dcb28e5b8f7f46ff20f05c0082311" -} - -verblist_add battle_chess_gog "Battle Chess (GOG.com)" setup_battle_chess.exe - -load_battle_chess_gog() -{ - # XXX: this installs 3 games, how should bat script be ? - _load_gog "battle_chess" "Battle Chess Special Edition" "" "TsCheckBox5" "" "battle_chess_special_edition" "" "46082407,258e74d9a4a2d9d3bd0e261c2a5b229c2b475b9c" -} - -verblist_add earth_2150_trilogy_gog "Earth 2150 trilogy (GOG.com)" setup_earth_2150_trilogy.exe - -load_earth_2150_trilogy_gog() -{ - # XXX: this installs 3 games, how should bat script be ? - _load_gog "earth_2150_trilogy" "Earth 2150 Trilogy" "" "TsCheckBox4" "" "" "" "1678391114,898711e463f78182cc008713e0a5be81ead060f0" -} - -verblist_add earth_2160_gog "Earth 2160 (GOG.com)" setup_earth_2160.exe - -load_earth_2160_gog() -{ - _load_gog "earth_2160" "Earth 2160" "" "TsCheckBox2" "Earth2160_START.exe" "" "" "912927726,5b59076ff5293456ed5043e130bf95e406e1dd73" -} - -verblist_add empire_earth_gold_gog "Empire Earth Gold (GOG.com)" setup_empire_earth_gold.exe - -load_empire_earth_gold_gog() -{ - # XXX: this installs 2 games, how should bat script be ? - _load_gog "empire_earth_gold" "Empire Earth Gold Edition" "" "TsCheckBox4" "" "empire_earth_gold_edition" "" "564162686,4fdc33fb072923d36749230df52d28fba3fcefe7" -} - -verblist_add earthworm_jim_1_2_gog "Earthworm Jim 1 & 2 (GOG.com)" setup_ewj_1_2.exe - -load_earthworm_jim_1_2_gog() -{ - # XXX: this installs 2 games, how should bat script be ? - _load_gog "ewj_1_2" "Earthworm Jim 1 and 2" "" "TsCheckBox5" "" "earthworm_jim_1_2" "" "622331530,0cf7876691c7fecbe017e7518fd6aab0417ab783" -} - -verblist_add shogo_gog "Shogo Mobile Armor Division (GOG.com)" setup_shogo.exe - -load_shogo_gog() -{ - # \x96 is ansi-1250 for "en dash" - _load_gog "shogo" "Shogo `echo -e '\x96'` Mobile Armor Division" "" "TsCheckBox2" "Shogo.exe" "shogo_mobile_armor_division" "" "262247809,9ca006401565a8bf45363c943a4c3cb0b09bec4b" -} - -verblist_add settlers_2_gold_gog "The Settlers 2 Gold (GOG.com)" setup_settlers_2_gold.exe - -load_settlers_2_gold_gog() -{ - _load_gog "settlers_2_gold" "Settlers 2 GOLD" "" "TsCheckBox2" "DOSBOX\\dosbox.exe -conf dosboxSettlers2.conf -noconsole -c \"exit\"" "the_settlers_2_gold_edition" "" "286716917,efe390e48867edc3840b0d7c9cbab35ea8639b0c" -} - -verblist_add robinson_requiem_collection_gog "Robinson Requiem & Deus (GOG.com)" setup_robinson_requiem_collection.exe - -load_robinson_requiem_collection_gog() -{ - # XXX: this installs 2 games, how should bat script be ? - _load_gog "robinson_requiem_collection" "Robinson's Requiem Collection" "" "TsCheckBox5" "" "robinsons_requiem_collection" "" "377524884,d7616bf701da1b48ca4dce4361f96f3d7aefea6d" -} - -verblist_add redneck_rampage_gog "Redneck Rampage (GOG.com)" setup_redneck_rampage.exe - -load_redneck_rampage_gog() -{ - # XXX: this installs 3 games, how should bat script be ? - _load_gog "redneck_rampage" "Redneck Rampage Collection" "" "TsCheckbox5" "" "redneck_rampage_collection" "" "636962785,ca1d8c1f276db37b8dc6f93890e09161f990733a" -} - -verblist_add praetorians_gog "Praetorians (GOG.com)" setup_praetorians.exe - -load_praetorians_gog() -{ - _load_gog "praetorians" "Praetorians" "" "TsCheckBox2" "Praetorians.exe" "" "" "507093445,69da99ab6910550bcb3181df99c8565f99a6c193" -} - -verblist_add perimeter_gog "Perimeter (GOG.com)" setup_perimeter.exe - -load_perimeter_gog() -{ - _load_gog "perimeter" "Perimeter" "" "TsCheckBox2" "perimeter.exe" "" "" "1340470012,64af926cc8dacda4b9c90efaf16e2e329b5532a7" -} - -verblist_add painkiller_black_gog "Painkiller Black (GOG.com)" setup_painkiller_black.exe setup_painkiller_black-1.bin setup_painkiller_black-2.bin - -load_painkiller_black_gog() -{ - _load_gog "painkiller_black" "Painkiller Black" "setup_painkiller_black-1.bin,2097647872,f863652603d2a75c746d62c0eddea0a00c7f3fbc setup_painkiller_black-2.bin,1710374334,e1f0e1b648752b8b0ac88c1b715a8a7ba72e85c4" "TsCheckBox2" "bin\\Painkiller.exe" "painkiller" "" "2351728,3648b6b598e2f600fbc711d66a7122c27d7cbbfc" -} - -verblist_add operation_flashpoint_goty_gog "Operation Flashpoint GOTY (GOG.com)" setup_operation_flashpoint_goty.exe - -load_operation_flashpoint_goty_gog() -{ - # XXX: this installs 2 games, how should bat script be ? - # \x96 is ansi-1250 for "en dash" - _load_gog "operation_flashpoint_goty" "Operation Flashpoint `echo -e '\x96'` Game of the Year Edition" "" "TsCheckBox2" "" "" "Operation Flashpoint - GOTY" "769403166,13152a02cc05915f1058b6357c1621aa6c759b62" -} - -verblist_add neighbours_from_hell_compilation_gog "Neighbours From Hell 1 & 2 (GOG.com)" setup_neighbours_from_hell_compilation.exe - -load_neighbours_from_hell_compilation_gog() -{ - # XXX: this installs 2 games, how should bat script be ? - _load_gog "neighbours_from_hell_compilation" "Neighbours From Hell Compilation" "" "TsCheckBox4" "" "" "" "373250380,fc7217f7536d0b6fcaef5111b32252bf707f0019" -} - -verblist_add mdk_gog "MDK (GOG.com)" setup_mdk.exe - -load_mdk_gog() -{ - _load_gog "mdk" "MDK" "" "TsCheckBox4" "gogwrap.exe GOGMDK" "" "" "104786630,0e68fc7a233a8549716d14244f4fc48ef31229e9" -} - -verblist_add mdk2_gog "MDK 2 (GOG.com)" setup_mdk_2.exe - -load_mdk2_gog() -{ - _load_gog "mdk_2" "MDK 2" "" "TsCheckBox2" "MDK2.exe" "" "" "231939898,e407fc49b06c8332f862b2a952aa62729c7c2388" -} - -verblist_add ground_control_2_gog "Ground Control 2 (GOG.com)" setup_ground_control_2.exe - -load_ground_control_2_gog() -{ - _load_gog "ground_control_2" "Ground Control II" "" "TsCheckBox2" "gcii.exe" "ground_control_2_operation_exodus" "" "641603732,b2466dd94e5e364e77ba042dc7d33088ffce585f" -} - -verblist_add ghost_master_gog "Ghost Master (GOG.com)" setup_ghost_master.exe - -load_ghost_master_gog() -{ - _load_gog "ghost_master" "Ghost Master" "" "TsCheckBox2" "ghost.exe" "" "" "537093924,65f89611eaba132c64bac0d1639407419a6628b2" -} - -verblist_add freespace_gog "Freespace (GOG.com)" setup_freespace.exe - -load_freespace_gog() -{ - _load_gog "freespace" "Freespace with Silent Threat Expansion" "" "TsCheckBox4" "fs.exe" "freespace_expansion" "Freespace" "871259230,99188805dab6b0b67d01b1fb07cf3f6f42334240" -} - -verblist_add freespace_2_gog "Freespace 2 (GOG.com)" setup_freespace_2.exe - -load_freespace_2_gog() -{ - _load_gog "freespace_2" "Freespace 2" "" "TsCheckBox2" "fs2.exe" "" "" "1669384651,09d2132a413aa76eaab251724ba756409fc0225a" -} - -verblist_add flatout_gog "FlatOut (GOG.com)" setup_flatout.exe - -load_flatout_gog() -{ - _load_gog "flatout" "FlatOut" "" "TsCheckBox2" "flatout.exe" "" "" "945261967,43e5e28a0a0c9541bbb4f4c664336442903483b3" -} - -verblist_add earthworm_jim_3d_gog "Earthworm Jim 3D (GOG.com)" setup_ewj3d.exe - -load_earthworm_jim_3d_gog() -{ - _load_gog "ewj3d" "Earthworm Jim 3D" "" "TsCheckBox2" "gogwrap.exe GOGEARTHWORMJIM3D" "earthworm_jim_3d" "" "144186449,3283ce57e845b111afa6df8c315bb57891046678" -} - -verblist_add fallout_gog "Fallout (GOG.com)" setup_fallout.exe - -load_fallout_gog() -{ - _load_gog "fallout" "Fallout" "" "TsCheckBox2" "falloutw.exe" "" "" "531198473,4c61f9e386dcfd38e55564a0bac26d5a1a8bd52a" -} - -verblist_add fallout_2_gog "Fallout 2 (GOG.com)" setup_fallout_2.exe - -load_fallout_2_gog() -{ - _load_gog "fallout_2" "Fallout 2" "" "TsCheckBox2" "fallout2.exe" "" "" "609017688,501a8bff61bc03643d32781d0b6b4d9f358fe863" -} - -verblist_add fallout_tactics_gog "Fallout Tactics (GOG.com)" setup_fallout_tactics.exe - -load_fallout_tactics_gog() -{ - _load_gog "fallout_tactics" "Fallout Tactics" "" "TsCheckBox2" "BOS.exe" "" "" "1629699801,a142ebb287d60e6ba619c8c67ec61270a3313dd3" -} - -verblist_add tex_murphy_1_and_2_gog "Tex Murphy 1 & 2 (GOG.com)" setup_tex_murphy_1_and_2.exe - -load_tex_murphy_1_and_2_gog() -{ - # XXX: this installs 2 games, how should bat script be ? - _load_gog "tex_murphy_1_and_2" "Tex Murphy 1 and 2" "" "TsCheckBox5" "" "tex_murphy_1_2" "" "29082356,7aaaa686fdf424fd403bc972cbc94464a2693ce3" -} - -verblist_add beneath_a_steel_sky_gog "Beneath a Steel Sky (GOG.com, free)" setup_beneath_a_steel_sky.exe - -load_beneath_a_steel_sky_gog() -{ - _load_gog "beneath_a_steel_sky" "Beneath a Steel Sky" "" "TsCheckBox4" "ScummVM\\scummvm.exe -c \"C:\\Program Files\\GOG.com\\Beneath a Steel Sky\\beneath.ini\" beneath" "" "" "75176395,1f99e12643529baa91fecfb206139a8921d9589c" -} - -# Brief HOWTO for adding a GOG game: -# - "beneath_a_steel_sky" is the installer exe name, minus "setup_" and ".exe" -# - "Beneath a Steel Sky" is installer window title, minus "Setup - " -# - There are no other files for this game, so this parameter is empty. -# Otherwise it should be of the following form: -# file_name[,length[,sha1sum]] [...] -# - "TsCheckBox4" is the control name for the checkbox deciding whether it will -# install some reader (Foxit in this case, could be acrobat reader). That -# installation is enabled by default, and would just bloat the generic -# AutoHotKey script, so it gets disabled. -# - "ScummVM\\[...]" is the command line to run the game, as fetched from the -# shortcut/launcher installer/wine creates, which will be used in BAT scripts -# created by wisotool -# - The part in the url which is specific to this game is identical to its "id" -# (first parameter), so this parameter is left out. -# - The install directory is the same as installer window title (second -# parameter), so this parameter is left out. -# - Main installer size and sha1sum, separated by a comma. - #---------------------------------------------------------------- # Generic Steam installer @@ -6328,11 +8799,11 @@ load_beneath_a_steel_sky_gog() # Used for AutoHotKey. FIXME: is this guaranteed to match the wiki? # game_cache_file # .gcf or .ncf file name. Note: Does _NOT_ always match the game folder name below. -# game_folder +# game_folder # Folder where files are stored under $STEAMDIR/steamapps/common/ # game_extra_files # Most games/demos come with one .gcf or .ncf file, then everything else in the -# $STEAMDIR/steamapps/common/$game_folder directory. Some (Total War demos) have several +# $STEAMDIR/steamapps/common/$game_folder directory. Some (Total War demos) have several # more .gcf/.ncf files. This should be a list, separated by commas. # # @@ -6359,7 +8830,6 @@ _load_steam_app() steam_dir="$programfilesdir_unix/Steam" - load_autohotkey test -f "$steam_dir/Steam.exe" || try sh $WINETRICKS -q steam app_id="$1" @@ -6367,7 +8837,7 @@ _load_steam_app() game_cache_file="$3" game_folder="$4" game_extra_files="$5" - + # If files are already cached, skipped downloading/installing and just restore from cache: if [ ! -f "$WISOTOOL_CACHE/$PACKAGE/$game_cache_file" ] then @@ -6377,8 +8847,8 @@ _load_steam_app() ; Originally used: ; run, Steam.exe -login $STEAM_USER $STEAM_PASS -applaunch $app_id ; but that doesn't work for all programs. Some would silently fail to start. - - ; Instead, run steam in the background, sleep for 30s to give it enough time + + ; Instead, run steam in the background, sleep for 30s to give it enough time ; to start, then use the steam:// prototol to install: run, Steam.exe -login $STEAM_USER $STEAM_PASS ; FIXME: should detect steam running properly... @@ -6397,7 +8867,7 @@ _load_steam_app() } sleep 30000 run, steam://install/$app_id - + ; Info screen, disk space required, etc. winwait, Install - $game_title winactivate, Install - $game_title @@ -6413,13 +8883,13 @@ _load_steam_app() sleep 10000 send {enter} sleep 10000 - - ; Here, it's getting the .gcf/.ncf files. This is normally quick, but can take a long time. - ; Most finish in a few seconds, but the Total War demos takes a couple minutes. - ; So, we'll exit AHK, then wait for all the game files to be present, + + ; Here, it's getting the .gcf/.ncf files. This is normally quick, but can take a long time. + ; Most finish in a few seconds, but the Total War demos takes a couple minutes. + ; So, we'll exit AHK, then wait for all the game files to be present, ; before continuing the install. exit - " + " if test ! "$game_extra_files" = "" then @@ -6444,7 +8914,7 @@ _load_steam_app() # FIXME: Is this a long enough sleep? sleep 30 - + ahk_do " winwait, Install - $game_title winactivate, Install - $game_title @@ -6489,7 +8959,7 @@ _load_steam_app() else mkdir -p "$steam_dir/steamapps/common" cp -r "$WISOTOOL_CACHE/$PACKAGE/$game_folder" "$steam_dir/steamapps/common" - cp -r "$WISOTOOL_CACHE/$PACKAGE/$game_cache_file" "$steam_dir/steamapps" + cp -r "$WISOTOOL_CACHE/$PACKAGE/$game_cache_file" "$steam_dir/steamapps" if test ! "$game_extra_files" = "" then IFS=$',' @@ -6501,8 +8971,9 @@ _load_steam_app() fi fi - -cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ + +cat > "$DRIVE_C/run-$PACKAGE.bat" <<__EOF__ +${programfilesdrive}: cd "$programfilesdir_x86_win\Steam" .\Steam.exe -login $STEAM_USER $STEAM_PASS -applaunch $app_id __EOF__ @@ -6632,7 +9103,7 @@ srcdir=`cd $srcdir; /bin/pwd` # Load external verbs. Filenames may not contain spaces. if cd "$WISOTOOL_VERBS" then - for file in `find . -type f -name '*.verb' 2>/dev/null` + for file in `find . -type f -name '*.verb' 2>/dev/null` do . $file done @@ -6716,8 +9187,16 @@ then programfilesdir_x86_win="${programfilesdir_win}" programfilesdir_x86_unix="${programfilesdir_unix}" fi +# FIXME: why export this? export programfilesdir_x86_unix +# FIXME: don't hardcode +programfilesdrive=c + +# localized, and different across Windows versions: +appdata_win="`unset WINEDEBUG; WINEDLLOVERRIDES=mshtml= $WINE cmd.exe /c echo "%AppData%" | tr -d '\015'`" +appdata_unix="`unset WINEDEBUG; $XXXPATH -u "$appdata_win" | tr -d '\015' `" + # (Fixme: get fonts path from SHGetFolderPath # See also http://blogs.msdn.com/oldnewthing/archive/2003/11/03/55532.aspx) # @@ -6764,7 +9243,7 @@ do load) load_iso dd;; load_harder) load_iso ddrescue;; load=*) key="`echo $PACKAGE | sed 's/load=//'`"; load_iso dd "$key";; - migrate) migrate_files;; + refile|migrate) migrate_files;; version) print_version;; *.verb) @@ -6791,7 +9270,10 @@ do esac shift - # User-specific postinstall hook. + # if verbs doesn't preserve the working directory, restore it + cd "$olddir" + + # User-specific postinstall hook. # Source it so the script can call download() if needed. if [ -f "$WISOTOOL_POST"/$PACKAGE/$PACKAGE-postinstall.sh ] then @@ -6804,4 +9286,8 @@ test "$WISOTOOL_CACHE_SYMLINK" && rm -f "$WISOTOOL_CACHE_SYMLINK" # remove the temp directory chmod -R 700 "$WISOTOOL_TMP" -rm -rf "$WISOTOOL_TMP" +while ! rm -rf "$WISOTOOL_TMP" +do + # Sometimes apps take a while to exit on Vista + sleep 1 +done