-
Notifications
You must be signed in to change notification settings - Fork 6
feat: Replace outcome
with Boost's version of outcome
to remove dependence on quickcpplib
.
#62
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 7 commits
8243ff7
ee2664b
15a669a
23bae4e
9497510
3047723
aa60263
c0208ac
df69a31
db16c39
00cbc53
c25d371
68f8bef
8a18f96
fa691c3
6a913df
afb5e98
84ee31e
58c4393
4c7a6c6
ccc5d80
2cbca1a
01e95d9
899b5f5
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,8 +3,6 @@ version: "3" | |
vars: | ||
G_CATCH2_LIB_NAME: "Catch2" | ||
G_CATCH2_WORK_DIR: "{{.G_DEPS_DIR}}/{{.G_CATCH2_LIB_NAME}}" | ||
G_OUTCOME_LIB_NAME: "outcome" | ||
G_OUTCOME_WORK_DIR: "{{.G_DEPS_DIR}}/{{.G_OUTCOME_LIB_NAME}}" | ||
G_QUICKCPPLIB_LIB_NAME: "quickcpplib" | ||
G_QUICKCPPLIB_WORK_DIR: "{{.G_DEPS_DIR}}/{{.G_QUICKCPPLIB_LIB_NAME}}" | ||
|
||
|
@@ -26,8 +24,8 @@ tasks: | |
install-all-run: | ||
internal: true | ||
deps: | ||
- "install-boost" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧹 Nitpick (assertive) Integrate Boost into parallel dependency installation 🤖 Prompt for AI Agents
|
||
- "install-Catch2" | ||
- "install-outcome" | ||
|
||
install-all-finish: | ||
internal: true | ||
|
@@ -58,53 +56,190 @@ tasks: | |
internal: true | ||
run: "once" | ||
cmds: | ||
- task: ":utils:cmake-install-remote-tar" | ||
- task: ":utils:cmake:install-remote-tar" | ||
anlowee marked this conversation as resolved.
Show resolved
Hide resolved
|
||
vars: | ||
NAME: "{{.G_CATCH2_LIB_NAME}}" | ||
CMAKE_PACKAGE_NAME: "{{.G_CATCH2_LIB_NAME}}" | ||
WORK_DIR: "{{.G_CATCH2_WORK_DIR}}" | ||
FILE_SHA256: "1ab2de20460d4641553addfdfe6acd4109d871d5531f8f519a52ea4926303087" | ||
URL: "https://github.com/catchorg/Catch2/archive/refs/tags/v3.8.0.tar.gz" | ||
TAR_SHA256: "1ab2de20460d4641553addfdfe6acd4109d871d5531f8f519a52ea4926303087" | ||
TAR_URL: "https://github.com/catchorg/Catch2/archive/refs/tags/v3.8.0.tar.gz" | ||
- task: "add-package-root-to-cmake-settings" | ||
vars: | ||
NAME: "{{.G_CATCH2_LIB_NAME}}" | ||
INSTALL_PREFIX: "{{.G_CATCH2_WORK_DIR}}/{{.G_CATCH2_LIB_NAME}}-install" | ||
|
||
install-outcome: | ||
install-boost: | ||
internal: true | ||
run: "once" | ||
deps: | ||
- "install-quickcpplib" | ||
cmds: | ||
- task: ":utils:cmake-install-remote-tar" | ||
vars: | ||
NAME: "{{.G_OUTCOME_LIB_NAME}}" | ||
WORK_DIR: "{{.G_OUTCOME_WORK_DIR}}" | ||
FILE_SHA256: "0382248cbb00806ce4b5f3ce6939797dc3b597c85fd3531614959e31ef488b39" | ||
URL: "https://github.com/ned14/outcome/archive/refs/tags/v2.2.11.tar.gz" | ||
GEN_ARGS: | ||
- "-C {{.G_DEPS_CMAKE_SETTINGS_DIR}}/{{.G_QUICKCPPLIB_LIB_NAME}}.cmake" | ||
- "-DBUILD_TESTING=OFF" | ||
- "-DCMAKE_BUILD_TYPE=Release" | ||
- "-DCMAKE_POLICY_DEFAULT_CMP0074=NEW" | ||
- task: "add-package-root-to-cmake-settings" | ||
- task: "boost-download-and-install" | ||
vars: | ||
NAME: "{{.G_OUTCOME_LIB_NAME}}" | ||
INSTALL_PREFIX: "{{.G_OUTCOME_WORK_DIR}}/{{.G_OUTCOME_LIB_NAME}}-install" | ||
WORK_DIR: "{{.G_DEPS_DIR}}/boost" | ||
anlowee marked this conversation as resolved.
Show resolved
Hide resolved
anlowee marked this conversation as resolved.
Show resolved
Hide resolved
|
||
FILE_SHA256: "2128a4c96862b5c0970c1e34d76b1d57e4a1016b80df85ad39667f30b1deba26" | ||
anlowee marked this conversation as resolved.
Show resolved
Hide resolved
|
||
URL: "https://github.com/boostorg/boost/releases/download/boost-1.86.0/\ | ||
boost-1.86.0-b2-nodocs.tar.gz" | ||
CMAKE_SETTINGS_DIR: "{{.G_DEPS_CMAKE_SETTINGS_DIR}}" | ||
TARGETS: | ||
- "filesystem" | ||
- "iostreams" | ||
- "process" | ||
- "program_options" | ||
- "regex" | ||
anlowee marked this conversation as resolved.
Show resolved
Hide resolved
|
||
- "system" | ||
anlowee marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
install-quickcpplib: | ||
# Runs the bootstrap.sh generate step in the given source directory. Boost only supports | ||
# in-source generation and building. | ||
# | ||
# @param {string} SOURCE_DIR Project source directory. | ||
# @param {string} INSTALL_PREFIX Path prefix of where the project should be installed. | ||
# @param {string[]} TARGETS Target libraries to build. | ||
# @param {string[]} [EXTRA_ARGS] Any additional arguments to pass to the generate command. | ||
boost-generate: | ||
internal: true | ||
run: "once" | ||
dir: "{{.SOURCE_DIR}}" | ||
cmds: | ||
- >- | ||
./bootstrap.sh | ||
--prefix="{{.INSTALL_PREFIX}}" | ||
--exec-prefix="{{.INSTALL_PREFIX}}" | ||
--with-libraries={{(join "," .TARGETS)}} | ||
{{- range .EXTRA_ARGS}} | ||
"{{.}}" | ||
{{- end}} | ||
|
||
# Runs the b2 build step for boost. The caller must have previously called `generate` on | ||
# `SOURCE_DIR` for this task to succeed. | ||
# | ||
# @param {string} SOURCE_DIR Directory containing the boost source. | ||
# @param {string[]} [EXTRA_ARGS] Any additional arguments to pass to the build command. | ||
# @param {int} [JOBS] The maximum number of concurrent processes to use when building. If | ||
# omitted, the b2 default number is used. Before 1.76.0, the number was 1. Since 1.76.0, the | ||
# default is the number of cores. | ||
boost-build: | ||
internal: true | ||
dir: "{{.SOURCE_DIR}}" | ||
cmds: | ||
- >- | ||
./b2 | ||
{{- range .EXTRA_ARGS}} | ||
"{{.}}" | ||
{{- end}} | ||
{{- if .JOBS}} | ||
"-j{{.JOBS}}" | ||
{{- end}} | ||
|
||
anlowee marked this conversation as resolved.
Show resolved
Hide resolved
|
||
# Runs the b2 install step for boost. The caller must have previously called `build` on | ||
# `SOURCE_DIR` for this task to succeed. If `CMAKE_SETTINGS_DIR` is set, a settings file will be | ||
# created in that directory, containing a `boost_ROOT` CMake variable that points to | ||
# `INSTALL_PREFIX`. | ||
# | ||
# @param {string} SOURCE_DIR Directory containing the boost source. | ||
# @param {string} INSTALL_PREFIX Path prefix of where the project should be installed. | ||
# @param {string} [CMAKE_SETTINGS_DIR] If set, the directory where the project's CMake settings | ||
# file should be stored. | ||
# @param {string[]} [EXTRA_ARGS] Any additional arguments to pass to the install command. | ||
boost-install: | ||
internal: true | ||
dir: "{{.SOURCE_DIR}}" | ||
cmds: | ||
- task: ":utils:cmake-install-remote-tar" | ||
- >- | ||
./b2 | ||
install | ||
{{- range .EXTRA_ARGS}} | ||
"{{.}}" | ||
{{- end}} | ||
- >- | ||
{{- if .CMAKE_SETTINGS_DIR}} | ||
echo "set(BOOST_ROOT | ||
\"{{.INSTALL_PREFIX}}\" | ||
CACHE PATH | ||
\"Package root for boost.\" | ||
)" >> "{{.CMAKE_SETTINGS_DIR}}/boost.cmake" | ||
{{- end}} | ||
|
||
# Downloads boost from `URL` and installs boost. | ||
# | ||
# General parameters | ||
# @param {string} [WORK_DIR={{.TASK_DIR}}] Base directory to store the install and src | ||
# directories inside. | ||
# @param {string} [SOURCE_DIR={{.WORK_DIR}}/boost-src] Directory in which to extract the tar | ||
# file. | ||
# | ||
# Download parameters | ||
# @param {string} FILE_SHA256 Content hash to verify the downloaded tar file against. | ||
# @param {string} URL | ||
# | ||
# Boost generate parameters | ||
# @param {string} [INSTALL_PREFIX={{.WORK_DIR}}/boost-install] Path prefix of where the project | ||
# should be installed. | ||
# @param {string[]} TARGETS Target libraries to build. | ||
# @param {string[]} [GEN_ARGS] Any additional arguments to pass to the generate command. | ||
# | ||
# Boost build parameters | ||
# @param {int} [JOBS] The maximum number of concurrent processes to use when building. If | ||
# omitted, the b2 default number is used. Before 1.76.0, the number was 1. Since 1.76.0, the | ||
# default is the number of cores. | ||
# @param {string[]} [BUILD_ARGS] Any additional arguments to pass to the build command. | ||
# | ||
# Boost install parameters | ||
# @param {string[]} [INSTALL_ARGS] Any additional arguments to pass to the install command. | ||
# @param {string} [CMAKE_SETTINGS_DIR] If set, the directory where the project's CMake settings | ||
# file should be stored. | ||
boost-download-and-install: | ||
internal: true | ||
label: "{{.TASK}}:{{.URL}}-{{.INSTALL_PREFIX}}" | ||
vars: | ||
# General parameters | ||
WORK_DIR: >- | ||
{{default .ROOT_DIR .WORK_DIR}} | ||
SOURCE_DIR: >- | ||
{{default (printf "%s/boost-src" .WORK_DIR) .SOURCE_DIR}} | ||
|
||
# Boost generate parameters | ||
INSTALL_PREFIX: >- | ||
{{default (printf "%s/boost-install" .WORK_DIR) .INSTALL_PREFIX}} | ||
TARGETS: | ||
ref: "default (list) .TARGETS" | ||
GEN_ARGS: | ||
ref: "default (list) .GEN_ARGS" | ||
|
||
# Boost build parameters | ||
BUILD_ARGS: | ||
ref: "default (list) .BUILD_ARGS" | ||
JOBS: >- | ||
{{default "" .JOBS}} | ||
|
||
# Boost install parameters | ||
INSTALL_ARGS: | ||
ref: "default (list) .INSTALL_ARGS" | ||
CMAKE_SETTINGS_DIR: >- | ||
{{default "" .CMAKE_SETTINGS_DIR}} | ||
anlowee marked this conversation as resolved.
Show resolved
Hide resolved
|
||
requires: | ||
vars: ["FILE_SHA256", "URL"] | ||
deps: | ||
- task: ":utils:remote:download-and-extract-tar" | ||
vars: | ||
NAME: "{{.G_QUICKCPPLIB_LIB_NAME}}" | ||
WORK_DIR: "{{.G_QUICKCPPLIB_WORK_DIR}}" | ||
FILE_SHA256: "5d4c9b2d6fa177d3fb14f3fe3086867e43b44f4a7a944eb10ee4616b2b0f3c05" | ||
URL: "https://github.com/ned14/quickcpplib/archive/f3e452e.tar.gz" | ||
GEN_ARGS: | ||
- "-DBUILD_TESTING=OFF" | ||
- "-DCMAKE_BUILD_TYPE=Release" | ||
- task: "add-package-root-to-cmake-settings" | ||
FILE_SHA256: "{{.FILE_SHA256}}" | ||
OUTPUT_DIR: "{{.SOURCE_DIR}}" | ||
URL: "{{.URL}}" | ||
cmds: | ||
- task: "boost-generate" | ||
vars: | ||
SOURCE_DIR: "{{.SOURCE_DIR}}" | ||
INSTALL_PREFIX: "{{.INSTALL_PREFIX}}" | ||
TARGETS: | ||
ref: ".TARGETS" | ||
EXTRA_ARGS: | ||
ref: ".GEN_ARGS" | ||
- task: "boost-build" | ||
vars: | ||
SOURCE_DIR: "{{.SOURCE_DIR}}" | ||
JOBS: "{{.JOBS}}" | ||
EXTRA_ARGS: | ||
ref: ".BUILD_ARGS" | ||
- task: "boost-install" | ||
vars: | ||
NAME: "{{.G_QUICKCPPLIB_LIB_NAME}}" | ||
INSTALL_PREFIX: "{{.G_QUICKCPPLIB_WORK_DIR}}/{{.G_QUICKCPPLIB_LIB_NAME}}-install" | ||
SOURCE_DIR: "{{.SOURCE_DIR}}" | ||
INSTALL_PREFIX: "{{.INSTALL_PREFIX}}" | ||
CMAKE_SETTINGS_DIR: "{{.CMAKE_SETTINGS_DIR}}" | ||
EXTRA_ARGS: | ||
ref: ".INSTALL_ARGS" |
Uh oh!
There was an error while loading. Please reload this page.