@set L=C:\windows\temp\install.log
@set IP=[===========Install Pass===========]
@set IPR=[===========Install Pass, Restart is need===========]
@set IF=[===========Install Fail===========]
@set Appxbundle=adc5a6a1ad7d49999542a951e16eeefe.appxbundle
@set License=adc5a6a1ad7d49999542a951e16eeefe_License1.xml
@set Framework1=Microsoft.NET.Native.Framework.2.2_2.2.29512.0_arm__8wekyb3d8bbwe.appx
@set Framework2=Microsoft.NET.Native.Framework.2.2_2.2.29512.0_arm64__8wekyb3d8bbwe.appx
@set Framework3=Microsoft.NET.Native.Framework.2.2_2.2.29512.0_x64__8wekyb3d8bbwe.appx
@set Framework4=Microsoft.NET.Native.Framework.2.2_2.2.29512.0_x86__8wekyb3d8bbwe.appx
@set Runtime1=Microsoft.NET.Native.Runtime.2.2_2.2.28604.0_arm__8wekyb3d8bbwe.appx
@set Runtime2=Microsoft.NET.Native.Runtime.2.2_2.2.28604.0_arm64__8wekyb3d8bbwe.appx
@set Runtime3=Microsoft.NET.Native.Runtime.2.2_2.2.28604.0_x64__8wekyb3d8bbwe.appx
@set Runtime4=Microsoft.NET.Native.Runtime.2.2_2.2.28604.0_x86__8wekyb3d8bbwe.appx
@set VCLibs1=Microsoft.VCLibs.140.00_14.0.29231.0_arm__8wekyb3d8bbwe.appx
@set VCLibs2=Microsoft.VCLibs.140.00_14.0.29231.0_arm64__8wekyb3d8bbwe.appx
@set VCLibs3=Microsoft.VCLibs.140.00_14.0.29231.0_x64__8wekyb3d8bbwe.appx
@set VCLibs4=Microsoft.VCLibs.140.00_14.0.29231.0_x86__8wekyb3d8bbwe.appx
													 

@echo [%time%]Install Intel IGCC >> %L%
DISM /Online /Add-ProvisionedAppxPackage /PackagePath:"%~dp0Apps\%Appxbundle%" /licensepath:"%~dp0Apps\%License%" /DependencyPackagePath:"%~dp0Apps\%Framework1%" /licensepath:"%~dp0Apps\%License%" /DependencyPackagePath:"%~dp0Apps\%Framework2%" /licensepath:"%~dp0Apps\%License%" /DependencyPackagePath:"%~dp0Apps\%Framework3%" /licensepath:"%~dp0Apps\%License%" /DependencyPackagePath:"%~dp0Apps\%Framework4%" /DependencyPackagePath:"%~dp0Apps\%Runtime1%" /DependencyPackagePath:"%~dp0Apps\%Runtime2%" /DependencyPackagePath:"%~dp0Apps\%Runtime3%" /DependencyPackagePath:"%~dp0Apps\%Runtime4%" /DependencyPackagePath:"%~dp0Apps\%VCLibs1%" /DependencyPackagePath:"%~dp0Apps\%VCLibs2%" /DependencyPackagePath:"%~dp0Apps\%VCLibs3%" /DependencyPackagePath:"%~dp0Apps\%VCLibs4%" /Region="All" >> %L%

@if %errorlevel%==0 (echo [%time%]%IP% >> %L% & goto resultpass)
@if %errorlevel%==259 (echo [%time%]%errorlevel% >> %L% & goto resultpass)
@if %errorlevel%==3010 (echo [%time%]%IPR% >> %L% & goto resultpass)
@if not %errorlevel%==0 goto ERR

:resultpass
@echo [%time%]=========Intel IGCC Install complete========= >> %L%
ECHO ERRRORLEVEL=%ERRORLEVEL% >> %L%
@set LL=C:\Windows\temp\Intel_GFX_IGCC.log
@echo [%time%] >>%LL%
EXIT /B 0

:ERR
echo [%time%]%IF% >> %L%
ECHO ERRRORLEVEL=%ERRORLEVEL% >> %L%
EXIT /B 1
