| [544] | 1 | <WARPIN VERSION="0.9.20" OS="OS2_4x">
|
|---|
| 2 |
|
|---|
| 3 | <HEAD>
|
|---|
| 4 |
|
|---|
| 5 | <TITLE>Qt Runtime Libraries ${version} (${date})</TITLE>
|
|---|
| 6 |
|
|---|
| 7 | <REXX NAME="GetDLLPath">
|
|---|
| 8 | rc = rxFuncAdd('SysLoadFuncs', 'REXXUTIL', 'SysLoadFuncs')
|
|---|
| 9 | rc = SysLoadFuncs()
|
|---|
| 10 | ret = SysBootDrive()'\OS2\DLL'
|
|---|
| 11 | bestPath = SysBootDrive()'\ecs\dll'
|
|---|
| 12 | config_sys = SysBootDrive()'\config.sys'
|
|---|
| 13 | do while lines(config_sys)
|
|---|
| 14 | line = linein(config_sys)
|
|---|
| 15 | if (left(line, 8) == 'LIBPATH=') then do
|
|---|
| 16 | /* locate the previous occurence of path */
|
|---|
| 17 | libpath = translate(substr(line, 9))
|
|---|
| 18 | path = translate(bestPath)
|
|---|
| 19 | l = length(path)
|
|---|
| 20 | found = 0; p = 1
|
|---|
| 21 | do while (\found)
|
|---|
| 22 | p = pos(path, libpath, p)
|
|---|
| 23 | if (p == 0) then leave
|
|---|
| 24 | cb = ''; ca = ''
|
|---|
| 25 | /*<*/
|
|---|
| 26 | if (p > 1) then cb = substr(libpath, p - 1, 1)
|
|---|
| 27 | if (p + l <= length(libpath)) then ca = substr(libpath, p + l, 1)
|
|---|
| 28 | /*>*/
|
|---|
| 29 | found = (cb == '' | cb == ';') & (ca == '' | ca == ';')
|
|---|
| 30 | if (\found) then p = p + 1
|
|---|
| 31 | end
|
|---|
| 32 | if (found) then do
|
|---|
| 33 | ret = bestPath
|
|---|
| 34 | leave
|
|---|
| 35 | end
|
|---|
| 36 | end
|
|---|
| 37 | end
|
|---|
| 38 | return ret
|
|---|
| 39 | </REXX>
|
|---|
| 40 |
|
|---|
| 41 | <REXX NAME="GetDocPath">
|
|---|
| 42 | rc = rxFuncAdd('SysLoadFuncs', 'REXXUTIL', 'SysLoadFuncs')
|
|---|
| 43 | rc = SysLoadFuncs()
|
|---|
| 44 | ret = SysBootDrive()'\OS2\DOC'
|
|---|
| 45 | bestPath = SysBootDrive()'\ecs\DOC'
|
|---|
| 46 | curDir = directory()
|
|---|
| 47 | if (directory(bestPath) \== '') then ret = bestPath
|
|---|
| 48 | call directory curdir
|
|---|
| 49 | return ret
|
|---|
| 50 | </REXX>
|
|---|
| 51 |
|
|---|
| 52 | <REXX NAME="GetSysAppPath">
|
|---|
| 53 | rc = rxFuncAdd('SysLoadFuncs', 'REXXUTIL', 'SysLoadFuncs')
|
|---|
| 54 | rc = SysLoadFuncs()
|
|---|
| 55 | ret = SysBootDrive()'\OS2\APPS'
|
|---|
| 56 | bestPath = SysBootDrive()'\ecs\SYSTEM'
|
|---|
| 57 | curDir = directory()
|
|---|
| 58 | if (directory(bestPath) \== '') then ret = bestPath
|
|---|
| 59 | call directory curdir
|
|---|
| 60 | return ret
|
|---|
| 61 | </REXX>
|
|---|
| 62 |
|
|---|
| [546] | 63 | <REXX NAME="CheckQt4RuntimePkg">
|
|---|
| 64 | ver = GetPkgVersion('netlabs.org\Qt4\Runtime')
|
|---|
| 65 | call WirexxPutEnv 'Qt4RuntimePkgVersion', ver
|
|---|
| 66 | if (ver == '') then return 4
|
|---|
| 67 | return 6
|
|---|
| 68 |
|
|---|
| 69 | /* same as below... */
|
|---|
| 70 | GetPkgVersion: procedure
|
|---|
| 71 | parse arg aPkgId
|
|---|
| 72 | rc = rxFuncAdd('SysLoadFuncs', 'REXXUTIL', 'SysLoadFuncs')
|
|---|
| 73 | rc = SysLoadFuncs()
|
|---|
| 74 | WarpInDir = strip(SysIni('USER', 'WarpIN', 'Path'), 'T', '0'x)
|
|---|
| 75 | if (WarpInDir \== '') then do
|
|---|
| 76 | rc = SysFileTree(WarpInDir'\DATBAS_?.INI', 'inis', 'FO')
|
|---|
| 77 | if (rc == 0) then do
|
|---|
| 78 | do i = 1 to inis.0
|
|---|
| 79 | rc = SysIni(inis.i, 'ALL:', 'apps')
|
|---|
| 80 | if (rc == '') then do
|
|---|
| 81 | do j = 1 to apps.0
|
|---|
| 82 | apps.j = strip(apps.j, 'T', '0'x)
|
|---|
| 83 | if (left(apps.j, length(aPkgId)) == aPkgId) then do
|
|---|
| 84 | /* found the app */
|
|---|
| 85 | ver = right(apps.j, length(apps.j) - length(aPkgId) - 1)
|
|---|
| 86 | ver = translate(ver, '.', '\')
|
|---|
| [723] | 87 | return ver
|
|---|
| [546] | 88 | end
|
|---|
| [544] | 89 | end
|
|---|
| 90 | end
|
|---|
| 91 | end
|
|---|
| 92 | end
|
|---|
| 93 | end
|
|---|
| [723] | 94 | return ''
|
|---|
| [544] | 95 | </REXX>
|
|---|
| 96 |
|
|---|
| [546] | 97 | <REXX NAME="GetQt4RuntimePkgVersion">
|
|---|
| 98 | return WirexxGetEnv('Qt4RuntimePkgVersion')
|
|---|
| [544] | 99 | </REXX>
|
|---|
| 100 |
|
|---|
| [736] | 101 | <REXX NAME="AskToUninstallPreviousVersion">
|
|---|
| 102 | call WirexxShowMessage ,
|
|---|
| 103 | 'Qt 4 Runtime: Warning',,
|
|---|
| [819] | 104 | 'IMPORTANT NOTICE:',
|
|---|
| 105 | ||'0D0A'x||'0D0A'x,
|
|---|
| 106 | ||'If you have another version of the Qt 4 Runtime package installed on',
|
|---|
| 107 | 'your computer, *PLEASE* cancel this installation now and uninstall',
|
|---|
| 108 | 'the previous version first! Upgrading the existing Qt 4 installation',
|
|---|
| 109 | 'is currently *NOT SUPPORTED*.',
|
|---|
| 110 | ||'0D0A'x||'0D0A'x,
|
|---|
| 111 | ||'The previous version of the Qt 4 Runtime package may be uninstalled',
|
|---|
| 112 | 'using the WarpIn utility which you can start through the Programs menu',
|
|---|
| 113 | '(Desktop > Local System > Install/Remove > WarpIn > WarpIn) or by',
|
|---|
| 114 | 'typing "warpin" in the command prompt.',
|
|---|
| 115 | ||'0D0A'x||'0D0A'x,
|
|---|
| 116 | ||'Please note that some Qt files may still remain in your system after',
|
|---|
| 117 | 'uninstallation and interfere with the new install. In order to avoid possible',
|
|---|
| 118 | 'problems, please search for the following files on a drive where Qt 4',
|
|---|
| 119 | 'was previously installed and delete them if found:'||'0D0A'x||'0D0A'x,
|
|---|
| 120 | ||'- Qt*4.dll'||'0D0A'x,
|
|---|
| 121 | ||'- qt*.conf'||'0D0A'x,
|
|---|
| 122 | ||'0D0A'x,
|
|---|
| [821] | 123 | ||'Sorry for the inconvenience, it is mostly caused by various',
|
|---|
| [819] | 124 | 'limitations of WarpIn. The next version of Qt 4 for OS/2 will be',
|
|---|
| 125 | 'distributed in RPM format which will solve most current installation',
|
|---|
| 126 | 'problems. See http://svn.netlabs.org/rpm for more information about',
|
|---|
| 127 | 'RPM for OS/2.'||'0D0A'x||'0D0A'x,,
|
|---|
| [821] | 128 | 1
|
|---|
| 129 | if (result == 2) then call WirexxCancel
|
|---|
| [736] | 130 | return ''
|
|---|
| 131 | </REXX>
|
|---|
| 132 |
|
|---|
| [544] | 133 | <!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
|
|---|
| 134 |
|
|---|
| 135 | <PCK INDEX=1
|
|---|
| [825] | 136 | PACKAGEID="netlabs.org\Qt4\Installation Utilities\${version_path}"
|
|---|
| 137 | TITLE="Installation Utilities"
|
|---|
| 138 | NODESELECT
|
|---|
| 139 | TARGET="=("GetSysAppPath")\Qt4" FIXED
|
|---|
| 140 | LONGFILENAMES
|
|---|
| 141 | >Contains installation utilities. This package is required</PCK>
|
|---|
| 142 |
|
|---|
| 143 | <PCK INDEX=2
|
|---|
| [544] | 144 | PACKAGEID="netlabs.org\Qt4\Runtime\${version_path}"
|
|---|
| [736] | 145 | TITLE="Runtime=("AskToUninstallPreviousVersion")"
|
|---|
| [544] | 146 | NODESELECT
|
|---|
| 147 | REQUIRES="netlabs.org\kLIBC\LIBC 0.6 Runtime\0\6\3"
|
|---|
| 148 | REQUIRES="netlabs.org\GCC4\Runtime\4\4\2\20091204"
|
|---|
| [825] | 149 | REQUIRES="1"
|
|---|
| [544] | 150 | TARGET="=("GetDLLPath")" FIXED
|
|---|
| 151 | LONGFILENAMES
|
|---|
| [825] | 152 | EXECUTE="$(1)\util\UpdateQtSysConf.cmd|Prefix=$(1),Settings=$\(ETC\)/xdg"
|
|---|
| [826] | 153 | EXECUTE="del $(HOME)\.config\Trolltech.ini"
|
|---|
| [544] | 154 | DEEXECUTE="del $(ETC)\qtsys.conf"
|
|---|
| [826] | 155 | DEEXECUTE="del $(HOME)\.config\Trolltech.ini"
|
|---|
|
|---|