|
| 1 | +# On Linux, if we don't link to gcc_eh, we get can get this error when loading the loadable extension: |
| 2 | +# undefined symbol: _Unwind_Resume |
| 3 | +# This adds around 29KB to the loadable extension. |
| 4 | +# It may also be an option to just define _Unwind_Resume, but it causes crashes on errors on e.g. iOS, so rather avoid it. |
| 5 | + |
| 6 | +[target.x86_64-unknown-linux-gnu] |
| 7 | +rustflags = [ |
| 8 | + "-C", "link-arg=-lgcc_eh", |
| 9 | +] |
| 10 | + |
| 11 | +[target.i686-linux-unknown-linux-gnu] |
| 12 | +rustflags = [ |
| 13 | + "-C", "link-arg=-lgcc_eh", |
| 14 | +] |
| 15 | + |
| 16 | +[target.aarch64-linux-unknown-linux-gnu] |
| 17 | +rustflags = [ |
| 18 | + "-C", "link-arg=-lgcc_eh", |
| 19 | +] |
| 20 | + |
| 21 | + |
| 22 | +# For iOS and macOS, we need to specify the minimum/target version. |
| 23 | +# This must match the versions in the podspec file. |
| 24 | +[target.aarch64-apple-ios] |
| 25 | +rustflags = [ |
| 26 | + "-C", "link-arg=-mios-version-min=11.0", |
| 27 | +] |
| 28 | + |
| 29 | +[target.aarch64-apple-ios-sim] |
| 30 | +rustflags = [ |
| 31 | + "-C", "link-arg=-miphonesimulator-version-min=11.0", |
| 32 | +] |
| 33 | + |
| 34 | +[target.x86_64-apple-ios] |
| 35 | +rustflags = [ |
| 36 | + "-C", "link-arg=-miphonesimulator-version-min=11.0", |
| 37 | +] |
| 38 | + |
| 39 | + |
| 40 | +[target.x86_64-apple-darwin] |
| 41 | +rustflags = [ |
| 42 | + "-C", "link-arg=-mmacosx-version-min=10.13", |
| 43 | +] |
| 44 | + |
| 45 | +[target.aarch64-apple-darwin] |
| 46 | +rustflags = [ |
| 47 | + "-C", "link-arg=-mmacosx-version-min=10.13", |
| 48 | +] |
| 49 | + |
0 commit comments