[mapguide-commits] r7549 - in trunk/Tools/JenkinsCI/home/slave_win/jobs: . MapGuide Open Source x64

svn_mapguide at osgeo.org svn_mapguide at osgeo.org
Sat Jun 1 11:22:19 PDT 2013


Author: jng
Date: 2013-06-01 11:22:19 -0700 (Sat, 01 Jun 2013)
New Revision: 7549

Removed:
   trunk/Tools/JenkinsCI/home/slave_win/jobs/mg-desktop-net40-vc10-x64/
Modified:
   trunk/Tools/JenkinsCI/home/slave_win/jobs/MapGuide Open Source x64/
   trunk/Tools/JenkinsCI/home/slave_win/jobs/MapGuide Open Source x64/config.xml
Log:
#2210: Fix and update the MapGuide 64-bit build job. This now integrates the mg-desktop and MgInstantSetup jobs, eliminating the need for those separate jobs.


Property changes on: trunk/Tools/JenkinsCI/home/slave_win/jobs/MapGuide Open Source x64
___________________________________________________________________
Modified: svn:ignore
   - builds
nextBuildNumber

   + builds
nextBuildNumber
workspace
lastStable
lastSuccessful


Modified: trunk/Tools/JenkinsCI/home/slave_win/jobs/MapGuide Open Source x64/config.xml
===================================================================
--- trunk/Tools/JenkinsCI/home/slave_win/jobs/MapGuide Open Source x64/config.xml	2013-05-31 09:41:13 UTC (rev 7548)
+++ trunk/Tools/JenkinsCI/home/slave_win/jobs/MapGuide Open Source x64/config.xml	2013-06-01 18:22:19 UTC (rev 7549)
@@ -20,10 +20,10 @@
         <hudson.model.StringParameterDefinition>
           <name>WITH_ARCSDE</name>
           <description></description>
-          <defaultValue>no</defaultValue>
+          <defaultValue>yes</defaultValue>
         </hudson.model.StringParameterDefinition>
         <hudson.model.StringParameterDefinition>
-          <name>MG_MAJOR_VER</name>
+          <name>MG_VER_MAJOR</name>
           <description></description>
           <defaultValue>2</defaultValue>
         </hudson.model.StringParameterDefinition>
@@ -47,6 +47,16 @@
           <description></description>
           <defaultValue>C:\builds\fdo\3.8.0\x64_vc10\Fdo</defaultValue>
         </hudson.model.StringParameterDefinition>
+        <hudson.model.StringParameterDefinition>
+          <name>INSTANT_SETUP_SRC</name>
+          <description></description>
+          <defaultValue>C:\working\sources\MgInstantSetup</defaultValue>
+        </hudson.model.StringParameterDefinition>
+        <hudson.model.BooleanParameterDefinition>
+          <name>CLEAR_WORKING_AREA</name>
+          <description></description>
+          <defaultValue>true</defaultValue>
+        </hudson.model.BooleanParameterDefinition>
       </parameterDefinitions>
     </hudson.model.ParametersDefinitionProperty>
   </properties>
@@ -66,6 +76,9 @@
 SET VC_COMPILER=vc100
 call "%WINDOWS_SDK_71_ROOT%\Bin\SetEnv.cmd" /release /x64
 
+REM Sigh! We can't seem to reference this from Jenkins
+SET MSBUILD_NET35=C:\Windows\Microsoft.NET\Framework\v3.5\msbuild.exe
+
 SET MG_VER_MAJOR_MINOR=%MG_VER_MAJOR%.%MG_VER_MINOR%
 SET MG_VER_MAJOR_MINOR_BUILD=%MG_VER_MAJOR_MINOR%.%MG_VER_BUILD%
 SET MG_BUILD_OUTPUT_ROOT64=%MG_BUILD_ARTIFACT_PATH%\mapguide
@@ -83,11 +96,22 @@
 echo MG_BUILD_AREA64            = %MG_BUILD_AREA64%
 echo REVNUM_FILE64              = %REVNUM_FILE64%
 echo MG_STAMP_FILE64            = %MG_STAMP_FILE64%
