Commit 4630ac74 authored by Ian Lynagh's avatar Ian Lynagh
Browse files

Create .hi-boot and .o-boot files in --make mode; fixes trac #1322

We were recompiling the .hs-boot files each time, as we were never
writing out the compilation results.
parent ee40dd6b
...@@ -156,7 +156,9 @@ compile hsc_env mod_summary maybe_old_linkable old_iface mod_index nmods = do ...@@ -156,7 +156,9 @@ compile hsc_env mod_summary maybe_old_linkable old_iface mod_index nmods = do
return (CompOK details iface maybe_old_linkable) return (CompOK details iface maybe_old_linkable)
handleBatch (HscRecomp hasStub, iface, details) handleBatch (HscRecomp hasStub, iface, details)
| isHsBoot src_flavour | isHsBoot src_flavour
= return (CompOK details iface Nothing) = do SysTools.touch dflags' "Touching object file"
object_filename
return (CompOK details iface Nothing)
| otherwise | otherwise
= do stub_unlinked <- getStubLinkable hasStub = do stub_unlinked <- getStubLinkable hasStub
(hs_unlinked, unlinked_time) <- (hs_unlinked, unlinked_time) <-
...@@ -1433,8 +1435,6 @@ hscNextPhase dflags other hsc_lang = ...@@ -1433,8 +1435,6 @@ hscNextPhase dflags other hsc_lang =
hscMaybeAdjustTarget :: DynFlags -> Phase -> HscSource -> HscTarget -> HscTarget hscMaybeAdjustTarget :: DynFlags -> Phase -> HscSource -> HscTarget -> HscTarget
hscMaybeAdjustTarget dflags stop HsBootFile current_hsc_lang
= HscNothing -- No output (other than Foo.hi-boot) for hs-boot files
hscMaybeAdjustTarget dflags stop other current_hsc_lang hscMaybeAdjustTarget dflags stop other current_hsc_lang
= hsc_lang = hsc_lang
where where
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment