[GHC] #14756: `ghc -M` doesn't emit dependencies for header files included either via CPP or CApiFFI
GHC
ghc-devs at haskell.org
Sun Feb 4 13:48:54 UTC 2018
#14756: `ghc -M` doesn't emit dependencies for header files included either via CPP
or CApiFFI
-------------------------------------+-------------------------------------
Reporter: hvr | Owner: (none)
Type: feature request | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 8.2.2
Resolution: | Keywords: capi capiffi
| cpp
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: None/Unknown | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Description changed by hvr:
Old description:
> Given the following simple module
>
> {{{#!hs
> {-# LANGUAGE CApiFFI #-}
>
> #include "Bar.hs.inc"
>
> module Foo where
>
> foreign import capi unsafe "cbits.h foo" c_foo :: Int -> IO ()
> }}}
>
> The dependency information produced by `ghc -dep-suffix '' -M Foo.hs` is
>
> {{{
> # DO NOT DELETE: Beginning of Haskell dependencies
> Foo.o : Foo.hs
> # DO NOT DELETE: End of Haskell dependencies
> }}}
>
> And neither mention the include header dependency `cbits.h` nor
> `Bar.hs.inc`.
>
>
> See also
> https://downloads.haskell.org/~ghc/latest/docs/html/users_guide/separate_compilation.html
> #makefile-dependencies
New description:
Given the following simple module
{{{#!hs
{-# LANGUAGE CPP, CApiFFI #-}
#include "Bar.hs.inc"
module Foo where
foreign import capi unsafe "cbits.h foo" c_foo :: Int -> IO ()
}}}
The dependency information produced by `ghc -dep-suffix '' -M Foo.hs` is
{{{
# DO NOT DELETE: Beginning of Haskell dependencies
Foo.o : Foo.hs
# DO NOT DELETE: End of Haskell dependencies
}}}
And neither mention the include header dependency `cbits.h` nor
`Bar.hs.inc`.
See also
https://downloads.haskell.org/~ghc/latest/docs/html/users_guide/separate_compilation.html
#makefile-dependencies
--
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/14756#comment:1>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list