Skip to content

Commit cd2db95

Browse files
committed
Exemplar updates since 2026-04-26
Update infra submodule to ea3ef79 and move INSTALL_GTEST=OFF into lockfile.json cmake_args Raise gtest_discover_tests DISCOVERY_TIMEOUT to 60s in tests/beman/transform_view/CMakeLists.txt Add vcpkg port templates, manifest, and CI/release workflows; bump infra submodule and infra-workflows to 1.6.0 Bump vcpkg-configuration.json default-registry and beman registry baselines
1 parent 04f9433 commit cd2db95

16 files changed

Lines changed: 186 additions & 12 deletions

.exemplar_version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
b1e7015b1bd62ce5b20009cec7ee98ba5c783818
1+
a8a97fdec16bfd081aa1814402f13b6a20327046

.github/workflows/ci_tests.yml

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@ on:
1313

1414
jobs:
1515
beman-submodule-check:
16-
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-submodule-check.yml@1.5.3
16+
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-submodule-check.yml@1.6.0
1717

1818
preset-test:
19-
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-preset-test.yml@1.5.3
19+
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-preset-test.yml@1.6.0
2020
with:
2121
matrix_config: >
2222
[
@@ -31,7 +31,7 @@ jobs:
3131
]
3232
3333
build-and-test:
34-
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-build-and-test.yml@1.5.3
34+
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-build-and-test.yml@1.6.0
3535
with:
3636
matrix_config: >
3737
{
@@ -123,7 +123,12 @@ jobs:
123123
]
124124
}
125125
126+
vcpkg-ci:
127+
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-vcpkg-ci.yml@1.6.0
128+
with:
129+
port_name: beman-transform-view
130+
126131
create-issue-when-fault:
127132
needs: [preset-test, build-and-test]
128133
if: failure() && github.event_name == 'schedule'
129-
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-create-issue-when-fault.yml@1.5.3
134+
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-create-issue-when-fault.yml@1.6.0

.github/workflows/pre-commit-check.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ on:
1010

1111
jobs:
1212
pre-commit:
13-
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-pre-commit.yml@1.5.3
13+
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-pre-commit.yml@1.6.0

.github/workflows/pre-commit-update.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ on:
99

1010
jobs:
1111
auto-update-pre-commit:
12-
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-update-pre-commit.yml@1.5.3
12+
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-update-pre-commit.yml@1.6.0
1313
secrets:
1414
APP_ID: ${{ secrets.AUTO_PR_BOT_APP_ID }}
1515
PRIVATE_KEY: ${{ secrets.AUTO_PR_BOT_PRIVATE_KEY }}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
2+
3+
name: vcpkg registry release
4+
on:
5+
release:
6+
types: [published]
7+
jobs:
8+
vcpkg-release:
9+
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-vcpkg-release.yml@1.6.0
10+
with:
11+
port_name: beman-transform-view
12+
secrets:
13+
VCPKG_REGISTRY_TOKEN: ${{ secrets.VCPKG_REGISTRY_TOKEN }}

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,4 +45,4 @@ repos:
4545
hooks:
4646
- id: beman-tidy
4747

48-
exclude: 'cookiecutter/|infra/'
48+
exclude: 'cookiecutter/|infra/|port/'

CONTRIBUTING.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,30 @@ ctest --test-dir build
5454
5555
## Dependency Management
5656

57+
### vcpkg
58+
59+
The best way to install the project's dependencies is to use the vcpkg workflow.
60+
61+
To do so, make sure vcpkg is installed and `VCPKG_ROOT` is defined in your environment,
62+
then specify
63+
`-DCMAKE_TOOLCHAIN_FILE="$VCPKG_ROOT/scripts/buildsystems/vcpkg.cmake"`. Vcpkg will handle
64+
the project's dependencies, including GoogleTest.
65+
66+
Example commands:
67+
68+
```
69+
cmake \
70+
-B build \
71+
-S . \
72+
-DCMAKE_CXX_STANDARD=17 \
73+
-DCMAKE_TOOLCHAIN_FILE="$VCPKG_ROOT/scripts/buildsystems/vcpkg.cmake"
74+
cmake --build build
75+
ctest --test-dir build
76+
```
77+
78+
The file `./vcpkg.json` configures the list of dependencies that will be configured by
79+
vcpkg.
80+
5781
### FetchContent
5882

