|
1 |
| -# Install 7zip |
2 |
| -$URL7Zip = "https://gist.githubusercontent.com/dansmith65/7dd950f183af5f5deaf9650f2ad3226c/raw/8b8f6e96de7469cea73c9fe63a5da4d44a7c1ba7/Install-7zip.ps1" |
3 |
| -$Path7Zip = ".\Install-7zip.ps1" |
4 |
| -Remove-Item -ErrorAction Ignore $Path7Zip |
5 |
| -Invoke-WebRequest -URI $URL7Zip -OutFile $Path7Zip |
6 |
| -powershell $Path7Zip |
7 |
| -Remove-Item -ErrorAction Ignore $Path7Zip |
8 |
| -$Path7zipApp="C:\Program Files\7-Zip\7z.exe" |
| 1 | +$PathBoostFolder="boost_1_81_0" |
| 2 | +if ($args[0] -eq "VS") |
| 3 | +{ |
| 4 | + # Prebuild libs for VS |
| 5 | + # $URLBoostVs = "https://downloads.sourceforge.net/project/boost/boost-binaries/1.81.0/boost_1_81_0-msvc-14.3-32.exe?ts=gAAAAABj4CrKnWOz1tor2EO1I8BXk_n0FEzGgMqcl_J5LqB9-IKXOXglKXejh8MZTvZuGwX1dE7qGgBGgu5NhN4-DCElUzPprg%3D%3D&r=https%3A%2F%2Fsourceforge.net%2Fprojects%2Fboost%2Ffiles%2Fboost-binaries%2F1.81.0%2Fboost_1_81_0-msvc-14.3-32.exe%2Fdownload" |
| 6 | + # $PathBoostExe = "boost.exe" |
| 7 | + # Invoke-WebRequest -URI $URLBoostVs -OutFile $PathBoostExe |
| 8 | + # Start-Process -Wait -FilePath $PathBoostExe /verysilent |
| 9 | + # Move-Item -Path C:\local\$PathBoostFolder -Destination .\erpcgen\VisualStudio_v14\$PathBoostFolder -force |
9 | 10 |
|
10 |
| -# Install mingw |
11 |
| -$URLMingw = "https://github.com/niXman/mingw-builds-binaries/releases/download/12.2.0-rt_v10-rev2/x86_64-12.2.0-release-win32-seh-ucrt-rt_v10-rev2.7z" |
12 |
| -$PathMingw7Zip = "mingw.7z" |
13 |
| -$PathMingw = "mingw64" |
14 |
| -$UnzipMingw = 'x',$PathMingw7Zip,'-y' |
15 |
| -Remove-Item -ErrorAction Ignore $PathMingw7Zip |
16 |
| -Remove-Item -ErrorAction Ignore $PathMingw |
17 |
| -Invoke-WebRequest -URI $URLMingw -OutFile $PathMingw7Zip |
18 |
| -& $Path7zipApp $UnzipMingw |
19 |
| -Remove-Item -ErrorAction Ignore $PathMingw7Zip |
| 11 | + # "https://aka.ms/vs/17/release/vs_BuildTools.exe" |
| 12 | + # "" |
| 13 | +} |
| 14 | +else |
| 15 | +{ |
| 16 | + # Install 7zip |
| 17 | + $URL7Zip = "https://gist.githubusercontent.com/dansmith65/7dd950f183af5f5deaf9650f2ad3226c/raw/8b8f6e96de7469cea73c9fe63a5da4d44a7c1ba7/Install-7zip.ps1" |
| 18 | + $Path7Zip = ".\Install-7zip.ps1" |
| 19 | + Remove-Item -ErrorAction Ignore $Path7Zip |
| 20 | + Invoke-WebRequest -URI $URL7Zip -OutFile $Path7Zip |
| 21 | + powershell $Path7Zip |
| 22 | + Remove-Item -ErrorAction Ignore $Path7Zip |
| 23 | + $Path7zipApp="C:\Program Files\7-Zip\7z.exe" |
20 | 24 |
|
21 |
| -# Install boost |
22 |
| -$PathBoostFolder="boost_1_81_0" |
23 |
| -$URLBoost = "https://boostorg.jfrog.io/artifactory/main/release/1.81.0/source/" + $PathBoostFolder + ".7z" |
24 |
| -$PatHBoost7Zip=".\boost.7z" |
25 |
| -$UnzipBoost = 'x',$PatHBoost7Zip,'-y' |
26 |
| -Remove-Item -ErrorAction Ignore $PatHBoost7Zip |
27 |
| -Remove-Item -ErrorAction Ignore $PathBoostFolder |
28 |
| -Invoke-WebRequest -URI $URLBoost -OutFile $PatHBoost7Zip |
29 |
| -& $Path7zipApp $UnzipBoost |
30 |
| -Remove-Item -ErrorAction Ignore $PatHBoost7Zip |
31 |
| -$env:Path += ';'+(Get-Location).tostring() + "\" + $PathMingw+"\bin" |
| 25 | + # Install mingw |
| 26 | + $URLMingw = "https://github.com/niXman/mingw-builds-binaries/releases/download/12.2.0-rt_v10-rev2/x86_64-12.2.0-release-win32-seh-ucrt-rt_v10-rev2.7z" |
| 27 | + $PathMingw7Zip = "mingw.7z" |
| 28 | + $PathMingw = "mingw64" |
| 29 | + $UnzipMingw = 'x',$PathMingw7Zip,'-y' |
| 30 | + Remove-Item -ErrorAction Ignore $PathMingw7Zip |
| 31 | + Remove-Item -ErrorAction Ignore $PathMingw |
| 32 | + Invoke-WebRequest -URI $URLMingw -OutFile $PathMingw7Zip |
| 33 | + & $Path7zipApp $UnzipMingw |
| 34 | + Remove-Item -ErrorAction Ignore $PathMingw7Zip |
| 35 | + |
| 36 | + # Install boost |
| 37 | + $URLBoost = "https://boostorg.jfrog.io/artifactory/main/release/1.81.0/source/" + $PathBoostFolder + ".7z" |
| 38 | + $PatHBoost7Zip=".\boost.7z" |
| 39 | + $UnzipBoost = 'x',$PatHBoost7Zip,'-y' |
| 40 | + Remove-Item -ErrorAction Ignore $PatHBoost7Zip |
| 41 | + Remove-Item -ErrorAction Ignore $PathBoostFolder |
| 42 | + Invoke-WebRequest -URI $URLBoost -OutFile $PatHBoost7Zip |
| 43 | + & $Path7zipApp $UnzipBoost |
| 44 | + Remove-Item -ErrorAction Ignore $PatHBoost7Zip |
| 45 | + $env:Path += ';'+(Get-Location).tostring() + "\" + $PathMingw+"\bin" |
32 | 46 |
|
33 |
| -Set-Location ".\"$PathBoostFolder |
34 |
| -.\bootstrap.bat gcc |
35 |
| -.\b2 --build-type=complete toolset=gcc install |
36 |
| -Set-Location "..\" |
| 47 | + Set-Location $PathBoostFolder |
| 48 | + .\bootstrap.bat gcc |
| 49 | + .\b2 toolset=gcc install |
| 50 | + Set-Location "..\" |
| 51 | +} |
37 | 52 |
|
38 | 53 | # Binson/flex
|
39 | 54 | Set-Location ".\erpcgen\VisualStudio_v14"
|
|
0 commit comments