docs: fix references to renamed function gst_plugin_version_helper::get_info()

This commit is contained in:
Michael Oultram 2022-10-19 11:34:21 +01:00
parent 59daaa62aa
commit e0437ae8f6
3 changed files with 5 additions and 5 deletions

View file

@ -105,13 +105,13 @@ Next we create `build.rs` in the project main directory.
```rust ```rust
fn main() { fn main() {
gst_plugin_version_helper::get_info() gst_plugin_version_helper::info()
} }
``` ```
`build.rs` compiles and runs before anything else, [see](https://doc.rust-lang.org/cargo/reference/build-scripts.html). `build.rs` compiles and runs before anything else, [see](https://doc.rust-lang.org/cargo/reference/build-scripts.html).
Therefore, `gst_plugin_version_helper::get_info()` will provide various information via `cargo` environment variables such as `COMMIT_ID` and `BUILD_REL_DATE` and these environment variables are then later accessed by our invocation of the `gst::plugin_define!` macro during compilation. Therefore, `gst_plugin_version_helper::info()` will provide various information via `cargo` environment variables such as `COMMIT_ID` and `BUILD_REL_DATE` and these environment variables are then later accessed by our invocation of the `gst::plugin_define!` macro during compilation.
In addition were defining an empty plugin entry point function that just returns `Ok(())` In addition were defining an empty plugin entry point function that just returns `Ok(())`

View file

@ -11,7 +11,7 @@ plugin:
gst_plugin_version_helper::info(); gst_plugin_version_helper::info();
``` ```
Inside `lib.rs` of the plugin, the information provided by `get_info` are usable as follows: Inside `lib.rs` of the plugin, the information provided by `info` are usable as follows:
```rust,ignore ```rust,ignore
gst::plugin_define!( gst::plugin_define!(

View file

@ -7,7 +7,7 @@
//! Extracts release for [GStreamer](https://gstreamer.freedesktop.org) plugin metadata //! Extracts release for [GStreamer](https://gstreamer.freedesktop.org) plugin metadata
//! //!
//! See [`get_info`](fn.get_info.html) for details. //! See [`info`](fn.info.html) for details.
//! //!
//! This function is supposed to be used as follows in the `build.rs` of a crate that implements a //! This function is supposed to be used as follows in the `build.rs` of a crate that implements a
//! plugin: //! plugin:
@ -16,7 +16,7 @@
//! gst_plugin_version_helper::info(); //! gst_plugin_version_helper::info();
//! ``` //! ```
//! //!
//! Inside `lib.rs` of the plugin, the information provided by `get_info` are usable as follows: //! Inside `lib.rs` of the plugin, the information provided by `info` are usable as follows:
//! //!
//! ```rust,ignore //! ```rust,ignore
//! gst::plugin_define!( //! gst::plugin_define!(