Trouble building Bioconductor
4
0
Entering edit mode
@atro-tossavainen-1104
Last seen 10.3 years ago
Hi, I have successfully built R 2.2.1 for x86 Linux, PPC Linux, Solaris 7 and IRIX 6.5. I am now trying to add Bioconductor to all of these using source("http://www.bioconductor.org/getBioC.R") getBioC() On x86 Linux (what I'm using is essentially FC1), I have no problems. On Solaris 7, building gcrma fails. Replacing my R path with "..." in the following error messages. I am using Sun WorkShop 6 update 2 C 5.3 2001/05/15. * Installing *source* package 'gcrma' ... ** libs cc -I/.../R/2.2.1/lib/R/include -I/another/include -KPIC -g -c baseProfile.c -o baseProfile.o cc -I/.../R/2.2.1/lib/R/include -I/another/include -KPIC -g -c computeAffinities.c -o computeAffinities.o cc -I/.../R/2.2.1/lib/R/include -I/another/include -KPIC -g -c postmean.c -o postmean.o "postmean.c", line 26: syntax error before or at: double "postmean.c", line 27: undefined symbol: pnorms "postmean.c", line 27: cannot dereference non-pointer type "postmean.c", line 32: cannot dereference non-pointer type "postmean.c", line 33: undefined symbol: diff_pnorms "postmean.c", line 33: cannot dereference non-pointer type "postmean.c", line 33: cannot dereference non-pointer type cc: acomp failed for postmean.c *** Error code 2 make: Fatal error: Command failed for target `postmean.o' ERROR: compilation failed for package 'gcrma' ** Removing '/.../R/2.2.1/lib.sun4x_57/R/library/gcrma' and everything else fails after that, of course, due to gcrma not having been built. On IRIX 6.5.28, with MIPSpro 7.3 compilers, it fails too: cc -I/.../R/2.2.1/lib/R/include -I/another/include -OPT:IEEE_NaN_inf=ON -g -c postmean.c -o postmean.o cc-1241 cc: ERROR File = postmean.c, Line = 26 A declaration cannot appear after an executable statement in a block. double pnorms[K+1],g[K+2],diff_pnorms; ^ 1 error detected in the compilation of "postmean.c". *** Error code 2 (bu21) ERROR: compilation failed for package 'gcrma' ** Removing '/.../R/2.2.1/lib. at sys/R/library/gcrma' On Yellow Dog Linux 2.3 (PPC, with gcc 2.95.4), it fails too: gcc -I/.../R/2.2.1/lib/R/include -I/usr/local/include -fPIC -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -g -O2 -c postmean.c -o postmean.o postmean.c: In function `posty': postmean.c:26: parse error before `double' postmean.c:27: `pnorms' undeclared (first use in this function) postmean.c:27: (Each undeclared identifier is reported only once postmean.c:27: for each function it appears in.) postmean.c:33: `diff_pnorms' undeclared (first use in this function) make: *** [postmean.o] Error 1 ERROR: compilation failed for package 'gcrma' ** Removing '/.../R/2.2.1/lib. at sys/R/library/gcrma' Help would be appreciated. -- Atro Tossavainen (Mr.) / The Institute of Biotechnology at Systems Analyst, Techno-Amish & / the University of Helsinki, Finland, +358-9-19158939 UNIX Dinosaur / employs me, but my opinions are my own. < URL : http : / / www . helsinki . fi / %7E atossava / > NO FILE ATTACHMENTS
gcrma gcrma • 1.6k views
ADD COMMENT
0
Entering edit mode
@herve-pages-1542
Last seen 3 days ago
Seattle, WA, United States
Hi Atro, These problems seem to occur with C compilers that don't support declarations that appear after an executable statement in a block. The ability to declare a variable in the middle of a block was introduced in the C99 specifications. Since the C code in the postmean.c file makes use of this feature, you'll need a C99-compliant in order to compile it. For a list of compilers that support C99, see: http://clc-wiki.net/wiki/C_Compilers A recent version of gcc (>= 3.3) should work... Best, H. Atro Tossavainen wrote: >Hi, > >I have successfully built R 2.2.1 for x86 Linux, PPC Linux, Solaris 7 >and IRIX 6.5. I am now trying to add Bioconductor to all of these >using > >source("http://www.bioconductor.org/getBioC.R") >getBioC() > >On x86 Linux (what I'm using is essentially FC1), I have no problems. > >On Solaris 7, building gcrma fails. Replacing my R path with "..." >in the following error messages. I am using Sun WorkShop 6 update 2 >C 5.3 2001/05/15. > >* Installing *source* package 'gcrma' ... >** libs >cc -I/.../R/2.2.1/lib/R/include -I/another/include -KPIC -g -c baseProfile.c -o baseProfile.o >cc -I/.../R/2.2.1/lib/R/include -I/another/include -KPIC -g -c computeAffinities.c -o computeAffinities.o >cc -I/.../R/2.2.1/lib/R/include -I/another/include -KPIC -g -c postmean.c -o postmean.o >"postmean.c", line 26: syntax error before or at: double >"postmean.c", line 27: undefined symbol: pnorms >"postmean.c", line 27: cannot dereference non-pointer type >"postmean.c", line 32: cannot dereference non-pointer type >"postmean.c", line 33: undefined symbol: diff_pnorms >"postmean.c", line 33: cannot dereference non-pointer type >"postmean.c", line 33: cannot dereference non-pointer type >cc: acomp failed for postmean.c >*** Error code 2 >make: Fatal error: Command failed for target `postmean.o' >ERROR: compilation failed for package 'gcrma' >** Removing '/.../R/2.2.1/lib.sun4x_57/R/library/gcrma' > >and everything else fails after that, of course, due to gcrma not having >been built. > >On IRIX 6.5.28, with MIPSpro 7.3 compilers, it fails too: > > cc -I/.../R/2.2.1/lib/R/include -I/another/include -OPT:IEEE_NaN_inf=ON -g -c postmean.c -o postmean.o >cc-1241 cc: ERROR File = postmean.c, Line = 26 > A declaration cannot appear after an executable statement in a block. > > double pnorms[K+1],g[K+2],diff_pnorms; > ^ > >1 error detected in the compilation of "postmean.c". >*** Error code 2 (bu21) >ERROR: compilation failed for package 'gcrma' >** Removing '/.../R/2.2.1/lib. at sys/R/library/gcrma' > >On Yellow Dog Linux 2.3 (PPC, with gcc 2.95.4), it fails too: > >gcc -I/.../R/2.2.1/lib/R/include -I/usr/local/include -fPIC -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -g -O2 -c postmean.c -o postmean.o >postmean.c: In function `posty': >postmean.c:26: parse error before `double' >postmean.c:27: `pnorms' undeclared (first use in this function) >postmean.c:27: (Each undeclared identifier is reported only once >postmean.c:27: for each function it appears in.) >postmean.c:33: `diff_pnorms' undeclared (first use in this function) >make: *** [postmean.o] Error 1 >ERROR: compilation failed for package 'gcrma' >** Removing '/.../R/2.2.1/lib. at sys/R/library/gcrma' > >Help would be appreciated. > > > -- ------------------------ Hervé Pagès E-mail: hpages at fhcrc.org Phone: (206) 667-5791 Fax: (206) 667-1319
ADD COMMENT
0
Entering edit mode
Dear Mr Pages > These problems seem to occur with C compilers that don't support > declarations that appear after an executable statement in a block. > The ability to declare a variable in the middle of a block was introduced > in the C99 specifications. Since the C code in the postmean.c file makes > use of this feature, you'll need a C99-compliant in order to compile it. Thank you for the explanation. > For a list of compilers that support C99, see: > http://clc-wiki.net/wiki/C_Compilers > > A recent version of gcc (>= 3.3) should work... The page contains nothing on anything related to anything else but x86 platforms (except for one compiler that runs on an outdated OS on Mac). So you're suggesting that I should recompile R, which can be quite a heavy application, with gcc, whose code generation on platforms other than x86 often leaves a lot to be desired, and where native compilers that are often significantly better than gcc in other respects are available to get any use of Bioconductor at all? It doesn't really sound all that appealing. Somewhat fortunately, Sun appears to have C99 support since Studio 9, and SGI since MIPSpro 7.4. Perhaps all that I need to do is to upgrade the operating systems and compiler libraries on all of the Suns and SGIs in my herd (which means several dozen machines) to these newer versions and I will be able to avoid gcc when compiling R. -- Atro Tossavainen (Mr.) / The Institute of Biotechnology at Systems Analyst, Techno-Amish & / the University of Helsinki, Finland, +358-9-19158939 UNIX Dinosaur / employs me, but my opinions are my own. < URL : http : / / www . helsinki . fi / %7E atossava / > NO FILE ATTACHMENTS
ADD REPLY
0
Entering edit mode
Atro Tossavainen wrote: >Dear Mr Pages > > > >>These problems seem to occur with C compilers that don't support >>declarations that appear after an executable statement in a block. >>The ability to declare a variable in the middle of a block was introduced >>in the C99 specifications. Since the C code in the postmean.c file makes >>use of this feature, you'll need a C99-compliant in order to compile it. >> >> > >Thank you for the explanation. > > > >>For a list of compilers that support C99, see: >> http://clc-wiki.net/wiki/C_Compilers >> >>A recent version of gcc (>= 3.3) should work... >> >> > >The page contains nothing on anything related to anything else but x86 >platforms (except for one compiler that runs on an outdated OS on Mac). > > Are you kidding? Nowhere it is said that the compilers listed on this page are for x86 only. For example, it says that the gcc compiler (the first in the list) supports "Windows, Linux and many others". And if you take the time to go on the GCC website, you'll see that it supports indeed many other platforms (http://gcc.gnu.org/install/specific.html), including Solaris 2.7 and Irix 6. >So you're suggesting that I should recompile R, which can be quite a >heavy application, with gcc, whose code generation on platforms other >than x86 often leaves a lot to be desired, and where native compilers >that are often significantly better than gcc in other respects are >available to get any use of Bioconductor at all? It doesn't really >sound all that appealing. > > If your native compiler supports C99 then use it. If it does not, then you have alternatives, like gcc. We are currently using gcc to build and check the binary packages that we distribute and we have no problem with it. It's free, it's open source, it successfully builds R on 32-bit Linux, 64-bit Linux, Mac OS X, Solaris, IRIX, and many more... It also supports Fortran, C++ and Java so by installing it you will also be able to compile R packages that make use of these languages. And recompiling R on a Unix system is very easy. What can be not that easy is to compile and install gcc + libraries (this can take a while on an old system). However the cost in time and effort to install gcc can't be compared in any manner to the cost in time and effort to upgrade the operating system. >Somewhat fortunately, Sun appears to have C99 support since Studio 9, >and SGI since MIPSpro 7.4. Perhaps all that I need to do is to upgrade >the operating systems and compiler libraries on all of the Suns and SGIs >in my herd (which means several dozen machines) to these newer versions >and I will be able to avoid gcc when compiling R. > > > Good luck! -- ------------------------ Hervé Pagès E-mail: hpages at fhcrc.org Phone: (206) 667-5791 Fax: (206) 667-1319
ADD REPLY
0
Entering edit mode
Dear Mr Pages >> The page contains nothing on anything related to anything else but x86 >> platforms (except for one compiler that runs on an outdated OS on Mac). > > Are you kidding? Nowhere it is said that the compilers listed on this > page are for x86 only. Aside from gcc, they are. And indeed it says: "This page lists compiler availability with a focus on free compilers that run on Windows and Linux." > For example, it says that the gcc compiler (the first > in the list) supports "Windows, Linux and many others". Yes, I am familiar with gcc and have had 3.4.2 available on all my platforms for quite some time. > If your native compiler supports C99 then use it. If it does not, then > you have alternatives, like gcc. My issue is the fact that I am able to build R with a particular compiler but unable to build Bioconductor with the same compiler. It would make sense for the requirements for R and its contributed packages to be identical, don't you think. > We are currently using gcc to build and check the binary packages that > we distribute and we have no problem with it. It's free, it's open > source, it successfully builds R on 32-bit Linux, > 64-bit Linux, Mac OS X, Solaris, IRIX, and many more... And makes coffee and plays gomoku. I do not need a lecture on the merits of gcc. I am perfectly aware of all that you say. However, compiling resource-hungry software such as R with a sub-optimal compiler such as gcc makes no sense. It only makes sense if you don't have access to the native compilers for the platform in question, and I dare say that most of the academic community who have any sort of access to commercial UNIX platforms already have access to the native compilers on those platforms via campus licensing agreements and would always expect to compile any software with the native compilers instead of gcc in order to reach the maximum potential of the hardware. -- Atro Tossavainen (Mr.) / The Institute of Biotechnology at Systems Analyst, Techno-Amish & / the University of Helsinki, Finland, +358-9-19158939 UNIX Dinosaur / employs me, but my opinions are my own. < URL : http : / / www . helsinki . fi / %7E atossava / > NO FILE ATTACHMENTS
ADD REPLY
0
Entering edit mode
On Feb 22, 2006, at 1:06 AM, Atro Tossavainen wrote: > Dear Mr Pages > >>> The page contains nothing on anything related to anything else >>> but x86 >>> platforms (except for one compiler that runs on an outdated OS on >>> Mac). >> >> Are you kidding? Nowhere it is said that the compilers listed on this >> page are for x86 only. > > Aside from gcc, they are. And indeed it says: "This page lists > compiler > availability with a focus on free compilers that run on Windows and > Linux." > >> For example, it says that the gcc compiler (the first >> in the list) supports "Windows, Linux and many others". > > Yes, I am familiar with gcc and have had 3.4.2 available on all my > platforms for quite some time. > >> If your native compiler supports C99 then use it. If it does not, >> then >> you have alternatives, like gcc. > > My issue is the fact that I am able to build R with a particular > compiler > but unable to build Bioconductor with the same compiler. It would > make > sense for the requirements for R and its contributed packages to be > identical, don't you think. Not necessarily. There are packages (both on CRAN and Bioconductor) that depends on external applications. I agree that it would be nice for a package such as gcrma to build on exactly the same platforms as R does. But R strongly suggests using a C99 compliant compiler (see R-exts) Quote: ***** A.1 Essential programs You need a means of compiling C and FORTRAN 77 (see Using FORTRAN). Some add-on packages also need a C++ compiler. Your C compiler should be IEC600593, POSIX 1003.1 and C99-compliant if at all possible. R tries to choose suitable flags for the C compilers it knows about, but you may have to set CFLAGS suitably. For recent versions of gcc with glibc this means including -std=gnu99 in CFLAGS (-std=c99 excludes POSIX functionality). ****** Note that it may be the case that your compilers are partly C99 compliant (enough so that they build R but fail to support this particular case). But since R-exts C99 compliance "if at all possible", it does not seem to be a strange requirement from gcrma. Now, I did a quick googling on your compilers and it seems to be the case that gcc-2.95.4 is not C99 compliant and that the IRX one needs a -c99 flag in order to ensure compliance. I could not find info on the Sun system. So for the IRX system you could recompile R with CFLAGS set "correctly" or you could do a testrun where you download the source code for gcrma, add a file in gcrma/src called Makevars with the line PKG_CFLAGS+= -c99 and see if it works. If your compiler really is C99 compliant and gcrma does not build, then you need to report that bug to the maintainer of gcrma. And there is always the question whether the function could be re-written so that the offending part is altered, but that needs a more careful analysis of the code. /Kasper >> We are currently using gcc to build and check the binary packages >> that >> we distribute and we have no problem with it. It's free, it's open >> source, it successfully builds R on 32-bit Linux, >> 64-bit Linux, Mac OS X, Solaris, IRIX, and many more... > > And makes coffee and plays gomoku. I do not need a lecture on the > merits > of gcc. I am perfectly aware of all that you say. However, compiling > resource-hungry software such as R with a sub-optimal compiler such as > gcc makes no sense. It only makes sense if you don't have access > to the > native compilers for the platform in question, and I dare say that > most > of the academic community who have any sort of access to commercial > UNIX > platforms already have access to the native compilers on those > platforms > via campus licensing agreements and would always expect to compile any > software with the native compilers instead of gcc in order to reach > the > maximum potential of the hardware. > > -- > Atro Tossavainen (Mr.) / The Institute of > Biotechnology at > Systems Analyst, Techno-Amish & / the University of Helsinki, > Finland, > +358-9-19158939 UNIX Dinosaur / employs me, but my opinions > are my own. > < URL : http : / / www . helsinki . fi / %7E atossava / > NO FILE > ATTACHMENTS > > _______________________________________________ > Bioconductor mailing list > Bioconductor at stat.math.ethz.ch > https://stat.ethz.ch/mailman/listinfo/bioconductor
ADD REPLY
0
Entering edit mode
@herve-pages-1542
Last seen 3 days ago
Seattle, WA, United States
We modified the code in the gcrma package so now it should build with an ANSI-compliant C compiler. To proceed: source("http://www.bioconductor.org/getBioC.R") getBioC() -- ------------------------ Hervé Pagès E-mail: hpages at fhcrc.org Phone: (206) 667-5791 Fax: (206) 667-1319
ADD COMMENT
0
Entering edit mode
@herve-pages-1542
Last seen 3 days ago
Seattle, WA, United States
Atro Tossavainen wrote: >Dear Mr Pages > >(Taking this out of the mailing list - probably no longer of general >interest if it ever was.) > > Yes it's still of general interest. > > >>We modified the code in the gcrma package so now it should build >>with an ANSI-compliant C compiler. >> >> > >Thank you! It did indeed. > >rowPAUCs.c in genefilter seems to require C99 too. > > Please consider reporting this problem with the maintainer of the package. >For whatever's it's worth, Studio 11 on Sun (which is free, and is >also available for Linux on x86 as well as Solaris on x86) compiles >C99 at least sufficiently to survive these uses of C99 features. > > Yes good news. It's free since... november 2005. And you need at least Solaris 8. Wasn't your system Solaris 7? >I have yet to try out MIPSpro 7.4 on SGI, but will let you know once >I have. > > -- ------------------------ Hervé Pagès E-mail: hpages at fhcrc.org Phone: (206) 667-5791 Fax: (206) 667-1319
ADD COMMENT
0
Entering edit mode
@atro-tossavainen-1104
Last seen 10.3 years ago
(Mr Pages - sorry - meant to send this to the list, of course, not to you alone.) > Yes it's still of general interest. OK, here it is, then. >> Thank you! It did indeed. >> >> rowPAUCs.c in genefilter seems to require C99 too. > > Please consider reporting this problem with the maintainer of > the package. I hope they're reading the list, then. > Yes good news. It's free since... november 2005. Indeed, this is fairly recent news. > And you need at least Solaris 8. Wasn't your system Solaris 7? Some of the older ones are. Time to upgrade, I guess. I was thinking it might be possible to run the Bioconductor that I compiled with the newer compiler on the older OS release nonetheless. Am trying it out right now. -- Atro Tossavainen (Mr.) / The Institute of Biotechnology at Systems Analyst, Techno-Amish & / the University of Helsinki, Finland, +358-9-19158939 UNIX Dinosaur / employs me, but my opinions are my own. < URL : http : / / www . helsinki . fi / %7E atossava / > NO FILE ATTACHMENTS
ADD COMMENT

Login before adding your answer.

Traffic: 669 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6