* Add IdeBplInstall executable to be used from a batch file.

* Add a batch file which installs design-time components.
* Bugfix build_super; going to the end of a batch file to exit it when inside a batch procedure does not work.
* Rename batch scripts so they appear in the directory in the order they are to be used in (1. compile, 2. install ide components, 3. generate installer relevant stuff).
This commit is contained in:
rosenfield
2007-10-22 15:34:17 +00:00
parent 058cd04d97
commit 4f5108ff1c
4 changed files with 151 additions and 2 deletions

View File

Binary file not shown.

View File

@@ -5,7 +5,7 @@ if not %errorlevel% == 0 goto extensions_failure
setlocal enabledelayexpansion 2>nul:
if not %errorlevel% == 0 goto delayexpansion_failure
goto test_dcc32
goto tool_tests
:extensions_failure
echo Error: Your command interpreter (cmd.exe) does not support
@@ -21,6 +21,8 @@ echo delayed variable expansion. This is not currently a requirement
echo for this build script, but may be in the future.
echo.
:tool_tests
:test_dcc32
dcc32.exe --version >NUL: 2>NUL:
if %errorlevel% == 0 goto test_svn
@@ -155,7 +157,7 @@ goto build
echo Compiling component %1, package %2.
cd /d "%base_dir%\components\%1\packages\%package_dir%\"
"%compiler%" %params% %2.dpk
if not %errorlevel% == 0 goto end
set err=%errorlevel%
echo.
goto :eof
@@ -164,34 +166,48 @@ echo.
rem Build EDBImage
call :compile edbimage VCLSer
if not %err% == 0 goto end
call :compile edbimage DCLSer
if not %err% == 0 goto end
rem Build SMDBGrid
call :compile smdbgrid SMDBGridComponents
if not %err% == 0 goto end
rem Build SynEdit
call :compile synedit SynEditR
if not %err% == 0 goto end
call :compile synedit SynEditD
if not %err% == 0 goto end
rem Build ZeosDBO
call :compile zeosdbo ZCore
if not %err% == 0 goto end
call :compile zeosdbo ZPlain
if not %err% == 0 goto end
call :compile zeosdbo ZParseSql
if not %err% == 0 goto end
call :compile zeosdbo ZDbc
if not %err% == 0 goto end
call :compile zeosdbo ZComponent
if not %err% == 0 goto end
call :compile zeosdbo ZComponentDesign
if not %err% == 0 goto end
rem Build HeidiComponents
call :compile heidisql HeidiComponents
if not %err% == 0 goto end
rem Build VirtualTreeView
call :compile virtualtreeview VirtualTreesR
if not %err% == 0 goto end
call :compile virtualtreeview VirtualTreesD
if not %err% == 0 goto end
rem Build main executable

View File

@@ -0,0 +1,133 @@
@echo off
setlocal enableextensions 2>nul:
if not %errorlevel% == 0 goto extensions_failure
setlocal enabledelayexpansion 2>nul:
if not %errorlevel% == 0 goto delayexpansion_failure
goto tool_tests
:extensions_failure
echo Error: Your command interpreter (cmd.exe) does not support
echo command processor extensions. This is a requirement for
echo this build script to work. Please upgrade your command processor.
echo.
pause > NUL:
goto :eof
:delayexpansion_failure
echo Notice: Your command interpreter (cmd.exe) does not support
echo delayed variable expansion. This is not currently a requirement
echo for this build script, but may be in the future.
echo.
:tool_tests
:test_dcc32
dcc32.exe --version >NUL: 2>NUL:
if %errorlevel% == 0 goto test_libs
:dcc32_not_found
echo Error: Delphi compiler 'dcc32.exe' was not found in PATH.
echo.
echo Please install Delphi. When installing, Delphi should modify
echo your system path to include the location of this file.
echo.
echo See also:
echo http://www.codegear.com/downloads/free/delphi
echo.
pause > NUL:
goto :eof
:locate_dcc32
if not "%compiler_dir%" == "none" goto :eof
pushd %~f1
if exist dcc32.exe set compiler_dir=found
if "%compiler_dir%" == "found" cd ..
if "%compiler_dir%" == "found" set compiler_dir=%CD%
popd
goto :eof
:test_libs
SET compiler_dir=none
for %%p in ("%PATH:;=" "%") do call :locate_dcc32 %%p
if "%compiler_dir%" == "none" (goto dcc32_not_found) else (goto test_packages)
:test_packages
set package_suffix=none
dcc32.exe --version | find "18.0" >NUL:
if %errorlevel% == 0 set package_suffix=100
dcc32.exe --version | find "18.5" >NUL:
if %errorlevel% == 0 set package_suffix=110
if "%package_suffix%" == "none" (goto unknown_version) else (goto init)
:unknown_version
echo Error: Unknown version of Delphi compiler 'dcc32.exe'!
echo.
echo At present, only Delphi 10 (Borland Developer Studio 2006)
echo and Delphi 11 (CodeGear Delphi 2007).
echo.
echo Please install one of those...
echo.
echo If you think you are receiving this message in error,
echo please inform the developers at heidisql-devel@sourceforge.net.
echo.
pause >NUL:
goto :eof
:init
set start_dir=%CD%
cd ..
set base_dir=%CD%
echo Base directory: %base_dir%
echo Package suffix: %package_suffix%
goto :start
:install
echo Installing component %1, package %2%package_suffix%.bpl.
%start_dir%\IdeBplInstall\IdeBplInstall.exe "%base_dir%\components\%1\build\%2%package_suffix%.bpl" "%1"
set err=%errorlevel%
echo.
goto :eof
:start
echo.
rem Install EDBImage
call :install edbimage DCLSer
if not %err% == 0 goto end
rem Install SMDBGrid
call :install smdbgrid SMDBGridComponents
if not %err% == 0 goto end
rem Install SynEdit
call :install synedit SynEditD
if not %err% == 0 goto end
rem Install ZeosDBO
call :install zeosdbo ZComponentDesign
if not %err% == 0 goto end
rem Install HeidiComponents
call :install heidisql HeidiComponents
if not %err% == 0 goto end
rem Install VirtualTreeView
call :install virtualtreeview VirtualTreesD
if not %err% == 0 goto end
echo.
echo Finished.
echo.
:end
cd /d "%start_dir%" 2>NUL: