Changeset 3612 for trunk/tools/DailyBuild
- Timestamp:
- May 27, 2000, 4:13:37 AM (25 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tools/DailyBuild/odin32env.cmd
r3521 r3612 1 /* $Id: odin32env.cmd,v 1. 2 2000-05-12 12:21:59bird Exp $1 /* $Id: odin32env.cmd,v 1.3 2000-05-27 02:13:37 bird Exp $ 2 2 * 3 3 * Sets the build environment. … … 9 9 */ 10 10 11 sToolkit = 'c:\appl\os2\toolkt40'; 12 sVAC = 'c:\appl\os2\ibmcpp30'; 13 sDDKBase = 'd:\knut\ddk\base'; 14 sMSC = 'd:\knut\ddk\ddktools\toolkits\msc60'; 15 sCVS = 'd:\knut\cvs'; 16 sEMXBack = 'c:\emx'; 17 sEMXForw = 'c:/emx'; 18 sMYSQL = 'c:\emx\mysql'; /* optionally */ 19 20 'SET CVSROOT=:pserver:bird@www.netlabs.org:d:/netlabs.src/odin32' 21 'SET HOME=d:\knut\home' 22 'SET USER=bird' 23 'SET DEBUG=1' 24 25 /* oopps! this one is problemous for 4OS/2 due the the '%N's... */ 26 'SET NLSPATH=C:\MPTN\MSG\NLS\%%N;C:\TCPIP\MSG\ENUS850\%%N;C:\netqos2\%%N;'sToolkit'\OPENDOC\BASE\LOCALE\EN_US\%%N;'sToolkit'\MSG\%%N;' 27 28 /* 29 * Non or minore changes are needed here! 30 */ 31 'SET TOOLKIT='sToolkit 32 'SET CPPLOCAL='sVAC 33 'SET DDKBASE='sDDKBase 34 'SET MSC='sMSC 35 36 'SET CPPHELP_INI=C:\OS2\SYSTEM' 37 'SET TMP=%TEMP%' 38 'SET TMPDIR=%TMP%' 39 40 'SET VACPP_SHARED=FALSE' 41 'SET CPPMAIN='sVAC 42 'SET CPPWORK='sVAC 43 'SET SMINCLUDE='sToolkit'\som\include;'sToolkit'\idl;'sVAC'\INCLUDE\SOM' 44 'SET HELPNDX=EPMKWHLP.NDX+CPP.NDX+CPPBRS.NDX' 45 46 'SET INCLUDE='sVAC'\INCLUDE;'sVAC'\INCLUDE\SOM;'sToolkit'\h;%include%;' 47 'SET LIB='sVAC'\LIB;%lib%;' 48 'SET LIB='sToolkit'\SPEECH\LIB;'sToolkit'\SAMPLES\MM\LIB;'sToolkit'\LIB;'sToolkit'\SOM\LIB;'sToolkit'\OPENDOC\BASE\LIB;%LIB%'; 49 'SET LOCPATH='sVAC'\LOCALE;%LOCPATH%' 50 'SET HELP='sVAC'\HELP;%HELP%;' 51 'SET BEGINLIBPATH='sVAC'\DLL;%BeginLIBPATH%;' 52 53 'SET PATH='sVAC'\BIN;'sMSC'\binp;'sCVS'\bin;%Path%' 54 'SET PATH='sToolkit'\BETA\BIN;'sToolkit'\SOM\COMMON;'sToolkit'\SOM\BIN;'sToolkit'\OPENDOC\BASE\BIN;'sToolkit'\BIN;%Path%;'sDDKBase'\tools'; 55 56 'SET DPATH='sVAC'\HELP;'sVAC';'sVAC'\LOCALE;%DPATH%' 57 'SET DPATH='sToolkit'\SOM\COMMON\SYSTEM;'sToolkit'\SOM\MSG;%DPath%'; 58 'SET DPATH='sToolkit'\MSG;'sToolkit'\OPENDOC\BASE\MSG;'sToolkit'\BOOK;%DPath' 59 60 'SET BOOKSHELF='sToolkit'\archived;'sToolkit'\book;'sToolkit'\books;'sVAC'\help;%BOOKSHELF%'; 61 62 63 /* emx + mysql */ 64 'set C_INCLUDE_PATH='sEMXForw'/include' 65 'set LIBRARY_PATH='sEMXForw'/lib' 66 'set CPLUS_INCLUDE_PATH='sEMXForw'/include/cpp;'sEMXForw'/include' 67 'set PROTODIR='sEMXForw'/include/cpp/gen' 68 'set OBJC_INCLUDE_PATH='sEMXForw'/include' 69 'set INFOPATH='sEMXForw'/info' 70 'set BOOKSHELF='sEMXBack'\BOOK;%BOOKSHELF%' 71 'set EMXBOOK=emxdev.inf+emxlib.inf+emxgnu.inf+emxbsd.inf' 72 'set HELPNDX=emxbook.ndx+%HELPNDX%' 73 'set DPATH='sEMXBack'\book;%DPATH%' 74 'set PATH='sEMXBack'\bin;%PATH%;'sMYSQL'\bin' 75 'set TERM=mono' 76 'set TERMCAP='sEMXForw'/etc/termcap.dat' 11 /* 12 * To use this script you'll have to adjust some paths to match your local 13 * installation. These paths are (mainly) called s<>Main or s<>Base, and usually 14 * the only assignment statements in the configuration procedures below. 15 * 16 * In addition the CVSROOT, USER and HOME directories right below have to corrected. 17 */ 18 call EnvVar_Set 0, 'SET CVSROOT', ':pserver:bird@www.netlabs.org:d:/netlabs.src/odin32' 19 call EnvVar_Set 0, 'HOME', 'd:\knut\home' 20 call EnvVar_Set 0, 'USER', 'bird' 21 22 /* 23 * Call the procedures which configure each tool. 24 * (The order this is done is _very_ important!) 25 */ 26 call CVS 0; 27 call DDKBase 0; 28 call MSC60 0; 29 call VAC30 0; 30 call Toolkit40 0; 31 call EnvVar_Set 0, 'DEBUG', '1' 77 32 78 33 exit(0); 34 35 36 37 38 /** 39 * Individual tools configurations 40 **/ 41 42 43 /* 44 * Concurrent Versions System (CVS) 45 */ 46 CVS: procedure 47 parse arg fRM 48 49 /* 50 * Concurrent Versions System (CVS) main directory. 51 */ 52 sCVSMain = 'd:\knut\tools\cvs'; 53 call EnvVar_Set fRM, 'cvsmain', sCVSMain; 54 call EnvVar_AddFront fRM, 'path', sCVSMain'\bin;' 55 call EnvVar_AddFront fRM, 'bookshelf', sCVSMain'\book;' 56 return 0; 57 58 59 /* 60 * EMX 61 */ 62 EMX: procedure 63 parse arg fRM 64 65 /* 66 * EMX/GCC main directory. 67 */ 68 sEMXBack = 'c:\emx'; 69 sEMXForw = 'c:/emx'; 70 71 call EnvVar_Set fRM, 'emx', sEMXBack; 72 73 call EnvVar_AddFront fRM, 'BEGINLIBPATH', sEMXBack'\dll;' 74 call EnvVar_AddFront fRM, 'PATH', sEMXBack'\bin;' 75 call EnvVar_AddFront fRM, 'DPATH', sEMXBack'\book;' 76 call EnvVar_AddFront fRM, 'BOOKSHELF', sEMXBack'\book;' 77 call EnvVar_AddFront fRM, 'HELP', sEMXBack'\help;' 78 call EnvVar_AddFront fRM, 'C_INCLUDE_PATH', sEMXForw'/include' 79 call EnvVar_AddFront fRM, 'LIBRARY_PATH', sEMXForw'/lib' 80 call EnvVar_AddFront fRM, 'CPLUS_INCLUDE_PATH', sEMXForw'/include/cpp;'sEMXForw'/include' 81 call EnvVar_Set fRM, 'PROTODIR', sEMXForw'/include/cpp/gen' 82 call EnvVar_Set fRM, 'OBJC_INCLUDE_PATH', sEMXForw'/include' 83 call EnvVar_Set fRM, 'GCCLOAD', '5' 84 call EnvVar_Set fRM, 'GCCOPT', '-pipe' 85 call EnvVar_AddFront fRM, 'INFOPATH', sEMXForw'/info' 86 call EnvVar_Set fRM, 'EMXBOOK', 'emxdev.inf+emxlib.inf+emxgnu.inf+emxbsd.inf' 87 call EnvVar_AddFront fRM, 'HELPNDX', 'emxbook.ndx', '+' 88 call EnvVar_Set fRM, 'EMXOPT', '-c -n -h1024' 89 if EnvVar_Get('TERM') = '' then do 90 call EnvVar_Set fRM, 'TERM', 'mono' 91 call EnvVar_Set fRM, 'TERMCAP', sEMXForw'/etc/termcap.dat' 92 end 93 return 0; 94 95 96 /* 97 * Device Driver Kit (DDK) base. 98 */ 99 DDKBase: procedure 100 parse arg fRM 101 102 /* 103 * Device Driver Kit (DDK) (v4.0+) base (important not main) directory. 104 */ 105 sDDKBase = 'f:\knut\ddk\base'; 106 call EnvVar_Set fRM, 'ddkbase', sDDKBase; 107 call EnvVar_AddFront fRM, 'path', sDDKBase'\tools;' 108 call EnvVar_AddFront fRM, 'include', sDDKBase'\h;' 109 call EnvVar_AddFront fRM, 'lib', sDDKBase'\lib;' 110 call EnvVar_AddFront fRM, 'bookshelf', sDDKBase'\..\docs;' 111 112 return 0; 113 114 115 116 /* 117 * Microsoft C v6.0a 118 */ 119 MSC60: procedure 120 parse arg fRM 121 122 /* 123 * Microsoft C v6.0a main directory. 124 */ 125 sMSCMain = 'f:\knut\ddk\ddktools\toolkits\msc60'; 126 call EnvVar_Set fRM, 'mscmain', sMSCMain; 127 call EnvVar_AddFront fRM, 'path', sMSCMain'\binp;' 128 call EnvVar_AddFront fRM, 'include', sMSCMain'\include;' 129 call EnvVar_AddFront fRM, 'lib', sMSCMain'\lib;' 130 return 0; 131 132 133 134 /* 135 * mySQL Database system 136 */ 137 mySQL: procedure 138 parse arg fRM 139 140 /* 141 * mySQL Database system main directory. 142 */ 143 sMySQLMain = 'c:\emx\mysql'; 144 call EnvVar_Set fRM, 'mysqlmain', sMySQLMain; 145 call EnvVar_AddFront fRM, 'path', sMySQLMain'\bin;' 146 call EnvVar_AddFront fRM, 'beginlibpath', sMySQLMain'\dll;' 147 call EnvVar_AddFront fRM, 'include', sMySQLMain'\include;' 148 /*call EnvVar_AddFront fRM, 'lib', sMySQLMain'\lib;'*/ 149 return 0; 150 151 152 153 /* 154 * NetQOS2 - help subsystem++ for VAC 3.6.5 and VAC 4.0 155 */ 156 NetQOS2: procedure 157 sNetQ11Main = 'd:\knut\tools\netqos2'; 158 call EnvVar_Set fRM, 'netq11main', sNetQ11Main 159 call EnvVar_AddFront fRM, 'path', sNetQ11Main';' 160 call EnvVar_AddFront fRM, 'dpath', sNetQ11Main';' 161 call EnvVar_AddFront fRM, 'beginlibpath', sNetQ11Main';' 162 call EnvVar_Set fRM, 'imndatasrv', sNetQ11Main'\DATA' 163 call EnvVar_Set fRM, 'imndatacl', sNetQ11Main'\DATA' 164 call EnvVar_Set fRM, 'imnworksrv', sNetQ11Main'\WORK' 165 call EnvVar_Set fRM, 'imnworkcl', sNetQ11Main'\WORK' 166 call EnvVar_Set fRM, 'imnnlpssrv', sNetQ11Main 167 call EnvVar_Set fRM, 'imnnlpscl', sNetQ11Main 168 call EnvVar_Set fRM, 'imncccfgfile', 'NETQ.CFG' 169 call EnvVar_Set fRM, 'imncscfgfile', 'NETQ.CFG' 170 call EnvVar_Set fRM, 'imqconfigsrv', sNetQ11Main'\instance' 171 call EnvVar_Set fRM, 'imqconfigcl', sNetQ11Main'\instance\dbcshelp' 172 return 0; 173 174 175 176 /* 177 * OS/2 Programmers Toolkit v4.0 (CSD1/4) 178 */ 179 Toolkit40: procedure 180 parse arg fRM 181 182 /* 183 * Toolkit (4.0) main directory. 184 */ 185 sTKMain = 'c:\appl\os2\toolkt40'; 186 187 call EnvVar_Set fRM, 'tkmain', sTkMain; 188 189 call EnvVar_AddFront fRM, 'beginlibpath', sTkMain'\BETA\DLL;'sTkMain'\SAMPLES\MM\DLL;'sTkMain'\SAMPLES\OPENDOC\PARTS\DLL;'sTkMain'\SOM\COMMON\DLL;'sTkMain'\SOM\LIB;'sTkMain'\OPENDOC\BASE\DLL;'sTkMain'\OPENDOC\BASE\LOCALE\EN_US;'sTkMain'\DLL;' 190 call EnvVar_AddFront fRM, 'path', sTkMain'\BETA\BIN;'sTkMain'\SOM\COMMON;'sTkMain'\SOM\BIN;.;'sTkMain'\OPENDOC\BASE\BIN;'sTkMain'\BIN;' 191 call EnvVar_AddFront fRM, 'dpath', sTkMain'\SOM\COMMON\SYSTEM;'sTkMain'\SOM\MSG;'sTkMain'\OPENDOC\BASE\MSG;'sTkMain'\BOOK;'sTkMain'\MSG;' 192 call EnvVar_AddFront fRM, 'help', sTkMain'\BETA\HELP;'sTkMain'\OPENDOC\BASE\LOCALE\EN_US;'sTkMain'\HELP;' 193 call EnvVar_AddFront fRM, 'bookshelf', sTkMain'\BETA\BOOK;'sTkMain'\BOOK;'sTkMain'\ARCHIVED;' 194 call EnvVar_AddFront fRM, 'somir', sTkMain'\SOM\COMMON\ETC\214\SOM.IR;'sTkMain'\OPENDOC\BASE\AVLSHELL.IR;' 195 call EnvVar_AddEnd fRM, 'somir', sTkMain'\OPENDOC\CUSTOM\OD.IR;'sTkMain'\SAMPLES\REXX\SOM\ANIMAL\ORXSMP.IR;' 196 call EnvVar_AddFront fRM, 'include', sTkMain'\SPEECH\H;'sTkMain'\BETA\H;'sTkMain'\SAMPLES\OPENDOC\PARTS\INCLUDE;'sTkMain'\SOM\INCLUDE;'sTkMain'\INC;'sTkMain'\H\GL;'sTkMain'\H;' 197 call EnvVar_AddEnd fRM, 'include', sTkMain'\H\LIBC;.;' 198 call EnvVar_AddFront fRM, 'lib', sTkMain'\SPEECH\LIB;'sTkMain'\SAMPLES\MM\LIB;'sTkMain'\LIB;'sTkMain'\SOM\LIB;'sTkMain'\OPENDOC\BASE\LIB;' 199 call EnvVar_AddFront fRM, 'nlspath', sTkMain'\OPENDOC\BASE\LOCALE\EN_US\%N;'sTkMain'\MSG\%N;' 200 call EnvVar_AddFront fRM, 'locpath', sTkMain'\OPENDOC\BASE\LOCALE;' 201 call EnvVar_AddFront fRM, 'ipfc', sTkMain'\IPFC;' 202 call EnvVar_Set fRM, 'odbase', sTkMain'\OPENDOC\BASE' 203 call EnvVar_Set fRM, 'odlang', 'en_US' 204 call EnvVar_AddFront fRM, 'odbasepaths', sTkMain'\OPENDOC\BASE;' 205 call EnvVar_Set fRM, 'odcfg', sTkMain'\OPENDOC\CUSTOM' 206 call EnvVar_Set fRM, 'odtmp', EnvVar_Get('tmp'); 207 call EnvVar_Set fRM, 'sombase', sTkMain'\SOM' 208 call EnvVar_Set fRM, 'somruntime', sTkMain'\SOM\COMMON' 209 210 call EnvVar_Set fRM, 'cpref', 'CP1.INF+CP2.INF+CP3.INF' 211 call EnvVar_Set fRM, 'gpiref', 'GPI1.INF+GPI2.INF+GPI3.INF+GPI4.INF' 212 call EnvVar_Set fRM, 'mmref', 'MMREF1.INF+MMREF2.INF+MMREF3.INF' 213 call EnvVar_Set fRM, 'pmref', 'PM1.INF+PM2.INF+PM3.INF+PM4.INF+PM5.INF' 214 call EnvVar_Set fRM, 'wpsref', 'WPS1.INF+WPS2.INF+WPS3.INF' 215 call EnvVar_AddFront fRM, 'sminclude', sTkMain'\H;'sTkMain'\IDL;'sTkMain'\SOM\INCLUDE;.;'sTkMain'\OPENDOC\BASE\INCLUDE;'sTkMain'\SAMPLES\OPENDOC\PARTS\INCLUDE;' 216 call EnvVar_Set fRM, 'smaddstar', '1' 217 call EnvVar_Set fRM, 'smemit', 'h;ih;c' 218 call EnvVar_Set fRM, 'smtmp', EnvVar_Get('tmp'); 219 call EnvVar_Set fRM, 'smclasses', 'WPTYPES.IDL' 220 call EnvVar_Set fRM, 'odparts', sTkMain'\SAMPLES\OPENDOC\PARTS' 221 call EnvVar_Set fRM, 'odsrc', sTkMain'\SAMPLES\OPENDOC\PARTS' 222 call EnvVar_AddFront fRM, 'odpartspaths', sTkMain'\SAMPLES\OPENDOC\PARTS;' 223 call EnvVar_AddFront fRM, 'odsrcpaths', sTkMain'\SAMPLES\OPENDOC\PARTS;' 224 /* 225 call EnvVar_Set fRM, 'CAT_MACHINE=COM1:57600' 226 call EnvVar_Set fRM, 'CAT_HOST_BIN_PATH='sTkMain'\BIN' 227 call EnvVar_Set fRM, 'CAT_COMMUNICATION_TYPE=ASYNC_SIGBRK' 228 call EnvVar_AddFront fRM, 'CAT_HOST_SOURCE_PATH='sTkMain'\BIN;' 229 */ 230 return 0; 231 232 233 234 /* 235 * OS/2 Programmers Toolkit v4.5 236 */ 237 Toolkit45: procedure 238 parse arg fRM 239 240 /* 241 * Toolkit (4.5) main directory. 242 */ 243 sTKMain = 'd:\knut\tools\toolkit45'; 244 245 call EnvVar_Set fRM, 'tkmain', sTkMain; 246 247 call EnvVar_AddFront fRM, 'path', sTkMain'\bin;' 248 call EnvVar_AddFront fRM, 'dpath', sTkMain'\book;' 249 call EnvVar_AddFront fRM, 'dpath', sTkMain'\msg;' 250 call EnvVar_AddFront fRM, 'beginlibpath', sTkMain'\dll;' 251 call EnvVar_AddFront fRM, 'help', sTkMain'\help;' 252 call EnvVar_AddFront fRM, 'bookshelf', sTkMain'\archived;' 253 call EnvVar_AddFront fRM, 'bookshelf', sTkMain'\book;' 254 call EnvVar_AddFront fRM, 'nlspath', sTkMain'\msg\%N;' 255 call EnvVar_AddEnd fRM, 'ulspath', sTkMain'\language;' 256 call EnvVar_AddFront fRM, 'include', sTkMain'\H;' 257 call EnvVar_AddFront fRM, 'include', sTkMain'\H\GL;' 258 call EnvVar_AddFront fRM, 'include', sTkMain'\SPEECH\H;' 259 call EnvVar_AddFront fRM, 'include', sTkMain'\H\RPC;' 260 call EnvVar_AddFront fRM, 'include', sTkMain'\H\NETNB;' 261 call EnvVar_AddFront fRM, 'include', sTkMain'\H\NETINET;' 262 call EnvVar_AddFront fRM, 'include', sTkMain'\H\NET;' 263 call EnvVar_AddFront fRM, 'include', sTkMain'\H\ARPA;' 264 call EnvVar_AddFront fRM, 'include', sTkMain'\INC;' 265 call EnvVar_AddEnd fRM, 'lib', sTkMain'\SAMPLES\MM\LIB;' 266 call EnvVar_AddEnd fRM, 'lib', sTkMain'\SPEECH\LIB;' 267 call EnvVar_AddFront fRM, 'lib', sTkMain'\lib;' 268 call EnvVar_AddFront fRM, 'helpndx', 'EPMKWHLP.NDX+', '+' 269 call EnvVar_AddFront fRM, 'ipfc', sTkMain'\ipfc;' 270 call EnvVar_Set fRM, 'LANG', 'en_us' 271 call EnvVar_Set fRM, 'CPREF', 'CP1.INF+CP2.INF+CP3.INF' 272 call EnvVar_Set fRM, 'GPIREF', 'GPI1.INF+GPI2.INF+GPI3.INF+GPI4.INF' 273 call EnvVar_Set fRM, 'MMREF', 'MMREF1.INF+MMREF2.INF+MMREF3.INF' 274 call EnvVar_Set fRM, 'PMREF', 'PM1.INF+PM2.INF+PM3.INF+PM4.INF+PM5.INF' 275 call EnvVar_Set fRM, 'WPSREF', 'WPS1.INF+WPS2.INF+WPS3.INF' 276 /* 277 call EnvVar_Set fRM, 'CAT_MACHINE', 'COM1:57600' 278 call EnvVar_Set fRM, 'CAT_HOST_BIN_PATH', TKMAIN'\BIN' 279 call EnvVar_Set fRM, 'CAT_COMMUNICATION_TYPE', 'ASYNC_SIGBRK' 280 call EnvVar_Set fRM, 'CAT_HOST_SOURCE_PATH',TKMAIN'\BIN;' 281 */ 282 283 return 0; 284 285 286 287 /* 288 * IBM Visual Age for C++ v3.08 for OS/2 289 */ 290 VAC30: procedure 291 parse arg fRM 292 293 /* 294 * IBM Visual Age for C++ Version 3.08 main directory. 295 */ 296 sCPPMain = 'c:\appl\os2\ibmcpp30' 297 call EnvVar_Set fRM, 'CPPMAIN', sCPPMain 298 call EnvVar_AddFront fRM, 'beginlibpath', sCPPMain'\DLL;'sCPPMain'\SAMPLES\TOOLKIT\DLL;' 299 call EnvVar_AddFront fRM, 'path', sCPPMain'\BIN;'sCPPMain'\SMARTS\SCRIPTS;'sCPPMain'\HELP;' 300 call EnvVar_AddFront fRM, 'dpath', sCPPMain'\HELP;'sCPPMain';'sCPPMain'\LOCALE;'sCPPMain'\MACROS;'sCPPMain'\BND;' 301 call EnvVar_AddFront fRM, 'help', sCPPMain'\HELP;'sCPPMain'\SAMPLES\TOOLKIT\HELP;' 302 call EnvVar_AddFront fRM, 'bookshelf', sCPPMain'\HELP;' 303 call EnvVar_AddFront fRM, 'somir', sCPPMain'\ETC\SOM.IR;' 304 call EnvVar_AddFront fRM, 'cpphelp_ini', 'C:\OS2\SYSTEM' 305 call EnvVar_AddFront fRM, 'locpath', sCPPMain'\LOCALE;%LOCPATH%;' 306 call EnvVar_AddFront fRM, 'include', sCPPMain'\INCLUDE;'sCPPMain'\INCLUDE\OS2;'sCPPMain'\INC;'sCPPMain'\INCLUDE\SOM;' 307 call EnvVar_AddFront fRM, 'sminclude', sCPPMain'\INCLUDE\OS2;'sCPPMain'\INCLUDE;'sCPPMain'\INCLUDE\SOM;' 308 309 call EnvVar_AddFront fRM, 'vbpath', '.;'sCPPMain'\DDE4VB;' 310 call EnvVar_Set fRM, 'tmpdir', EnvVar_Get('tmp') 311 call EnvVar_Set fRM, 'lxevfref', 'EVFELREF.INF+LPXCREF.INF' 312 call EnvVar_Set fRM, 'lxevfhdi', 'EVFELHDI.INF+LPEXHDI.INF' 313 call EnvVar_AddFront fRM, 'lpath', sCPPMain'\MACROS;' 314 call EnvVar_AddFront fRM, 'codelpath', sCPPMain'\CODE\MACROS;'sCPPMain'\MACROS;' 315 call EnvVar_Set fRM, 'clref', 'CPPCLRF.INF+CPPDAT.INF+CPPAPP.INF+CPPWIN.INF+CPPCTL.INF+CPPADV.INF+CPP2DG.INF+CPPDDE.INF+CPPDM.INF+CPPMM.INF+CPPCLRB.INF' 316 call EnvVar_AddFront fRM, 'ipfc', sCPPMain'\IPFC' 317 call EnvVar_AddFront fRM, 'lib', sCPPMain'\LIB;'sCPPMain'\DLL;' 318 call EnvVar_Set fRM, 'cpplocal', sCPPMain 319 call EnvVar_Set fRM, 'cppmain', sCPPMain 320 call EnvVar_Set fRM, 'cppwork', sCPPMain 321 call EnvVar_Set fRM, 'iwf.default_prj','CPPDFTPRJ' 322 323 call EnvVar_Set fRM, 'iwf.solution_lang_support', 'CPPIBS30;ENG' 324 call EnvVar_Set fRM, 'vacpp_shared' 'FALSE' 325 call EnvVar_Set fRM, 'iwfhelp', 'IWFHDI.INF' 326 call EnvVar_Set fRM, 'iwfopt', sCPPMain 327 328 call EnvVar_Set fRM, 'somruntime', sCPPMain'\DLL' 329 call EnvVar_Set fRM, 'smaddstar', '1' 330 call EnvVar_Set fRM, 'smemit', 'h;ih;c' 331 call EnvVar_Set fRM, 'sombase', sCPPMain 332 call EnvVar_Set fRM, 'smtmp', EnvVar_Get('tmp') 333 call EnvVar_Set fRM, 'smclasses', 'WPTYPES.IDL' 334 335 /* FIXME THESE USES '+' AS SEPERATOR NOT ';'!!! */ 336 call EnvVar_AddFront fRM, 'helpndx', 'EPMKWHLP.NDX+CPP.NDX+CPPBRS.NDX', '+' 337 call EnvVar_AddFront fRM, 'ipf_keys', 'SHOWNAV' 338 return 0; 339 340 341 342 /* 343 * Visual Age / C and C++ tools v3.6.5 for OS/2 344 */ 345 VAC36: procedure 346 parse arg fRM 347 348 /* 349 * IBM C/C++ Compiler and Tools Version 3.6.5 main directory. 350 */ 351 sCxxMain = 'd:\knut\tools\ibmcxxo'; 352 353 call EnvVar_Set fRM, 'cxxmain', sCxxMain; 354 355 call EnvVar_AddFront fRM, 'path', sCxxMain'\bin;' 356 call EnvVar_AddFront fRM, 'dpath', sCxxMain'\local;'sCxxMain'\help;' 357 call EnvVar_AddFront fRM, 'beginlibpath', sCxxMain'\dll;'sCxxMain'\runtime;' 358 call EnvVar_AddFront fRM, 'nlspath', sCxxMain'\msg\%N;' 359 call EnvVar_AddFront fRM, 'include', sCxxMain'\include;' 360 call EnvVar_AddFront fRM, 'lib', sCxxMain'\lib;' 361 call EnvVar_AddFront fRM, 'ipfc', sCxxMain'\ipfc;' 362 call EnvVar_Set fRM, 'LANG', 'en_us' 363 call EnvVar_Set fRM, 'CPP_DBG_LANG', 'CPP' 364 return 0; 365 366 367 368 369 /** 370 * Helper Procedure section 371 **/ 372 373 374 /* 375 * Add sToAdd in front of sEnvVar. 376 * Note: sToAdd now is allowed to be alist! 377 * 378 * Known features: Don't remove sToAdd from original value if sToAdd 379 * is at the end and don't end with a ';'. 380 */ 381 EnvVar_addFront: procedure 382 parse arg fRM, sEnvVar, sToAdd, sSeparator 383 384 /* sets default separator if not specified. */ 385 if (sSeparator = '') then sSeparator = ';'; 386 387 /* checks that sToAdd ends with an ';'. Adds one if not. */ 388 if (substr(sToAdd, length(sToAdd), 1) <> sSeparator) then 389 sToAdd = sToAdd || sSeparator; 390 391 /* check and evt. remove ';' at start of sToAdd */ 392 if (substr(sToAdd, 1, 1) = ';') then 393 sToAdd = substr(sToAdd, 2); 394 395 /* loop thru sToAdd */ 396 rc = 0; 397 i = length(sToAdd); 398 do while i > 1 & rc = 0 399 j = lastpos(sSeparator, sToAdd, i-1); 400 rc = EnvVar_AddFront2(fRM, sEnvVar, substr(sToAdd, j+1, i - j), sSeparator); 401 i = j; 402 end 403 404 return rc; 405 406 /* 407 * Add sToAdd in front of sEnvVar. 408 * 409 * Known features: Don't remove sToAdd from original value if sToAdd 410 * is at the end and don't end with a ';'. 411 */ 412 EnvVar_AddFront2: procedure 413 parse arg fRM, sEnvVar, sToAdd, sSeparator 414 415 /* sets default separator if not specified. */ 416 if (sSeparator = '') then sSeparator = ';'; 417 418 /* checks that sToAdd ends with a separator. Adds one if not. */ 419 if (substr(sToAdd, length(sToAdd), 1) <> sSeparator) then 420 sToAdd = sToAdd || sSeparator; 421 422 /* check and evt. remove the separator at start of sToAdd */ 423 if (substr(sToAdd, 1, 1) = sSeparator) then 424 sToAdd = substr(sToAdd, 2); 425 426 /* Get original variable value */ 427 sOrgEnvVar = EnvVar_Get(sEnvVar); 428 429 /* Remove previously sToAdd if exists. (Changing sOrgEnvVar). */ 430 i = pos(translate(sToAdd), translate(sOrgEnvVar)); 431 if (i > 0) then 432 sOrgEnvVar = substr(sOrgEnvVar, 1, i-1) || substr(sOrgEnvVar, i + length(sToAdd)); 433 434 /* set environment */ 435 if (fRM) then 436 return EnvVar_Set(0, sEnvVar, sOrgEnvVar); 437 return EnvVar_Set(0, sEnvVar, sToAdd||sOrgEnvVar); 438 439 440 /* 441 * Add sToAdd as the end of sEnvVar. 442 * Note: sToAdd now is allowed to be alist! 443 * 444 * Known features: Don't remove sToAdd from original value if sToAdd 445 * is at the end and don't end with a ';'. 446 */ 447 EnvVar_addEnd: procedure 448 parse arg fRM, sEnvVar, sToAdd, sSeparator 449 450 /* sets default separator if not specified. */ 451 if (sSeparator = '') then sSeparator = ';'; 452 453 /* checks that sToAdd ends with a separator. Adds one if not. */ 454 if (substr(sToAdd, length(sToAdd), 1) <> sSeparator) then 455 sToAdd = sToAdd || sSeparator; 456 457 /* check and evt. remove ';' at start of sToAdd */ 458 if (substr(sToAdd, 1, 1) = sSeparator) then 459 sToAdd = substr(sToAdd, 2); 460 461 /* loop thru sToAdd */ 462 rc = 0; 463 i = length(sToAdd); 464 do while i > 1 & rc = 0 465 j = lastpos(sSeparator, sToAdd, i-1); 466 rc = EnvVar_AddEnd2(fRM, sEnvVar, substr(sToAdd, j+1, i - j), sSeparator); 467 i = j; 468 end 469 470 return rc; 471 472 /* 473 * Add sToAdd as the end of sEnvVar. 474 * 475 * Known features: Don't remove sToAdd from original value if sToAdd 476 * is at the end and don't end with a ';'. 477 */ 478 EnvVar_AddEnd2: procedure 479 parse arg fRM, sEnvVar, sToAdd, sSeparator 480 481 /* sets default separator if not specified. */ 482 if (sSeparator = '') then sSeparator = ';'; 483 484 /* checks that sToAdd ends with a separator. Adds one if not. */ 485 if (substr(sToAdd, length(sToAdd), 1) <> sSeparator) then 486 sToAdd = sToAdd || sSeparator; 487 488 /* check and evt. remove separator at start of sToAdd */ 489 if (substr(sToAdd, 1, 1) = sSeparator) then 490 sToAdd = substr(sToAdd, 2); 491 492 /* Get original variable value */ 493 sOrgEnvVar = EnvVar_Get(sEnvVar); 494 495 /* Remove previously sToAdd if exists. (Changing sOrgEnvVar). */ 496 i = pos(translate(sToAdd), translate(sOrgEnvVar)); 497 if (i > 0) then 498 sOrgEnvVar = substr(sOrgEnvVar, 1, i-1) || substr(sOrgEnvVar, i + length(sToAdd)); 499 500 /* checks that sOrgEnvVar ends with a separator. Adds one if not. */ 501 if (substr(sOrgEnvVar, length(sOrgEnvVar), 1) <> sSeparator) then 502 sOrgEnvVar = sOrgEnvVar || sSeparator; 503 504 /* set environment */ 505 if fRM then return EnvVar_Set(0, sEnvVar, sOrgEnvVar); 506 return EnvVar_Set(0, sEnvVar, sOrgEnvVar||sToAdd); 507 508 509 /* 510 * Sets sEnvVar to sValue. 511 */ 512 EnvVar_Set: procedure 513 parse arg fRM, sEnvVar, sValue 514 515 /* if we're to remove this, make valuestring empty! */ 516 if fRM then 517 sValue = ''; 518 sEnvVar = translate(sEnvVar); 519 520 /* 521 * Begin/EndLibpath fix: 522 * We'll have to set internal these using both commandline 'SET' 523 * and internal VALUE in order to export it and to be able to 524 * get it (with EnvVar_Get) again. 525 */ 526 if sEnvVar = 'BEGINLIBPATH' | sEnvVar = 'ENDLIBPATH' then 527 'set' sEnvVar'='sValue; 528 sRc = VALUE(sEnvVar, sValue, 'OS2ENVIRONMENT'); 529 return 0; 530 531 /* 532 * Gets the value of sEnvVar. 533 */ 534 EnvVar_Get: procedure 535 parse arg sEnvVar 536 return value(sEnvVar,, 'OS2ENVIRONMENT'); 537 538
Note:
See TracChangeset
for help on using the changeset viewer.