3
3
REM ---------------------------------------------------------------
4
4
REM -- Post-Build Script
5
5
REM ---------------------------------------------------------------
7
7
REM Copy engine data, themes, translation and required dlls to the
8
REM output folder and optionally create an installer
10
10
REM Expected parameters
15
REM Installer ("1" to build, "0" to skip)
16
17
if "%~1"=="" goto error_root
17
18
if "%~2"=="" goto error_output
18
19
if "%~3"=="" goto error_arch
19
20
if "%~4"=="" goto error_libs
21
if "%~5"=="" goto error_installer
21
23
echo Copying data files
25
xcopy /F /Y "%~1/dists/engine-data/*.dat" %~2 > NUL 2>&1
26
xcopy /F /Y "%~1/dists/engine-data/*.tbl" %~2 > NUL 2>&1
27
xcopy /F /Y "%~1/dists/engine-data/*.cpt" %~2 > NUL 2>&1
28
xcopy /F /Y "%~1/dists/engine-data/README" %~2 > NUL 2>&1
29
xcopy /F /Y "%~1/gui/themes/*.zip" %~2 > NUL 2>&1
30
xcopy /F /Y "%~1/gui/themes/translations.dat" %~2 > NUL 2>&1
31
xcopy /F /Y "%~4/lib/%~3/SDL.dll" %~2 > NUL 2>&1
33
xcopy /F /Y "%~1/backends/vkeybd/packs/vkeybd_default.zip" %~2 > NUL 2>&1
26
xcopy /F /Y "%~4/lib/%~3/SDL.dll" "%~2" 1>NUL 2>&1
27
xcopy /F /Y "%~1/backends/vkeybd/packs/vkeybd_default.zip" "%~2" 1>NUL 2>&1
29
if "%~5"=="0" goto done
31
echo Running installer script
33
@call cscript "%~1/devtools/create_project/scripts/installer.vbs" "%~1" "%~2" "%~3" 1>NUL
34
if not %errorlevel% == 0 goto error_script