I'm looking for some help in getting R to compile on Sunos. We run a collection of Sunos and Solaris machines in the department here. I got to compile on Solaris 2.5.1 using gcc 2.7.2.2. On my Sunos 4.1.3 (and I've tried it on Sunos 4.1.4 as well) machines, it crashes during the compile. I'm using gcc 2.8.1 on there. It gets to this point: gcc -g -O2 -I../include -I../../src/include -c bessel_y.c -o bessel_y.o gcc -g -O2 -I../include -I../../src/include -c choose.c -o choose.o gcc -g -O2 -I../include -I../../src/include -c snorm.c -o snorm.o gcc -g -O2 -I../include -I../../src/include -c sunif.c -o sunif.o sunif.c: In function `unif_rand': sunif.c:131: `RAND_MAX' undeclared (first use in this function) sunif.c:131: (Each undeclared identifier is reported only once sunif.c:131: for each function it appears in.) sunif.c: In function `Randomize': sunif.c:213: `NULL' undeclared (first use in this function) make[2]: *** [sunif.o] Error 1 make[2]: Leaving directory `/usr/export/home/fac2/faulkner/R-0.63.2/src/nmath' make[1]: *** [R] Error 1 make[1]: Leaving directory `/usr/export/home/fac2/faulkner/R-0.63.2/src' make: *** [R] Error 1 Anyone have any hints on this? Its particularly wanted on Sunos by a professor here. -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= =- Wendy Faulkner =- Def: Skydiver - a person who =- faulkner at eco.utexas.edu =- plays chicken with the earth. =- http://www.eco.utexas.edu/~faulkner =- Rule #1: The earth doesn't flinch. =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
>>>>> faulkner writes:> I'm looking for some help in getting R to compile on Sunos. We run a > collection of Sunos and Solaris machines in the department here. I got > to compile on Solaris 2.5.1 using gcc 2.7.2.2. On my Sunos 4.1.3 (and > I've tried it on Sunos 4.1.4 as well) machines, it crashes during the > compile. I'm using gcc 2.8.1 on there. It gets to this point:> gcc -g -O2 -I../include -I../../src/include -c bessel_y.c -o bessel_y.o > gcc -g -O2 -I../include -I../../src/include -c choose.c -o choose.o > gcc -g -O2 -I../include -I../../src/include -c snorm.c -o snorm.o > gcc -g -O2 -I../include -I../../src/include -c sunif.c -o sunif.o > sunif.c: In function `unif_rand': > sunif.c:131: `RAND_MAX' undeclared (first use in this function) > sunif.c:131: (Each undeclared identifier is reported only once > sunif.c:131: for each function it appears in.) > sunif.c: In function `Randomize': > sunif.c:213: `NULL' undeclared (first use in this function) > make[2]: *** [sunif.o] Error 1 > make[2]: Leaving directory > `/usr/export/home/fac2/faulkner/R-0.63.2/src/nmath' > make[1]: *** [R] Error 1 > make[1]: Leaving directory `/usr/export/home/fac2/faulkner/R-0.63.2/src' > make: *** [R] Error 1Should be fixed in the most recent r-release snapshots. -k -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
On Wed, 24 Feb 1999 faulkner at eco.utexas.edu wrote:> I'm looking for some help in getting R to compile on Sunos.If you want a patch in the meantime (rather than getting the newest release version), try using the following patch (in src/nmath). (This just hand-defines RAND_MAX and changes NULL to 0.) It worked for me on release 0.63.1, SunOS 4.1.4. *** sunif.c.orig Sat Jan 2 15:16:12 1999 --- sunif.c Sat Jan 2 15:24:40 1999 *************** *** 46,51 **** --- 46,53 ---- Int32 dummy[3]; + #define RAND_MAX 4294967295 /* 2^32-1; works on SunOS 4.1.4 */ + RNGTAB RNG_Table[] { /* kind name is_seeded seed-length i1_s, *seed-vec */ *************** *** 210,216 **** MaybeAllocSeeds(kind); ! srand((int)time(NULL)); RNG_Init(kind, (long) rand() | 01/* odd */); } --- 212,218 ---- MaybeAllocSeeds(kind); ! srand((int)time(0)); RNG_Init(kind, (long) rand() | 01/* odd */); } -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._