5983
Instead of installing the project's dependencies via a package manager, you can optionally

README.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,17 @@ For details on building beman.transform_view without using a CMake preset, refer
106106

107107
### Installation
108108

109+
#### Vcpkg
110+
111+
The preferred way to install transform_view is via vcpkg. To do so, after installing vcpkg
112+
itself, you need to add support for the Beman project's [vcpkg
113+
registry](https://github.com/bemanproject/vcpkg-registry) by configuring a
114+
`vcpkg-configuration.json` file (which transform_view [provides](vcpkg-configuration.json)).
115+
116+
Then, simply run `vcpkg install beman-transform-view`.
117+
118+
#### Manual
119+
109120
To install beman.transform_view globally after building with the `gcc-release` preset, you can
110121
run:
111122

infra/.beman_submodule

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
[beman_submodule]
22
remote=https://github.com/bemanproject/infra.git
3-
commit_hash=dfdb103b5fc9cccd3424c377130e318466f1dd89
3+
commit_hash=3a49dffbffbfd1c405ce36091dfc68ad02dd6965

infra/cmake/use-fetch-content.cmake

Lines changed: 46 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,50 @@ function(BemanExemplar_provideDependency method package_name)
157157
GIT_TAG "${BemanExemplar_tag}"
158158
EXCLUDE_FROM_ALL
159159
)
160-
set(INSTALL_GTEST OFF) # Disable GoogleTest installation
160+
161+
# Apply per-dependency cmake_args from the lockfile
162+
string(
163+
JSON BemanExemplar_cmakeArgs
164+
ERROR_VARIABLE BemanExemplar_cmakeArgsError
165+
GET "${BemanExemplar_depObj}"
166+
"cmake_args"
167+
)
168+
if(NOT BemanExemplar_cmakeArgsError)
169+
string(
170+
JSON BemanExemplar_numCmakeArgs
171+
LENGTH "${BemanExemplar_cmakeArgs}"
172+
)
173+
if(BemanExemplar_numCmakeArgs GREATER 0)
174+
math(
175+
EXPR
176+
BemanExemplar_maxArgIndex
177+
"${BemanExemplar_numCmakeArgs} - 1"
178+
)
179+
foreach(
180+
BemanExemplar_argIndex
181+
RANGE "${BemanExemplar_maxArgIndex}"
182+
)
183+
string(
184+
JSON BemanExemplar_argKey
185+
MEMBER "${BemanExemplar_cmakeArgs}"
186+
"${BemanExemplar_argIndex}"
187+
)
188+
string(
189+
JSON BemanExemplar_argValue
190+
GET "${BemanExemplar_cmakeArgs}"
191+
"${BemanExemplar_argKey}"
192+
)
193+
message(
194+
DEBUG
195+
"Setting ${BemanExemplar_argKey}=${BemanExemplar_argValue} for ${BemanExemplar_name}"
196+
)
197+
set("${BemanExemplar_argKey}"
198+
"${BemanExemplar_argValue}"
199+
)
200+
endforeach()
201+
endif()
202+
endif()
203+
161204
FetchContent_MakeAvailable("${BemanExemplar_name}")
162205

163206
# Catch2's CTest integration module isn't on CMAKE_MODULE_PATH
@@ -179,6 +222,8 @@ function(BemanExemplar_provideDependency method package_name)
179222
endforeach()
180223
endfunction()
181224

225+
set(BEMAN_USE_FETCH_CONTENT_ENABLED ON)
226+
182227
cmake_language(
183228
SET_DEPENDENCY_PROVIDER BemanExemplar_provideDependency
184229
SUPPORTED_METHODS FIND_PACKAGE

0 commit comments

Comments
 (0)