Skip to content

Commit

Permalink
skip custom build in meson
Browse files Browse the repository at this point in the history
  • Loading branch information
vhdirk committed Jan 10, 2024
1 parent 56fbdc4 commit bf4e14b
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
5 changes: 3 additions & 2 deletions build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ fn compile_glib() {
}

fn main() {
// TODO: we probably only want to do this when not running under meson
compile_glib();
if !env::var("BUILD_IS_MESON").is_ok_and(|val| val == "true") {
compile_glib();
}
}
1 change: 0 additions & 1 deletion src/application.rs
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,6 @@ impl Application {
app.disconnect(signalid_.borrow_mut().take().expect("Signal ID went missing"));
gtk::init().expect("Failed to initalize gtk4");
adw::init().expect("Failed to initialize adw");
panel::init();
});
*signalid.borrow_mut() = Some(id);
}
Expand Down
2 changes: 1 addition & 1 deletion src/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ else
message('Building in release mode')
endif

cargo_env = [ 'CARGO_HOME=' + meson.project_build_root() / 'cargo-home' ]
cargo_env = [ 'CARGO_HOME=' + meson.project_build_root() / 'cargo-home', 'BUILD_IS_MESON=true' ]

cargo_build = custom_target(
'cargo-build',
Expand Down

0 comments on commit bf4e14b

Please sign in to comment.