BrettMayson / arma-rs

GNU General Public License v2.0
42 stars 8 forks source link

strip symbols from static library on Linux #23

Closed jonpas closed 2 years ago

jonpas commented 2 years ago

Using the following in Cargo.toml:

strip = true  # or equivalent "symbols"

works fine on Windows, it strips the irrelevant symbols from Rust libraries and retains all RVExtension* ones.

On Linux however, it removes all symbols.

strip has 3 values:

On Windows "debuginfo" and "symbols" result in the same thing, but on Linux they are different, "symbols" removes everything.

I don't know if there is an attribute that can be set on those symbols to prevent stripping them on Linux, so I am opening this issue in case there is a known solution. Of course the obvious solution is to use "debuginfo", but that also doesn't get rid of everything it could have.

jonpas commented 2 years ago

Disregard, the problem was caused by something completely different, this just partly fixed it, but is not the cause.