[Hackage] #564: Cabal doesn't use LD options when testing linking

Hackage trac at galois.com
Tue Jul 7 15:44:20 EDT 2009


#564: Cabal doesn't use LD options when testing linking
----------------------------+-----------------------------------------------
  Reporter:  igloo          |        Owner:           
      Type:  defect         |       Status:  new      
  Priority:  high           |    Milestone:  Cabal-1.8
 Component:  Cabal library  |      Version:  1.6.0.1  
  Severity:  normal         |   Resolution:           
  Keywords:                 |   Difficulty:  unknown  
Ghcversion:                 |     Platform:           
----------------------------+-----------------------------------------------
Comment (by sudish):

 Replying to [comment:4 duncan]:
 > It'd be better to use:
 > {{{
 > --extra-lib-dirs=/usr/local/lib
 > --extra-include-dirs=/usr/local/include
 > }}}

 I'm running into the same problem when trying to build ghc HEAD under OS
 X.  In my case, I have some of the requisite libs under
 /opt/local/{include,lib} since I use MacPorts to install them.  The ghc
 build system fails to find them for the above reasons.

 I tried to work around this by adding the following to ~/.cabal/config:

 {{{
 extra-include-dirs: /opt/local/include
 extra-lib-dirs: /opt/local/lib
 }}}

 This seems to have no effect on the build.  Does the in-place cabal not
 look at that config file?

 More to the point, is there any way to pass in those dirs as defaults for
 the entire build?  I.e., a way to add to ghc's in-place cabal's default
 search paths?

 Thanks!
 -Sudish

 PS: I do have a very ugly workaround: symlink all required headers and
 libs into dirs on gcc's default search paths.  This is very fragile and
 error-prone, however, and I would rather not do that.

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


More information about the cabal-devel mailing list