Skip to content

Commit

Permalink
Merge pull request #1214 from microsoft/jandupej/newboost
Browse files Browse the repository at this point in the history
Add support for Boost 1.83
  • Loading branch information
jandupej authored Oct 2, 2024
2 parents 4e3a21f + 0fa934e commit a17b6ab
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 11 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ different versioning scheme, following the Haskell community's
runtime if custom allocators for containers are used. Newer MSVC versions and
other compilers are not affected, neither are Release builds with MSVC 14.0. This
can be worked around by using newer MSVC version or building in Release configuration.
* Added support for Boost 1.83.

### C# ###

Expand Down
1 change: 1 addition & 0 deletions examples/cpp/core/multiprecision/multiprecision.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
#include <bond/stream/output_buffer.h>

#include <boost/multiprecision/miller_rabin.hpp>
#include <boost/random.hpp>

using namespace examples::multiprecision;

Expand Down
2 changes: 1 addition & 1 deletion examples/cpp/core/multiprecision/multiprecision.h
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ namespace bond
// Bond expects that blob with default value is empty
return 0;
else
return num.backend().size() * sizeof(limb_type);
return static_cast<uint32_t>(num.backend().size() * sizeof(limb_type));
}


Expand Down
2 changes: 1 addition & 1 deletion tools/ci-scripts/linux/image-builder/build_boosts.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

set -eux

BOOST_VERSIONS=(1.61.0 1.62.0 1.63.0 1.64.0 1.65.1 1.66.0 1.67.0)
BOOST_VERSIONS=(1.61.0 1.62.0 1.63.0 1.64.0 1.65.1 1.66.0 1.67.0 1.83.0)
BOOST_LIBRARIES="chrono,date_time,python,system,test,thread"

BUILD_ROOT=/tmp/boosts
Expand Down
2 changes: 1 addition & 1 deletion tools/ci-scripts/windows/Get-BoostLocation.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ param
[string]
$Version,

[ValidateSet('12.0', '14.0', '14.1', '14.2')]
[ValidateSet('12.0', '14.0', '14.1', '14.2', '14.3')]
[string]
$VcToolsetVer
)
Expand Down
29 changes: 21 additions & 8 deletions tools/ci-scripts/windows/Install-Boost.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ param
[string]
$Version,

[ValidateSet('12.0', '14.0', '14.1', '14.2')]
[ValidateSet('12.0', '14.0', '14.1', '14.2', '14.3')]
[string]
$VcToolsetVer,

Expand Down Expand Up @@ -123,13 +123,26 @@ function Install-BoostComponent([string]$Component)
-InstallDir $workDir `
-PackageVersion $Version

Move-Item `
-Path ([System.IO.Path]::Combine($workDir, $packageId, 'lib', 'native', 'address-model-32', 'lib', '*')) `
-Destination $lib32Dir

Move-Item `
-Path ([System.IO.Path]::Combine($workDir, $packageId, 'lib', 'native', 'address-model-64', 'lib', '*')) `
-Destination $lib64Dir
if ($Version -gt 1.66)
{
$sourceFolder = ([System.IO.Path]::Combine($workDir, $packageId, 'lib', 'native'))
$itemsToMove32 = Get-ChildItem -Path $sourceFolder | Where-Object { $_.Name -like "*x32*" }
$itemsToMove64 = Get-ChildItem -Path $sourceFolder | Where-Object { $_.Name -like "*x64*" }

$itemsToMove32 | ForEach-Object { Move-Item -Path $_.FullName -Destination $lib32Dir }
$itemsToMove64 | ForEach-Object { Move-Item -Path $_.FullName -Destination $lib64Dir }

}
else
{
Move-Item `
-Path ([System.IO.Path]::Combine($workDir, $packageId, 'lib', 'native', 'address-model-64', 'lib', '*')) `
-Destination $lib64Dir

Move-Item `
-Path ([System.IO.Path]::Combine($workDir, $packageId, 'lib', 'native', 'address-model-32', 'lib', '*')) `
-Destination $lib32Dir
}
}
}

Expand Down

0 comments on commit a17b6ab

Please sign in to comment.