Skip to content

Commit aa2d376

Browse files
authored
[workflow] Split Windows branch to separate port (#48855)
1 parent afcc8a3 commit aa2d376

11 files changed

Lines changed: 111 additions & 34 deletions

File tree

ports/kedixa-coke/vcpkg.json

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"name": "kedixa-coke",
33
"version": "0.7.0",
4+
"port-version": 1,
45
"description": "Coroutine Workflow based on C++ 20",
56
"homepage": "https://github.com/kedixa/coke",
67
"license": "Apache-2.0",
@@ -15,6 +16,13 @@
1516
"name": "vcpkg-cmake-config",
1617
"host": true
1718
},
18-
"workflow"
19+
{
20+
"name": "workflow",
21+
"platform": "!windows | mingw"
22+
},
23+
{
24+
"name": "workflow-win",
25+
"platform": "windows & !mingw"
26+
}
1927
]
2028
}

ports/srpc/vcpkg.json

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"name": "srpc",
33
"version-semver": "0.10.4",
4+
"port-version": 1,
45
"description": "RPC based on Sogou C++ Workflow",
56
"homepage": "https://github.com/sogou/srpc",
67
"license": "Apache-2.0",
@@ -17,7 +18,14 @@
1718
"name": "vcpkg-cmake-config",
1819
"host": true
1920
},
20-
"workflow",
21+
{
22+
"name": "workflow",
23+
"platform": "!windows | mingw"
24+
},
25+
{
26+
"name": "workflow-win",
27+
"platform": "windows & !mingw"
28+
},
2129
"zlib"
2230
]
2331
}

ports/workflow-win/portfile.cmake

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
vcpkg_from_github(
2+
OUT_SOURCE_PATH SOURCE_PATH
3+
REPO sogou/workflow
4+
REF b92ead03ec62609a3cc1293041a9caa58a6b4800
5+
SHA512 4f9ac3daefcafaffe9121bd2b91b7a9311bd9f09690f723c970ebeab9f092fe3cd6745983c459c9781f673e898d74b6382e654db758914e9c73f9462394e2f73
6+
HEAD_REF windows
7+
)
8+
9+
string(COMPARE EQUAL "${VCPKG_CRT_LINKAGE}" "static" BUILD_STATIC_RUNTIME)
10+
11+
vcpkg_cmake_configure(
12+
SOURCE_PATH "${SOURCE_PATH}"
13+
DISABLE_PARALLEL_CONFIGURE # because configure_package_config_file to ${PROJECT_SOURCE_DIR}
14+
OPTIONS
15+
-DWORKFLOW_BUILD_STATIC_RUNTIME=${BUILD_STATIC_RUNTIME}
16+
)
17+
vcpkg_cmake_install()
18+
vcpkg_cmake_config_fixup(CONFIG_PATH "lib/cmake/workflow" PACKAGE_NAME "workflow")
19+
vcpkg_copy_pdbs()
20+
21+
file(REMOVE_RECURSE
22+
"${CURRENT_PACKAGES_DIR}/debug/include"
23+
"${CURRENT_PACKAGES_DIR}/debug/share"
24+
"${CURRENT_PACKAGES_DIR}/share/doc"
25+
)
26+
27+
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE")

ports/workflow-win/vcpkg.json

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
{
2+
"name": "workflow-win",
3+
"version": "2026-01-09",
4+
"description": "C++ Parallel Computing and Asynchronous Networking Engine (Windows version)",
5+
"homepage": "https://github.com/sogou/workflow",
6+
"license": "Apache-2.0",
7+
"supports": "windows & !mingw",
8+
"dependencies": [
9+
"openssl",
10+
{
11+
"name": "vcpkg-cmake",
12+
"host": true
13+
},
14+
{
15+
"name": "vcpkg-cmake-config",
16+
"host": true
17+
}
18+
]
19+
}

ports/workflow/portfile.cmake

