Skip to content

Commit

Permalink
arm support (#185)
Browse files Browse the repository at this point in the history
* update boring and drop bazel

* arm build

* up

* bump 0.1.8

* separate target

* up

* up

* up

* up

* up

* up

* up

* up
  • Loading branch information
ibigbug authored Nov 22, 2023
1 parent 91a0ce5 commit 13ac356
Show file tree
Hide file tree
Showing 13 changed files with 71 additions and 22,175 deletions.
12 changes: 0 additions & 12 deletions .bazelrc

This file was deleted.

11 changes: 10 additions & 1 deletion .cargo/config
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,13 @@ rustflags = ["--cfg", "tokio_unstable"]

[env]
BORING_BSSL_SOURCE_PATH = { value = "deps/boringssl/src", relative = true}
RUST_LOG = { value = "clash=trace" }
RUST_LOG = { value = "clash=trace" }

[target.aarch64-unknown-linux-gnu]
linker = "/usr/bin/aarch64-linux-gnu-gcc"

[target.armv7-unknown-linux-gnueabihf]
linker = "/usr/bin/arm-linux-gnueabihf-gcc"

[target.armv7-unknown-linux-gnueabi]
linker = "/usr/bin/arm-linux-gnueabi-gcc"
30 changes: 12 additions & 18 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,31 +27,25 @@ jobs:
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
# https://github.com/bazelbuild/rules_rust/issues/1966
# maybe we should not use bazel anymore
# - run: CARGO_BAZEL_ISOLATED=0 CARGO_BAZEL_REPIN=true bazelisk test --test_output=all //clash_lib/... //clash/...
- uses: Swatinem/rust-cache@v2
- run: cargo test --all --all-features

publish:
name: publish ${{ matrix.platforms.target }} on ${{ matrix.platforms.os }}
if: contains(github.ref, 'tags/v')
needs: [test]
runs-on: ${{ matrix.os }}
container: ${{ matrix.container }}
runs-on: ${{ matrix.platforms.os }}
strategy:
matrix:
os: [ubuntu-22.04, macos-13, windows-2022]
include:
- os: ubuntu-22.04
targets: >
x86_64-unknown-linux-gnu
- os: macos-13
targets: >
aarch64-apple-darwin
x86_64-apple-darwin
- os: windows-2022
targets: >
x86_64-pc-windows-msvc
platforms: [
{os: ubuntu-22.04, target: x86_64-unknown-linux-gnu},
{os: ubuntu-22.04, target: aarch64-unknown-linux-gnu},
{os: ubuntu-22.04, target: armv7-unknown-linux-gnueabihf},
{os: ubuntu-22.04, target: armv7-unknown-linux-gnueabi},
{os: macos-13, target: aarch64-apple-darwin},
{os: macos-13, target: x86_64-apple-darwin},
{os: windows-2022, target: x86_64-pc-windows-msvc},
]
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -65,7 +59,7 @@ jobs:
toolchain: stable
- uses: Swatinem/rust-cache@v2
- name: Build
run: sh ./scripts/build.sh "${{ matrix.targets }}"
run: sh ./scripts/build.sh "${{ matrix.platforms.target }}"
- name: Create Release
id: create_release
uses: softprops/action-gh-release@v1
Expand Down
1 change: 0 additions & 1 deletion BUILD.bazel

This file was deleted.

Loading

0 comments on commit 13ac356

Please sign in to comment.