2022-10-27 09:05:13 +03:00
|
|
|
distributable:
|
|
|
|
url: https://github.com/rust-lang/cargo/archive/refs/tags/{{version}}.tar.gz
|
|
|
|
strip-components: 1
|
|
|
|
|
|
|
|
versions:
|
|
|
|
github: rust-lang/cargo/tags
|
|
|
|
|
|
|
|
provides:
|
|
|
|
- bin/cargo
|
|
|
|
|
2023-03-28 15:42:12 +03:00
|
|
|
runtime:
|
|
|
|
env:
|
2023-10-02 03:03:16 +03:00
|
|
|
CARGO_INSTALL_ROOT: ${{home}}/.local
|
2023-03-28 15:42:12 +03:00
|
|
|
|
2023-10-06 17:13:00 +03:00
|
|
|
companions:
|
2023-10-05 19:26:05 +03:00
|
|
|
git-scm.org: ^2
|
2022-10-27 09:05:13 +03:00
|
|
|
rust-lang.org: '*'
|
2023-10-06 17:13:00 +03:00
|
|
|
|
|
|
|
dependencies:
|
2023-03-28 15:42:12 +03:00
|
|
|
zlib.net: ^1
|
2023-10-05 19:26:05 +03:00
|
|
|
libgit2.org: ^1
|
2023-10-09 23:36:00 +03:00
|
|
|
curl.se/ca-certs: '*'
|
2023-10-05 19:26:05 +03:00
|
|
|
linux:
|
2023-10-06 17:13:00 +03:00
|
|
|
llvm.org: '*' # FIXME only need the linker actually
|
|
|
|
curl.se: '*'
|
|
|
|
# ^^ Apple adds patches to curl on Darwin that prevent breakage with this pkg
|
|
|
|
# NOTE maybe in general we should just use darwin curl?
|
|
|
|
# https://github.com/pkgxdev/pantry/issues/3520
|
2022-10-27 09:05:13 +03:00
|
|
|
|
|
|
|
build:
|
|
|
|
dependencies:
|
2023-10-06 17:13:00 +03:00
|
|
|
rust-lang.org: '*'
|
2022-10-27 09:05:13 +03:00
|
|
|
gnu.org/tar: '*'
|
|
|
|
tukaani.org/xz: '*'
|
|
|
|
freedesktop.org/pkg-config: ^0.29
|
2023-07-16 06:48:14 +03:00
|
|
|
rust-lang.org/cargo: '*'
|
2023-10-06 15:21:54 +03:00
|
|
|
script:
|
2023-10-09 23:36:00 +03:00
|
|
|
# otherwise we are not ABI compatible and new macOS versions may break
|
|
|
|
# this happened with Sonoma
|
|
|
|
- echo "default = ['curl/force-system-lib-on-osx']" >> Cargo.toml
|
|
|
|
- cargo install
|
2023-10-06 17:13:00 +03:00
|
|
|
--verbose
|
2023-10-06 15:21:54 +03:00
|
|
|
--root={{ prefix }}
|
|
|
|
--path=.
|
2022-10-27 09:05:13 +03:00
|
|
|
env:
|
2023-10-06 15:21:54 +03:00
|
|
|
LIBGIT2_SYS_USE_PKG_CONFIG: 1
|
|
|
|
LIBSSH2_SYS_USE_PKG_CONFIG: 1
|
2023-10-06 17:13:00 +03:00
|
|
|
|
2022-10-27 09:05:13 +03:00
|
|
|
test:
|
2023-10-09 23:36:00 +03:00
|
|
|
dependencies: #FIXME brewkit should add companions to the test env
|
2023-10-06 17:13:00 +03:00
|
|
|
git-scm.org: ^2
|
|
|
|
rust-lang.org: '*'
|
2022-10-27 09:05:13 +03:00
|
|
|
script: |
|
2023-03-29 03:49:54 +03:00
|
|
|
cargo init . --name xyz_tea_fixture
|
2022-10-27 09:05:13 +03:00
|
|
|
echo 'fn main() {println!("Hello World!");}' >src/main.rs
|
|
|
|
cargo clippy
|
|
|
|
cargo run
|
2023-03-28 15:42:12 +03:00
|
|
|
cargo run --release
|
|
|
|
cargo install cowsay
|
|
|
|
test -x ~/.local/bin/cowsay
|
|
|
|
~/.local/bin/cowsay xyz.tea.hi
|