Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(xtask): Dont update run submodule update #2556

Merged
merged 2 commits into from
Dec 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ jobs:
- name: Install dependencies
run: |
sudo apt update
sudo apt install build-essential pkg-config nasm libva-dev libdrm-dev libvulkan-dev libx264-dev libxrandr-dev libunwind-dev libgtk-3-dev libpipewire-0.3-dev libspa-0.2-dev
sudo apt install build-essential pkg-config nasm libva-dev libdrm-dev libvulkan-dev libx264-dev libasound2-dev libxrandr-dev libunwind-dev libgtk-3-dev libpipewire-0.3-dev libspa-0.2-dev

- name: Prepare deps
env:
Expand All @@ -57,12 +57,15 @@ jobs:
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
with:
submodules: true
- uses: dtolnay/rust-toolchain@stable
with:
components: clippy
- uses: Swatinem/rust-cache@v2

- run: cargo xtask prepare-deps --platform macos
# This step currently does nothing on macos, but might in the future
# - run: cargo xtask prepare-deps --platform macos

- run: cargo clippy

Expand Down Expand Up @@ -155,7 +158,7 @@ jobs:
- name: Install dependencies
run: |
sudo apt update
sudo apt install build-essential pkg-config nasm libva-dev libdrm-dev libvulkan-dev libx264-dev libxrandr-dev libunwind-dev libgtk-3-dev libpipewire-0.3-dev libspa-0.2-dev
sudo apt install build-essential pkg-config nasm libva-dev libdrm-dev libvulkan-dev libx264-dev libasound2-dev libxrandr-dev libunwind-dev libgtk-3-dev libpipewire-0.3-dev libspa-0.2-dev

- name: Prepare deps
env:
Expand Down
28 changes: 0 additions & 28 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion alvr/audio/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ alvr_common.workspace = true
alvr_session.workspace = true
alvr_sockets.workspace = true

cpal = { version = "0.15", features = ["jack"] }
cpal = "0.15"
rodio = "0.19"
serde = "1"

Expand Down
2 changes: 1 addition & 1 deletion alvr/session/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use std::{env, fmt::Write, fs, path::PathBuf};
fn main() {
let openvr_driver_header_string =
fs::read_to_string(alvr_filesystem::workspace_dir().join("openvr/headers/openvr_driver.h"))
.unwrap();
.expect("Missing openvr header files, did you clone the submodule?\n");
zmerp marked this conversation as resolved.
Show resolved Hide resolved

let property_finder = Regex::new(
r"\tProp_([A-Za-z\d_]+)_(Bool|Int32|Uint64|Float|String|Vector3)[\t ]+= ([0-9]+)",
Expand Down
2 changes: 1 addition & 1 deletion alvr/xtask/src/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ pub fn build_android_client(profile: Profile) {
{
let keystore_path = build_dir.join("debug.keystore");
if !keystore_path.exists() {
let keytool = PathBuf::from(env::var("JAVA_HOME").unwrap())
let keytool = PathBuf::from(env::var("JAVA_HOME").expect("Env var JAVA_HOME not set"))
.join("bin")
.join(afs::exec_fname("keytool"));
let pass = "alvrclient";
Expand Down
20 changes: 1 addition & 19 deletions alvr/xtask/src/dependencies.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,6 @@ pub enum OpenXRLoadersSelection {
All,
}

pub fn update_submodules(sh: &Shell) {
let dir = sh.push_dir(afs::workspace_dir());
cmd!(sh, "git submodule update --init --recursive")
.run()
.unwrap();
std::mem::drop(dir);
}

pub fn choco_install(sh: &Shell, packages: &[&str]) -> Result<(), xshell::Error> {
cmd!(
sh,
Expand Down Expand Up @@ -85,8 +77,6 @@ pub fn prepare_ffmpeg_windows(deps_path: &Path) {
pub fn prepare_windows_deps(skip_admin_priv: bool) {
let sh = Shell::new().unwrap();

update_submodules(&sh);

let deps_path = afs::deps_dir().join("windows");
sh.remove_path(&deps_path).ok();
sh.create_dir(&deps_path).unwrap();
Expand All @@ -113,8 +103,6 @@ pub fn prepare_windows_deps(skip_admin_priv: bool) {
pub fn prepare_linux_deps(enable_nvenc: bool) {
let sh = Shell::new().unwrap();

update_submodules(&sh);

let deps_path = afs::deps_dir().join("linux");
sh.remove_path(&deps_path).ok();
sh.create_dir(&deps_path).unwrap();
Expand Down Expand Up @@ -293,11 +281,7 @@ pub fn build_ffmpeg_linux(enable_nvenc: bool, deps_path: &Path) {
cmd!(sh, "make install").run().unwrap();
}

pub fn prepare_macos_deps() {
let sh = Shell::new().unwrap();

update_submodules(&sh);
}
pub fn prepare_macos_deps() {}

pub fn prepare_server_deps(
platform: Option<BuildPlatform>,
Expand Down Expand Up @@ -390,8 +374,6 @@ pub fn build_android_deps(
) {
let sh = Shell::new().unwrap();

update_submodules(&sh);

if cfg!(windows) && !skip_admin_priv {
choco_install(&sh, &["unzip", "llvm"]).unwrap();
}
Expand Down
5 changes: 4 additions & 1 deletion wiki/Building-From-Source.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,10 @@ Preferred IDE (optional): Visual Studio Code with rust-analyzer extension

You need to install [rustup](https://www.rust-lang.org/tools/install).

On Windows you need also [Chocolatey](https://chocolatey.org/install).
On Windows you also need [Chocolatey](https://chocolatey.org/install).

To clone the repository use `git clone --recurse-submodules https://github.com/alvr-org/ALVR.git`.
If you previously cloned the repo without submodules, simply run `git submodule update --init --checkout --recursive` in it.

# Streamer Building

Expand Down
Loading