[Hackage] #262: Check for required C libraries during configure

Hackage trac at galois.com
Tue Mar 25 13:50:55 EDT 2008


#262: Check for required C libraries during configure
----------------------------+-----------------------------------------------
  Reporter:  guest          |        Owner:         
      Type:  enhancement    |       Status:  new    
  Priority:  normal         |    Milestone:         
 Component:  Cabal library  |      Version:  1.2.3.0
  Severity:  normal         |   Resolution:         
  Keywords:                 |   Difficulty:  normal 
Ghcversion:  6.8.2          |     Platform:         
----------------------------+-----------------------------------------------
Comment (by duncan):

 I don't think the dependency analysis tickets are relevant here. Just
 knowing the required C headers and C libs and the include and library
 search paths is enough information to do the checks. It's just the same
 check that autoconf does and we can do it in a similar way.

 I'm not sure that being able to specify the foreign package dependencies
 would help here as we don't have a platform independent way of checking
 for them anyway. Those are more hints for package managers I'd say.

 So we should look up exactly how autoconf does these checks. My
 understanding is:

  * for headers it makes a small .c file that #includes the header and
 calls gcc/cpp to process the file. It passes the extra include search dirs
 with the -I flag.
  * for libs it makes a small .o file and calls gcc/ld with the -l and -L
 flags.

 If they fail then it means we cannot find the header/lib in question.

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


More information about the cabal-devel mailing list