cross-rs / cross

“Zero setup” cross compilation and “cross testing” of Rust crates
Apache License 2.0
6.27k stars 357 forks source link

Set `PKG_CONFIG_ALLOW_CROSS=1` inside our dockerfiles instead of on invocation of docker #1413

Closed Emilgardis closed 6 months ago

Emilgardis commented 6 months ago

We currently set PKG_CONFIG_ALLOW_CROSS=1 here

https://github.com/cross-rs/cross/blob/3fc18388a8f159a01bd592adcc523c1c6a163790/src/docker/shared.rs#L1038

This should be done inside the image, since some images may not have pkg-config properly setup.

Emilgardis commented 6 months ago

To fix this, above line should be removed and instead PKG_CONFIG_ALLOW_CROSS=1 should be added to all dockerfiles that include PKG_CONFIG_PATH

Those files can be found with

rg -l 'PKG_CONFIG_PATH=' -g 'Dockerfile.*'

Swiimmingly commented 6 months ago

Hi, everything was provided pretty much but I fixed it I believe. First time contributing so please let me know if something is wrong

Emilgardis commented 6 months ago

Fixed by #1415