One of the big problems in mixing fortran and C is knowing if the various compilers/loaders need extra underscores in the names of the entry points. The 0.62 release of R, which has reverted to using fortran, seems to be broken in this respect. In particular, on a machine which does not append underscores to fortran entry points (HP-UX 10.20), there are many problems. It seems that the configure script correctly determines is an extra underscore is needed or not, but it also seems that this information is not used. Early in the make process, the GETSYMBOLS script is run, but as far as I can tell this adds an extra underscore all the time. The GETSYMBOLS script relies on the information in appl/ROUTINES to determine if an entry point is fortran or C. However some of those entries (e.g., bkslv) are listed as fortran when they are really C entry points that have previously been converted from fortran (using f2c). Suffice to say, one (at least this "one") gets lost in the process of adding, subtracting underscores from various tables. Has anyone already fixed the underscore mess? Regards, --Mike Mike Meyer, Department of Statistics, Carnegie Mellon University -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- 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 _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
Mike Meyer <mikem at stat.cmu.edu> writes:> Early in the make process, the GETSYMBOLS script is run, but as far as I can > tell this adds an extra underscore all the time.Yup. You're right. The GETSYMBOLS script relies> on the information in appl/ROUTINES to determine if an entry point is fortran > or C. However some of those entries (e.g., bkslv) are listed as fortran when > they are really C entry points that have previously been converted from > fortran (using f2c).Yup again (wonder what happened to the original...).> Suffice to say, one (at least this "one") gets lost in the process of adding, > subtracting underscores from various tables.> Has anyone already fixed the underscore mess?It's a bit difficult without actually having a system where it matters... As far as I can see, what needs to be done is to apply the following algorithm: 100 Modify the GETSYMBOLS script by stripping the underscores from the F77_SUBROUTINE lines (2 lines, 3 underscores). 110 Try to compile. 120 IF it fails due to an f2c routine, edit src/appl/ROUTINES, replacing the F77_SUBROUTINE(xxx) with C_FUNCTION(xxx_), and goto 110. 130 Send us a copy of the resulting ROUTINES file. (We'll need to think of a way to get GETSYMBOLS to understand about the configure results, but getting the ROUTINES file right would be a useful first step) -- O__ ---- Peter Dalgaard Blegdamsvej 3 c/ /'_ --- Dept. of Biostatistics 2200 Cph. N (*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918 ~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk) FAX: (+45) 35327907 -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- 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 _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._