[PowerPC] Set the default PLT mode on musl to Secure PLT

The musl libc only supports Secure PLT.

Patch by A. Wilcox!

Reviewed By: jhibbits

Differential Revision: https://reviews.llvm.org/D59185

llvm-svn: 362051
This commit is contained in:
Fangrui Song 2019-05-30 02:13:15 +00:00
parent 0666f9c4e4
commit d9e9701c4b
1 changed files with 1 additions and 1 deletions

View File

@ -115,7 +115,7 @@ ppc::ReadGOTPtrMode ppc::getPPCReadGOTPtrMode(const Driver &D, const llvm::Tripl
const ArgList &Args) {
if (Args.getLastArg(options::OPT_msecure_plt))
return ppc::ReadGOTPtrMode::SecurePlt;
if (Triple.isOSNetBSD() || Triple.isOSOpenBSD())
if (Triple.isOSNetBSD() || Triple.isOSOpenBSD() || Triple.isMusl())
return ppc::ReadGOTPtrMode::SecurePlt;
else
return ppc::ReadGOTPtrMode::Bss;