Reworked the workspace scripts so the build should fail on compile errors. This build should fail as a test.
This commit is contained in:
parent
10ee3b9e92
commit
e3359fdbd3
4 changed files with 63 additions and 60 deletions
|
@ -1,18 +1,38 @@
|
|||
@cd ..
|
||||
@echo off
|
||||
echo =================================== Build Start =================================
|
||||
cd ..
|
||||
|
||||
@rmdir /S /Q src
|
||||
@mkdir src
|
||||
xcopy /Q /Y /E src_work\* src\
|
||||
rem rmdir /S /Q src
|
||||
rem mkdir src
|
||||
|
||||
echo src_work -^> src
|
||||
rem xcopy /Q /Y /E src_work\* src\
|
||||
echo.
|
||||
|
||||
echo forge_client -^> minecraft
|
||||
xcopy /Y /E forge\forge_client\src\net\* src\minecraft\net
|
||||
echo.
|
||||
|
||||
echo forge_server -^> minecraft_server
|
||||
xcopy /Y /E forge\forge_server\src\net\* src\minecraft_server\net
|
||||
echo.
|
||||
|
||||
echo forge_common -^> minecraft
|
||||
xcopy /Y /E forge\forge_common\net\* src\minecraft\net
|
||||
echo.
|
||||
|
||||
echo forge_common -^> minecraft_server
|
||||
xcopy /Y /E forge\forge_common\net\* src\minecraft_server\net
|
||||
|
||||
@cd forge
|
||||
@cmd /C inject_version.bat ../src/minecraft/net/minecraft/src/forge/ForgeHooks.java
|
||||
@cmd /C inject_version.bat ../src/minecraft_server/net/minecraft/src/forge/ForgeHooks.java
|
||||
@cd ..
|
||||
|
||||
@echo | call recompile.bat
|
||||
echo.
|
||||
|
||||
cd forge
|
||||
cmd /C inject_version.bat ../src/minecraft/net/minecraft/src/forge/ForgeHooks.java
|
||||
cmd /C inject_version.bat ../src/minecraft_server/net/minecraft/src/forge/ForgeHooks.java
|
||||
cd ..
|
||||
|
||||
runtime\bin\python\python_mcp runtime\recompile.py
|
||||
|
||||
set ret=%ERRORLEVEL%
|
||||
cd forge
|
||||
echo =================================== Build Finished %ret% =================================
|
||||
if %ret% NEQ 0 exit /b %ret%
|
||||
|
|
|
@ -3,36 +3,24 @@ version=$major.$minor.$revision.$build
|
|||
build_dir=`pwd`
|
||||
dir=`pwd`/../forge-$version
|
||||
|
||||
function remove_svn () {
|
||||
(
|
||||
cd "$1"
|
||||
|
||||
if [ -d .svn ]; then
|
||||
rm -rf .svn
|
||||
fi
|
||||
|
||||
for j in `ls`
|
||||
do
|
||||
if [ -d $j ]; then
|
||||
remove_svn $j
|
||||
fi
|
||||
done
|
||||
)
|
||||
}
|
||||
|
||||
function package_all () {
|
||||
qual=$1
|
||||
|
||||
|
||||
echo "=================================== MinecraftForge$qual-$version.zip Start ================================="
|
||||
|
||||
cp "$build_dir/minecraftforge_credits.txt" .
|
||||
|
||||
echo "Making minecraftforge$qual-$version.zip"
|
||||
|
||||
zip -r "$dir/minecraftforge$qual-$version.zip" .
|
||||
|
||||
echo "=================================== MinecraftForge$qual-$version.zip Finished ================================="
|
||||
}
|
||||
|
||||
cd ../reobf
|
||||
|
||||
remove_svn .
|
||||
if [ ! -d "minecraft" -o ! -d "minecraft_server" ]; then
|
||||
echo "Reobfusication failed, output directories do no exist."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
rm -rf "$dir"
|
||||
mkdir "$dir"
|
||||
|
@ -49,6 +37,7 @@ rm -rf reobf
|
|||
|
||||
cd "$build_dir"
|
||||
|
||||
echo "=================================== MinecraftForge-src-$version.zip Start ================================="
|
||||
mkdir forge
|
||||
cd forge
|
||||
mkdir src
|
||||
|
@ -69,22 +58,12 @@ cp ../install/install.sh .
|
|||
cp ../download_fernflower.py .
|
||||
cp ../install/README.txt .
|
||||
cp ../minecraftforge_credits.txt .
|
||||
cp -r ../doc .
|
||||
|
||||
cd ..
|
||||
sh inject_version.sh forge/src/minecraft/net/minecraft/src/forge/ForgeHooks.java
|
||||
sh inject_version.sh forge/src/minecraft_server/net/minecraft/src/forge/ForgeHooks.java
|
||||
cd forge
|
||||
|
||||
cd src
|
||||
remove_svn .
|
||||
cd ../patches
|
||||
remove_svn .
|
||||
cd ../conf
|
||||
remove_svn .
|
||||
cd ..
|
||||
|
||||
cd ..
|
||||
|
||||
zip -r "$dir/minecraftforge-src-$version.zip" forge
|
||||
rm -rf forge
|
||||
|
||||
echo "=================================== MinecraftForge-src-$version.zip Finished ================================="
|
||||
|
|
|
@ -1,15 +1,16 @@
|
|||
@cmd /C build.bat
|
||||
@echo off
|
||||
|
||||
if %ERRORLEVEL% NEQ 0 exit 1
|
||||
call build.bat
|
||||
if %ERRORLEVEL% NEQ 0 exit /b %ERRORLEVEL%
|
||||
|
||||
@cd ..
|
||||
echo =================================== Release Start =================================
|
||||
|
||||
@echo | cmd /C reobfuscate.bat
|
||||
cd ..
|
||||
runtime\bin\python\python_mcp runtime\reobfuscate.py
|
||||
cd forge
|
||||
|
||||
@set PATH=E:\cygwin\bin;%PATH%
|
||||
set PATH=E:\cygwin\bin;%PATH%
|
||||
sh package.sh
|
||||
|
||||
@cd forge
|
||||
|
||||
@sh package.sh
|
||||
|
||||
pause
|
||||
echo =================================== Release Finished %ERRORLEVEL% =================================
|
||||
if %ERRORLEVEL% NEQ 0 exit /b %ERRORLEVEL%
|
|
@ -1,4 +1,5 @@
|
|||
echo off
|
||||
@echo off
|
||||
echo =================================== Setup Start =================================
|
||||
pushd .. >nul
|
||||
|
||||
if "%1"=="-skipdecompile" (
|
||||
|
@ -14,12 +15,12 @@ pushd .. >nul
|
|||
exit 1
|
||||
)
|
||||
rmdir /S /Q src
|
||||
@echo | cmd /C decompile.bat -r
|
||||
echo | cmd /C decompile.bat -r
|
||||
)
|
||||
|
||||
.\runtime\bin\python\python_mcp forge\clean_src.py src
|
||||
|
||||
@echo | cmd /C updatemd5.bat -f
|
||||
echo | cmd /C updatemd5.bat -f
|
||||
|
||||
rmdir /S /Q src_base
|
||||
rmdir /S /Q src_work
|
||||
|
@ -37,7 +38,6 @@ pushd .. >nul
|
|||
echo Applying patches
|
||||
for /f %%i in ('find ../forge/patches -type f') do (
|
||||
set file=%%i
|
||||
rem Have to do this to filter out .svn entries
|
||||
if /I "!file:~-6!" EQU ".patch" (
|
||||
..\runtime\bin\python\python_mcp ..\forge\lfcr.py %%i ..\forge\temp.patch
|
||||
..\runtime\bin\applydiff.exe -uf -p2 -i ..\forge\temp.patch
|
||||
|
@ -46,5 +46,8 @@ pushd .. >nul
|
|||
)
|
||||
popd >nul
|
||||
popd >nul
|
||||
echo finished
|
||||
pause
|
||||
echo =================================== Setup Finished =================================
|
||||
|
||||
if NOT "%1"=="-skipdecompile" (
|
||||
pause
|
||||
)
|
Loading…
Reference in a new issue