[BioC] Problems installing BioC, zlib.h

Herve Pages hpages at fhcrc.org
Tue Jun 26 21:19:37 CEST 2007

Hi Markus,

Markus Schmidberger wrote:
> Hello,
> we have installed R-2.5.0 at a Debian 4.0
> ./configure --with-x=no && make && make checks && make install
> There are no problems and R is running very well.
>  >sessionInfo()
> R version 2.5.0 (2007-04-23)
> i686-pc-linux-gnu
> locale:
> attached base packages:
> [1] "stats"     "graphics"  "grDevices" "utils"     "datasets"  "methods"
> [7] "base"
> But when we install Bioconductor or only the library(affyio) we get the 
> error:
> ==================================================
> downloaded 57Kb
> * Installing *source* package 'affyio' ...
> creating cache ./config.cache
> checking how to run the C preprocessor... cc -E
> checking for main in -lz... no
> updating cache ./config.cache
> creating ./config.status
> creating src/Makevars
> ** libs
> gcc -std=gnu99 -I/usr/local/lib/R/include -I/usr/local/lib/R/include  
> -I/usr/local/include    -fpic  -g -O2 -c read_abatch.c -o read_abatch.o
> read_abatch.c:153:18: error: zlib.h: Datei oder Verzeichnis nicht gefunden
> read_abatch.c:1246: error: expected declaration specifiers or â...â 
> before âgzFileâ
> read_abatch.c: In function âReadgzFileLineâ:
> read_abatch.c:1247: warning: implicit declaration of function âgzgetsâ
> read_abatch.c:1247: error: âcurrentFileâ undeclared (first use in this 
> function)
> read_abatch.c:1247: error: (Each undeclared identifier is reported only 
> once
> I think that there is missing a zlib library, but zlib-bin and zlibc are 
> installed.

affyio configure script is reporting "checking for main in -lz... no" which
seems to indicate that something is wrong with your zlib installation.
Try this simple test (1):

  echo "main() {return 0;}" | gcc -x c - -lz

This should produce an executable a.out linked to the libz library. If you
are curious to see which libs a.out is actually linked to, try (2):

  ldd a.out

If (1) fails for you, then you probably have the wrong deb packages installed
or something bad happened when they were installed. Try to reinstall them.
FYI, on my Ubuntu 6.06 system, the zlib packages I have are zlib1g and zlib1g-dev
The latter is required too in order to compile affyio.


> What is wrong?
> Thanks a lot
> Markus

More information about the Bioconductor mailing list