cc-rs icon indicating copy to clipboard operation
cc-rs copied to clipboard

cc 1.0.86 changes placement of .a files in an incompatible manner, but only when used in `cargo install`

Open scouten-adobe opened this issue 1 year ago • 3 comments

Discovered that a public crate I maintain (https://github.com/adobe/xmp-toolkit-rs) that uses cc suddenly stopped building today, but only when it is used by a downstream crate and then only when the downstream crate is built using cargo install.

I've confirmed that pinning the cc release to 1.0.83 "fixes" the problem and am working on an emergency release.

Some additional info here (https://github.com/adobe/xmp-toolkit-rs/pull/194#issuecomment-1955898906). If needed, I can work on building a repro case in a day or two if that would be helpful.

A quick bit of context before I have to sign off. xmp-toolkit-rs has a rather complicated build process that assembles object files from three different libraries, each with wildly different requirements for C vs C++ build flags and then links them together. It depends on the location of the intermediate .o files as part of the build process and those files appear to have moved (again, only in the downstream cargo install case) between 1.0.83 and 1.0.86.

The error surfaced in this part of the build.rs code for xml-toolkit-rs: https://github.com/adobe/xmp-toolkit-rs/blob/76ba3ba32a46e9e2b6262c8b457449f422cda7b9/build.rs#L171-L199

scouten-adobe avatar Feb 21 '24 05:02 scouten-adobe