Release script improvements.
This commit is contained in:
@@ -1,82 +0,0 @@
|
||||
rem Uncomment the next line to set the version; used also in wxWidgets.iss
|
||||
SET WXW_VER=3.1.0
|
||||
if (%WXW_VER%)==() SET WXW_VER=git
|
||||
|
||||
echo docs building for %WXW_VER%
|
||||
|
||||
rem This builds the docs in %WXWIN% in a number of formats
|
||||
rem and a clean inno setup in a second tree
|
||||
rem it uses a number of tools, gnuwin32 zip & dos2unix,
|
||||
rem writes a log file in c:\
|
||||
|
||||
echo Building wxWidgets-%WXW_VER% docs... > c:\temp.log
|
||||
|
||||
set WXWIN=c:\wx\wxWidgets
|
||||
set DAILY=c:\daily
|
||||
set INNO=c:\wx\inno\wxWidgets
|
||||
|
||||
rem svn already in my path...
|
||||
set PATH=%PATH%;c:\wx\Gnu\bin;c:\progra~1\htmlhe~1;C:\PROGRA~1\INNOSE~1;c:\wx\doxygen\bin
|
||||
set PATH=%PATH%;C:\wx\Graphviz\bin
|
||||
echo %PATH% >> c:\temp.log
|
||||
|
||||
|
||||
rem update wxwidgets (holds docs) and inno (wxMSW setup.exe only)
|
||||
c:
|
||||
cd %WXWIN%
|
||||
svn cleanup >> c:\temp.log
|
||||
svn up >> c:\temp.log
|
||||
|
||||
rem now inno
|
||||
cd %INNO% >> c:\temp.log
|
||||
rem Don't update the svn automatically
|
||||
rem svn cleanup >> c:\temp.log
|
||||
rem svn up >> c:\temp.log
|
||||
|
||||
if exist include\wx\msw\setup.h del include\wx\msw\setup.h
|
||||
if exist include\wx\univ\setup.h del include\wx\univ\setup.h
|
||||
|
||||
del c*.*
|
||||
svn up configure
|
||||
svn up configure.in
|
||||
svn up config.guess
|
||||
svn up config.sub
|
||||
dos2unix configure
|
||||
dos2unix config.guess
|
||||
dos2unix config.sub
|
||||
copy include\wx\msw\setup0.h include\wx\msw\setup.h
|
||||
copy include\wx\univ\setup0.h include\wx\univ\setup.h
|
||||
echo SVN update >> c:\temp.log
|
||||
|
||||
rem make chm
|
||||
rem Now create standalone copies of docs (chm and htb)
|
||||
cd %WXWIN%\docs\doxygen
|
||||
del out\html\*.html
|
||||
del out\html\*.htb
|
||||
del out\html\*.zip
|
||||
del out\*.chm
|
||||
call regen chm
|
||||
|
||||
|
||||
cd %WXWIN%\docs\doxygen\out
|
||||
zip wxWidgets-%WXW_VER%-docs-chm.zip wx.chm
|
||||
copy wxWidgets-%WXW_VER%-docs-chm.zip %DAILY%
|
||||
cd html
|
||||
del *.dot
|
||||
del *.md5
|
||||
zip -r wx.htb *.*
|
||||
copy wx.htb %DAILY%\wxWidgets-%WXW_VER%-docs-html.zip
|
||||
zip wxWidgets-%WXW_VER%-docs-htb.zip wx.htb
|
||||
copy wxWidgets-%WXW_VER%-docs-htb.zip %DAILY%
|
||||
|
||||
|
||||
mkdir %INNO%\docs\htmlhelp
|
||||
copy %WXWIN%\docs\doxygen\out\wx.chm %INNO%\docs\htmlhelp\wx.chm
|
||||
cd %WXWIN%\build\tools
|
||||
iscc wxwidgets.iss >> c:\temp.log
|
||||
copy %INNO%\..\wxMSW-%WXW_VER%-Setup.exe c:\daily
|
||||
|
||||
echo docs built for %WXW_VER%
|
||||
echo docs built for %WXW_VER% >> c:\temp.log
|
||||
|
||||
|
@@ -1,30 +0,0 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# This script creates archives of HTML documentation in tar.bz2 and zip
|
||||
# formats. It relies on docs/doxygen/regen.sh to really generate the docs.
|
||||
#
|
||||
# The script should be ran from the root of wxWidgets checkout and creates the
|
||||
# output files in its parent directory.
|
||||
|
||||
version=$1
|
||||
if [ -z "$version" ]; then
|
||||
echo "Must specify the distribution version." >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
set -e
|
||||
set -x
|
||||
|
||||
docs_dir_name=wxWidgets-$version
|
||||
docs_file_basename=wxWidgets-$version-docs-html
|
||||
|
||||
cd docs/doxygen
|
||||
./regen.sh html
|
||||
cd out
|
||||
mv html $docs_dir_name
|
||||
tar cjf ../../../../$docs_file_basename.tar.bz2 $docs_dir_name
|
||||
cd $docs_dir_name
|
||||
zip -q -r ../../../../../$docs_file_basename.zip .
|
||||
|
||||
cd ..
|
||||
mv $docs_dir_name html
|
71
build/tools/release.bat
Normal file
71
build/tools/release.bat
Normal file
@@ -0,0 +1,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%"
|
@@ -6,11 +6,7 @@
|
||||
# distribution and we don't need to maintain the list of them ourselves but we
|
||||
# also don't run the risk of including anything unwanted.
|
||||
#
|
||||
# To summarize, here are the steps to create the release:
|
||||
#
|
||||
# % git tag vX.Y.Z -m 'Tag X.Y.Z release.'
|
||||
# % ./build/tools/git-make-release.sh X.Y.Z
|
||||
# % ... upload ../wxWidgets-X.Y.Z.{7z,tar.bz2,zip} ...
|
||||
# See docs/contributing/how-to-release.md for usage instructions.
|
||||
|
||||
version=$1
|
||||
if [ -z "$version" ]; then
|
||||
@@ -18,6 +14,9 @@ if [ -z "$version" ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
root="$(readlink -f $(dirname $(readlink -f $0))/../..)"
|
||||
cd "$root"
|
||||
|
||||
if ! git diff --quiet; then
|
||||
echo "Working copy has modifications, commit or stash them." >&2
|
||||
exit 2
|
||||
@@ -27,18 +26,19 @@ set -e
|
||||
set -x
|
||||
|
||||
prefix=wxWidgets-$version
|
||||
destdir=$(dirname $(readlink -f $0))/../../../$prefix
|
||||
destdir="$root/distrib/release/$version"
|
||||
|
||||
cleanup() {
|
||||
rm -rf $destdir
|
||||
rm -rf $destdir/$prefix
|
||||
}
|
||||
|
||||
trap cleanup INT TERM EXIT
|
||||
|
||||
cleanup
|
||||
|
||||
git archive --prefix=$prefix/ HEAD | (cd ..; tar x)
|
||||
cd ..
|
||||
mkdir -p $destdir
|
||||
git archive --prefix=$prefix/ HEAD | (cd $destdir; tar x)
|
||||
cd $destdir
|
||||
# All setup0.h files are supposed to be renamed to just setup.h when checked
|
||||
# out and in the distribution.
|
||||
find $prefix/include/wx -type f -name setup0.h | while read f; do
|
||||
@@ -56,3 +56,16 @@ zip -q -r ../$prefix.zip .
|
||||
|
||||
7z a ../$prefix.7z . >/dev/null
|
||||
7z a ../${prefix}-headers.7z include >/dev/null
|
||||
|
||||
# Build HTML documentation packages.
|
||||
prefix_docs=$prefix-docs-html
|
||||
cd "$root/docs/doxygen"
|
||||
rm -rf out
|
||||
./regen.sh html
|
||||
cd out
|
||||
mv html "$prefix_docs"
|
||||
tar cjf "$destdir/$prefix_docs.tar.bz2" "$prefix_docs"
|
||||
cd "$prefix_docs"
|
||||
zip -q -r "$destdir/$prefix_docs.zip" .
|
||||
cd "$root"
|
||||
rm -rf "$root/docs/doxygen/out"
|
@@ -7,9 +7,9 @@
|
||||
#define WXW_DIR "..\.."
|
||||
#endif
|
||||
|
||||
#if GetEnv("WXW_VER") == "git"
|
||||
#define INFOFILE WXW_DIR + "\BuildGit.txt"
|
||||
#define WX_VERSION "SVN"
|
||||
#if GetEnv("WXW_VER") == "Snapshot"
|
||||
#define INFOFILE WXW_DIR + "\BuildGit.txt"
|
||||
#define WX_VERSION "Snapshot"
|
||||
#elif GetEnv("WXW_VER") != ""
|
||||
#define INFOFILE WXW_DIR + "\docs\msw\install.txt"
|
||||
#define WX_VERSION GetEnv("WXW_VER")
|
||||
|
Reference in New Issue
Block a user