mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-12-27 18:31:15 +08:00
[boost] pulling has_synchro bits from https://github.com/microsoft/vcpkg/pull… (#30836)
* pulling has_synchro bits from https://github.com/microsoft/vcpkg/pull/27694 * bump port version * version * fix clang * bump version * version * oops * bump dependency version for boost-atomic's boost-module-build-helper dependency * version * revert renaming stuff -.- * version * remove detection stuff for lib prefix/suffix * version * fix indentation * version * forgot one * version * one more! * version * revert changes to cmake-get-vars * version * generate ports * version db * generate ports * version db --------- Co-authored-by: Alexander Neumann <30894796+Neumann-A@users.noreply.github.com>
This commit is contained in:
parent
1e90576cf5
commit
c6c59e33f3
@ -13,6 +13,8 @@ vcpkg_replace_string("${SOURCE_PATH}/build/Jamfile.v2"
|
||||
"project.load [ path.join [ path.make $(here:D) ] ../config/checks/architecture ]"
|
||||
)
|
||||
file(COPY "${CURRENT_INSTALLED_DIR}/share/boost-config/checks" DESTINATION "${SOURCE_PATH}/config")
|
||||
#Make sure to keep this line when updating boost.
|
||||
file(INSTALL "${SOURCE_PATH}/config/has_synchronization_lib.cpp" DESTINATION "${CURRENT_PACKAGES_DIR}/share/boost-atomic")
|
||||
include(${CURRENT_HOST_INSTALLED_DIR}/share/boost-build/boost-modular-build.cmake)
|
||||
boost_modular_build(SOURCE_PATH ${SOURCE_PATH})
|
||||
include(${CURRENT_INSTALLED_DIR}/share/boost-vcpkg-helpers/boost-modular-headers.cmake)
|
||||
|
@ -2,7 +2,7 @@
|
||||
"$comment": "Automatically generated by scripts/boost/generate-ports.ps1",
|
||||
"name": "boost-atomic",
|
||||
"version": "1.82.0",
|
||||
"port-version": 2,
|
||||
"port-version": 3,
|
||||
"description": "Boost atomic module",
|
||||
"homepage": "https://github.com/boostorg/atomic",
|
||||
"license": "BSL-1.0",
|
||||
|
@ -61,12 +61,12 @@ if(VCPKG_DETECTED_MSVC)
|
||||
set(USER_CONFIG_TOOLSET clang-win)
|
||||
else()
|
||||
set(USER_CONFIG_TOOLSET msvc)
|
||||
endif()
|
||||
if(VCPKG_DETECTED_MSVC_VERSION LESS "1900")
|
||||
math(EXPR USER_CONFIG_TOOLSET_VERSION "${VCPKG_DETECTED_MSVC_VERSION} / 10 - 60")
|
||||
else()
|
||||
math(EXPR USER_CONFIG_TOOLSET_VERSION "${VCPKG_DETECTED_MSVC_VERSION} / 10 - 50")
|
||||
endif()
|
||||
endif()
|
||||
elseif(VCPKG_TARGET_ARCHITECTURE STREQUAL "wasm32")
|
||||
set(USER_CONFIG_TOOLSET emscripten)
|
||||
elseif(VCPKG_DETECTED_CMAKE_CXX_COMPILER_ID MATCHES "Clang")
|
||||
@ -144,7 +144,7 @@ if(CFLAGS MATCHES "-Zi" OR CXXFLAGS MATCHES "-Zi")
|
||||
)
|
||||
endif()
|
||||
|
||||
if(USER_CONFIG_TOOLSET STREQUAL "msvc")
|
||||
if(USER_CONFIG_TOOLSET MATCHES "^(msvc|clang-win)$")
|
||||
file(TO_CMAKE_PATH "${CMAKE_CURRENT_LIST_DIR}/nothing.bat" NOTHING_BAT)
|
||||
string(APPEND USER_CONFIG_TOOLSET_OPTIONS
|
||||
" <setup>\"${NOTHING_BAT}\"\n"
|
||||
@ -171,7 +171,7 @@ if(NOT LDFLAGS STREQUAL "")
|
||||
string(APPEND USER_CONFIG_TOOLSET_OPTIONS " <linkflags>\"${LDFLAGS}\"\n")
|
||||
endif()
|
||||
|
||||
if(WIN32 AND NOT USER_CONFIG_TOOLSET STREQUAL "msvc")
|
||||
if(WIN32 AND NOT USER_CONFIG_TOOLSET MATCHES "^(msvc|clang-win)$")
|
||||
# MINGW here causes b2 to not run cygpath
|
||||
string(APPEND USER_CONFIG_TOOLSET_OPTIONS
|
||||
" <flavor>mingw\n"
|
||||
@ -291,10 +291,10 @@ add_custom_target(boost ALL
|
||||
threading=multi
|
||||
|
||||
stage
|
||||
WORKING_DIRECTORY ${SOURCE_PATH}/build
|
||||
WORKING_DIRECTORY "${SOURCE_PATH}/build"
|
||||
)
|
||||
|
||||
set(SUBDIR ${CMAKE_CURRENT_BINARY_DIR}/stage/lib)
|
||||
set(SUBDIR "${CMAKE_CURRENT_BINARY_DIR}/stage/lib")
|
||||
install(
|
||||
CODE "
|
||||
file(GLOB LIBS \"${SUBDIR}/*.so.*\" \"${SUBDIR}/*.so\" \"${SUBDIR}/*.a\" \"${SUBDIR}/*.dylib\" \"${SUBDIR}/*.dylib.*\" \"${SUBDIR}/*.lib\")
|
||||
|
@ -4,6 +4,7 @@ constant BOOST_JAMROOT_MODULE : $(__name__) ;
|
||||
|
||||
import boostcpp ;
|
||||
import feature ;
|
||||
import configure ;
|
||||
|
||||
boostcpp.set-version $(BOOST_VERSION) ;
|
||||
|
||||
@ -100,10 +101,36 @@ if "@PORT@" != "boost-filesystem"
|
||||
|
||||
if "@PORT@" != "boost-atomic"
|
||||
{
|
||||
lib synchronization ;
|
||||
explicit synchronization ;
|
||||
|
||||
exe has_synchronization_lib : @CURRENT_INSTALLED_DIR@/share/boost-atomic/has_synchronization_lib.cpp : <library>synchronization ;
|
||||
explicit has_synchronization_lib ;
|
||||
|
||||
rule check-synchronization-lib ( properties * )
|
||||
{
|
||||
local result ;
|
||||
|
||||
if <target-os>windows in $(properties)
|
||||
{
|
||||
if [ configure.builds has_synchronization_lib : $(properties) : "has synchronization.lib" ]
|
||||
{
|
||||
result += <library>synchronization ;
|
||||
}
|
||||
else
|
||||
{
|
||||
result += <define>BOOST_ATOMIC_NO_SYNCHRONIZATION_LIB ;
|
||||
}
|
||||
}
|
||||
|
||||
return $(result) ;
|
||||
}
|
||||
use-project /boost/atomic : . ;
|
||||
|
||||
lib boost_atomic : : <file>"@CURRENT_INSTALLED_DIR@/lib/@BOOST_LIB_PREFIX@boost_atomic@BOOST_LIB_RELEASE_SUFFIX@" <variant>release ;
|
||||
lib boost_atomic : : <file>"@CURRENT_INSTALLED_DIR@/debug/lib/@BOOST_LIB_PREFIX@boost_atomic@BOOST_LIB_DEBUG_SUFFIX@" <variant>debug ;
|
||||
lib boost_atomic : : <file>"@CURRENT_INSTALLED_DIR@/lib/@BOOST_LIB_PREFIX@boost_atomic@BOOST_LIB_RELEASE_SUFFIX@" <variant>release : : usage-requirements
|
||||
<conditional>@check-synchronization-lib ;
|
||||
lib boost_atomic : : <file>"@CURRENT_INSTALLED_DIR@/debug/lib/@BOOST_LIB_PREFIX@boost_atomic@BOOST_LIB_DEBUG_SUFFIX@" <variant>debug : : usage-requirements
|
||||
<conditional>@check-synchronization-lib ;
|
||||
explicit boost_atomic ;
|
||||
}
|
||||
|
||||
|
@ -5,7 +5,7 @@ include("${CMAKE_CURRENT_LIST_DIR}/../vcpkg-cmake-get-vars/vcpkg-port-config.cma
|
||||
get_filename_component(BOOST_BUILD_INSTALLED_DIR "${CMAKE_CURRENT_LIST_DIR}" DIRECTORY)
|
||||
get_filename_component(BOOST_BUILD_INSTALLED_DIR "${BOOST_BUILD_INSTALLED_DIR}" DIRECTORY)
|
||||
|
||||
set(BOOST_VERSION 1.82.0)
|
||||
set(BOOST_VERSION "${VERSION}")
|
||||
string(REGEX MATCH "^([0-9]+)\\.([0-9]+)\\.([0-9]+)" BOOST_VERSION_MATCH "${BOOST_VERSION}")
|
||||
if("${CMAKE_MATCH_3}" GREATER 0)
|
||||
set(BOOST_VERSION_ABI_TAG "${CMAKE_MATCH_1}_${CMAKE_MATCH_2}_${CMAKE_MATCH_3}")
|
||||
@ -38,7 +38,6 @@ function(boost_modular_build)
|
||||
else()
|
||||
message(FATAL_ERROR "Could not find b2 in ${BOOST_BUILD_PATH}")
|
||||
endif()
|
||||
|
||||
if(NOT VCPKG_CMAKE_SYSTEM_NAME OR VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
|
||||
set(BOOST_LIB_PREFIX)
|
||||
if(VCPKG_PLATFORM_TOOLSET MATCHES "v14.")
|
||||
@ -102,7 +101,7 @@ function(boost_modular_build)
|
||||
string(REPLACE "." "" PYTHON_VERSION_TAG "${python3_version}")
|
||||
endif()
|
||||
|
||||
configure_file(${BOOST_BUILD_INSTALLED_DIR}/share/boost-build/Jamroot.jam.in ${_bm_SOURCE_PATH}/Jamroot.jam @ONLY)
|
||||
configure_file("${BOOST_BUILD_INSTALLED_DIR}/share/boost-build/Jamroot.jam.in" "${_bm_SOURCE_PATH}/Jamroot.jam" @ONLY)
|
||||
|
||||
set(configure_options)
|
||||
if(_bm_BOOST_CMAKE_FRAGMENT)
|
||||
@ -199,5 +198,5 @@ function(boost_modular_build)
|
||||
message(FATAL_ERROR "No libraries were produced. This indicates a failure while building the boost library.")
|
||||
endif()
|
||||
|
||||
configure_file(${BOOST_BUILD_INSTALLED_DIR}/share/boost-build/usage ${CURRENT_PACKAGES_DIR}/share/${PORT}/usage COPYONLY)
|
||||
configure_file("${BOOST_BUILD_INSTALLED_DIR}/share/boost-build/usage" "${CURRENT_PACKAGES_DIR}/share/${PORT}/usage" COPYONLY)
|
||||
endfunction()
|
||||
|
@ -2,7 +2,7 @@
|
||||
"$comment": "Automatically generated by scripts/boost/generate-ports.ps1",
|
||||
"name": "boost-modular-build-helper",
|
||||
"version": "1.82.0",
|
||||
"port-version": 2,
|
||||
"port-version": 3,
|
||||
"description": "Internal vcpkg port used to build Boost libraries",
|
||||
"license": "MIT",
|
||||
"dependencies": [
|
||||
|
@ -24,7 +24,8 @@ else {
|
||||
# Clear this array when moving to a new boost version
|
||||
$defaultPortVersion = 2
|
||||
$portVersions = @{
|
||||
#e.g. "boost-asio" = 1;
|
||||
"boost-atomic" = 3;
|
||||
"boost-modular-build-helper" = 3;
|
||||
}
|
||||
|
||||
function Get-PortVersion {
|
||||
|
@ -3,3 +3,5 @@ vcpkg_replace_string("${SOURCE_PATH}/build/Jamfile.v2"
|
||||
"project.load [ path.join [ path.make $(here:D) ] ../config/checks/architecture ]"
|
||||
)
|
||||
file(COPY "${CURRENT_INSTALLED_DIR}/share/boost-config/checks" DESTINATION "${SOURCE_PATH}/config")
|
||||
#Make sure to keep this line when updating boost.
|
||||
file(INSTALL "${SOURCE_PATH}/config/has_synchronization_lib.cpp" DESTINATION "${CURRENT_PACKAGES_DIR}/share/boost-atomic")
|
@ -1751,6 +1751,7 @@ vcpkg-ci-arrow:x64-windows-static-md=pass
|
||||
vcpkg-ci-arrow:x64-osx=pass
|
||||
vcpkg-ci-arrow:x64-linux=pass
|
||||
vcpkg-ci-boost:x64-linux=pass
|
||||
vcpkg-ci-boost:arm64-windows=pass
|
||||
vcpkg-ci-boost:x64-osx=pass
|
||||
vcpkg-ci-boost:x64-windows-static-md=pass
|
||||
vcpkg-ci-boost:x64-windows-static=pass
|
||||
|
@ -38,6 +38,11 @@
|
||||
"find-package": {
|
||||
"description": "Ports to be tested via find_package($package)",
|
||||
"dependencies": [
|
||||
{
|
||||
"$package": "Boost",
|
||||
"name":"boost",
|
||||
"platform": "!uwp"
|
||||
},
|
||||
{
|
||||
"$package": "BZip2",
|
||||
"name": "bzip2"
|
||||
|
@ -8,7 +8,8 @@
|
||||
"default-features": false,
|
||||
"features": [
|
||||
"mpi"
|
||||
]
|
||||
],
|
||||
"platform":"!(arm & windows)"
|
||||
},
|
||||
{
|
||||
"name": "boost-asio",
|
||||
@ -22,14 +23,16 @@
|
||||
"default-features": false,
|
||||
"features": [
|
||||
"numa"
|
||||
]
|
||||
],
|
||||
"platform":"!uwp & !arm & !emscripten"
|
||||
},
|
||||
{
|
||||
"name": "boost-locale",
|
||||
"default-features": false,
|
||||
"features": [
|
||||
"icu"
|
||||
]
|
||||
],
|
||||
"platform":"!uwp"
|
||||
},
|
||||
{
|
||||
"name": "boost-mpi",
|
||||
@ -37,29 +40,47 @@
|
||||
"features": [
|
||||
"python3"
|
||||
],
|
||||
"platform": "!static"
|
||||
"platform": "!static & !(arm & windows)"
|
||||
},
|
||||
{
|
||||
"name":"boost-odeint",
|
||||
"default-features":false
|
||||
},
|
||||
{
|
||||
"name": "boost-odeint",
|
||||
"default-features": false,
|
||||
"features": [
|
||||
"mpi"
|
||||
]
|
||||
],
|
||||
"platform": "!(arm & windows)"
|
||||
},
|
||||
{
|
||||
"name": "boost-python",
|
||||
"default-features":false,
|
||||
"features":[
|
||||
"python2"
|
||||
],
|
||||
"platform":"!(arm & windows)"
|
||||
},
|
||||
{
|
||||
"name": "boost-python",
|
||||
"default-features": false,
|
||||
"features": [
|
||||
"python2",
|
||||
"python3"
|
||||
]
|
||||
],
|
||||
"platform":"!uwp"
|
||||
},
|
||||
{
|
||||
"name":"boost-regex",
|
||||
"default-features":false
|
||||
},
|
||||
{
|
||||
"name": "boost-regex",
|
||||
"default-features": false,
|
||||
"features": [
|
||||
"icu"
|
||||
]
|
||||
],
|
||||
"platform":"!uwp"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
@ -1,5 +1,10 @@
|
||||
{
|
||||
"versions": [
|
||||
{
|
||||
"git-tree": "05f82c6b7fe3a31ffb4f16f25eb98473131f201a",
|
||||
"version": "1.82.0",
|
||||
"port-version": 3
|
||||
},
|
||||
{
|
||||
"git-tree": "4cd58a1ad5ec2c381440b733e3799368df678b49",
|
||||
"version": "1.82.0",
|
||||
|
@ -1,5 +1,10 @@
|
||||
{
|
||||
"versions": [
|
||||
{
|
||||
"git-tree": "98f75b07bdab1080c9470eb115836035d7142397",
|
||||
"version": "1.82.0",
|
||||
"port-version": 3
|
||||
},
|
||||
{
|
||||
"git-tree": "3ae088c69a58eb9a5854ff99807397a0c09daf6a",
|
||||
"version": "1.82.0",
|
||||
|
@ -666,7 +666,7 @@
|
||||
},
|
||||
"boost-atomic": {
|
||||
"baseline": "1.82.0",
|
||||
"port-version": 2
|
||||
"port-version": 3
|
||||
},
|
||||
"boost-beast": {
|
||||
"baseline": "1.82.0",
|
||||
@ -934,7 +934,7 @@
|
||||
},
|
||||
"boost-modular-build-helper": {
|
||||
"baseline": "1.82.0",
|
||||
"port-version": 2
|
||||
"port-version": 3
|
||||
},
|
||||
"boost-move": {
|
||||
"baseline": "1.82.0",
|
||||
|
@ -1,5 +1,10 @@
|
||||
{
|
||||
"versions": [
|
||||
{
|
||||
"git-tree": "c6eb09f11e34173a4bfc31252d02d6aea6c25d8f",
|
||||
"version-date": "2023-04-13",
|
||||
"port-version": 0
|
||||
},
|
||||
{
|
||||
"git-tree": "2e624c2cf12a97a7a802e31ff1d28b9fa6ba9bde",
|
||||
"version-date": "2023-03-02",
|
||||
|
Loading…
x
Reference in New Issue
Block a user