Search code examples
gccrustllvmtarget

How to use the -mlongcall GCC flag in Rust?


I am trying to run a Rust program on a powerpc arch. When I build my code in C I use the flag -mlongcall.

How can I use this flag for my Rust program? In general, it would be nice to know if I can use flags that I know from GCC in my Rust build.


Solution

  • The solution for the -mlongcall flag is to use the flag: -Ctarget-features=+longcall as suggested in this issue: add mlongcall flag to rustc