| 1 | @Rem Author: Jorge <josp.jorge@gmail.com>
|
|---|
| 2 |
|
|---|
| 3 | rem @Echo Off
|
|---|
| 4 | Rem Compila tol y toltcl, el postbuild se encarga de copiar los binarios
|
|---|
| 5 | Rem Copia stdlib hacia ActiveTOL
|
|---|
| 6 | Rem Copia tolbase\toltklib\byswidget, tolbase\lib\ hacia ActiveTOL
|
|---|
| 7 |
|
|---|
| 8 | rem SetLocal enableextensions enabledelayedexpansion
|
|---|
| 9 | Rem Validacion de argumentos
|
|---|
| 10 |
|
|---|
| 11 | Rem procesamiento de opciones de linea de comandos
|
|---|
| 12 | Set _rebuild=0
|
|---|
| 13 | Set _jup=0
|
|---|
| 14 | Set _pnsis=0
|
|---|
| 15 | Set _dotests=0
|
|---|
| 16 | Set _dodist=0
|
|---|
| 17 |
|
|---|
| 18 | Set _plog=!CD!\log2clog.exe
|
|---|
| 19 | Set _fbody=!CD!\test_status\BODY.txt
|
|---|
| 20 |
|
|---|
| 21 | If Not Exist test_status\nul (
|
|---|
| 22 | Md test_status
|
|---|
| 23 | )
|
|---|
| 24 |
|
|---|
| 25 | Rem !!!!!!!!!!!!!!!!!!!!!!!
|
|---|
| 26 |
|
|---|
| 27 | Set _url_bin_=https://www.tol-project.org/win32
|
|---|
| 28 |
|
|---|
| 29 | Set tdt_subject="UPTOL works fine"
|
|---|
| 30 | Set tdt_body=%_fbody%
|
|---|
| 31 | Set tdt_attach=""
|
|---|
| 32 |
|
|---|
| 33 |
|
|---|
| 34 | :READ_OPTS
|
|---|
| 35 | If "%1"=="" Goto END_OPTS
|
|---|
| 36 | If "%1"=="/?" Goto SHOW_HELP
|
|---|
| 37 | If "%1"=="/no_update" (
|
|---|
| 38 | Goto NEXT_OPTS
|
|---|
| 39 | )
|
|---|
| 40 | If "%1"=="/smartbuild" (
|
|---|
| 41 | Set _rebuild=0
|
|---|
| 42 | Goto NEXT_OPTS
|
|---|
| 43 | )
|
|---|
| 44 | If "%1"=="/rebuild" (
|
|---|
| 45 | Set _rebuild=1
|
|---|
| 46 | Goto NEXT_OPTS
|
|---|
| 47 | )
|
|---|
| 48 | If "%1"=="/jup" (
|
|---|
| 49 | Set _jup=1
|
|---|
| 50 | Goto NEXT_OPTS
|
|---|
| 51 | )
|
|---|
| 52 | If "%1"=="/pnsis" (
|
|---|
| 53 | Set _pnsis=1
|
|---|
| 54 | Goto NEXT_OPTS
|
|---|
| 55 | )
|
|---|
| 56 | If "%1"=="/tests" (
|
|---|
| 57 | Set _dotests=1
|
|---|
| 58 | Goto NEXT_OPTS
|
|---|
| 59 | )
|
|---|
| 60 | If "%1"=="/no_tests" (
|
|---|
| 61 | Set _dotests=0
|
|---|
| 62 | Goto NEXT_OPTS
|
|---|
| 63 | )
|
|---|
| 64 | If "%1"=="/dist" (
|
|---|
| 65 | Set _dodist=1
|
|---|
| 66 | Goto NEXT_OPTS
|
|---|
| 67 | )
|
|---|
| 68 | Set _msg_error=Opcion invalida %1
|
|---|
| 69 | Goto ERROR
|
|---|
| 70 | :NEXT_OPTS
|
|---|
| 71 | Shift
|
|---|
| 72 | Goto READ_OPTS
|
|---|
| 73 | :END_OPTS
|
|---|
| 74 |
|
|---|
| 75 | Rem Goto TMP
|
|---|
| 76 | Rem Goto DODIST
|
|---|
| 77 |
|
|---|
| 78 |
|
|---|
| 79 | If "%_rebuild%"=="1" (
|
|---|
| 80 | Set _rbopt=/rebuild
|
|---|
| 81 | )
|
|---|
| 82 |
|
|---|
| 83 | Set ATOLDIR=!CD!\..\ActiveTol\bin
|
|---|
| 84 |
|
|---|
| 85 | Goto BEGIN
|
|---|
| 86 |
|
|---|
| 87 | Rem Ayuda de uso
|
|---|
| 88 | :SHOW_HELP
|
|---|
| 89 | @more README
|
|---|
| 90 | Goto END
|
|---|
| 91 |
|
|---|
| 92 | Rem Codigo de error
|
|---|
| 93 | :ERROR
|
|---|
| 94 | If Not Defined _msg_error (
|
|---|
| 95 | Echo Error invocado sin mensage
|
|---|
| 96 | ) else (
|
|---|
| 97 | Echo %_msg_error%
|
|---|
| 98 | Set tdt_subject="UPTOL works badly"
|
|---|
| 99 | Echo %_msg_error% >> %_fbody%
|
|---|
| 100 | )
|
|---|
| 101 | Pause
|
|---|
| 102 | Goto END
|
|---|
| 103 |
|
|---|
| 104 | Rem Codigo de retorno generico
|
|---|
| 105 | :RET
|
|---|
| 106 | If Defined _ret (
|
|---|
| 107 | Goto %_ret%
|
|---|
| 108 | ) Else (
|
|---|
| 109 | Set _msg_error=Error interno! Punto de retorno no definido.
|
|---|
| 110 | Goto ERROR
|
|---|
| 111 | )
|
|---|
| 112 |
|
|---|
| 113 | Rem Actualiza scripts en ActiveTOL, recibe como argumento
|
|---|
| 114 | Rem - _dir_src, directorio origen
|
|---|
| 115 | Rem - _dir_dest, directorio destino
|
|---|
| 116 | :UP_SCRIPTS
|
|---|
| 117 | If Exist %_dir_dest%\nul (
|
|---|
| 118 | Echo Borrando scripts antiguos de %_dir_dest%
|
|---|
| 119 | Rmdir /S /Q %_dir_dest%
|
|---|
| 120 | )
|
|---|
| 121 | Echo Copiando scripts nuevos de %_dir_src% a %_dir_dest%
|
|---|
| 122 | xcopy %_dir_src% %_dir_dest% /S /F /Y /I /EXCLUDE:exclude.lst
|
|---|
| 123 | If errorlevel 1 (
|
|---|
| 124 | Set _msg_error=Error copiando %_dir_src% hacia %_dir_dest%
|
|---|
| 125 | Goto ERROR
|
|---|
| 126 | )
|
|---|
| 127 | Goto RET
|
|---|
| 128 |
|
|---|
| 129 | Rem Codigo generico de compilacion
|
|---|
| 130 | :COMPILE
|
|---|
| 131 | Rem Verifico que ejecutemos desde el SDK
|
|---|
| 132 | If Not Defined MSSdk (
|
|---|
| 133 | Set _msg_error=Solo se puede compilar desde una consola Microsoft Platform SDK
|
|---|
| 134 | Goto ERROR
|
|---|
| 135 | )
|
|---|
| 136 | If Not Defined _mod (
|
|---|
| 137 | Set _msg_error=Error interno! variable _mod no definida en COMPILE
|
|---|
| 138 | Goto ERROR
|
|---|
| 139 | )
|
|---|
| 140 | If Not Exist ..\..\%_mod%\nul (
|
|---|
| 141 | Set _msg_error=Error interno! el directorio %_mod% debia existir cuando se ha solicitado su compilacion.
|
|---|
| 142 | Goto ERROR
|
|---|
| 143 | )
|
|---|
| 144 | If Not Defined _sln (
|
|---|
| 145 | Set _msg_error=Error interno variable _sln no definida en COMPILE
|
|---|
| 146 | Goto ERROR
|
|---|
| 147 | )
|
|---|
| 148 | If Not Exist ..\..\%_mod%\win-VC8\%_sln% (
|
|---|
| 149 | Set _msg_error=No se puede compilar, el archivo %_mod%\win-VC8\%_sln% no existe
|
|---|
| 150 | Goto ERROR
|
|---|
| 151 | )
|
|---|
| 152 | If "%_vsvars32%"=="" (
|
|---|
| 153 | If Defined VS80COMNTOOLS (
|
|---|
| 154 | call "%VS80COMNTOOLS%vsvars32"
|
|---|
| 155 | If errorlevel 1 (
|
|---|
| 156 | Set _msg_error=No se pudo ejecutar vsvars32
|
|---|
| 157 | Goto ERROR
|
|---|
| 158 | )
|
|---|
| 159 | Set _vsvars32=1
|
|---|
| 160 | ) else (
|
|---|
| 161 | Echo VS80COMNTOOLS no esta definida intentanto vsvars32 desde el PATH
|
|---|
| 162 | call vsvars32
|
|---|
| 163 | If errorlevel 1 (
|
|---|
| 164 | Set _msg_error=No se pudo ejecutar vsvars32
|
|---|
| 165 | Goto ERROR
|
|---|
| 166 | )
|
|---|
| 167 | )
|
|---|
| 168 | ) else (
|
|---|
| 169 | Echo vsvars32 ya ha sido invocado
|
|---|
| 170 | )
|
|---|
| 171 | Rem Verifico postbuild.bat: aseguro que existe. postbuild copia la compilacion a ActiveTOL
|
|---|
| 172 | If Not Exist ..\..\%_mod%\win-VC8\postbuild.bat (
|
|---|
| 173 | xcopy /F /Y postbuild.bat %_mod%\win-VC8
|
|---|
| 174 | )
|
|---|
| 175 | vcbuild %_rbopt% /useenv ..\..\%_mod%\win-VC8\%_sln% "Release|Win32"
|
|---|
| 176 | If errorlevel 1 (
|
|---|
| 177 | Set _msg_error=Fallo en vcbuild con la solucion %_sln%
|
|---|
| 178 | Goto ERROR
|
|---|
| 179 | )
|
|---|
| 180 | Goto RET
|
|---|
| 181 |
|
|---|
| 182 | :CHECK_VARS
|
|---|
| 183 | For %%v in %_vars% do (
|
|---|
| 184 | If Not defined %%v (
|
|---|
| 185 | Echo La variable %%v debe estar definida para compilar %_mod%
|
|---|
| 186 | If Not Defined _msg_extra Goto END
|
|---|
| 187 | If "%_msg_extra%"=="" Goto END
|
|---|
| 188 | Echo %_msg_extra%
|
|---|
| 189 | Pause
|
|---|
| 190 | Goto END
|
|---|
| 191 | )
|
|---|
| 192 | )
|
|---|
| 193 | Goto RET
|
|---|
| 194 |
|
|---|
| 195 | :BEGIN
|
|---|
| 196 |
|
|---|
| 197 | Rem Compilacion de TOL
|
|---|
| 198 | Set _mod=tol
|
|---|
| 199 | Set _sln=gnutol.sln
|
|---|
| 200 | Set _ret=RET_TOLCC
|
|---|
| 201 | Goto COMPILE
|
|---|
| 202 | :RET_TOLCC
|
|---|
| 203 |
|
|---|
| 204 | Rem Compilacion de TOLTCL
|
|---|
| 205 | Rem Verifico que las variable de entorno de TOLTCL esten definidas
|
|---|
| 206 | Set _vars=(TCL_INCLUDE TCL_LIB)
|
|---|
| 207 | Set _msg_extra=TCL_INCLUDE debe apuntar a los include de Tcl. TCL_LIB debe apuntar a las librerias de Tcl.
|
|---|
| 208 | Set _ret=RET_VARTT
|
|---|
| 209 | Goto CHECK_VARS
|
|---|
| 210 | :RET_VARTT
|
|---|
| 211 | Set _mod=toltcl
|
|---|
| 212 | Set _sln=toltcl.sln
|
|---|
| 213 | Set _ret=RET_TTCC
|
|---|
| 214 | Goto COMPILE
|
|---|
| 215 | :RET_TTCC
|
|---|
| 216 |
|
|---|
| 217 | Rem Compilacion de VBTOL
|
|---|
| 218 | If "%_jup%"=="1" Goto RET_VBCC
|
|---|
| 219 | Set _mod=vbtol
|
|---|
| 220 | Set _sln=vbtol.sln
|
|---|
| 221 | Set _ret=RET_VBCC
|
|---|
| 222 | Goto COMPILE
|
|---|
| 223 | :RET_VBCC
|
|---|
| 224 |
|
|---|
| 225 | Rem Compilacion de TOLSH
|
|---|
| 226 | If "%_jup%"=="1" Goto RET_TSHCC
|
|---|
| 227 | PushD ..\..\tolsh
|
|---|
| 228 | call build
|
|---|
| 229 | xcopy /F /Y tolsh.exe !ATOLDIR!
|
|---|
| 230 | PopD
|
|---|
| 231 | :RET_TSHCC
|
|---|
| 232 |
|
|---|
| 233 | If "%_jup%"=="1" Goto END
|
|---|
| 234 |
|
|---|
| 235 | Rem Copio scripts TOL y TCL hacia ActiveTOL
|
|---|
| 236 | If Not Exist ..\ActiveTOL\nul (
|
|---|
| 237 | Echo Directorio ActiveTOL no existente. No se copiaran scripts.
|
|---|
| 238 | Pause
|
|---|
| 239 | Goto END
|
|---|
| 240 | )
|
|---|
| 241 |
|
|---|
| 242 | Rem Copia de stdlib
|
|---|
| 243 | Set _dir_src=..\..\tol\stdlib
|
|---|
| 244 | Set _dir_dest=..\ActiveTOL\bin\stdlib
|
|---|
| 245 | Set _ret=RET_CPTL
|
|---|
| 246 | Goto UP_SCRIPTS
|
|---|
| 247 | :RET_CPTL
|
|---|
| 248 | Rem copiamos pkgIndex.tcl de toltcl
|
|---|
| 249 | xcopy ..\..\toltcl\pkgIndex.tcl ..\ActiveTOL\lib\toltcl\ /F /Y /I
|
|---|
| 250 | If errorlevel 1 (
|
|---|
| 251 | Set _msg_error=Error copiando toltcl\pkgIndex.tcl hacia ActiveTOL
|
|---|
| 252 | Goto ERROR
|
|---|
| 253 | )
|
|---|
| 254 | Rem Copia de scripts tcl, byswidget, toltk y rmtps_client
|
|---|
| 255 | Rem byswidget
|
|---|
| 256 | Set _dir_src=..\..\tolbase\lib\byswidget
|
|---|
| 257 | Set _dir_dest=..\ActiveTOL\lib\byswidget
|
|---|
| 258 | Set _ret=RET_CPBYS
|
|---|
| 259 | Goto UP_SCRIPTS
|
|---|
| 260 | :RET_CPBYS
|
|---|
| 261 | Rem toltk
|
|---|
| 262 | Set _dir_src=..\..\tolbase\lib\toltk
|
|---|
| 263 | Set _dir_dest=..\ActiveTOL\lib\toltk
|
|---|
| 264 | Set _ret=RET_CPTTK
|
|---|
| 265 | Goto UP_SCRIPTS
|
|---|
| 266 | :RET_CPTTK
|
|---|
| 267 | Rem rmtps_client
|
|---|
| 268 | Set _dir_src=..\..\tolbase\lib\rmtps_client
|
|---|
| 269 | Set _dir_dest=..\ActiveTOL\lib\rmtps_client
|
|---|
| 270 | Set _ret=RET_CPRMT
|
|---|
| 271 | Goto UP_SCRIPTS
|
|---|
| 272 | :RET_CPRMT
|
|---|
| 273 |
|
|---|
| 274 | Rem Recupero ficheros perdidos por cualquier causa
|
|---|
| 275 | If Not Exist ..\ActiveTOL\bin\tol.exe (
|
|---|
| 276 | Echo Recuperando ejecutable perdido ..\ActiveTOL\bin\tol.exe
|
|---|
| 277 | copy ..\..\tol\win-VC8\release\tol.exe ..\ActiveTOL\bin\tol.exe
|
|---|
| 278 | )
|
|---|
| 279 | If Not Exist ..\ActiveTOL\bin\tol.dll (
|
|---|
| 280 | Echo Recuperando librería perdida ..\ActiveTOL\bin\tol.dll
|
|---|
| 281 | copy ..\..\tol\win-VC8\release\tol.dll ..\ActiveTOL\bin\tol.dll
|
|---|
| 282 | )
|
|---|
| 283 | If Not Exist ..\ActiveTOL\bin\tolodbc*.dll (
|
|---|
| 284 | Echo Recuperando librería perdida ..\ActiveTOL\bin\tolodbc*.dll
|
|---|
| 285 | copy ..\..\tol\win-VC8\libtolodbc\Release\*.dll ..\ActiveTOL\bin
|
|---|
| 286 | )
|
|---|
| 287 | If Not Exist ..\ActiveTOL\bin\tolmysql*.dll (
|
|---|
| 288 | Echo Recuperando librería perdida ..\ActiveTOL\bin\tolmysql*.dll
|
|---|
| 289 | copy ..\..\tol\win-VC8\libtolmysql\Release\*.dll ..\ActiveTOL\bin
|
|---|
| 290 | )
|
|---|
| 291 | If Not Exist ..\ActiveTOL\bin\tolpgsql*.dll (
|
|---|
| 292 | Echo Recuperando librería perdida ..\ActiveTOL\bin\tolpgsql*.dll
|
|---|
| 293 | copy ..\..\tol\win-VC8\libtolpgsql\Release\*.dll ..\ActiveTOL\bin
|
|---|
| 294 | )
|
|---|
| 295 | If Not Exist ..\ActiveTOL\lib\toltcl\toltcl.dll (
|
|---|
| 296 | Echo Recuperando librería perdida ..\ActiveTOL\lib\toltcl\toltcl.dll
|
|---|
| 297 | copy ..\..\toltcl\win-VC8\Release\toltcl.dll ..\ActiveTOL\lib\toltcl\toltcl.dll
|
|---|
| 298 | )
|
|---|
| 299 | If Not Exist ..\ActiveTOL\bin\vbtol.dll (
|
|---|
| 300 | Echo Recuperando librería perdida ..\ActiveTOL\bin\vbtol.dll
|
|---|
| 301 | copy ..\..\vbtol\win-VC8\Release\vbtol.dll ..\ActiveTOL\bin\vbtol.dll
|
|---|
| 302 | )
|
|---|
| 303 |
|
|---|
| 304 | Rem Ejecuto los tests si me lo han pedido
|
|---|
| 305 | :DO_TESTS
|
|---|
| 306 | If "%_dodist%"=="1" (
|
|---|
| 307 | If "%_dotests%"=="0" (
|
|---|
| 308 | Echo "Forzando los test de tol debido a que se ha solicitado /dist"
|
|---|
| 309 | Set _dotests=1
|
|---|
| 310 | )
|
|---|
| 311 | )
|
|---|
| 312 |
|
|---|
| 313 | If "%_dotests%"=="1" (
|
|---|
| 314 | If Exist ..\ActiveTOL\bin\tol.exe (
|
|---|
| 315 | If Not Exist test_status (
|
|---|
| 316 | Md test_status
|
|---|
| 317 | ) Else (
|
|---|
| 318 | Del /Q test_status\*.*
|
|---|
| 319 | )
|
|---|
| 320 | Set _tst_cd=!CD!\test_status
|
|---|
| 321 | PushD ..\ActiveTOL\bin
|
|---|
| 322 | Echo Ejecutando Tol standard tests ...
|
|---|
| 323 | echo %CD%\\test_status\
|
|---|
| 324 |
|
|---|
| 325 | tol.exe -v -c"Text DupTestIndicatorPath=\"%CD%\\test_status\"" "..\\..\\..\\tol_tests\\tol\\_tolTester.tol">!_tst_cd!\init.log
|
|---|
| 326 | PopD
|
|---|
| 327 | If Exist test_status\FAIL.txt (
|
|---|
| 328 | Set test_status=FAIL
|
|---|
| 329 | Set tdt_subject="ERROR ejecutando TOL_TESTS"
|
|---|
| 330 | Set tdt_body="La ejecucion de TOL_TESTS genero el archivo de estado FAIL.txt. No se ha actualizado Tolbase en %_url_bin_%."
|
|---|
| 331 | Set tdt_attach=test_status\FAIL.txt
|
|---|
| 332 | ) Else If Exist test_status\WARNING.txt (
|
|---|
| 333 | Set test_status=WARNING
|
|---|
| 334 | Set tdt_subject="Version %_branchid% actualizada, WARNING ejecutando TOL_TESTS"
|
|---|
| 335 | Set tdt_body=test_status\BODY.txt
|
|---|
| 336 | Set tdt_attach=test_status\WARNING.txt
|
|---|
| 337 | ) Else If Exist test_status\OK.txt (
|
|---|
| 338 | Set test_status=OK
|
|---|
| 339 | Set tdt_subject="Version %_branchid% actualizada, OK ejecutando TOL_TESTS"
|
|---|
| 340 | Set tdt_body=test_status\BODY.txt
|
|---|
| 341 | Set tdt_attach=test_status\OK.txt
|
|---|
| 342 | ) Else (
|
|---|
| 343 | Set test_status=FAIL
|
|---|
| 344 | Set tdt_subject="ERROR ejecutando TOL_TEST"
|
|---|
| 345 | Echo TOL_TEST no genero archivo de estado, verifique manualmente /tests>>%_fbody%
|
|---|
| 346 | Echo.>>%_fbody%
|
|---|
| 347 | Echo COMPUTERNAME = %COMPUTERNAME%>>%_fbody%
|
|---|
| 348 | Echo USERNAME = %USERNAME%>>%_fbody%
|
|---|
| 349 | Echo BRANCHID = ""RAMA SVN"
|
|---|
| 350 | Echo.>>%_fbody%
|
|---|
| 351 | Echo Se ha adjuntado el log de inicializacion de TOL.>>%_fbody%
|
|---|
| 352 | Set tdt_body=test_status\BODY.txt
|
|---|
| 353 | Set tdt_attach=test_status\init.log
|
|---|
| 354 | )
|
|---|
| 355 | ) Else (
|
|---|
| 356 | Set _msg_error=No se encuentra ..ºActiveTOL\bin\tol.exe necesario para ejecutar los tests de TOL
|
|---|
| 357 | Goto ERROR
|
|---|
| 358 | )
|
|---|
| 359 | )
|
|---|
| 360 | If "%test_status%"=="FAIL" (
|
|---|
| 361 | Echo TOL_TESTS finalizo con errores, chequee %CD%\test_status
|
|---|
| 362 | Goto SENDMAIL
|
|---|
| 363 | )
|
|---|
| 364 |
|
|---|
| 365 |
|
|---|
| 366 | Rem empaco la distribucion de tolbase si me lo han pedido
|
|---|
| 367 | If "%_dodist%"=="1" (
|
|---|
| 368 | If Not Exist ..\NSIS\Tolbase*.exe (
|
|---|
| 369 | Echo ..\NSIS\Tolbase*.exe no existe
|
|---|
| 370 | If Not "%_pnsis%"=="1" (
|
|---|
| 371 | Echo Habilitando /pnsis para poder hacer /dist
|
|---|
| 372 | Set _pnsis=1
|
|---|
| 373 | )
|
|---|
| 374 | )
|
|---|
| 375 | )
|
|---|
| 376 | Set _cwd=%CD%
|
|---|
| 377 | If "%_pnsis%"=="1" (
|
|---|
| 378 |
|
|---|
| 379 | Echo Generando el archivo de creación del instalador de tolbase ...
|
|---|
| 380 | ..\ActiveTOL\bin\tol -v ..\NSIS\Tolbase.nsi.generate.tol
|
|---|
| 381 | If Not Exist ..\NSIS\Tolbase.nsi (
|
|---|
| 382 | Set _msg_error=El empaquetado de tolbase ..ºNSIS\Tolbase.nsi no existe.
|
|---|
| 383 | Goto ERROR
|
|---|
| 384 | )
|
|---|
| 385 | If Exist ..\NSIS\Tolbase*.exe (
|
|---|
| 386 | Del /Q ..\NSIS\Tolbase*.exe
|
|---|
| 387 | )
|
|---|
| 388 | Echo Creando instalador de tolbase ...
|
|---|
| 389 | makensis /V2 /X"SetCompressor /FINAL /SOLID lzma" ..\NSIS\Tolbase.nsi
|
|---|
| 390 | If Exist ..\NSIS\Tolbase*.exe (
|
|---|
| 391 | Echo El instalador de Tolbase ha sido creado en "%_cwd%\..\NSIS"
|
|---|
| 392 | ) Else (
|
|---|
| 393 | Set _msg_error=No se ha encontrado el resultado de ejecutar makensis
|
|---|
| 394 | Goto ERROR
|
|---|
| 395 | )
|
|---|
| 396 | )
|
|---|
| 397 |
|
|---|
| 398 | :DODIST
|
|---|
| 399 | Rem envio el empaquetado hacia www.tol-project.org si se ha pedido
|
|---|
| 400 | Echo status es %test_status%
|
|---|
| 401 | If "%_dodist%"=="1" (
|
|---|
| 402 | If Exist ..\NSIS\Tolbase*.exe (
|
|---|
| 403 | For %%f In (..\NSIS\Tolbase*.exe) Do (
|
|---|
| 404 | Echo encontrado %%~nxf
|
|---|
| 405 | Set _fbin=%%~nxf
|
|---|
| 406 | )
|
|---|
| 407 | REM echo Creando el tag automatico correspondiente al empaquetado
|
|---|
| 408 | cd ..\NSIS
|
|---|
| 409 | REM ..\ActiveTOL\bin\tol -v create_tag_build.tol
|
|---|
| 410 | REM call create_tag_build.bat
|
|---|
| 411 | REM Echo copiando last_official_tol_release_win.txt hacia www.tol-project.org
|
|---|
| 412 | REM ..\ActiveTOL\bin\tol -v -c"Text WriteFile(\"last_official_tol_release_win.txt\",Version);"
|
|---|
| 413 | REM pscp last_official_tol_release_win.txt toldevel@tolp.localbayes.es:.
|
|---|
| 414 | Echo copiando Tolbase hacia www.tol-project.org
|
|---|
| 415 | pscp Tolbase*.exe toldevel@tolp.localbayes.es:/var/www/packages/win32/.
|
|---|
| 416 | If "%_branchid%"=="REMtrunkREM" (
|
|---|
| 417 | Echo copiando tolbase-%_versionNumber%-setup.exe como tolbase-cvstrunk-setup.exe en www.tol-project.org
|
|---|
| 418 | plink tdt@cvs.tol-project.org "cp /home/bayes/pub/bin/win/tolbase-%_versionNumber%-setup.exe /home/bayes/pub/bin/win/tolbase-cvstrunk-setup.exe"
|
|---|
| 419 | )
|
|---|
| 420 | REM Echo Moviendo el empaquetado a la carpeta de almacenamiento historico
|
|---|
| 421 | REM ..\ActiveTOL\bin\tol -v store_history.tol
|
|---|
| 422 | cd..
|
|---|
| 423 | GOTO END
|
|---|
| 424 | REM Echo Nueva version %_branchid% disponible en %_url_bin_%/!_fbin!>test_status\BODY.txt
|
|---|
| 425 | Echo.>>%_fbody%
|
|---|
| 426 | Echo El resultado de tol_tests esta disponible en el archivo adjunto.>>%_fbody%
|
|---|
| 427 | Echo.>>%_fbody%
|
|---|
| 428 | ) Else (
|
|---|
| 429 | Echo No se puede enviar Tolbase hacia www.tol-project.exe pues no existe en NSIS
|
|---|
| 430 | Set _msg_error=Utilice /pnsis para construirlo
|
|---|
| 431 | Goto ERROR
|
|---|
| 432 | )
|
|---|
| 433 | ) Else (
|
|---|
| 434 | Goto END
|
|---|
| 435 | )
|
|---|
| 436 |
|
|---|
| 437 | GOTO END
|
|---|
| 438 |
|
|---|
| 439 | :MAILTDT
|
|---|
| 440 | If Not Defined _lastup (
|
|---|
| 441 | Echo.>>%_fbody%
|
|---|
| 442 | Echo Variable interna _lastup con la fecha de la ultima actualizacion no esta definida.>>%_fbody%
|
|---|
| 443 | Echo No se podra generar el reporte de cambios.>>%_fbody%
|
|---|
| 444 | Echo Verifique .cvsopts.bat>>%_fbody%
|
|---|
| 445 | Goto SENDMAIL
|
|---|
| 446 | )
|
|---|
| 447 | Echo Los cambios desde la fecha %_lastup% son los siguientes:>>%_fbody%
|
|---|
| 448 | Rem Log de TOL
|
|---|
| 449 | Set _mod=tol
|
|---|
| 450 | Set _ret=RET_TOLLOG
|
|---|
| 451 | Goto CVS_GENLOG
|
|---|
| 452 | :RET_TOLLOG
|
|---|
| 453 | Rem Log de TOLTCL
|
|---|
| 454 | Set _mod=toltcl
|
|---|
| 455 | Set _ret=RET_TTLOG
|
|---|
| 456 | Goto CVS_GENLOG
|
|---|
| 457 | :RET_TTLOG
|
|---|
| 458 | Rem Log de VBTOL
|
|---|
| 459 | Set _mod=vbtol
|
|---|
| 460 | Set _ret=RET_VBLOG
|
|---|
| 461 | Goto CVS_GENLOG
|
|---|
| 462 | :RET_VBLOG
|
|---|
| 463 | Rem Log de TOLBASE
|
|---|
| 464 | Set _mod=tolbase
|
|---|
| 465 | Set _ret=RET_TBLOG
|
|---|
| 466 | Goto CVS_GENLOG
|
|---|
| 467 | :RET_TBLOG
|
|---|
| 468 | Rem Log de TOL_TESTS
|
|---|
| 469 | Set _mod=tol_tests
|
|---|
| 470 | Set _ret=RET_TTSTLOG
|
|---|
| 471 | Goto CVS_GENLOG
|
|---|
| 472 | :RET_TTSTLOG
|
|---|
| 473 | Rem Actualizo la fecha de ultima actualizacion exitosa
|
|---|
| 474 | Echo Set _lastup=%DATE:~6,4%-%DATE:~3,2%-%DATE:~0,2%>>.cvsopts.bat
|
|---|
| 475 |
|
|---|
| 476 | :SENDMAIL
|
|---|
| 477 | mailtdt %tdt_subject% %tdt_body% %tdt_attach%
|
|---|
| 478 | :END
|
|---|
| 479 | Rem Limpia variables d entorno
|
|---|
| 480 | EndLocal
|
|---|