[clang] [Driver] Add support for -export-dynamic which can match GCC behavior. (PR #72781)

dong jianqiang via cfe-commits cfe-commits at lists.llvm.org
Sun Nov 19 17:17:25 PST 2023


dongjianqiang2 wrote:

> GCC's default spec file for Linux does not say how `-export-dynamic` translates to ld `-export-dynamic`.
> 
> I think ld `--export-dynamic` is exclusively caused by `-Wl,--export-dynamic` or `-rdynamic`. Do you have any example of `gcc -export-dynamic` uses?
> 
> > clang splits -export-dynamic into "-e" and "xport-dynamic"
> 
> This behavior simulates GCC but the uses seem extremely rare or not used at all. We probably should just reject `-exxx`: #72804



https://github.com/llvm/llvm-project/pull/72781


More information about the cfe-commits mailing list