2023-01-15 03:20:35 +03:00
|
|
|
distributable:
|
|
|
|
url: https://codeload.github.com/rustls/rustls-ffi/tar.gz/refs/tags/v{{version}}
|
|
|
|
strip-components: 1
|
|
|
|
|
|
|
|
versions:
|
|
|
|
github: rustls/rustls-ffi/tags
|
|
|
|
strip: /v/
|
|
|
|
|
|
|
|
build:
|
|
|
|
dependencies:
|
|
|
|
rust-lang.org/cargo: '*'
|
|
|
|
script: |
|
|
|
|
cargo install cbindgen
|
|
|
|
make DESTDIR={{prefix}}
|
|
|
|
make DESTDIR={{prefix}} install
|
|
|
|
|
|
|
|
test:
|
|
|
|
dependencies:
|
2023-04-16 02:04:12 +03:00
|
|
|
curl.se: '*'
|
2023-01-15 03:20:35 +03:00
|
|
|
env:
|
2023-03-30 00:25:52 +03:00
|
|
|
ARGS:
|
2023-01-15 03:20:35 +03:00
|
|
|
- -lrustls
|
|
|
|
linux:
|
2023-03-30 00:25:52 +03:00
|
|
|
ARGS:
|
|
|
|
- -Wl,--gc-sections
|
2023-01-15 03:20:35 +03:00
|
|
|
- -lpthread
|
|
|
|
- -ldl
|
|
|
|
darwin:
|
2023-03-30 00:25:52 +03:00
|
|
|
ARGS:
|
|
|
|
- -Wl,-dead_strip
|
2023-01-15 03:20:35 +03:00
|
|
|
- -framework Security
|
2023-03-30 00:25:52 +03:00
|
|
|
- -framework Foundation
|
2023-04-16 02:04:12 +03:00
|
|
|
TESTFILES:
|
|
|
|
- client.c
|
|
|
|
- common.c
|
|
|
|
- common.h
|
2023-01-15 03:20:35 +03:00
|
|
|
script: |
|
2023-04-16 02:04:12 +03:00
|
|
|
for file in $TESTFILES; do
|
|
|
|
curl -O https://raw.githubusercontent.com/rustls/rustls-ffi/v{{ version }}/tests/$file
|
|
|
|
done
|
2023-03-30 00:25:52 +03:00
|
|
|
cc client.c common.c -o client $ARGS
|
2023-01-15 03:20:35 +03:00
|
|
|
CA_FILE=$SSL_CERT_FILE ./client tea.xyz 443 /
|