+echo INSTANT_SETUP_SRC          = %INSTANT_SETUP_SRC%
 echo =======================================================================
 
-echo [prepare]: Cleaning out build artifacts and build area
+echo [prepare]: Cleaning out build artifacts
 if exist %MG_BUILD_OUTPUT64% rd /S /Q %MG_BUILD_OUTPUT64%
+
+if "%CLEAR_WORKING_AREA%"=="false" (
+    echo [prepare]: Skip cleaning build area
+    goto build_mapguide
+)
+
+echo [prepare]: Cleaning out SVN metadata in build area
+if exist %MG_BUILD_AREA64% for /R %MG_BUILD_AREA64% %%X in (.svn) do (RD /S /Q %%X 2>nul)
+echo [prepare]: Cleaning out build area
 if exist %MG_BUILD_AREA64% rd /S /Q %MG_BUILD_AREA64%
+echo [prepare]: Re-creating output directories
 if not exist %MG_BUILD_AREA64%\Installer mkdir %MG_BUILD_AREA64%\Installer
 if not exist %MG_BUILD_AREA64%\MgDev mkdir %MG_BUILD_AREA64%\MgDev
 if not exist %MG_BUILD_ARTIFACT_PATH%\mg-desktop mkdir %MG_BUILD_ARTIFACT_PATH%\mg-desktop
@@ -97,24 +121,48 @@
 svn export %MG_BUILD_SRC64%\Installer %MG_BUILD_AREA64%\Installer --force
 if "%errorlevel%"=="1" goto error
 
-REM Need to copy and not export as we need the SVN metadata for packaging with the installer
 echo [prepare]: Copying SVN working copy to build area (MgDev)
 SET BUILD_ACTION=Copying SVN working copy to build area (MgDev)
-robocopy %MG_BUILD_SRC64%\MgDev %MG_BUILD_AREA64%\MgDev /E /NFL /NDL /nc /ns /np
+svn export %MG_BUILD_SRC64%\MgDev %MG_BUILD_AREA64%\MgDev --force
 if "%errorlevel%"=="1" goto error
 
+echo [prepare]: Overlaying SVN metadata
+REM Yeah, we're basically re-copying, but this will include missing SVN metadata that export obviously leaves out
+robocopy %MG_BUILD_SRC64%\MgDev\Oem\fusion_build %MG_BUILD_AREA64%\MgDev\Oem\fusion_build /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\Web\src\localized %MG_BUILD_AREA64%\MgDev\Web\src\localized /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\Web\src\mapadmin %MG_BUILD_AREA64%\MgDev\Web\src\mapadmin /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\UnitTest/WebTier\MapAgent\MapAgentForms %MG_BUILD_AREA64%\MgDev\UnitTest/WebTier\MapAgent\MapAgentForms /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\Web\src\mapviewerjava %MG_BUILD_AREA64%\MgDev\Web\src\mapviewerjava /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\Web\src\mapviewernet %MG_BUILD_AREA64%\MgDev\Web\src\mapviewernet /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\Web\src\mapviewerphp %MG_BUILD_AREA64%\MgDev\Web\src\mapviewerphp /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\Web\src\schemareport %MG_BUILD_AREA64%\MgDev\Web\src\schemareport /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\Web\src\stdicons %MG_BUILD_AREA64%\MgDev\Web\src\stdicons /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\Web\src\viewerfiles %MG_BUILD_AREA64%\MgDev\Web\src\viewerfiles /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\Doc\samples\dotnetsamples %MG_BUILD_AREA64%\MgDev\Doc\samples\dotnetsamples /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\Doc\samples\dotnetviewersample %MG_BUILD_AREA64%\MgDev\Doc\samples\dotnetviewersample /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\Doc\samples\javasamples %MG_BUILD_AREA64%\MgDev\Doc\samples\javasamples /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\Doc\samples\javaviewersample %MG_BUILD_AREA64%\MgDev\Doc\samples\javaviewersample /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\Doc\samples\phpsamples %MG_BUILD_AREA64%\MgDev\Doc\samples\phpsamples /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\Doc\samples\phpviewersample %MG_BUILD_AREA64%\MgDev\Doc\samples\phpviewersample /E /NFL /NDL /nc /ns /np /MT
+robocopy %MG_BUILD_SRC64%\MgDev\Doc\viewerapi %MG_BUILD_AREA64%\MgDev\Doc\viewerapi /E /NFL /NDL /nc /ns /np /MT
+
 echo [prepare]: Setup FDO in Oem
 cd %MG_BUILD_AREA64%\MgDev\Oem\FDO
 xcopy /S /Y /I %FDO_SRC64%\Inc Inc
 xcopy /S /Y /I %FDO_SRC64%\Lib Lib64
 xcopy /S /Y /I %FDO_SRC64%\Bin Bin\Release64
 xcopy /S /Y /I %FDO_SRC64%\Bin\com\*.* Bin\Release64\com
