driver: pass '-fPIC' option to assembler as well
authorSergei Trofimovich <slyfox@gentoo.org>
Wed, 27 Aug 2014 19:19:52 +0000 (22:19 +0300)
committerAustin Seipp <austin@well-typed.com>
Mon, 27 Oct 2014 15:57:15 +0000 (10:57 -0500)
commit39d0cad37a91591ae5be22200753206b57d0f169
tree1555c17e3d53843251d13fcd5db3363817b5ceee
parent53c6dcf7de6a57c68df52bb0efac3a4205086f73
driver: pass '-fPIC' option to assembler as well

Summary:
Before the patch '-fPIC' was passed only to C compiler,
but not to assembler itself.

It led to runtime crash in GHC_DYNAMIC_PROGRAMS=YES mode
on sparc32.

Technical details are in 'Note [-fPIC for assembler]'.

Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
Test Plan: validate on sparc

Reviewers: simonmar, austin, kgardas

Reviewed By: austin

Subscribers: simonmar, ezyang, carter

Differential Revision: https://phabricator.haskell.org/D177

(cherry picked from commit a93ab43ab5f40cadbedea2f6342b93c245e91434)
compiler/main/DriverPipeline.hs