[mapguide-commits] r10260 - branches/4.0/MgDev
svn_mapguide at osgeo.org
svn_mapguide at osgeo.org
Tue Nov 3 03:46:52 PST 2026
Author: jng
Date: 2026-11-03 03:46:51 -0800 (Tue, 03 Nov 2026)
New Revision: 10260
Modified:
branches/4.0/MgDev/build.bat
Log:
Prepare staging area Repositories dir instead of copying the source one
Modified: branches/4.0/MgDev/build.bat
===================================================================
--- branches/4.0/MgDev/build.bat 2026-11-03 11:44:14 UTC (rev 10259)
+++ branches/4.0/MgDev/build.bat 2026-11-03 11:46:51 UTC (rev 10260)
@@ -293,18 +293,28 @@
%XCOPY_SINGLE% "%MG_SERVER%\bin\%TYPEBUILD%" "%MG_OUTPUT_SERVER%\bin" /EXCLUDE:%CONFIGURATION%_excludes.txt
echo [install]: Server - FDO
%XCOPY% "%MG_SERVER%\bin\%TYPEBUILD%\FDO" "%MG_OUTPUT_SERVER%\FDO" /EXCLUDE:%CONFIGURATION%_excludes.txt
-echo [install]: Server - Logs
-%XCOPY% "%MG_SERVER%\bin\%TYPEBUILD%\Logs" "%MG_OUTPUT_SERVER%\Logs"
-echo [install]: Server - Packages
-%XCOPY% "%MG_SERVER%\bin\%TYPEBUILD%\Packages" "%MG_OUTPUT_SERVER%\Packages"
echo [install]: Server - Repositories
-%XCOPY% "%MG_SERVER%\bin\%TYPEBUILD%\Repositories" "%MG_OUTPUT_SERVER%\Repositories"
+rem Repositories, Logs, Packages and Temp are runtime state: the test suites
+rem and any server started from the build output write into them, so copying
+rem them out of the build output ships that state with the installation. An
+rem installation has them empty - the server initializes its repositories on
+rem its first start - so create the empty layout instead of copying it.
+if exist "%MG_OUTPUT_SERVER%\Repositories" rd /S /Q "%MG_OUTPUT_SERVER%\Repositories"
+if exist "%MG_OUTPUT_SERVER%\Logs" rd /S /Q "%MG_OUTPUT_SERVER%\Logs"
+if exist "%MG_OUTPUT_SERVER%\Packages" rd /S /Q "%MG_OUTPUT_SERVER%\Packages"
+if exist "%MG_OUTPUT_SERVER%\Temp" rd /S /Q "%MG_OUTPUT_SERVER%\Temp"
+mkdir "%MG_OUTPUT_SERVER%\Repositories\Library\DataFiles"
+mkdir "%MG_OUTPUT_SERVER%\Repositories\Session\DataFiles"
+mkdir "%MG_OUTPUT_SERVER%\Repositories\Site"
+mkdir "%MG_OUTPUT_SERVER%\Repositories\TileCache"
+mkdir "%MG_OUTPUT_SERVER%\Logs"
+mkdir "%MG_OUTPUT_SERVER%\Packages"
+mkdir "%MG_OUTPUT_SERVER%\Temp"
+if not exist "%MG_OUTPUT_SERVER%\Repositories\TileCache" goto error_create_runtime_folders
echo [install]: Server - Resources
%XCOPY% "%MG_SERVER%\bin\%TYPEBUILD%\Resources" "%MG_OUTPUT_SERVER%\Resources"
echo [install]: Server - Schema
%XCOPY% "%MG_SERVER%\bin\%TYPEBUILD%\Schema" "%MG_OUTPUT_SERVER%\Schema"
-echo [install]: Server - Temp
-%XCOPY% "%MG_SERVER%\bin\%TYPEBUILD%\Temp" "%MG_OUTPUT_SERVER%\Temp"
echo [install]: Server - WFS
%XCOPY% "%MG_SERVER%\bin\%TYPEBUILD%\wfs" "%MG_OUTPUT_SERVER%\wfs"
echo [install]: Server - WMS
@@ -496,6 +506,10 @@
copy /Y "%CD%\Bindings\src\ApiDump\README.txt" "%MG_OUTPUT%\Snapshot"
goto quit
+:error_create_runtime_folders
+SET ERRORMSG=Could not create the empty server runtime folders under %MG_OUTPUT_SERVER%
+goto custom_error_no_help
+
:error
echo [ERROR]: There was an error building the component
popd
More information about the mapguide-commits
mailing list