-
Notifications
You must be signed in to change notification settings - Fork 0
/
jenkins-configure-and-build.bat
92 lines (60 loc) · 3.19 KB
/
jenkins-configure-and-build.bat
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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
@echo off
echo "*** Running jenkins-configure-and-build.bat..."
REM ===========================================================================
REM Configure environment on Jenkins machine
REM ===========================================================================
call "%~dp0"jenkins-custom.bat
REM ===========================================================================
REM Copy and unpack 3-rd parties
REM ===========================================================================
mkdir 3rd-parties-arc
echo "*** Copying the 3-rd parties %JENKINS_3RDPARTIES_ARCHIVE_DIR%\%JENKINS_3RDPARTIES_ARCHIVE%"
copy %JENKINS_3RDPARTIES_ARCHIVE_DIR%\%JENKINS_3RDPARTIES_ARCHIVE% 3rd-parties-arc
copy %JENKINS_3RDPARTIES_ARCHIVE_DIR%\%JENKINS_3RDPARTIES_FBX_ARCHIVE% 3rd-parties-arc
copy %JENKINS_3RDPARTIES_ARCHIVE_DIR%\7z.dll 3rd-parties-arc
copy %JENKINS_3RDPARTIES_ARCHIVE_DIR%\7z.exe 3rd-parties-arc
copy jenkins-install-products.bat 3rd-parties-arc
cd 3rd-parties-arc
call "jenkins-install-products.bat" ..\3rd-parties
cd ..
set "JENKINS_3RDPARTIES=%~dp03rd-parties"
REM ===========================================================================
REM Configure environment
REM ===========================================================================
set "JENKINS_JOB_DIR=%~dp0"
echo JENKINS_JOB_DIR: %JENKINS_JOB_DIR%
set "ASI_DOCS=%~dp0docs/www"
REM ===========================================================================
REM Prepare build and install directories for CMake
REM ===========================================================================
echo Create cmake-build-dir and cmake-install-dir
mkdir cmake-build-dir
mkdir cmake-install-dir
REM ===========================================================================
REM Run CMake from build directory: configure
REM ===========================================================================
cd cmake-build-dir
echo "*** Running CMake configuration..."
"%JENKINS_CMAKE_BIN%\cmake.exe" -G"Visual Studio 16 2019" -A x64 -DCMAKE_BUILD_TYPE=Release ^
-DUSE_CONSOLE=true -DUSE_THREADING=false -DUSE_RAPIDJSON=true -DUSE_FBX_SDK=true -DUSE_MOBIUS=true -DUSE_NETGEN=false ^
-DDISTRIBUTION_GENERATE_DOC=false ^
-D3RDPARTY_mobius_DIR=%JENKINS_3RDPARTIES_MOBIUS_DIR% ^
-D3RDPARTY_DIR:PATH=%JENKINS_3RDPARTIES% -DINSTALL_DIR:PATH=../cmake-install-dir ../
REM ===========================================================================
REM CMake build and install
REM ===========================================================================
echo "*** Running compilation in Release mode..."
"%JENKINS_CMAKE_BIN%\cmake.exe" --build . --config Release --target INSTALL
REM ===========================================================================
REM Generate docs
REM ===========================================================================
echo "*** Generating commands list..."
cd ../cmake-install-dir/bin
asiExe.exe /gendoc
REM ===========================================================================
REM Prepare installer
REM ===========================================================================
cd ../..
xcopy /S /Y cmake-build-dir\setup .\setup
echo "*** Running installation packaging..."
"%JENKINS_3RDPARTIES%\innosetup6\ISCC.exe" .\setup\setup.iss