Lines changed: 14 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,38 +1,23 @@
1-
if(VCPKG_TARGET_IS_WINDOWS AND NOT VCPKG_TARGET_IS_MINGW)
2-
vcpkg_from_github(
3-
OUT_SOURCE_PATH SOURCE_PATH
4-
REPO sogou/workflow
5-
REF "v0.11.8-win"
6-
SHA512 4d33904742c41b9cc5efb38a0950dd1f1ef5a0aacab1d3c1fda899244af5b63e734c74dcb5a231623518880b90fa1db5280bf03c4186e94d293fcd2ad6286929
7-
HEAD_REF windows
8-
)
9-
else()
10-
vcpkg_from_github(
11-
OUT_SOURCE_PATH SOURCE_PATH
12-
REPO sogou/workflow
13-
REF "v${VERSION}"
14-
SHA512 78996029efd23ca7843f4089d801729174bf8e6bcb1babbe6f557db0c0b4094069dce38328332ddcddffec6710e77cfd03110264d0c670b8cd42b23dda5061ed
15-
HEAD_REF master
16-
)
17-
endif()
18-
19-
if(VCPKG_CRT_LINKAGE STREQUAL "static")
20-
set(CONFIGURE_OPTIONS "-DWORKFLOW_BUILD_STATIC_RUNTIME=ON")
21-
else()
22-
set(CONFIGURE_OPTIONS "-DWORKFLOW_BUILD_STATIC_RUNTIME=OFF")
23-
endif()
1+
vcpkg_from_github(
2+
OUT_SOURCE_PATH SOURCE_PATH
3+
REPO sogou/workflow
4+
REF "v${VERSION}"
5+
SHA512 78996029efd23ca7843f4089d801729174bf8e6bcb1babbe6f557db0c0b4094069dce38328332ddcddffec6710e77cfd03110264d0c670b8cd42b23dda5061ed
6+
HEAD_REF master
7+
)
248

259
vcpkg_cmake_configure(
2610
SOURCE_PATH "${SOURCE_PATH}"
27-
DISABLE_PARALLEL_CONFIGURE
28-
OPTIONS ${CONFIGURE_OPTIONS}
11+
DISABLE_PARALLEL_CONFIGURE # because configure_package_config_file to ${PROJECT_SOURCE_DIR}
2912
)
3013
vcpkg_cmake_install()
31-
vcpkg_cmake_config_fixup(CONFIG_PATH "lib/cmake/${PORT}")
14+
vcpkg_cmake_config_fixup(CONFIG_PATH "lib/cmake/workflow")
3215
vcpkg_copy_pdbs()
3316

34-
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
35-
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
36-
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/share/doc")
17+
file(REMOVE_RECURSE
18+
"${CURRENT_PACKAGES_DIR}/debug/include"
19+
"${CURRENT_PACKAGES_DIR}/debug/share"
20+
"${CURRENT_PACKAGES_DIR}/share/doc"
21+
)
3722

3823
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE")

ports/workflow/vcpkg.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
11
{
22
"name": "workflow",
33
"version": "0.11.11",
4-
"description": "About C++ Parallel Computing and Asynchronous Networking Engine",
4+
"port-version": 1,
5+
"description": "C++ Parallel Computing and Asynchronous Networking Engine",
56
"homepage": "https://github.com/sogou/workflow",
67
"license": "Apache-2.0",
8+
"supports": "!windows | mingw",
79
"dependencies": [
810
"openssl",
911
{

versions/baseline.json

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4218,7 +4218,7 @@
42184218
},
42194219
"kedixa-coke": {
42204220
"baseline": "0.7.0",
4221-
"port-version": 0
4221+
"port-version": 1
42224222
},
42234223
"kenlm": {
42244224
"baseline": "20230531",
@@ -9442,7 +9442,7 @@
94429442
},
94439443
"srpc": {
94449444
"baseline": "0.10.4",
9445-
"port-version": 0
9445+
"port-version": 1
94469446
},
94479447
"sse2neon": {
94489448
"baseline": "1.9.1",
@@ -10698,6 +10698,10 @@
1069810698
},
1069910699
"workflow": {
1070010700
"baseline": "0.11.11",
10701+
"port-version": 1
10702+
},
10703+
"workflow-win": {
10704+
"baseline": "2026-01-09",
1070110705
"port-version": 0
1070210706
},
1070310707
"wpilib": {

versions/k-/kedixa-coke.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
{
22
"versions": [
3+
{
4+
"git-tree": "cd27cd1c0d601c32d04a8bfe8cb660c69acf4641",
5+
"version": "0.7.0",
6+
"port-version": 1
7+
},
38
{
49
"git-tree": "0fcbbada8de4cf80251ab2d15ea5ea5b87c9aebd",
510
"version": "0.7.0",

versions/s-/srpc.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
{
22
"versions": [
3+
{
4+
"git-tree": "4336be6add18045a17054a0c16df338b3cd9097f",
5+
"version-semver": "0.10.4",
6+
"port-version": 1
7+
},
38
{
49
"git-tree": "b2c3dd8895a29f12367479a1bc98cd1eefd277fa",
510
"version-semver": "0.10.4",

versions/w-/workflow-win.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"versions": [
3+
{
4+
"git-tree": "8d5a082487d44364d43cb8021b63b019c631a51d",
5+
"version": "2026-01-09",
6+
"port-version": 0
7+
}
8+
]
9+
}

0 commit comments

Comments
 (0)