update boost toolset and notes, remove BOOST_ROOT

This commit is contained in:
Aleksandr Chebotov
2020-03-17 09:47:22 +03:00
parent 8254ea02af
commit 80449e25a0
52 changed files with 728 additions and 864 deletions

View File

@@ -63,6 +63,78 @@ function RunTestsByPath {
}
}
function Get-SystemDefaultPython {
Write-Host "Validate system Python..."
if (Get-Command -Name 'python')
{
Write-Host "Python $(& python -V 2>&1) on path"
}
else
{
Write-Host "Python is not on path"
exit 1
}
$pythonBinVersion = $(& python -V 2>&1)
if ($pythonBinVersion -notlike "Python 3.*")
{
Write-Error "Python 3 is not in the PATH"
exit 1
}
$pythonBinOnPath = Split-Path -Path (Get-Command -Name 'python').Path
$description = GetDefaultToolDescription -SoftwareVersion $pythonBinVersion -SoftwareLocation $pythonBinOnPath
return $description
}
function Get-SystemDefaultRuby {
Write-Host "Validate system Ruby..."
if (Get-Command -Name 'ruby')
{
Write-Host "$(ruby --version) is on the path."
}
else
{
Write-Host "Ruby is not on the path."
exit 1
}
$rubyBinOnPath = Split-Path -Path (Get-Command -Name 'ruby').Path
if ( $(ruby --version) -notmatch 'ruby (?<version>.*) \(.*' )
{
Write-Host "Unable to determine Ruby version at " + $rubyBinOnPath
exit 1
}
$rubyVersionOnPath = "Ruby $($Matches.version)"
$description = GetDefaultToolDescription -SoftwareVersion $rubyVersionOnPath -SoftwareLocation $rubyBinOnPath
$gemVersion = & gem -v
$description += "* Gem Version: $gemVersion<br/>"
return $description
}
function GetDefaultToolDescription {
param (
[Parameter(Mandatory = $True)]
[string]$SoftwareVersion,
[Parameter(Mandatory = $True)]
[string]$SoftwareLocation
)
$description = "<br/>__System default version:__ $SoftwareVersion<br/>"
$description += "_Environment:_<br/>"
$description += "* Location: $SoftwareLocation<br/>"
$description += "* PATH: contains the location of $SoftwareVersion<br/>"
return $description
}
function GetMarkdownDescription {
param (
[Parameter(Mandatory = $True)]
@@ -123,6 +195,14 @@ function ToolcacheTest {
$markdownDescription += GetMarkdownDescription -SoftwareVersion $foundVersion -SoftwareArchitecture $requiredArchitecture
}
}
if ($SoftwareName -contains "Python") {
$markdownDescription += Get-SystemDefaultPython
}
if ($SoftwareName -contains "Ruby") {
$markdownDescription += Get-SystemDefaultRuby
}
Add-SoftwareDetailsToMarkdown -SoftwareName $SoftwareName -DescriptionMarkdown $markdownDescription
}