-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
16 changed files
with
648 additions
and
648 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,55 +1,55 @@ | ||
@set TITLE=Building SwiftShader | ||
@TITLE %TITLE% | ||
|
||
@rem Determine swiftshader build environment root folder and convert the path to it into DOS 8.3 format to avoid quotes mess. | ||
@cd "%~dp0" | ||
@cd ..\..\ | ||
@for %%a in ("%cd%") do @set devroot=%%~sa | ||
|
||
@set projectname=swiftshader-dist-win | ||
@set "ERRORLEVEL=" | ||
|
||
@rem Detect and activate ci mode | ||
@set cimode=0 | ||
@IF NOT "%1"=="" set cimode=1 | ||
@IF %cimode% EQU 1 call %devroot%\%projectname%\buildscript\ci\%1.cmd | ||
|
||
@rem Select target architecture | ||
@call %devroot%\%projectname%\buildscript\modules\abi.cmd | ||
|
||
@rem Analyze environment. Get each dependency status: 0=missing, 1=standby/load manually in PATH, 2=cannot be unloaded. | ||
@rem Not all dependencies can have all these states. | ||
|
||
@rem Search for compiler toolchain. Hard fail if none found | ||
@call %devroot%\%projectname%\buildscript\modules\toolchain.cmd | ||
|
||
@rem Search for Python. State tracking is pointless as it is loaded once and we are done. Hard fail if missing. | ||
@call %devroot%\%projectname%\buildscript\modules\discoverpython.cmd | ||
@call %devroot%\%projectname%\buildscript\modules\pythonpackages.cmd | ||
|
||
@rem Build throttle. | ||
@call %devroot%\%projectname%\buildscript\modules\throttle.cmd | ||
|
||
@rem Version control | ||
@call %devroot%\%projectname%\buildscript\modules\git.cmd | ||
|
||
@rem Check for remaining dependencies: cmake, ninja. | ||
@call %devroot%\%projectname%\buildscript\modules\cmake.cmd | ||
@call %devroot%\%projectname%\buildscript\modules\ninja.cmd | ||
|
||
@rem SwiftShader build. | ||
@call %devroot%\%projectname%\buildscript\modules\%projectname:~0,-9%.cmd | ||
|
||
@rem Dump build environment information | ||
@call %devroot%\%projectname%\buildscript\modules\envdump.cmd | ||
|
||
@IF /I "%1"=="x86-llvm10" echo -------------------------------------------- | ||
@IF /I "%1"=="x64-llvm10" echo -------------------------------------------- | ||
@IF /I "%1"=="x86-subzero" echo --------------------------------------------- | ||
@IF /I "%1"=="x64-subzero" echo --------------------------------------------- | ||
@IF %cimode% EQU 1 echo Build job %1 completed successfully. | ||
@IF /I "%1"=="x86-llvm10" echo -------------------------------------------- | ||
@IF /I "%1"=="x64-llvm10" echo -------------------------------------------- | ||
@IF /I "%1"=="x86-subzero" echo --------------------------------------------- | ||
@IF /I "%1"=="x64-subzero" echo --------------------------------------------- | ||
@set TITLE=Building SwiftShader | ||
@TITLE %TITLE% | ||
|
||
@rem Determine swiftshader build environment root folder and convert the path to it into DOS 8.3 format to avoid quotes mess. | ||
@cd "%~dp0" | ||
@cd ..\..\ | ||
@for %%a in ("%cd%") do @set devroot=%%~sa | ||
|
||
@set projectname=swiftshader-dist-win | ||
@set "ERRORLEVEL=" | ||
|
||
@rem Detect and activate ci mode | ||
@set cimode=0 | ||
@IF NOT "%1"=="" set cimode=1 | ||
@IF %cimode% EQU 1 call %devroot%\%projectname%\buildscript\ci\%1.cmd | ||
|
||
@rem Select target architecture | ||
@call %devroot%\%projectname%\buildscript\modules\abi.cmd | ||
|
||
@rem Analyze environment. Get each dependency status: 0=missing, 1=standby/load manually in PATH, 2=cannot be unloaded. | ||
@rem Not all dependencies can have all these states. | ||
|
||
@rem Search for compiler toolchain. Hard fail if none found | ||
@call %devroot%\%projectname%\buildscript\modules\toolchain.cmd | ||
|
||
@rem Search for Python. State tracking is pointless as it is loaded once and we are done. Hard fail if missing. | ||
@call %devroot%\%projectname%\buildscript\modules\discoverpython.cmd | ||
@call %devroot%\%projectname%\buildscript\modules\pythonpackages.cmd | ||
|
||
@rem Build throttle. | ||
@call %devroot%\%projectname%\buildscript\modules\throttle.cmd | ||
|
||
@rem Version control | ||
@call %devroot%\%projectname%\buildscript\modules\git.cmd | ||
|
||
@rem Check for remaining dependencies: cmake, ninja. | ||
@call %devroot%\%projectname%\buildscript\modules\cmake.cmd | ||
@call %devroot%\%projectname%\buildscript\modules\ninja.cmd | ||
|
||
@rem SwiftShader build. | ||
@call %devroot%\%projectname%\buildscript\modules\%projectname:~0,-9%.cmd | ||
|
||
@rem Dump build environment information | ||
@call %devroot%\%projectname%\buildscript\modules\envdump.cmd | ||
|
||
@IF /I "%1"=="x86-llvm10" echo -------------------------------------------- | ||
@IF /I "%1"=="x64-llvm10" echo -------------------------------------------- | ||
@IF /I "%1"=="x86-subzero" echo --------------------------------------------- | ||
@IF /I "%1"=="x64-subzero" echo --------------------------------------------- | ||
@IF %cimode% EQU 1 echo Build job %1 completed successfully. | ||
@IF /I "%1"=="x86-llvm10" echo -------------------------------------------- | ||
@IF /I "%1"=="x64-llvm10" echo -------------------------------------------- | ||
@IF /I "%1"=="x86-subzero" echo --------------------------------------------- | ||
@IF /I "%1"=="x64-subzero" echo --------------------------------------------- | ||
@IF %cimode% EQU 1 echo. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,33 +1,33 @@ | ||
@echo ------------------------------------------------------------- | ||
@echo BUILDING SWIFTSHADER WITH SUBZERO BACKEND FOR X64 ARHITECTURE | ||
@echo ------------------------------------------------------------- | ||
|
||
@rem modules\abi.cmd | ||
@set x64=y | ||
|
||
@rem modules\toolchain.cmd | ||
@set selecttoolchain=1 | ||
@set addvcpp=n | ||
|
||
@rem modules\discoverpython.cmd | ||
@set pyselect=1 | ||
|
||
@rem modules\pythonpackages.cmd | ||
@set pyupd=n | ||
@IF EXIST %devroot%\%projectname%\buildscript\assets\ciparallel.* set pyupd=y | ||
|
||
@rem modules\throttle.cmd | ||
@set throttle=%NUMBER_OF_PROCESSORS% | ||
|
||
@rem modules\swiftshader.cmd | ||
@set buildswiftshader=y | ||
@set srcupd=n | ||
@set ninja=n | ||
@set subzerojit=y | ||
@set spirvtools=y | ||
@set test-swiftshader=n | ||
@set cleanbuild=y | ||
|
||
@rem modules\envdump.cmd | ||
@set enableenvdump=n | ||
@echo ------------------------------------------------------------- | ||
@echo BUILDING SWIFTSHADER WITH SUBZERO BACKEND FOR X64 ARHITECTURE | ||
@echo ------------------------------------------------------------- | ||
|
||
@rem modules\abi.cmd | ||
@set x64=y | ||
|
||
@rem modules\toolchain.cmd | ||
@set selecttoolchain=1 | ||
@set addvcpp=n | ||
|
||
@rem modules\discoverpython.cmd | ||
@set pyselect=1 | ||
|
||
@rem modules\pythonpackages.cmd | ||
@set pyupd=n | ||
@IF EXIST %devroot%\%projectname%\buildscript\assets\ciparallel.* set pyupd=y | ||
|
||
@rem modules\throttle.cmd | ||
@set throttle=%NUMBER_OF_PROCESSORS% | ||
|
||
@rem modules\swiftshader.cmd | ||
@set buildswiftshader=y | ||
@set srcupd=n | ||
@set ninja=n | ||
@set subzerojit=y | ||
@set spirvtools=y | ||
@set test-swiftshader=n | ||
@set cleanbuild=y | ||
|
||
@rem modules\envdump.cmd | ||
@set enableenvdump=n | ||
@IF EXIST %devroot%\%projectname%\buildscript\assets\ciparallel.* set enableenvdump=y |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,31 @@ | ||
@echo ------------------------------------------------------------- | ||
@echo BUILDING SWIFTSHADER WITH SUBZERO BACKEND FOR X86 ARHITECTURE | ||
@echo ------------------------------------------------------------- | ||
|
||
@rem modules\abi.cmd | ||
@set x64=n | ||
|
||
@rem modules\toolchain.cmd | ||
@set selecttoolchain=1 | ||
@set addvcpp=n | ||
|
||
@rem modules\discoverpython.cmd | ||
@set pyselect=1 | ||
|
||
@rem modules\pythonpackages.cmd | ||
@set pyupd=n | ||
|
||
@rem modules\throttle.cmd | ||
@set throttle=%NUMBER_OF_PROCESSORS% | ||
|
||
@rem modules\swiftshader.cmd | ||
@set buildswiftshader=y | ||
@set srcupd=n | ||
@set ninja=n | ||
@set subzerojit=y | ||
@set spirvtools=y | ||
@set test-swiftshader=n | ||
@set cleanbuild=y | ||
|
||
@rem modules\envdump.cmd | ||
@echo ------------------------------------------------------------- | ||
@echo BUILDING SWIFTSHADER WITH SUBZERO BACKEND FOR X86 ARHITECTURE | ||
@echo ------------------------------------------------------------- | ||
|
||
@rem modules\abi.cmd | ||
@set x64=n | ||
|
||
@rem modules\toolchain.cmd | ||
@set selecttoolchain=1 | ||
@set addvcpp=n | ||
|
||
@rem modules\discoverpython.cmd | ||
@set pyselect=1 | ||
|
||
@rem modules\pythonpackages.cmd | ||
@set pyupd=n | ||
|
||
@rem modules\throttle.cmd | ||
@set throttle=%NUMBER_OF_PROCESSORS% | ||
|
||
@rem modules\swiftshader.cmd | ||
@set buildswiftshader=y | ||
@set srcupd=n | ||
@set ninja=n | ||
@set subzerojit=y | ||
@set spirvtools=y | ||
@set test-swiftshader=n | ||
@set cleanbuild=y | ||
|
||
@rem modules\envdump.cmd | ||
@set enableenvdump=n |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
@setlocal | ||
@set abi=x86 | ||
@IF %cimode% EQU 0 set "x64=" | ||
@IF %cimode% EQU 0 set /p x64=Do you want to build for x64? (y/n) Otherwise build for x86: | ||
@IF %cimode% EQU 1 echo Do you want to build for x64? (y/n) Otherwise build for x86:%x64% | ||
@echo. | ||
@if /I "%x64%"=="y" set abi=x64 | ||
@set TITLE=%TITLE% %abi% | ||
@TITLE %TITLE% | ||
@set longabi=%abi% | ||
@if %abi%==x64 set longabi=x86_64 | ||
@setlocal | ||
@set abi=x86 | ||
@IF %cimode% EQU 0 set "x64=" | ||
@IF %cimode% EQU 0 set /p x64=Do you want to build for x64? (y/n) Otherwise build for x86: | ||
@IF %cimode% EQU 1 echo Do you want to build for x64? (y/n) Otherwise build for x86:%x64% | ||
@echo. | ||
@if /I "%x64%"=="y" set abi=x64 | ||
@set TITLE=%TITLE% %abi% | ||
@TITLE %TITLE% | ||
@set longabi=%abi% | ||
@if %abi%==x64 set longabi=x86_64 | ||
@endlocal&set abi=%abi%&set TITLE=%TITLE%&set longabi=%longabi% |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
@setlocal | ||
@rem CMake build generator. Can have all states. | ||
@set cmakestate=2 | ||
@CMD /C EXIT 0 | ||
@where /q cmake.exe | ||
@if NOT "%ERRORLEVEL%"=="0" set cmakestate=1 | ||
@IF %cmakestate%==1 IF NOT EXIST %devroot%\cmake\bin\cmake.exe set cmakestate=0 | ||
@setlocal | ||
@rem CMake build generator. Can have all states. | ||
@set cmakestate=2 | ||
@CMD /C EXIT 0 | ||
@where /q cmake.exe | ||
@if NOT "%ERRORLEVEL%"=="0" set cmakestate=1 | ||
@IF %cmakestate%==1 IF NOT EXIST %devroot%\cmake\bin\cmake.exe set cmakestate=0 | ||
@endlocal&set cmakestate=%cmakestate% |
Oops, something went wrong.