- Notifications
You must be signed in to change notification settings - Fork 212
/
Copy pathpost_install.bat
28 lines (25 loc) · 783 Bytes
/
post_install.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
@echooff
setARGS=/SE /SW /SA
if"%PROCESSOR_ARCHITECTURE%"=="AMD64" (
drivers\dpinst-amd64.exe %ARGS%
) ELSEIF"%PROCESSOR_ARCHITEW6432%"=="AMD64" (
drivers\dpinst-amd64.exe %ARGS%
) ELSE (
drivers\dpinst-x86.exe %ARGS%
)
@echooff
setlocal
for /f "tokens=4-5 delims=[.] "%%iin ('ver') do@(if %%i==Version (set VERSION=%%j) else (set VERSION=%%i))
if%VERSION%GEQ10 (
exit /b 0
)
endlocal
REM dpinst /PATH has problems with relative paths, so use absolute path.
if"%PROCESSOR_ARCHITECTURE%"=="AMD64" (
drivers\dpinst-amd64.exe /PATH %cd%\drivers\prewin10 %ARGS%
) ELSEIF"%PROCESSOR_ARCHITEW6432%"=="AMD64" (
drivers\dpinst-amd64.exe /PATH %cd%\drivers\prewin10 %ARGS%
) ELSE (
drivers\dpinst-x86.exe /PATH %cd%\drivers\prewin10 %ARGS%
)
exit /b 0