mirror of
https://github.com/shadowsocks/shadowsocks-rust.git
synced 2026-02-09 01:59:16 +08:00
local-redir will not be set by default
This commit is contained in:
@@ -25,7 +25,7 @@ jobs:
|
||||
- restore_cache:
|
||||
key: cargo-cache-{{ arch }}-{{ checksum "rust-version" }}-{{ checksum "Cargo.lock" }}
|
||||
- run:
|
||||
command: BUILD_EXTRA_FEATURES="openssl-vendored" ./build-host-release
|
||||
command: BUILD_EXTRA_FEATURES="openssl-vendored local-redir" ./build-host-release
|
||||
no_output_timeout: 1h
|
||||
- save_cache:
|
||||
paths:
|
||||
|
||||
@@ -57,6 +57,12 @@ install:
|
||||
|
||||
script:
|
||||
- cargo test --no-fail-fast
|
||||
- cargo test --no-fail-fast --features aes-pmac-siv
|
||||
- cargo test --no-fail-fast --no-default-features
|
||||
- cargo test --no-fail-fast --features aes-pmac-siv
|
||||
- cargo test --no-fail-fast --features single-threaded
|
||||
- cargo test --no-fail-fast --features openssl-vendored
|
||||
- cargo test --no-fail-fast --features local-dns-relay
|
||||
- cargo test --no-fail-fast --no-default-features --features "local-http local-http-rustls"
|
||||
- if [ "${TRAVIS_OS_NAME}" = "linux" -o "${TRAVIS_OS_NAME}" = "osx" ]; then
|
||||
cargo test --no-fail-fast --features local-redir
|
||||
fi
|
||||
|
||||
@@ -9,6 +9,12 @@ keywords = ["shadowsocks", "proxy", "socks", "socks5", "firewall"]
|
||||
license = "MIT"
|
||||
edition = "2018"
|
||||
|
||||
[badges]
|
||||
appveyor = { repository = "shadowsocks/shadowsocks-rust", branch = "master", service = "github" }
|
||||
circle-ci = { repository = "shadowsocks/shadowsocks-rust", branch = "master" }
|
||||
travis-ci = { repository = "shadowsocks/shadowsocks-rust", branch = "master" }
|
||||
maintenance = { status = "passively-maintained" }
|
||||
|
||||
[lib]
|
||||
name = "shadowsocks"
|
||||
|
||||
|
||||
11
build.rs
11
build.rs
@@ -1,11 +0,0 @@
|
||||
fn main() {
|
||||
// Enable redir (transparent proxy) for these targets
|
||||
if cfg!(any(
|
||||
target_os = "linux",
|
||||
target_os = "macos",
|
||||
target_os = "freebsd",
|
||||
target_os = "openbsd"
|
||||
)) {
|
||||
println!("cargo:rustc-cfg=feature=\"local-redir\"")
|
||||
}
|
||||
}
|
||||
@@ -31,8 +31,13 @@ function build() {
|
||||
|
||||
RELEASE_DIR="target/${TARGET}/release"
|
||||
|
||||
EXTRA_FEATURES=""
|
||||
if [[ "$TARGET" == *"-linux-"* || "$TARGET" == *"-darwin" ]]; then
|
||||
EXTRA_FEATURES="local-redir"
|
||||
fi
|
||||
|
||||
cross build --target "${TARGET}" \
|
||||
--features "aes-pmac-siv openssl-vendored" \
|
||||
--features "aes-pmac-siv openssl-vendored ${EXTRA_FEATURES}" \
|
||||
--release
|
||||
|
||||
if [[ $? != "0" ]]; then
|
||||
|
||||
Reference in New Issue
Block a user