Victor Moreno <v.moreno at ico.scs.es> writes:> This is a recurrent question but could not find the answer in the > documentation. > > I want to build a dll for windows from a fortran program to be loaded with > dyn.load. I can do it easily for linux with: g77 -shared -o foo.dll foo.f > > The g77 compiler (mingw-1.01) for windows does not recognise the -shared > option. > > In windows the Writing extensions manual tells to use Rcmd SHLIB but I can't > find Rcmd > > Any help would be appreciated.Rcmd SHLIB is exactly for sorting out these OS differences. Rcmd.exe should be sitting in the same directory as Rgui.exe. I'm not quite sure whether it is selectable during installation. Did you read http://www.stats.ox.ac.uk/pub/Rtools/ ? You might also want to have a look at the readme.packages file in the top R directory. -- 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 _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
On Wed, 19 Sep 2001 12:53:31 -0400, you wrote in message <01091912533100.03175 at serc-vm.ico.scs.es>:>This is a recurrent question but could not find the answer in the >documentation. > >I want to build a dll for windows from a fortran program to be loaded with >dyn.load. I can do it easily for linux with: g77 -shared -o foo.dll foo.f > >The g77 compiler (mingw-1.01) for windows does not recognise the -shared >option. > >In windows the Writing extensions manual tells to use Rcmd SHLIB but I can't >find RcmdRcmd.exe should be in the "bin" subdirectory of the R home directory. If you're compiling things or putting together packages, it's a good idea to put that directory on your path. Other useful directories on your path if you're developing code: 1. the directory where you've got the collection of GNU tools (sed, make, etc.) 2. the Perl bin directory 3. directories where you keep any other useful tools and batch files you'll want to use 4. the Windows\command directory 5. the TeX bin directory 6. the HTML Help Workshop directory, if you're building Windows help files. My path has them in that order (with the R bin directory between 4 and 5); I'm not sure how crucial the order is, except that you definitely want to find the GNU tools before you find similarly named tools from other collections. Duncan Murdoch -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- 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 _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
Victor Moreno wrote:>This is a recurrent question but could not find the answer in the >documentation.>I want to build a dll for windows from a fortran program to be loaded with >dyn.load. I can do it easily for linux with: g77 -shared -o foo.dll foo.f>The g77 compiler (mingw-1.01) for windows does not recognise the -shared >option.>In windows the Writing extensions manual tells to use Rcmd SHLIB but Ican't>find RcmdYou don't tell which R version you have, but in v. 1.3.x, Rcmd.exe is in the \bin subdirectory. All the best, Philippe Grosjean ...........]<(({?<...............<?}))><............................... ) ) ) ) ) __ __ ( ( ( ( ( |__) | _ ) ) ) ) ) | hilippe |__)rosjean ( ( ( ( ( Marine Biol. Lab., ULB, Belgium ) ) ) ) ) __ ( ( ( ( ( |\ /| |__) ) ) ) ) ) | \/ |ariculture & |__)iostatistics ( ( ( ( ( ) ) ) ) ) e-mail: phgrosje at ulb.ac.be or phgrosjean at sciviews.org ( ( ( ( ( SciViews project coordinator (http://www.sciviews.org) ) ) ) ) ) tel: 00-32-2-650.29.70 (lab), 00-32-2-673.31.33 (home) ( ( ( ( ( ) ) ) ) ) "I'm 100% confident that p is between 0 and 1" ( ( ( ( ( L. Gonick & W. Smith (1993) ) ) ) ) ) ....................................................................... -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- 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, 19 Sep 2001, Victor Moreno wrote:> This is a recurrent question but could not find the answer in the > documentation. > > I want to build a dll for windows from a fortran program to be loaded with > dyn.load. I can do it easily for linux with: g77 -shared -o foo.dll foo.f > > The g77 compiler (mingw-1.01) for windows does not recognise the -shared > option. > > In windows the Writing extensions manual tells to use Rcmd SHLIB but I can't > find Rcmd > > Any help would be appreciated.Just to add a small piece: with that compiler g77 --shared -o foo.dll foo.f works for me. Note, --shared. -- Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272860 (secr) Oxford OX1 3TG, UK Fax: +44 1865 272595 -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- 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 _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
This is a recurrent question but could not find the answer in the documentation. I want to build a dll for windows from a fortran program to be loaded with dyn.load. I can do it easily for linux with: g77 -shared -o foo.dll foo.f The g77 compiler (mingw-1.01) for windows does not recognise the -shared option. In windows the Writing extensions manual tells to use Rcmd SHLIB but I can't find Rcmd Any help would be appreciated. Victor Moreno Catalan Institute of Oncology -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- 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 _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._