mirror of
https://github.com/kunkundi/crossdesk.git
synced 2026-07-25 16:58:40 +08:00
fix: repair Slint dependency setup
This commit is contained in:
@@ -99,12 +99,20 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
submodules: recursive
|
submodules: recursive
|
||||||
|
|
||||||
|
- name: Install Linux build dependencies
|
||||||
|
run: apt install -y curl libxft-dev
|
||||||
|
|
||||||
|
- name: Install Rust
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal --default-toolchain 1.92.0
|
||||||
|
echo "${HOME}/.cargo/bin" >> "${GITHUB_PATH}"
|
||||||
|
|
||||||
- name: Build CrossDesk
|
- name: Build CrossDesk
|
||||||
env:
|
env:
|
||||||
CUDA_PATH: /usr/local/cuda
|
CUDA_PATH: /usr/local/cuda
|
||||||
XMAKE_GLOBALDIR: /data
|
XMAKE_GLOBALDIR: /data
|
||||||
run: |
|
run: |
|
||||||
apt install -y libxft-dev
|
|
||||||
xmake f --CROSSDESK_VERSION=${LEGAL_VERSION} --USE_CUDA=true --root -y
|
xmake f --CROSSDESK_VERSION=${LEGAL_VERSION} --USE_CUDA=true --root -y
|
||||||
xmake b -vy --root crossdesk
|
xmake b -vy --root crossdesk
|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,6 @@ package("slint")
|
|||||||
local configs = {
|
local configs = {
|
||||||
"-DSLINT_BUILD_TESTING=OFF",
|
"-DSLINT_BUILD_TESTING=OFF",
|
||||||
"-DSLINT_BUILD_EXAMPLES=OFF",
|
"-DSLINT_BUILD_EXAMPLES=OFF",
|
||||||
"-DSLINT_COMPILER=download",
|
|
||||||
"-DSLINT_FEATURE_INTERPRETER=OFF",
|
"-DSLINT_FEATURE_INTERPRETER=OFF",
|
||||||
"-DSLINT_FEATURE_LIVE_PREVIEW=OFF",
|
"-DSLINT_FEATURE_LIVE_PREVIEW=OFF",
|
||||||
"-DSLINT_FEATURE_TESTING=OFF",
|
"-DSLINT_FEATURE_TESTING=OFF",
|
||||||
@@ -36,23 +35,6 @@ package("slint")
|
|||||||
"-DBUILD_SHARED_LIBS=ON"
|
"-DBUILD_SHARED_LIBS=ON"
|
||||||
}
|
}
|
||||||
import("package.tools.cmake").install(package, configs)
|
import("package.tools.cmake").install(package, configs)
|
||||||
|
|
||||||
-- SLINT_COMPILER=download only configures downstream CMake projects.
|
|
||||||
-- xmake's native Slint rule needs the matching host executable here.
|
|
||||||
import("net.http")
|
|
||||||
import("utils.archive")
|
|
||||||
local host_system = is_host("windows") and "windows" or (is_host("macosx") and "Darwin" or "Linux")
|
|
||||||
local host_arch = os.arch()
|
|
||||||
if host_arch == "x64" then
|
|
||||||
host_arch = "x86_64"
|
|
||||||
end
|
|
||||||
local suffix = host_system .. "-" .. host_arch
|
|
||||||
local archive_name = "slint-compiler-" .. suffix .. ".tar.gz"
|
|
||||||
local archive_file = path.join(package:builddir(), archive_name)
|
|
||||||
local download_url = "https://github.com/slint-ui/slint/releases/download/v" .. package:version_str() .. "/" .. archive_name
|
|
||||||
http.download(download_url, archive_file)
|
|
||||||
os.mkdir(path.join(package:installdir(), "bin"))
|
|
||||||
archive.extract(archive_file, package:installdir())
|
|
||||||
end)
|
end)
|
||||||
|
|
||||||
on_test(function(package)
|
on_test(function(package)
|
||||||
Vendored
+1
-1
@@ -1 +1 @@
|
|||||||
includes("cpp-httplib")
|
includes("cpp-httplib", "slint")
|
||||||
|
|||||||
@@ -1,8 +1,6 @@
|
|||||||
set_project("crossdesk")
|
set_project("crossdesk")
|
||||||
set_license("GPL-3.0-only")
|
set_license("GPL-3.0-only")
|
||||||
|
|
||||||
add_repositories("crossdesk-packages " .. path.join(os.scriptdir(), "xmake", "repository"))
|
|
||||||
|
|
||||||
includes("xmake/options.lua")
|
includes("xmake/options.lua")
|
||||||
includes("xmake/platform.lua")
|
includes("xmake/platform.lua")
|
||||||
includes("xmake/rules/slint.lua")
|
includes("xmake/rules/slint.lua")
|
||||||
|
|||||||
Reference in New Issue
Block a user