You've already forked KernelSU-Next
mirror of
https://github.com/KernelSU-Next/KernelSU-Next.git
synced 2025-08-27 23:46:34 +00:00
Compare commits
5 Commits
f0934e6b90
...
dependabot
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
49a0cbfb9a | ||
|
|
1de68a8ed2 | ||
|
|
e0c461322b | ||
|
|
edb99a2c1a | ||
|
|
eaab98b7ec |
2
.github/workflows/avd-kernel.yml
vendored
2
.github/workflows/avd-kernel.yml
vendored
@@ -49,7 +49,7 @@ jobs:
|
||||
remove-haskell: 'true'
|
||||
remove-codeql: 'true'
|
||||
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v5
|
||||
with:
|
||||
path: KernelSU-Next
|
||||
fetch-depth: 0
|
||||
|
||||
4
.github/workflows/build-kernel-a12.yml
vendored
4
.github/workflows/build-kernel-a12.yml
vendored
@@ -51,9 +51,9 @@ jobs:
|
||||
RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
|
||||
steps:
|
||||
- name: Download artifacts
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v5
|
||||
with:
|
||||
path: KernelSU-Next
|
||||
fetch-depth: 0
|
||||
|
||||
4
.github/workflows/build-kernel-a13.yml
vendored
4
.github/workflows/build-kernel-a13.yml
vendored
@@ -85,9 +85,9 @@ jobs:
|
||||
RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
|
||||
steps:
|
||||
- name: Download artifacts
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v5
|
||||
with:
|
||||
path: KernelSU-Next
|
||||
fetch-depth: 0
|
||||
|
||||
4
.github/workflows/build-kernel-a14.yml
vendored
4
.github/workflows/build-kernel-a14.yml
vendored
@@ -106,9 +106,9 @@ jobs:
|
||||
RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
|
||||
steps:
|
||||
- name: Download artifacts
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v5
|
||||
with:
|
||||
path: KernelSU-Next
|
||||
fetch-depth: 0
|
||||
|
||||
4
.github/workflows/build-kernel-a15.yml
vendored
4
.github/workflows/build-kernel-a15.yml
vendored
@@ -76,9 +76,9 @@ jobs:
|
||||
RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
|
||||
steps:
|
||||
- name: Download artifacts
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v5
|
||||
with:
|
||||
path: KernelSU-Next
|
||||
fetch-depth: 0
|
||||
|
||||
2
.github/workflows/build-kernel-arcvm.yml
vendored
2
.github/workflows/build-kernel-arcvm.yml
vendored
@@ -66,7 +66,7 @@ jobs:
|
||||
sudo ln -s --force /usr/bin/clang++-$LLVM_VERSION /usr/bin/clang++
|
||||
|
||||
- name: Checkout KernelSU-Next
|
||||
uses: actions/checkout@v4
|
||||
uses: actions/checkout@v5
|
||||
with:
|
||||
path: KernelSU-Next
|
||||
fetch-depth: 0
|
||||
|
||||
197
.github/workflows/build-manager-ci.yml
vendored
197
.github/workflows/build-manager-ci.yml
vendored
@@ -19,12 +19,48 @@ on:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
check-cache:
|
||||
runs-on: ubuntu-latest
|
||||
outputs:
|
||||
cache-hit: ${{ steps.cache-artifacts.outputs.cache-hit }}
|
||||
cache-key: ${{ steps.generate-cache-key.outputs.cache-key }}
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v5
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Generate cache key from source files
|
||||
id: generate-cache-key
|
||||
run: |
|
||||
# Calculate hash of all files except manager directory
|
||||
HASH=$(find . -type f \
|
||||
-not -path "./manager/*" \
|
||||
-not -path "./.git/*" \
|
||||
-not -path "./.github/workflows/build-manager-ci.yml" \
|
||||
-exec sha256sum {} \; | sort | sha256sum | cut -d' ' -f1)
|
||||
echo "cache-key=artifacts-$HASH" >> $GITHUB_OUTPUT
|
||||
echo "Generated cache key: artifacts-$HASH"
|
||||
|
||||
- name: Check for cached artifacts
|
||||
id: cache-artifacts
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: |
|
||||
cached-artifacts/susfsd
|
||||
cached-artifacts/ksud_overlayfs
|
||||
cached-artifacts/ksud_magic
|
||||
key: ${{ steps.generate-cache-key.outputs.cache-key }}
|
||||
|
||||
build-lkm:
|
||||
needs: check-cache
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: ./.github/workflows/build-lkm.yml
|
||||
secrets: inherit
|
||||
|
||||
build-susfsd:
|
||||
needs: build-lkm
|
||||
needs: [check-cache, build-lkm]
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
strategy:
|
||||
matrix:
|
||||
include:
|
||||
@@ -34,7 +70,8 @@ jobs:
|
||||
os: ${{ matrix.os }}
|
||||
|
||||
build-ksud:
|
||||
needs: build-susfsd
|
||||
needs: [check-cache, build-susfsd]
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
strategy:
|
||||
matrix:
|
||||
include:
|
||||
@@ -49,8 +86,43 @@ jobs:
|
||||
target: ${{ matrix.target }}
|
||||
os: ${{ matrix.os }}
|
||||
|
||||
cache-artifacts:
|
||||
needs: [check-cache, build-ksud]
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Download susfsd artifacts
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: susfsd-linux-android
|
||||
path: cached-artifacts/susfsd
|
||||
|
||||
- name: Download ksud_overlayfs artifacts
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
pattern: ksud_overlayfs-*
|
||||
path: cached-artifacts/ksud_overlayfs
|
||||
merge-multiple: true
|
||||
|
||||
- name: Download ksud_magic artifacts
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
pattern: ksud_magic-*
|
||||
path: cached-artifacts/ksud_magic
|
||||
merge-multiple: true
|
||||
|
||||
- name: Cache artifacts
|
||||
uses: actions/cache/save@v4
|
||||
with:
|
||||
path: |
|
||||
cached-artifacts/susfsd
|
||||
cached-artifacts/ksud_overlayfs
|
||||
cached-artifacts/ksud_magic
|
||||
key: ${{ needs.check-cache.outputs.cache-key }}
|
||||
|
||||
build-manager:
|
||||
needs: build-ksud
|
||||
needs: [check-cache, build-ksud]
|
||||
if: always() && needs.check-cache.result == 'success' && (needs.check-cache.outputs.cache-hit == 'true' || needs.build-ksud.result == 'success')
|
||||
runs-on: ubuntu-latest
|
||||
defaults:
|
||||
run:
|
||||
@@ -58,7 +130,7 @@ jobs:
|
||||
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v4
|
||||
uses: actions/checkout@v5
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
@@ -84,7 +156,7 @@ jobs:
|
||||
fi
|
||||
|
||||
- name: Setup Java
|
||||
uses: actions/setup-java@v4
|
||||
uses: actions/setup-java@v5
|
||||
with:
|
||||
distribution: temurin
|
||||
java-version: 21
|
||||
@@ -92,87 +164,122 @@ jobs:
|
||||
- name: Setup Gradle
|
||||
uses: gradle/actions/setup-gradle@v4
|
||||
|
||||
# Restore cached artifacts if cache hit
|
||||
- name: Restore cached artifacts
|
||||
if: needs.check-cache.outputs.cache-hit == 'true'
|
||||
uses: actions/cache/restore@v4
|
||||
with:
|
||||
path: |
|
||||
cached-artifacts/susfsd
|
||||
cached-artifacts/ksud_overlayfs
|
||||
cached-artifacts/ksud_magic
|
||||
key: ${{ needs.check-cache.outputs.cache-key }}
|
||||
|
||||
# Download fresh artifacts if cache miss
|
||||
- name: Download susfsd
|
||||
uses: actions/download-artifact@v4
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: susfsd-linux-android
|
||||
path: .
|
||||
|
||||
- name: Copy susfsd to app jniLibs
|
||||
run: |
|
||||
mkdir -p app/src/main/jniLibs/arm64-v8a
|
||||
cp -f ../arm64-v8a/susfsd ../manager/app/src/main/jniLibs/arm64-v8a/libsusfsd.so
|
||||
|
||||
mkdir -p app/src/main/jniLibs/armeabi-v7a
|
||||
cp -f ../armeabi-v7a/susfsd ../manager/app/src/main/jniLibs/armeabi-v7a/libsusfsd.so
|
||||
|
||||
mkdir -p app/src/main/jniLibs/x86_64
|
||||
cp -f ../x86_64/susfsd ../manager/app/src/main/jniLibs/x86_64/libsusfsd.so
|
||||
|
||||
|
||||
# Download fresh ksud artifacts if cache miss
|
||||
- name: Download arm64 ksud_overlayfs
|
||||
uses: actions/download-artifact@v4
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_overlayfs-aarch64-linux-android
|
||||
path: ksud_overlayfs
|
||||
|
||||
- name: Download arm ksud_overlayfs
|
||||
uses: actions/download-artifact@v4
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_overlayfs-armv7-linux-androideabi
|
||||
path: ksud_overlayfs
|
||||
|
||||
- name: Download x86_64 ksud_overlayfs
|
||||
uses: actions/download-artifact@v4
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_overlayfs-x86_64-linux-android
|
||||
path: ksud_overlayfs
|
||||
|
||||
- name: Copy ksud_overlayfs to app jniLibs
|
||||
run: |
|
||||
mkdir -p app/src/main/jniLibs/arm64-v8a
|
||||
|
||||
mkdir -p app/src/main/jniLibs/armeabi-v7a
|
||||
|
||||
mkdir -p app/src/main/jniLibs/x86_64
|
||||
|
||||
cp -f ../ksud_overlayfs/aarch64-linux-android/release/ksud ../manager/app/src/main/jniLibs/arm64-v8a/libksud_overlayfs.so
|
||||
|
||||
cp -f ../ksud_overlayfs/armv7-linux-androideabi/release/ksud ../manager/app/src/main/jniLibs/armeabi-v7a/libksud_overlayfs.so
|
||||
|
||||
cp -f ../ksud_overlayfs/x86_64-linux-android/release/ksud ../manager/app/src/main/jniLibs/x86_64/libksud_overlayfs.so
|
||||
|
||||
- name: Download arm64 ksud_magic
|
||||
uses: actions/download-artifact@v4
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_magic-aarch64-linux-android
|
||||
path: ksud_magic
|
||||
|
||||
- name: Download arm ksud_magic
|
||||
uses: actions/download-artifact@v4
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_magic-armv7-linux-androideabi
|
||||
path: ksud_magic
|
||||
|
||||
- name: Download x86_64 ksud_magic
|
||||
uses: actions/download-artifact@v4
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_magic-x86_64-linux-android
|
||||
path: ksud_magic
|
||||
|
||||
# Copy artifacts to jniLibs (works for both cached and fresh)
|
||||
- name: Copy susfsd to app jniLibs
|
||||
run: |
|
||||
mkdir -p app/src/main/jniLibs/arm64-v8a
|
||||
mkdir -p app/src/main/jniLibs/armeabi-v7a
|
||||
mkdir -p app/src/main/jniLibs/x86_64
|
||||
|
||||
if [ "${{ needs.check-cache.outputs.cache-hit }}" == "true" ]; then
|
||||
# Copy from cached artifacts
|
||||
cp -f ../cached-artifacts/susfsd/arm64-v8a/susfsd ../manager/app/src/main/jniLibs/arm64-v8a/libsusfsd.so
|
||||
cp -f ../cached-artifacts/susfsd/armeabi-v7a/susfsd ../manager/app/src/main/jniLibs/armeabi-v7a/libsusfsd.so
|
||||
cp -f ../cached-artifacts/susfsd/x86_64/susfsd ../manager/app/src/main/jniLibs/x86_64/libsusfsd.so
|
||||
else
|
||||
# Copy from fresh artifacts
|
||||
cp -f ../arm64-v8a/susfsd ../manager/app/src/main/jniLibs/arm64-v8a/libsusfsd.so
|
||||
cp -f ../armeabi-v7a/susfsd ../manager/app/src/main/jniLibs/armeabi-v7a/libsusfsd.so
|
||||
cp -f ../x86_64/susfsd ../manager/app/src/main/jniLibs/x86_64/libsusfsd.so
|
||||
fi
|
||||
|
||||
- name: Copy ksud_overlayfs to app jniLibs
|
||||
run: |
|
||||
mkdir -p app/src/main/jniLibs/arm64-v8a
|
||||
mkdir -p app/src/main/jniLibs/armeabi-v7a
|
||||
mkdir -p app/src/main/jniLibs/x86_64
|
||||
|
||||
if [ "${{ needs.check-cache.outputs.cache-hit }}" == "true" ]; then
|
||||
# Copy from cached artifacts
|
||||
cp -f ../cached-artifacts/ksud_overlayfs/aarch64-linux-android/release/ksud ../manager/app/src/main/jniLibs/arm64-v8a/libksud_overlayfs.so
|
||||
cp -f ../cached-artifacts/ksud_overlayfs/armv7-linux-androideabi/release/ksud ../manager/app/src/main/jniLibs/armeabi-v7a/libksud_overlayfs.so
|
||||
cp -f ../cached-artifacts/ksud_overlayfs/x86_64-linux-android/release/ksud ../manager/app/src/main/jniLibs/x86_64/libksud_overlayfs.so
|
||||
else
|
||||
# Copy from fresh artifacts
|
||||
cp -f ../ksud_overlayfs/aarch64-linux-android/release/ksud ../manager/app/src/main/jniLibs/arm64-v8a/libksud_overlayfs.so
|
||||
cp -f ../ksud_overlayfs/armv7-linux-androideabi/release/ksud ../manager/app/src/main/jniLibs/armeabi-v7a/libksud_overlayfs.so
|
||||
cp -f ../ksud_overlayfs/x86_64-linux-android/release/ksud ../manager/app/src/main/jniLibs/x86_64/libksud_overlayfs.so
|
||||
fi
|
||||
|
||||
- name: Copy ksud_magic to app jniLibs
|
||||
run: |
|
||||
mkdir -p app/src/main/jniLibs/arm64-v8a
|
||||
|
||||
mkdir -p app/src/main/jniLibs/armeabi-v7a
|
||||
|
||||
mkdir -p app/src/main/jniLibs/x86_64
|
||||
|
||||
cp -f ../ksud_magic/aarch64-linux-android/release/ksud ../manager/app/src/main/jniLibs/arm64-v8a/libksud_magic.so
|
||||
|
||||
cp -f ../ksud_magic/armv7-linux-androideabi/release/ksud ../manager/app/src/main/jniLibs/armeabi-v7a/libksud_magic.so
|
||||
|
||||
cp -f ../ksud_magic/x86_64-linux-android/release/ksud ../manager/app/src/main/jniLibs/x86_64/libksud_magic.so
|
||||
if [ "${{ needs.check-cache.outputs.cache-hit }}" == "true" ]; then
|
||||
# Copy from cached artifacts
|
||||
cp -f ../cached-artifacts/ksud_magic/aarch64-linux-android/release/ksud ../manager/app/src/main/jniLibs/arm64-v8a/libksud_magic.so
|
||||
cp -f ../cached-artifacts/ksud_magic/armv7-linux-androideabi/release/ksud ../manager/app/src/main/jniLibs/armeabi-v7a/libksud_magic.so
|
||||
cp -f ../cached-artifacts/ksud_magic/x86_64-linux-android/release/ksud ../manager/app/src/main/jniLibs/x86_64/libksud_magic.so
|
||||
else
|
||||
# Copy from fresh artifacts
|
||||
cp -f ../ksud_magic/aarch64-linux-android/release/ksud ../manager/app/src/main/jniLibs/arm64-v8a/libksud_magic.so
|
||||
cp -f ../ksud_magic/armv7-linux-androideabi/release/ksud ../manager/app/src/main/jniLibs/armeabi-v7a/libksud_magic.so
|
||||
cp -f ../ksud_magic/x86_64-linux-android/release/ksud ../manager/app/src/main/jniLibs/x86_64/libksud_magic.so
|
||||
fi
|
||||
|
||||
- name: Build with Gradle
|
||||
run: |
|
||||
|
||||
191
.github/workflows/build-manager-spoofed.yml
vendored
191
.github/workflows/build-manager-spoofed.yml
vendored
@@ -21,12 +21,48 @@ on:
|
||||
- cron: "0 12 * * *" # 6 PM UTC+6 | 12 PM UTC
|
||||
|
||||
jobs:
|
||||
check-cache:
|
||||
runs-on: ubuntu-latest
|
||||
outputs:
|
||||
cache-hit: ${{ steps.cache-artifacts.outputs.cache-hit }}
|
||||
cache-key: ${{ steps.generate-cache-key.outputs.cache-key }}
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v5
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Generate cache key from source files
|
||||
id: generate-cache-key
|
||||
run: |
|
||||
# Calculate hash of all files except manager directory
|
||||
HASH=$(find . -type f \
|
||||
-not -path "./manager/*" \
|
||||
-not -path "./.git/*" \
|
||||
-not -path "./.github/workflows/build-manager-spoofed.yml" \
|
||||
-exec sha256sum {} \; | sort | sha256sum | cut -d' ' -f1)
|
||||
echo "cache-key=artifacts-spoofed-$HASH" >> $GITHUB_OUTPUT
|
||||
echo "Generated cache key: artifacts-spoofed-$HASH"
|
||||
|
||||
- name: Check for cached artifacts
|
||||
id: cache-artifacts
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: |
|
||||
cached-artifacts/susfsd
|
||||
cached-artifacts/ksud_overlayfs
|
||||
cached-artifacts/ksud_magic
|
||||
key: ${{ steps.generate-cache-key.outputs.cache-key }}
|
||||
|
||||
build-lkm:
|
||||
needs: check-cache
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: ./.github/workflows/build-lkm.yml
|
||||
secrets: inherit
|
||||
|
||||
build-susfsd:
|
||||
needs: build-lkm
|
||||
needs: [check-cache, build-lkm]
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
strategy:
|
||||
matrix:
|
||||
include:
|
||||
@@ -36,7 +72,8 @@ jobs:
|
||||
os: ${{ matrix.os }}
|
||||
|
||||
build-ksud:
|
||||
needs: build-susfsd
|
||||
needs: [check-cache, build-susfsd]
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
strategy:
|
||||
matrix:
|
||||
include:
|
||||
@@ -51,8 +88,43 @@ jobs:
|
||||
target: ${{ matrix.target }}
|
||||
os: ${{ matrix.os }}
|
||||
|
||||
cache-artifacts:
|
||||
needs: [check-cache, build-ksud]
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Download susfsd artifacts
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: susfsd-linux-android
|
||||
path: cached-artifacts/susfsd
|
||||
|
||||
- name: Download ksud_overlayfs artifacts
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
pattern: ksud_overlayfs-*
|
||||
path: cached-artifacts/ksud_overlayfs
|
||||
merge-multiple: true
|
||||
|
||||
- name: Download ksud_magic artifacts
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
pattern: ksud_magic-*
|
||||
path: cached-artifacts/ksud_magic
|
||||
merge-multiple: true
|
||||
|
||||
- name: Cache artifacts
|
||||
uses: actions/cache/save@v4
|
||||
with:
|
||||
path: |
|
||||
cached-artifacts/susfsd
|
||||
cached-artifacts/ksud_overlayfs
|
||||
cached-artifacts/ksud_magic
|
||||
key: ${{ needs.check-cache.outputs.cache-key }}
|
||||
|
||||
build-manager:
|
||||
needs: build-ksud
|
||||
needs: [check-cache, build-ksud]
|
||||
if: always() && needs.check-cache.result == 'success' && (needs.check-cache.outputs.cache-hit == 'true' || needs.build-ksud.result == 'success')
|
||||
runs-on: ubuntu-latest
|
||||
defaults:
|
||||
run:
|
||||
@@ -60,7 +132,7 @@ jobs:
|
||||
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v4
|
||||
uses: actions/checkout@v5
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
@@ -91,7 +163,7 @@ jobs:
|
||||
fi
|
||||
|
||||
- name: Setup Java
|
||||
uses: actions/setup-java@v4
|
||||
uses: actions/setup-java@v5
|
||||
with:
|
||||
distribution: temurin
|
||||
java-version: 21
|
||||
@@ -99,75 +171,122 @@ jobs:
|
||||
- name: Setup Gradle
|
||||
uses: gradle/actions/setup-gradle@v4
|
||||
|
||||
# Restore cached artifacts if cache hit
|
||||
- name: Restore cached artifacts
|
||||
if: needs.check-cache.outputs.cache-hit == 'true'
|
||||
uses: actions/cache/restore@v4
|
||||
with:
|
||||
path: |
|
||||
cached-artifacts/susfsd
|
||||
cached-artifacts/ksud_overlayfs
|
||||
cached-artifacts/ksud_magic
|
||||
key: ${{ needs.check-cache.outputs.cache-key }}
|
||||
|
||||
# Download fresh artifacts if cache miss
|
||||
- name: Download susfsd
|
||||
uses: actions/download-artifact@v4
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: susfsd-linux-android
|
||||
path: .
|
||||
|
||||
- name: Copy susfsd to app jniLibs
|
||||
run: |
|
||||
mkdir -p app/src/main/jniLibs/arm64-v8a
|
||||
cp -f ../arm64-v8a/susfsd ../manager/app/src/main/jniLibs/arm64-v8a/libsusfsd.so
|
||||
|
||||
mkdir -p app/src/main/jniLibs/armeabi-v7a
|
||||
cp -f ../armeabi-v7a/susfsd ../manager/app/src/main/jniLibs/armeabi-v7a/libsusfsd.so
|
||||
|
||||
mkdir -p app/src/main/jniLibs/x86_64
|
||||
cp -f ../x86_64/susfsd ../manager/app/src/main/jniLibs/x86_64/libsusfsd.so
|
||||
|
||||
|
||||
# Download fresh ksud artifacts if cache miss
|
||||
- name: Download arm64 ksud_overlayfs
|
||||
uses: actions/download-artifact@v4
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_overlayfs-aarch64-linux-android
|
||||
path: ksud_overlayfs
|
||||
|
||||
- name: Download arm ksud_overlayfs
|
||||
uses: actions/download-artifact@v4
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_overlayfs-armv7-linux-androideabi
|
||||
path: ksud_overlayfs
|
||||
|
||||
- name: Download x86_64 ksud_overlayfs
|
||||
uses: actions/download-artifact@v4
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_overlayfs-x86_64-linux-android
|
||||
path: ksud_overlayfs
|
||||
|
||||
- name: Copy ksud_overlayfs to app jniLibs
|
||||
run: |
|
||||
cp -f ../ksud_overlayfs/aarch64-linux-android/release/ksud ../manager/app/src/main/jniLibs/arm64-v8a/libksud_overlayfs.so
|
||||
|
||||
cp -f ../ksud_overlayfs/armv7-linux-androideabi/release/ksud ../manager/app/src/main/jniLibs/armeabi-v7a/libksud_overlayfs.so
|
||||
|
||||
cp -f ../ksud_overlayfs/x86_64-linux-android/release/ksud ../manager/app/src/main/jniLibs/x86_64/libksud_overlayfs.so
|
||||
|
||||
- name: Download arm64 ksud_magic
|
||||
uses: actions/download-artifact@v4
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_magic-aarch64-linux-android
|
||||
path: ksud_magic
|
||||
|
||||
- name: Download arm ksud_magic
|
||||
uses: actions/download-artifact@v4
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_magic-armv7-linux-androideabi
|
||||
path: ksud_magic
|
||||
|
||||
- name: Download x86_64 ksud_magic
|
||||
uses: actions/download-artifact@v4
|
||||
if: needs.check-cache.outputs.cache-hit != 'true'
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_magic-x86_64-linux-android
|
||||
path: ksud_magic
|
||||
|
||||
# Copy artifacts to jniLibs (works for both cached and fresh)
|
||||
- name: Copy susfsd to app jniLibs
|
||||
run: |
|
||||
mkdir -p app/src/main/jniLibs/arm64-v8a
|
||||
mkdir -p app/src/main/jniLibs/armeabi-v7a
|
||||
mkdir -p app/src/main/jniLibs/x86_64
|
||||
|
||||
if [ "${{ needs.check-cache.outputs.cache-hit }}" == "true" ]; then
|
||||
# Copy from cached artifacts
|
||||
cp -f ../cached-artifacts/susfsd/arm64-v8a/susfsd ../manager/app/src/main/jniLibs/arm64-v8a/libsusfsd.so
|
||||
cp -f ../cached-artifacts/susfsd/armeabi-v7a/susfsd ../manager/app/src/main/jniLibs/armeabi-v7a/libsusfsd.so
|
||||
cp -f ../cached-artifacts/susfsd/x86_64/susfsd ../manager/app/src/main/jniLibs/x86_64/libsusfsd.so
|
||||
else
|
||||
# Copy from fresh artifacts
|
||||
cp -f ../arm64-v8a/susfsd ../manager/app/src/main/jniLibs/arm64-v8a/libsusfsd.so
|
||||
cp -f ../armeabi-v7a/susfsd ../manager/app/src/main/jniLibs/armeabi-v7a/libsusfsd.so
|
||||
cp -f ../x86_64/susfsd ../manager/app/src/main/jniLibs/x86_64/libsusfsd.so
|
||||
fi
|
||||
|
||||
- name: Copy ksud_overlayfs to app jniLibs
|
||||
run: |
|
||||
mkdir -p app/src/main/jniLibs/arm64-v8a
|
||||
mkdir -p app/src/main/jniLibs/armeabi-v7a
|
||||
mkdir -p app/src/main/jniLibs/x86_64
|
||||
|
||||
if [ "${{ needs.check-cache.outputs.cache-hit }}" == "true" ]; then
|
||||
# Copy from cached artifacts
|
||||
cp -f ../cached-artifacts/ksud_overlayfs/aarch64-linux-android/release/ksud ../manager/app/src/main/jniLibs/arm64-v8a/libksud_overlayfs.so
|
||||
cp -f ../cached-artifacts/ksud_overlayfs/armv7-linux-androideabi/release/ksud ../manager/app/src/main/jniLibs/armeabi-v7a/libksud_overlayfs.so
|
||||
cp -f ../cached-artifacts/ksud_overlayfs/x86_64-linux-android/release/ksud ../manager/app/src/main/jniLibs/x86_64/libksud_overlayfs.so
|
||||
else
|
||||
# Copy from fresh artifacts
|
||||
cp -f ../ksud_overlayfs/aarch64-linux-android/release/ksud ../manager/app/src/main/jniLibs/arm64-v8a/libksud_overlayfs.so
|
||||
cp -f ../ksud_overlayfs/armv7-linux-androideabi/release/ksud ../manager/app/src/main/jniLibs/armeabi-v7a/libksud_overlayfs.so
|
||||
cp -f ../ksud_overlayfs/x86_64-linux-android/release/ksud ../manager/app/src/main/jniLibs/x86_64/libksud_overlayfs.so
|
||||
fi
|
||||
|
||||
- name: Copy ksud_magic to app jniLibs
|
||||
run: |
|
||||
cp -f ../ksud_magic/aarch64-linux-android/release/ksud ../manager/app/src/main/jniLibs/arm64-v8a/libksud_magic.so
|
||||
|
||||
cp -f ../ksud_magic/armv7-linux-androideabi/release/ksud ../manager/app/src/main/jniLibs/armeabi-v7a/libksud_magic.so
|
||||
mkdir -p app/src/main/jniLibs/arm64-v8a
|
||||
mkdir -p app/src/main/jniLibs/armeabi-v7a
|
||||
mkdir -p app/src/main/jniLibs/x86_64
|
||||
|
||||
cp -f ../ksud_magic/x86_64-linux-android/release/ksud ../manager/app/src/main/jniLibs/x86_64/libksud_magic.so
|
||||
if [ "${{ needs.check-cache.outputs.cache-hit }}" == "true" ]; then
|
||||
# Copy from cached artifacts
|
||||
cp -f ../cached-artifacts/ksud_magic/aarch64-linux-android/release/ksud ../manager/app/src/main/jniLibs/arm64-v8a/libksud_magic.so
|
||||
cp -f ../cached-artifacts/ksud_magic/armv7-linux-androideabi/release/ksud ../manager/app/src/main/jniLibs/armeabi-v7a/libksud_magic.so
|
||||
cp -f ../cached-artifacts/ksud_magic/x86_64-linux-android/release/ksud ../manager/app/src/main/jniLibs/x86_64/libksud_magic.so
|
||||
else
|
||||
# Copy from fresh artifacts
|
||||
cp -f ../ksud_magic/aarch64-linux-android/release/ksud ../manager/app/src/main/jniLibs/arm64-v8a/libksud_magic.so
|
||||
cp -f ../ksud_magic/armv7-linux-androideabi/release/ksud ../manager/app/src/main/jniLibs/armeabi-v7a/libksud_magic.so
|
||||
cp -f ../ksud_magic/x86_64-linux-android/release/ksud ../manager/app/src/main/jniLibs/x86_64/libksud_magic.so
|
||||
fi
|
||||
|
||||
- name: Build with Gradle
|
||||
run: |
|
||||
|
||||
18
.github/workflows/build-manager.yml
vendored
18
.github/workflows/build-manager.yml
vendored
@@ -58,7 +58,7 @@ jobs:
|
||||
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v4
|
||||
uses: actions/checkout@v5
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
@@ -84,7 +84,7 @@ jobs:
|
||||
fi
|
||||
|
||||
- name: Setup Java
|
||||
uses: actions/setup-java@v4
|
||||
uses: actions/setup-java@v5
|
||||
with:
|
||||
distribution: temurin
|
||||
java-version: 21
|
||||
@@ -93,7 +93,7 @@ jobs:
|
||||
uses: gradle/actions/setup-gradle@v4
|
||||
|
||||
- name: Download susfsd
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: susfsd-linux-android
|
||||
path: .
|
||||
@@ -111,19 +111,19 @@ jobs:
|
||||
|
||||
|
||||
- name: Download arm64 ksud_overlayfs
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_overlayfs-aarch64-linux-android
|
||||
path: ksud_overlayfs
|
||||
|
||||
- name: Download arm ksud_overlayfs
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_overlayfs-armv7-linux-androideabi
|
||||
path: ksud_overlayfs
|
||||
|
||||
- name: Download x86_64 ksud_overlayfs
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_overlayfs-x86_64-linux-android
|
||||
path: ksud_overlayfs
|
||||
@@ -137,19 +137,19 @@ jobs:
|
||||
cp -f ../ksud_overlayfs/x86_64-linux-android/release/ksud ../manager/app/src/main/jniLibs/x86_64/libksud_overlayfs.so
|
||||
|
||||
- name: Download arm64 ksud_magic
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_magic-aarch64-linux-android
|
||||
path: ksud_magic
|
||||
|
||||
- name: Download arm ksud_magic
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_magic-armv7-linux-androideabi
|
||||
path: ksud_magic
|
||||
|
||||
- name: Download x86_64 ksud_magic
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: ksud_magic-x86_64-linux-android
|
||||
path: ksud_magic
|
||||
|
||||
2
.github/workflows/build-su.yml
vendored
2
.github/workflows/build-su.yml
vendored
@@ -15,7 +15,7 @@ jobs:
|
||||
name: Build userspace su
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v5
|
||||
with:
|
||||
fetch-depth: 0
|
||||
- name: Setup need_upload
|
||||
|
||||
2
.github/workflows/clippy.yml
vendored
2
.github/workflows/clippy.yml
vendored
@@ -24,7 +24,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v4
|
||||
uses: actions/checkout@v5
|
||||
|
||||
- name: Setup Rust
|
||||
run: rustup update stable
|
||||
|
||||
2
.github/workflows/gki-kernel.yml
vendored
2
.github/workflows/gki-kernel.yml
vendored
@@ -82,7 +82,7 @@ jobs:
|
||||
remove-haskell: 'true'
|
||||
remove-codeql: 'true'
|
||||
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v5
|
||||
with:
|
||||
path: KernelSU-Next
|
||||
fetch-depth: 0
|
||||
|
||||
4
.github/workflows/ksud.yml
vendored
4
.github/workflows/ksud.yml
vendored
@@ -22,12 +22,12 @@ jobs:
|
||||
runs-on: ${{ inputs.os }}
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v4
|
||||
uses: actions/checkout@v5
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Download Artifacts
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
|
||||
- name: Prepare LKM Files
|
||||
if: ${{ inputs.pack_lkm }}
|
||||
|
||||
2
.github/workflows/release.yml
vendored
2
.github/workflows/release.yml
vendored
@@ -39,7 +39,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Download artifacts
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
- name: Zip AnyKernel3
|
||||
run: |
|
||||
for dir in AnyKernel3-*; do
|
||||
|
||||
2
.github/workflows/rustfmt.yml
vendored
2
.github/workflows/rustfmt.yml
vendored
@@ -23,7 +23,7 @@ jobs:
|
||||
format:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v5
|
||||
|
||||
- uses: dtolnay/rust-toolchain@nightly
|
||||
with:
|
||||
|
||||
2
.github/workflows/shellcheck.yml
vendored
2
.github/workflows/shellcheck.yml
vendored
@@ -18,7 +18,7 @@ jobs:
|
||||
shellcheck:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v5
|
||||
|
||||
- name: Run ShellCheck
|
||||
uses: ludeeus/action-shellcheck@2.0.0
|
||||
|
||||
2
.github/workflows/susfsd.yml
vendored
2
.github/workflows/susfsd.yml
vendored
@@ -17,7 +17,7 @@ jobs:
|
||||
name: Build userspace susfsd
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v5
|
||||
with:
|
||||
fetch-depth: 0
|
||||
- name: Build susfsd
|
||||
|
||||
6
.github/workflows/wsa-kernel.yml
vendored
6
.github/workflows/wsa-kernel.yml
vendored
@@ -36,7 +36,7 @@ jobs:
|
||||
key: llvm-12.0.1
|
||||
|
||||
- name: Setup LLVM
|
||||
uses: KyleMayes/install-llvm-action@v1
|
||||
uses: KyleMayes/install-llvm-action@v2
|
||||
with:
|
||||
version: "12.0.1"
|
||||
force-version: true
|
||||
@@ -44,13 +44,13 @@ jobs:
|
||||
cached: ${{ steps.cache-llvm.outputs.cache-hit }}
|
||||
|
||||
- name: Checkout KernelSU-Next
|
||||
uses: actions/checkout@v4
|
||||
uses: actions/checkout@v5
|
||||
with:
|
||||
path: KernelSU-Next
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Setup kernel source
|
||||
uses: actions/checkout@v4
|
||||
uses: actions/checkout@v5
|
||||
with:
|
||||
repository: microsoft/WSA-Linux-Kernel
|
||||
ref: android-lts/latte-2/${{ inputs.version }}
|
||||
|
||||
@@ -40,4 +40,11 @@ config KSU_LSM_SECURITY_HOOKS
|
||||
Disabling this is mostly only useful for kernel 4.1 and older.
|
||||
Make sure to implement manual hooks on security/security.c.
|
||||
|
||||
config KSU_SWITCH_MANAGER
|
||||
bool "KernelSU switch manager support"
|
||||
depends on KSU
|
||||
default n
|
||||
help
|
||||
Enable KernelSU switch manager support.
|
||||
|
||||
endmenu
|
||||
|
||||
@@ -314,7 +314,9 @@ static struct kernel_param_ops expected_size_ops = {
|
||||
module_param_cb(ksu_debug_manager_uid, &expected_size_ops,
|
||||
&ksu_debug_manager_uid, S_IRUSR | S_IWUSR);
|
||||
|
||||
#else
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_KSU_SWITCH_MANAGER
|
||||
|
||||
static int set_expected_size(const char *val, const struct kernel_param *kp)
|
||||
{
|
||||
@@ -385,9 +387,5 @@ bool is_manager_apk(char *path)
|
||||
pr_info("%s: expected size: %u, expected hash: %s\n",
|
||||
path, expected_manager_size, expected_manager_hash);
|
||||
|
||||
#ifdef CONFIG_KSU_DEBUG
|
||||
return check_v2_signature(path, EXPECTED_MANAGER_SIZE, EXPECTED_MANAGER_HASH);
|
||||
#else
|
||||
return check_v2_signature(path, expected_manager_size, expected_manager_hash);
|
||||
#endif
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user