+REM For release we don't want pdbs and .net assemblies
+cd %MG_BUILD_AREA64%\MgDev\Oem\FDO\Bin\Release64
+del /Q OSGeo.FDO.*
+del /Q *.pdb
 
 echo [prepare]: Pre-process for 64-bit compilation with Windows SDK 7.1
 sed -i "s/\%%MSBUILD\%% InstallerPreReq\%%VS_SLN_SUFFIX\%%.sln/REM \%%MSBUILD\%% InstallerPreReq\%%VS_SLN_SUFFIX\%%.sln/g" %MG_BUILD_AREA64%\Installer\build64.bat
 sed -i "s/REM call build64_vce.bat/call build64_vce.bat/g" %MG_BUILD_AREA64%\Installer\build64.bat
 echo Updated - %MG_BUILD_AREA64%\Installer\build64.bat
 
+:build_mapguide
 cd %MG_BUILD_SRC64%\MgDev
 echo [prepare]: Noting SVN revision
 svn info . | perl %REVNUM_FILE64% > revision.txt
@@ -130,6 +178,7 @@
 
 REM ========================================= MapGuide ====================================================
 
+cd %MG_BUILD_AREA64%\MgDev
 echo [build]: Set env vars
 call setenvironment64.bat vc10
 
@@ -143,18 +192,23 @@
 call build64.bat -a=install -o=%MG_BUILD_OUTPUT64%
 if "%errorlevel%"=="1" goto error
 
-pushd %MG_BUILD_AREA64%\Installer
-echo [build]: Prepare artifact directory
-SET BUILD_ACTION=Prepare artifact directory
-call build64.bat -a=prepare -source=%MG_BUILD_OUTPUT64%
-if "%errorlevel%"=="1" goto error
+REM Move fusion-selfbuild tools out of staging area
+pushd %MG_BUILD_OUTPUT64%\fusion-selfbuild
+move /Y fusion-buildtools.zip %MG_BUILD_OUTPUT_ROOT64%
 popd
+pushd %MG_BUILD_OUTPUT64%
+rd /S /Q fusion-selfbuild
+popd
 
 REM ========================================= mg-desktop ====================================================
-
+:build_mgdesktop
+REM HACK: mg-desktop batch files not aware of new output dir so set old one
+SET MG_OUTPUT=%MG_BUILD_AREA64%\MgDev\Release64
 pushd %MG_BUILD_AREA64%\MgDev
 echo [build]: mg-desktop
+SET BUILD_ACTION=Build mg-desktop
 call build_desktop.bat x64
+if "%errorlevel%"=="1" goto error
 popd
 
 pushd %MG_BUILD_AREA64%\MgDev\nuget
@@ -164,22 +218,76 @@
 
 pushd %MG_BUILD_AREA64%\MgDev
 echo [build]: Nuget packages
-call nuget_prepare.bat %MG_VER_MAJOR_MINOR_BUILD%.%REVISION64% x64
+call nuget_prepare.bat %MG_VER_MAJOR_MINOR_BUILD%.%MG_REVISION64% x64
+SET BUILD_ACTION=Nuget packages
 call nuget_pack.bat x64
