Comments (6)
Righty, I'll have to get round to documenting it properly sometime soon, but until then here's what I do:
- Build Aravis itself from source and copy the
Aravis-*.gir
to thegir-files
folder. - Install Aravis so that the build script for the FFI crate can find it. You should be able to install it in a user directory, as long as
pkgconf/pkg-config
can find it. - If you want to update the gtk-rs gir files, you should just update the submodule to the current master. The relevant files are symlinked, so you don't have to copy anything manually.
- Run the
gir
tool from gtk-rs in the root of thearavis-sys
crate. All required options are taken from theGir.toml
file. You probably need to fix some things in the build script. The generated script from thegir
tool writesversion checkspkgconf queries that don't actually work for Aravis. You need to tweakaravis-sys/tests/abi.rs
for the same reason. Your best bet is to look at the diff and undo anything other than actual version changes. You could try to build first if you want to see how it fails, of course. - Run the
gir
tool in thearavis
crate. This time there should be no manual intervention needed. - Run
cargo fmt
in both crates after re-generating the files. Or maybe thegir
tool already does that. Can't hurt though :)
If you run into issues with the compiler or borrow checker with this procedure, there may be updates that are incompatible with the manual code in the aravis
crate.
from aravis-rs.
Oh, I forget, we also want to put the documentation back. It's stripped by default for licensing reasons, but I think we attribute the documentation to the original Aravis project. (If not, that should still be done.)
- Run
gir -m doc
in each crate followed byrust-doc-stripper -g -o vendor.md
. You can installrust-doc-stripper
from https://crates.io. Don't commitvendor.md
itself. Runcargo fmt
again after :)
from aravis-rs.
Hi Maarten,
Oh, I forget, we also want to put the documentation back. It's stripped by default for licensing reasons
What is the issue with the documentation license ?
from aravis-rs.
Hey :)
I don't think there is an issue with the license here. But the gir
tool from gtk-rs
strips all documentation by default because they're covered by the license of the upstream project, and not the license of the generated bindings. As a safe default, they just remove it.
I think the Aravis license permits redistributing the documentation though, so I prefer to have it included in the code and therefore the autogenerated Rust documentation :)
Although I see now that this is all I included in the LICENSE.md
file here:
This license applies to the Rust bindings, not to the Aravis library itself.
That is not very explicit about the license of the documentation. I'll think I'll make it more explicit and also include something in the documentation itself here: https://docs.rs/aravis/.
from aravis-rs.
I updated the Rust crate to Aravis 0.8.1 now. This should provide you with a smaller diff when testing custom versions of Aravis based on 0.8.1.
I also clarified the license/copyright situation a bit. The LICENSE.md
file now includes this:
This copyright notice and license apply to the Rust bindings.
They do not apply to the Aravis library itself or it's documentation.
See https://github.com/AravisProject/aravis for more information.
And on docs.rs it says this:
This crate contains (mostly) safe bindings to the Aravis library.
The bindings are mostly auto-generated with the
gir
tool from the gtk-rs project.This crate currently targets version 0.8.1 of the Aravis library.
This documentation constist mainly of original documentation of the Aravis project. The copyright and license of the Aravis project apply to those parts. The full original documentation is also available online and might help if the translation to Rust made things unclear.
It's released as 0.4.1 on https://crates.io (I messed up the documentation for 0.4.0).
from aravis-rs.
This is awesome, thank you! And sorry for not having answered sooner, I'm just now remembering of this issue ^^' I just wanted to say I no longer personally have a need for this, as I was able to make the crate work properly with a version of aravis that worked too.
Do you want to keep this issue open to track the addition of documentation that'd explain how to bump to a newer aravis version (basically what you wrote in this issue, but in some .md file in the repo), or should we close this? :)
from aravis-rs.
Related Issues (12)
- CameraExt::get_gv_packet_size returns Result<(), …> instead of Result<usize, …> HOT 11
- Failed to set trigger source to software: AcquisitionFrameRateEnable HOT 4
- Serde Feature
- building for aarch64
- PixelFormat is not an enum, and ARV_PIXEL_FORMAT_* constants are not exposed HOT 13
- Update dependencies HOT 2
- Update to latest glib HOT 2
- Aravis 0.8.5 HOT 2
- Discovering that you need `*Ext` extension traits is not obvious enough.
- `Camera::new()` modifies global state to do discovery. HOT 7
- StreamExt::push_buffer question HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from aravis-rs.