ci for linux x86_64 sciter deb and flatpak (#8545)
Signed-off-by: 21pages <sunboeasy@gmail.com>
This commit is contained in:
parent
e71d86c124
commit
285e974d1a
56
.github/workflows/flutter-build.yml
vendored
56
.github/workflows/flutter-build.yml
vendored
@ -1262,21 +1262,31 @@ jobs:
|
|||||||
files: |
|
files: |
|
||||||
res/rustdesk-${{ env.VERSION }}*.zst
|
res/rustdesk-${{ env.VERSION }}*.zst
|
||||||
|
|
||||||
build-rustdesk-sciter-arm:
|
build-rustdesk-linux-sciter:
|
||||||
if: ${{ inputs.upload-artifact }}
|
if: ${{ inputs.upload-artifact }}
|
||||||
needs: build-rustdesk-linux # not for dep, just make it run later for parallelism
|
needs: build-rustdesk-linux # not for dep, just make it run later for parallelism
|
||||||
runs-on: [self-hosted, Linux, ARM64]
|
runs-on: ${{ matrix.job.on }}
|
||||||
name: build-rustdesk-sciter-arm ${{ matrix.job.target }}
|
name: build-rustdesk-linux-sciter ${{ matrix.job.target }}
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
# use a high level qemu-user-static
|
# use a high level qemu-user-static
|
||||||
job:
|
job:
|
||||||
|
- {
|
||||||
|
arch: x86_64,
|
||||||
|
target: x86_64-unknown-linux-gnu,
|
||||||
|
on: ubuntu-20.04,
|
||||||
|
distro: ubuntu18.04,
|
||||||
|
deb_arch: amd64,
|
||||||
|
sciter_arch: x64,
|
||||||
|
}
|
||||||
- {
|
- {
|
||||||
arch: armv7,
|
arch: armv7,
|
||||||
target: armv7-unknown-linux-gnueabihf,
|
target: armv7-unknown-linux-gnueabihf,
|
||||||
deb-arch: armhf,
|
on: [self-hosted, Linux, ARM64],
|
||||||
use-cross: true,
|
distro: ubuntu18.04-rustdesk,
|
||||||
|
deb_arch: armhf,
|
||||||
|
sciter_arch: arm32,
|
||||||
}
|
}
|
||||||
steps:
|
steps:
|
||||||
- name: Export GitHub Actions cache environment variables
|
- name: Export GitHub Actions cache environment variables
|
||||||
@ -1340,7 +1350,7 @@ jobs:
|
|||||||
id: vcpkg
|
id: vcpkg
|
||||||
with:
|
with:
|
||||||
arch: ${{ matrix.job.arch }}
|
arch: ${{ matrix.job.arch }}
|
||||||
distro: ubuntu18.04-rustdesk
|
distro: ${{ matrix.job.distro }}
|
||||||
githubToken: ${{ github.token }}
|
githubToken: ${{ github.token }}
|
||||||
setup: |
|
setup: |
|
||||||
ls -l "${PWD}"
|
ls -l "${PWD}"
|
||||||
@ -1406,13 +1416,13 @@ jobs:
|
|||||||
pushd /workspace
|
pushd /workspace
|
||||||
python3 ./res/inline-sciter.py
|
python3 ./res/inline-sciter.py
|
||||||
export VCPKG_ROOT=/opt/artifacts/vcpkg
|
export VCPKG_ROOT=/opt/artifacts/vcpkg
|
||||||
export ARCH=armhf
|
|
||||||
export CARGO_INCREMENTAL=0
|
export CARGO_INCREMENTAL=0
|
||||||
cargo build --features inline --release --bins --jobs 1
|
cargo build --features inline --release --bins --jobs 1
|
||||||
# package
|
# package
|
||||||
mkdir -p ./Release
|
mkdir -p ./Release
|
||||||
mv ./target/release/rustdesk ./Release/rustdesk
|
mv ./target/release/rustdesk ./Release/rustdesk
|
||||||
wget -O ./Release/libsciter-gtk.so https://github.com/c-smile/sciter-sdk/raw/master/bin.lnx/arm32/libsciter-gtk.so
|
wget -O ./Release/libsciter-gtk.so https://github.com/c-smile/sciter-sdk/raw/master/bin.lnx/${{ matrix.job.sciter_arch }}/libsciter-gtk.so
|
||||||
|
export DEB_ARCH=${{ matrix.job.deb_arch }}
|
||||||
./build.py --package ./Release
|
./build.py --package ./Release
|
||||||
|
|
||||||
- name: Rename rustdesk
|
- name: Rename rustdesk
|
||||||
@ -1432,6 +1442,13 @@ jobs:
|
|||||||
files: |
|
files: |
|
||||||
rustdesk-${{ env.VERSION }}-${{ matrix.job.arch }}-sciter.deb
|
rustdesk-${{ env.VERSION }}-${{ matrix.job.arch }}-sciter.deb
|
||||||
|
|
||||||
|
- name: Upload deb
|
||||||
|
uses: actions/upload-artifact@master
|
||||||
|
if: env.UPLOAD_ARTIFACT == 'true'
|
||||||
|
with:
|
||||||
|
name: rustdesk-${{ env.VERSION }}-${{ matrix.job.arch }}-sciter.deb
|
||||||
|
path: rustdesk-${{ env.VERSION }}-${{ matrix.job.arch }}-sciter.deb
|
||||||
|
|
||||||
build-appimage:
|
build-appimage:
|
||||||
name: Build appimage ${{ matrix.job.target }}
|
name: Build appimage ${{ matrix.job.target }}
|
||||||
needs: [build-rustdesk-linux]
|
needs: [build-rustdesk-linux]
|
||||||
@ -1489,8 +1506,10 @@ jobs:
|
|||||||
./appimage/rustdesk-${{ env.VERSION }}-*.AppImage
|
./appimage/rustdesk-${{ env.VERSION }}-*.AppImage
|
||||||
|
|
||||||
build-flatpak:
|
build-flatpak:
|
||||||
name: Build flatpak ${{ matrix.job.target }}
|
name: Build flatpak ${{ matrix.job.target }}${{ matrix.job.suffix }}
|
||||||
needs: [build-rustdesk-linux]
|
needs:
|
||||||
|
- build-rustdesk-linux
|
||||||
|
- build-rustdesk-linux-sciter
|
||||||
runs-on: ${{ matrix.job.on }}
|
runs-on: ${{ matrix.job.on }}
|
||||||
if: ${{ inputs.upload-artifact }}
|
if: ${{ inputs.upload-artifact }}
|
||||||
strategy:
|
strategy:
|
||||||
@ -1502,6 +1521,14 @@ jobs:
|
|||||||
distro: ubuntu18.04,
|
distro: ubuntu18.04,
|
||||||
on: ubuntu-20.04,
|
on: ubuntu-20.04,
|
||||||
arch: x86_64,
|
arch: x86_64,
|
||||||
|
suffix: "",
|
||||||
|
}
|
||||||
|
- {
|
||||||
|
target: x86_64-unknown-linux-gnu,
|
||||||
|
distro: ubuntu18.04,
|
||||||
|
on: ubuntu-20.04,
|
||||||
|
arch: x86_64,
|
||||||
|
suffix: "-sciter",
|
||||||
}
|
}
|
||||||
- {
|
- {
|
||||||
target: aarch64-unknown-linux-gnu,
|
target: aarch64-unknown-linux-gnu,
|
||||||
@ -1509,6 +1536,7 @@ jobs:
|
|||||||
distro: ubuntu22.04,
|
distro: ubuntu22.04,
|
||||||
on: [self-hosted, Linux, ARM64],
|
on: [self-hosted, Linux, ARM64],
|
||||||
arch: aarch64,
|
arch: aarch64,
|
||||||
|
suffix: "",
|
||||||
}
|
}
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout source code
|
- name: Checkout source code
|
||||||
@ -1517,12 +1545,12 @@ jobs:
|
|||||||
- name: Download Binary
|
- name: Download Binary
|
||||||
uses: actions/download-artifact@master
|
uses: actions/download-artifact@master
|
||||||
with:
|
with:
|
||||||
name: rustdesk-${{ env.VERSION }}-${{ matrix.job.arch }}.deb
|
name: rustdesk-${{ env.VERSION }}-${{ matrix.job.arch }}${{ matrix.job.suffix }}.deb
|
||||||
path: .
|
path: .
|
||||||
|
|
||||||
- name: Rename Binary
|
- name: Rename Binary
|
||||||
run: |
|
run: |
|
||||||
mv rustdesk-${{ env.VERSION }}-${{ matrix.job.arch }}.deb flatpak/rustdesk.deb
|
mv rustdesk-${{ env.VERSION }}-${{ matrix.job.arch }}${{ matrix.job.suffix }}.deb flatpak/rustdesk.deb
|
||||||
|
|
||||||
- uses: rustdesk-org/run-on-arch-action@amd64-support
|
- uses: rustdesk-org/run-on-arch-action@amd64-support
|
||||||
name: Build rustdesk flatpak package for ${{ matrix.job.arch }}
|
name: Build rustdesk flatpak package for ${{ matrix.job.arch }}
|
||||||
@ -1568,7 +1596,7 @@ jobs:
|
|||||||
pushd flatpak
|
pushd flatpak
|
||||||
git clone https://github.com/flathub/shared-modules.git --depth=1
|
git clone https://github.com/flathub/shared-modules.git --depth=1
|
||||||
flatpak-builder --user --force-clean --repo=repo ./build ./rustdesk.json
|
flatpak-builder --user --force-clean --repo=repo ./build ./rustdesk.json
|
||||||
flatpak build-bundle ./repo rustdesk-${{ env.VERSION }}-${{ matrix.job.arch }}.flatpak com.rustdesk.RustDesk
|
flatpak build-bundle ./repo rustdesk-${{ env.VERSION }}-${{ matrix.job.arch }}${{ matrix.job.suffix }}.flatpak com.rustdesk.RustDesk
|
||||||
|
|
||||||
- name: Publish flatpak package
|
- name: Publish flatpak package
|
||||||
uses: softprops/action-gh-release@v1
|
uses: softprops/action-gh-release@v1
|
||||||
@ -1576,7 +1604,7 @@ jobs:
|
|||||||
prerelease: true
|
prerelease: true
|
||||||
tag_name: ${{ env.TAG_NAME }}
|
tag_name: ${{ env.TAG_NAME }}
|
||||||
files: |
|
files: |
|
||||||
flatpak/rustdesk-${{ env.VERSION }}-${{ matrix.job.arch }}.flatpak
|
flatpak/rustdesk-${{ env.VERSION }}-${{ matrix.job.arch }}${{ matrix.job.suffix }}.flatpak
|
||||||
|
|
||||||
build-rustdesk-web:
|
build-rustdesk-web:
|
||||||
if: False
|
if: False
|
||||||
|
6
build.py
6
build.py
@ -25,8 +25,8 @@ flutter_build_dir_2 = f'flutter/{flutter_build_dir}'
|
|||||||
skip_cargo = False
|
skip_cargo = False
|
||||||
|
|
||||||
|
|
||||||
def get_arch() -> str:
|
def get_deb_arch() -> str:
|
||||||
custom_arch = os.environ.get("ARCH")
|
custom_arch = os.environ.get("DEB_ARCH")
|
||||||
if custom_arch is None:
|
if custom_arch is None:
|
||||||
return "amd64"
|
return "amd64"
|
||||||
return custom_arch
|
return custom_arch
|
||||||
@ -294,7 +294,7 @@ Homepage: https://rustdesk.com
|
|||||||
Depends: libgtk-3-0, libxcb-randr0, libxdo3, libxfixes3, libxcb-shape0, libxcb-xfixes0, libasound2, libsystemd0, curl, libva-drm2, libva-x11-2, libvdpau1, libgstreamer-plugins-base1.0-0, libpam0g, libappindicator3-1, gstreamer1.0-pipewire
|
Depends: libgtk-3-0, libxcb-randr0, libxdo3, libxfixes3, libxcb-shape0, libxcb-xfixes0, libasound2, libsystemd0, curl, libva-drm2, libva-x11-2, libvdpau1, libgstreamer-plugins-base1.0-0, libpam0g, libappindicator3-1, gstreamer1.0-pipewire
|
||||||
Description: A remote control software.
|
Description: A remote control software.
|
||||||
|
|
||||||
""" % (version, get_arch())
|
""" % (version, get_deb_arch())
|
||||||
file = open(control_file_path, "w")
|
file = open(control_file_path, "w")
|
||||||
file.write(content)
|
file.write(content)
|
||||||
file.close()
|
file.close()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user