fix(nix): FINALLY
This commit is contained in:
4
Cargo.lock
generated
4
Cargo.lock
generated
@@ -2528,12 +2528,12 @@ checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f"
|
|||||||
[[package]]
|
[[package]]
|
||||||
name = "stereokit-macros"
|
name = "stereokit-macros"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
source = "git+https://github.com/mvvvv/StereoKit-rust.git#2bfa9a812422a2b5b98db9979b5a4cc28cea151e"
|
source = "git+https://github.com/technobaboo/StereoKit-rust.git#93829181d5eea954e15dba9d9bfb0ec62e98d400"
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "stereokit-rust"
|
name = "stereokit-rust"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
source = "git+https://github.com/mvvvv/StereoKit-rust.git#2bfa9a812422a2b5b98db9979b5a4cc28cea151e"
|
source = "git+https://github.com/technobaboo/StereoKit-rust.git#93829181d5eea954e15dba9d9bfb0ec62e98d400"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"android-activity",
|
"android-activity",
|
||||||
"android_logger",
|
"android_logger",
|
||||||
|
|||||||
@@ -21,6 +21,7 @@ default = ["wayland"]
|
|||||||
wayland = ["dep:smithay"]
|
wayland = ["dep:smithay"]
|
||||||
profile_tokio = ["dep:console-subscriber", "tokio/tracing"]
|
profile_tokio = ["dep:console-subscriber", "tokio/tracing"]
|
||||||
profile_app = ["dep:tracing-tracy"]
|
profile_app = ["dep:tracing-tracy"]
|
||||||
|
local_deps = ["stereokit-rust/force-local-deps"]
|
||||||
|
|
||||||
[package.metadata.appimage]
|
[package.metadata.appimage]
|
||||||
auto_link = true
|
auto_link = true
|
||||||
@@ -108,9 +109,8 @@ optional = true
|
|||||||
[dependencies.stereokit-rust]
|
[dependencies.stereokit-rust]
|
||||||
# path = "../StereoKit-rust"
|
# path = "../StereoKit-rust"
|
||||||
# git = "https://github.com/mvvvv/StereoKit-rust.git"
|
# git = "https://github.com/mvvvv/StereoKit-rust.git"
|
||||||
# features = ["no-event-loop"]
|
|
||||||
git = "https://github.com/technobaboo/StereoKit-rust.git"
|
git = "https://github.com/technobaboo/StereoKit-rust.git"
|
||||||
# features = ["force-local-deps"]
|
features = ["no-event-loop"]
|
||||||
default-features = false
|
default-features = false
|
||||||
|
|
||||||
[dependencies.stardust-xr]
|
[dependencies.stardust-xr]
|
||||||
|
|||||||
@@ -3,8 +3,8 @@
|
|||||||
let
|
let
|
||||||
sk_gpu_zip = fetchurl {
|
sk_gpu_zip = fetchurl {
|
||||||
url =
|
url =
|
||||||
"https://github.com/StereoKit/sk_gpu/releases/download/v2024.8.12/sk_gpu.v2024.8.12.zip";
|
"https://github.com/StereoKit/sk_gpu/releases/download/v2024.8.16/sk_gpu.v2024.8.16.zip";
|
||||||
sha256 = "sha256-NPjOFzu7AlpQKJ8PZYeUuegrR6TXtRyg+Hm2BxIAMLI=";
|
sha256 = "sha256-Wk3PZFlWqhrsQ8xG0sQaV2xSasdg2D7TMiPvl/CgtGU=";
|
||||||
};
|
};
|
||||||
in stdenv.mkDerivation rec {
|
in stdenv.mkDerivation rec {
|
||||||
name = "sk_gpu";
|
name = "sk_gpu";
|
||||||
|
|||||||
@@ -1,6 +1,26 @@
|
|||||||
{ rustPlatform, src, name, libGL, mesa, xorg, fontconfig, libxkbcommon, libclang
|
{ rustPlatform
|
||||||
, cmake, cpm-cmake, pkg-config, llvmPackages, fetchFromGitHub, sk_gpu, libXau
|
, src
|
||||||
, libXdmcp, stdenv, lib }:
|
, name
|
||||||
|
, libGL
|
||||||
|
, mesa
|
||||||
|
, xorg
|
||||||
|
, fontconfig
|
||||||
|
, libxkbcommon
|
||||||
|
, libclang
|
||||||
|
|
||||||
|
, cmake
|
||||||
|
, cpm-cmake
|
||||||
|
, pkg-config
|
||||||
|
, llvmPackages
|
||||||
|
, fetchFromGitHub
|
||||||
|
, sk_gpu
|
||||||
|
, libXau
|
||||||
|
|
||||||
|
, libXdmcp
|
||||||
|
, stdenv
|
||||||
|
, lib
|
||||||
|
, openxr-loader
|
||||||
|
}:
|
||||||
|
|
||||||
rustPlatform.buildRustPackage rec {
|
rustPlatform.buildRustPackage rec {
|
||||||
inherit src name;
|
inherit src name;
|
||||||
@@ -8,18 +28,13 @@ rustPlatform.buildRustPackage rec {
|
|||||||
lockFile = (src + "/Cargo.lock");
|
lockFile = (src + "/Cargo.lock");
|
||||||
allowBuiltinFetchGit = true;
|
allowBuiltinFetchGit = true;
|
||||||
};
|
};
|
||||||
|
buildFeatures = [ "local_deps" ];
|
||||||
FORCE_LOCAL_DEPS = true;
|
FORCE_LOCAL_DEPS = true;
|
||||||
CPM_LOCAL_PACKAGES_ONLY = true;
|
CPM_LOCAL_PACKAGES_ONLY = true;
|
||||||
CPM_SOURCE_CACHE = "./build";
|
CPM_SOURCE_CACHE = "./build";
|
||||||
CPM_USE_LOCAL_PACKAGES = true;
|
CPM_USE_LOCAL_PACKAGES = true;
|
||||||
CPM_DOWNLOAD_ALL = false;
|
CPM_DOWNLOAD_ALL = false;
|
||||||
|
|
||||||
openxr_loader = fetchFromGitHub {
|
|
||||||
owner = "KhronosGroup";
|
|
||||||
repo = "OpenXR-SDK";
|
|
||||||
rev = "288d3a7ebc1ad959f62d51da75baa3d27438c499";
|
|
||||||
sha256 = "sha256-RdmnBe26hqPmqwCHIJolF6bSmZRmIKVlGF+TXAY35ig=";
|
|
||||||
};
|
|
||||||
meshoptimizer = fetchFromGitHub {
|
meshoptimizer = fetchFromGitHub {
|
||||||
owner = "zeux";
|
owner = "zeux";
|
||||||
repo = "meshoptimizer";
|
repo = "meshoptimizer";
|
||||||
@@ -33,9 +48,9 @@ rustPlatform.buildRustPackage rec {
|
|||||||
sha256 = "sha256-zBRAXgG5Fi6+5uPQCI/RCGatY6O4ELuYBoKrPNn4K+8=";
|
sha256 = "sha256-zBRAXgG5Fi6+5uPQCI/RCGatY6O4ELuYBoKrPNn4K+8=";
|
||||||
};
|
};
|
||||||
|
|
||||||
DEP_OPENXR_LOADER_SOURCE = "${openxr_loader}";
|
|
||||||
DEP_MESHOPTIMIZER_SOURCE = "${meshoptimizer}";
|
DEP_MESHOPTIMIZER_SOURCE = "${meshoptimizer}";
|
||||||
DEP_BASIS_UNIVERSAL_SOURCE = "${basis_universal}";
|
DEP_BASIS_UNIVERSAL_SOURCE = "${basis_universal}";
|
||||||
|
DEP_SK_GPU_SOURCE = "${sk_gpu}";
|
||||||
|
|
||||||
postPatch = let libPath = lib.makeLibraryPath [ stdenv.cc.cc.lib ];
|
postPatch = let libPath = lib.makeLibraryPath [ stdenv.cc.cc.lib ];
|
||||||
in ''
|
in ''
|
||||||
@@ -65,6 +80,7 @@ rustPlatform.buildRustPackage rec {
|
|||||||
libxkbcommon
|
libxkbcommon
|
||||||
libXau
|
libXau
|
||||||
libXdmcp
|
libXdmcp
|
||||||
|
openxr-loader
|
||||||
];
|
];
|
||||||
LIBCLANG_PATH = "${libclang.lib}/lib";
|
LIBCLANG_PATH = "${libclang.lib}/lib";
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user