Cykooz / libheif-sys

Rust bindings to libheif-dev
MIT License
10 stars 9 forks source link

Build fails under i386 #8

Open sophie-h opened 4 days ago

sophie-h commented 4 days ago

Is the solution here to enable bindgen again?

error[E0080]: evaluation of constant value failed
   --> /builds/sophie-h/glycin/builddir/cargo-home/registry/src/index.crates.io-1cd66030c949c28d/libheif-sys-2.2.0+1.17.6/src/bindings.rs:210:28
    |
210 |     ["Size of heif_error"][::std::mem::size_of::<heif_error>() - 16usize];
    |                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempt to compute `12_usize - 16_usize`, which would overflow
error[E0080]: evaluation of constant value failed
   --> /builds/sophie-h/glycin/builddir/cargo-home/registry/src/index.crates.io-1cd66030c949c28d/libheif-sys-2.2.0+1.17.6/src/bindings.rs:310:34
    |
310 |     ["Size of heif_plugin_info"][::std::mem::size_of::<heif_plugin_info>() - 24usize];
    |                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempt to compute `16_usize - 24_usize`, which would overflow
error[E0080]: evaluation of constant value failed
   --> /builds/sophie-h/glycin/builddir/cargo-home/registry/src/index.crates.io-1cd66030c949c28d/libheif-sys-2.2.0+1.17.6/src/bindings.rs:490:29
    |
490 |     ["Size of heif_reader"][::std::mem::size_of::<heif_reader>() - 40usize];
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempt to compute `20_usize - 40_usize`, which would overflow
error[E0080]: evaluation of constant value failed
   --> /builds/sophie-h/glycin/builddir/cargo-home/registry/src/index.crates.io-1cd66030c949c28d/libheif-sys-2.2.0+1.17.6/src/bindings.rs:695:10
    |
695 |         [::std::mem::size_of::<heif_depth_representation_info>() - 64usize];
    |          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempt to compute `56_usize - 64_usize`, which would overflow
error[E0080]: evaluation of constant value failed
    --> /builds/sophie-h/glycin/builddir/cargo-home/registry/src/index.crates.io-1cd66030c949c28d/libheif-sys-2.2.0+1.17.6/src/bindings.rs:1148:39
     |
1148 |     ["Size of heif_decoding_options"][::std::mem::size_of::<heif_decoding_options>() - 72usize];
     |                                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempt to compute `44_usize - 72_usize`, which would overflow
error[E0080]: evaluation of constant value failed
    --> /builds/sophie-h/glycin/builddir/cargo-home/registry/src/index.crates.io-1cd66030c949c28d/libheif-sys-2.2.0+1.17.6/src/bindings.rs:1390:10
     |
1390 |         [::std::mem::align_of::<heif_decoded_mastering_display_colour_volume>() - 8usize];
     |          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempt to compute `4_usize - 8_usize`, which would overflow
error[E0080]: evaluation of constant value failed
    --> /builds/sophie-h/glycin/builddir/cargo-home/registry/src/index.crates.io-1cd66030c949c28d/libheif-sys-2.2.0+1.17.6/src/bindings.rs:1468:29
     |
1468 |     ["Size of heif_writer"][::std::mem::size_of::<heif_writer>() - 16usize];
     |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempt to compute `8_usize - 16_usize`, which would overflow
error[E0080]: evaluation of constant value failed
    --> /builds/sophie-h/glycin/builddir/cargo-home/registry/src/index.crates.io-1cd66030c949c28d/libheif-sys-2.2.0+1.17.6/src/bindings.rs:1798:39
     |
1798 |     ["Size of heif_encoding_options"][::std::mem::size_of::<heif_encoding_options>() - 40usize];
     |                                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempt to compute `32_usize - 40_usize`, which would overflow
For more information about this error, try `rustc --explain E0080`.
error: could not compile `libheif-sys` (lib) due to 8 previous errors
Cykooz commented 3 days ago

Hm... bindgen is enabled by default.