[Hackage] #527: CPP not called before ffihugs

Hackage trac at galois.com
Wed Mar 18 02:36:42 EDT 2009


#527: CPP not called before ffihugs
----------------------------+-----------------------------------------------
  Reporter:  guest          |        Owner:         
      Type:  defect         |       Status:  new    
  Priority:  normal         |    Milestone:         
 Component:  Cabal library  |      Version:  1.6.0.1
  Severity:  normal         |     Keywords:         
Difficulty:  unknown        |   Ghcversion:         
  Platform:                 |  
----------------------------+-----------------------------------------------
 When building for Hugs, if CPP is being used in conjunction with FFI, then
 cpp/cpphs
 is not called before ffihugs is called. Thus, users must pass an
 -F flag to ffihugs in order to declare a code filter (and must pass
 all cpp-options to -F manually). For example:

 {{{ --ffihugs-option=-F'cpp -P -traditional -D__HUGS__ -D__BLAH__' }}}

 This requires duplicating the build specifications, which defeats
 the point of Cabal. Also it leads to tricky issues about ensuring
 the proper level of quoting/escaping. (e.g. using the plural,
 --ffihugs-options=..., breaks it. Wrapping the -F'cpp...' in double
 quotes breaks it.)

 A simple example of this bug can be seen in Darcs repo
 http://community.haskell.org/~wren/cabal-ffihugstest

-- 
Ticket URL: <http://hackage.haskell.org/trac/hackage/ticket/527>
Hackage <http://haskell.org/cabal/>
Hackage: Cabal and related projects


More information about the cabal-devel mailing list