[Bug 2028895] Review Request: rust-tree-sitter - Rust bindings to the Tree-sitter parsing library

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



https://bugzilla.redhat.com/show_bug.cgi?id=2028895

Fabio Valentini <decathorpe@xxxxxxxxx> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Assignee|nobody@xxxxxxxxxxxxxxxxx    |decathorpe@xxxxxxxxx
           Doc Type|---                         |If docs needed, set a value
             Status|NEW                         |ASSIGNED
                 CC|                            |decathorpe@xxxxxxxxx



--- Comment #1 from Fabio Valentini <decathorpe@xxxxxxxxx> ---
This crate seems to contain a bundled copy of tree-sitter C library? You will
need to declare that in the .spec file somehow (and make sure the license is
also acceptable).

Additionally, the Rust bindings are generated sources (with bindgen), which is
not permissible in Fedora.

Generated sources must be regenerated at build time, but there is neither a
build.rs script that supports doing that, nor can we be sure that the generated
sources haven't been "tampered" with post-generation.

At any rate, using pre-generated sources from bindgen is a bad idea in general,
because they encode architecture-specific details from the machine that bindgen
was run on (i.e. running bindgen on x86_64 machine often produces bindings that
are wrong or broken on 32-bit architectures, like i686 or arm).

You'll need to ask upstream for a way to regenerate those sources at build time
(probably a `build.rs` script with Cargo feature flags to turn regenerating
bindings on or off, or `/usr/bin/bindgen` invocation). You can look at other
-sys crates how they handle this case (to make sure bindgen is run not only
during the create build itself, but also when building the crate in dependent
packages, regardless of chosen feature set).


-- 
You are receiving this mail because:
You are always notified about changes to this product and component
You are on the CC list for the bug.
https://bugzilla.redhat.com/show_bug.cgi?id=2028895
_______________________________________________
package-review mailing list -- package-review@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to package-review-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/package-review@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure




[Index of Archives]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite Conditions]     [KDE Users]

  Powered by Linux