disable generation of lttng tracepoints if no tracing feature set
Signed-off-by: Fabrizio <fab@pop-os.localdomain>
This commit is contained in:
parent
7550842126
commit
36d3ce3a09
File diff suppressed because it is too large
Load Diff
9
build.rs
9
build.rs
|
@ -1,9 +1,11 @@
|
||||||
use std::env;
|
use std::env;
|
||||||
use std::path::PathBuf;
|
use std::path::PathBuf;
|
||||||
|
|
||||||
|
#[cfg(feature = "tracing")]
|
||||||
use lttng_ust_generate::{Provider, Generator, CTFType, CIntegerType};
|
use lttng_ust_generate::{Provider, Generator, CTFType, CIntegerType};
|
||||||
|
|
||||||
fn main() {
|
#[cfg(feature = "tracing")]
|
||||||
|
fn setup_tracepoints() {
|
||||||
// the provider is called calendar
|
// the provider is called calendar
|
||||||
let mut provider = Provider::new("calendar");
|
let mut provider = Provider::new("calendar");
|
||||||
|
|
||||||
|
@ -23,3 +25,8 @@ fn main() {
|
||||||
.generate()
|
.generate()
|
||||||
.expect("Unable to generate tracepoint bindings");
|
.expect("Unable to generate tracepoint bindings");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
#[cfg(feature = "tracing")]
|
||||||
|
setup_tracepoints();
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in New Issue