summaryrefslogtreecommitdiffstats
path: root/lib/Driver/ToolChains/OpenBSD.cpp
diff options
context:
space:
mode:
authorHans Wennborg <hans@hanshq.net>2017-08-02 17:42:08 +0000
committerHans Wennborg <hans@hanshq.net>2017-08-02 17:42:08 +0000
commitc4d55f5857a1e3a7f41bc75914fd43da30ae6326 (patch)
tree1d4b085a5e38008afce99e3399a2d8488b9023e6 /lib/Driver/ToolChains/OpenBSD.cpp
parent2239da4a1b47021c70e9a5aa4d0061412ea9f91b (diff)
Merging r309523:
------------------------------------------------------------------------ r309523 | brad | 2017-07-30 14:13:59 -0700 (Sun, 30 Jul 2017) | 2 lines Also pass -pie back to the linker when linking on OpenBSD. ------------------------------------------------------------------------ git-svn-id: https://llvm.org/svn/llvm-project/cfe/branches/release_50@309844 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Driver/ToolChains/OpenBSD.cpp')
-rw-r--r--lib/Driver/ToolChains/OpenBSD.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/Driver/ToolChains/OpenBSD.cpp b/lib/Driver/ToolChains/OpenBSD.cpp
index c5f266ec8f..1d54a1e9cb 100644
--- a/lib/Driver/ToolChains/OpenBSD.cpp
+++ b/lib/Driver/ToolChains/OpenBSD.cpp
@@ -133,6 +133,8 @@ void openbsd::Linker::ConstructJob(Compilation &C, const JobAction &JA,
}
}
+ if (Args.hasArg(options::OPT_pie))
+ CmdArgs.push_back("-pie");
if (Args.hasArg(options::OPT_nopie))
CmdArgs.push_back("-nopie");