+if "%errorlevel%"=="1" goto error
 popd
 
 pushd %MG_BUILD_AREA64%\MgDev\nuget
 echo [build]: Copy mg-desktop build artifacts (NuGet packages)
+set BUILD_ACTION=Copy mg-desktop build artifacts (NuGet packages)
 move *.nupkg %MG_BUILD_ARTIFACT_PATH%\mg-desktop
+if "%errorlevel%"=="1" goto error
 popd
 
 pushd %MG_BUILD_AREA64%\MgDev\Release64
 echo [build]: Copy mg-desktop build artifacts (zip dist)
-7z a -mx9 %MG_BUILD_ARTIFACT_PATH%\mg-desktop\mg-desktop-%MG_VER_MAJOR_MINOR_BUILD%.%REVISION64%-net40-vc10-x64.zip Desktop DesktopSamples
+SET BUILD_ACTION=Copy mg-desktop build artifacts (zip dist)
+7z a -mx9 %MG_BUILD_ARTIFACT_PATH%\mg-desktop\mg-desktop-%MG_VER_MAJOR_MINOR_BUILD%.%MG_REVISION64%-net40-vc10-x64.zip Desktop DesktopSamples
+if "%errorlevel%"=="1" goto error
 popd
 
+REM ========================================= Instant Setup =========================================================
+pushd %MG_BUILD_AREA64%\Installer
+echo [build]: Prepare artifact directory
+SET BUILD_ACTION=Prepare artifact directory
+call build64.bat -a=prepare -source=%MG_BUILD_OUTPUT64%
+if "%errorlevel%"=="1" goto error
+popd
+
+if not exist %INSTANT_SETUP_SRC% goto checkout_instantsetup
+goto update_instantsetup
+:checkout_instantsetup
+echo [build]: svn checkout MgInstantSetup
+SET BUILD_ACTION=svn checkout MgInstantSetup
+svn co %INSTANT_SETUP_SVN_URL% %INSTANT_SETUP_SRC%
+if "%errorlevel%"=="1" goto error
+goto build_instantsetup
+
+:update_instantsetup
+REM We'll allow this to fail
+echo [build]: svn update MgInstantSetup
+pushd %INSTANT_SETUP_SRC%
+svn update
+popd
+
+:build_instantsetup
+echo [build]: MgInstantSetup
+pushd %INSTANT_SETUP_SRC%
+SET BUILD_ACTION=Building MgInstantSetup
+%MSBUILD_NET35% /p:Configuration=Release;Platform="Any CPU" MgInstantSetup.sln
+if "%errorlevel%"=="1" goto error
+popd
+
+:copy_instantsetup_build_artifacts
+echo [build]: Copy MgInstantSetup build artifacts
+if not exist %MG_BUILD_OUTPUT64%\Setup mkdir %MG_BUILD_OUTPUT64%\Setup
+pushd %INSTANT_SETUP_SRC%\InstantSetup\bin\release
+copy /Y *.exe %MG_BUILD_OUTPUT64%\Setup
+copy /Y *.pdb %MG_BUILD_OUTPUT64%\Setup
+copy /Y *.dll %MG_BUILD_OUTPUT64%\Setup
+copy /Y *.config %MG_BUILD_OUTPUT64%\Setup
+popd
+
+:zip_mginstantsetup
+pushd %MG_BUILD_OUTPUT64%
+7z a %MG_BUILD_OUTPUT_ROOT64%\MapGuideOpenSource-%MG_VER_MAJOR_MINOR_BUILD%.%MG_REVISION64%-InstantSetup-x64.exe -mmt -mx5 -sfx7z.sfx .
+popd
+
 REM ========================================= MapGuide Installer ====================================================
 
+:build_installer
 pushd %MG_BUILD_AREA64%\Installer
 echo [build]: Generate installer file listings
 SET BUILD_ACTION=Generate installer file listings



More information about the mapguide-commits mailing list