
#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_com... #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_com... #makefile-dependencies -- -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14756#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler