File: release.bat

package info (click to toggle)
wxpython4.0 4.2.0%2Bdfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 232,540 kB
  • sloc: cpp: 958,937; python: 233,059; ansic: 150,441; makefile: 51,662; sh: 8,687; perl: 1,563; javascript: 584; php: 326; xml: 200
file content (71 lines) | stat: -rw-r--r-- 1,752 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
@echo off
setlocal enabledelayedexpansion

rem This script builds the CHM manual and the Windows installer for release.

if "%1" == "" (
    echo You must specify a release version.
    exit /b 1
)

pushd "%~dp0..\.."

set root=%cd%
set version=%1
set prefix=wxWidgets-%1
set release_path=%root%\distrib\release\%version%

where /q 7z
if %ERRORLEVEL% neq 0 (
    echo Error: 7-Zip was not found in your PATH.
    exit /b 1
)
where /q dot
if %ERRORLEVEL% neq 0 (
    echo Error: GraphViz was not found in your PATH.
    exit /b 1
)
where /q doxygen
if %ERRORLEVEL% neq 0 (
    echo Error: Doxygen was not found in your PATH.
    exit /b 1
)
where /q hhc
if %ERRORLEVEL% neq 0 (
    echo Error: HTML Help Workshop was not found in your PATH.
    exit /b 1
)
where /q iscc
if %ERRORLEVEL% neq 0 (
    echo Error: Inno Setup was not found in your PATH.
    exit /b 1
)

if not exist "%release_path%\%prefix%.zip" (
    echo Error: Release ZIP package not found: %release_path%\%prefix%.zip
    exit /b 1
)

pushd "%root%\docs\doxygen"
echo Building the CHM manual...
call regen.bat chm
if %errorlevel% neq 0 exit /b %errorlevel%
copy out\wx.chm "%release_path%\%prefix%.chm"
popd

if exist "%release_path%\%prefix%" rd /s /q "%release_path%\%prefix%"
md "%release_path%\%prefix%"
pushd "%release_path%\%prefix%"
echo Extracting release ZIP for installer...
7z x "..\%prefix%.zip"
if %errorlevel% neq 0 exit /b %errorlevel%
md docs\htmlhelp
copy "..\%prefix%.chm" docs\htmlhelp\wx.chm
set WXW_VER=%1
echo Building the installer...
iscc /Qp build\tools\wxwidgets.iss
if %errorlevel% neq 0 exit /b %errorlevel%
popd

echo Cleaning up installer files...
rd /s /q "%release_path%\%prefix%"