[Hackage] #209: Implement "package()" configurations predicate

Hackage trac at galois.com
Sat Nov 8 11:01:33 EST 2008


#209: Implement "package()" configurations predicate
----------------------------+-----------------------------------------------
  Reporter:  duncan         |        Owner:  nominolo      
      Type:  enhancement    |       Status:  new           
  Priority:  normal         |    Milestone:  Cabal-1.8     
 Component:  Cabal library  |      Version:  1.2.3.0       
  Severity:  normal         |   Resolution:                
  Keywords:                 |   Difficulty:  hard (< 1 day)
Ghcversion:  6.8.2          |     Platform:                
----------------------------+-----------------------------------------------
Comment (by duncan):

 Of course if we want it for `build-depends` then we may also want it for
 other dependencies like `pkgconfig-depends` or `build-tools`. So we should
 bear that in mind in designing a syntax.

 For example darcs might like to use:
 {{{
   pkgconfig-depends: libcurl
   if pkgconfig-depends(libcurl >= 7.19.1)
       -- curl 7.19.1 has bug-free pipelining
       cpp-options: -DCURL_PIPELINING_DEFAULT
 }}}
 as syntactic sugar for:
 {{{
 flag curl-pipelining
   description: Use libcurl's HTTP pipelining.

 ...

   pkgconfig-depends: libcurl
   if flag(curl-pipelining)
     -- curl 7.19.1 has bug-free pipelining
     pkgconfig-depends: libcurl >= 7.19.1
     cpp-options: -DCURL_PIPELINING_DEFAULT
   else
     pkgconfig-depends: libcurl < 7.19.1
 }}}

 Note of course the above doesn't work well yet anyway, it needs #342 to be
 implemented.

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


More information about the cabal-devel mailing list