[Rd] package matrix dummy.cpp
Hi, The recommended package matrix contains an empty file src/dummy.cpp which results in using g++ instead of gcc to link Matrix.so. What is the reason for that? Is there any difference between using g++ or gcc? (There are no other cpp files in the source) I asked the maintainers of the package (matrix-auth...@r-project.org) 3 weeks ago but haven't received any answer. On my system (NixOS Linux distribution, http://nixos.org) I can't compile package Matrix unless this file is deleted. Thank you very much, Ambrus Kaposi __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
Re: [Rd] package matrix dummy.cpp
It is Matrix, not matrix I too have corresponded with them about this. It seems to be a legacy from when the package contained C++ code, and can now be deleted. On Sun, 28 Nov 2010, Ambrus Kaposi wrote: Hi, The recommended package matrix contains an empty file src/dummy.cpp which results in using g++ instead of gcc to link Matrix.so. What is the reason for that? Is there any difference between using g++ or gcc? (There are no other cpp files in the source) I asked the maintainers of the package (matrix-auth...@r-project.org) 3 weeks ago but haven't received any answer. On my system (NixOS Linux distribution, http://nixos.org) I can't compile package Matrix unless this file is deleted. Most likely you have not installed the C++ compiler (which is usually g++ on Linux) -- but you shouldn't need to in order to install R. Thank you very much, Ambrus Kaposi __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel -- Brian D. Ripley, rip...@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 272866 (PA) Oxford OX1 3TG, UKFax: +44 1865 272595 __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
Re: [Rd] package matrix dummy.cpp
> Prof Brian Ripley > on Sun, 28 Nov 2010 16:00:53 + (GMT) writes: > It is Matrix, not matrix indeed! > I too have corresponded with them about this. It seems to > be a legacy from when the package contained C++ code, and > can now be deleted. yes. Though, as Brian mentions below it's strange that you can't compile the package (how?) with the file present. I'd guess that this would mean you cannot (easily) install any CRAN packages that use C++ ? I think this will preclude you from using very fine R extensions! > On Sun, 28 Nov 2010, Ambrus Kaposi wrote: >> Hi, >> >> The recommended package matrix contains an empty file >> src/dummy.cpp which results in using g++ instead of gcc >> to link Matrix.so. What is the reason for that? Is there >> any difference between using g++ or gcc? (There are no >> other cpp files in the source) I asked the maintainers of >> the package (matrix-auth...@r-project.org) 3 weeks ago >> but haven't received any answer. I apologize for that. Both Professor Doug Bates and I have been overloaded, and so this has "slipped". >> On my system (NixOS >> Linux distribution, http://nixos.org) I can't compile >> package Matrix unless this file is deleted. > Most likely you have not installed the C++ compiler (which > is usually g++ on Linux) -- but you shouldn't need to in > order to install R. Indeed, currently a C++ compiler for compiling/linking the R sources should not be needed just because of dummy.cpp in Matrix; and hence I've removed it for the next version of Matrix. However, as said above, I strongly believe your OS / R setup should be amended in such a way that you can also easily install packages with C++ code. Best regards, Martin Maechler, ETH Zurich >> Thank you very much, Ambrus Kaposi __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
Re: [Rd] package matrix dummy.cpp
Thank you for the help. > yes. Though, as Brian mentions below it's strange that you > can't compile the package (how?) with the file present. > I'd guess that this would mean you cannot (easily) install any > CRAN packages that use C++ ? > I think this will preclude you from using very fine R extensions! My g++ compiler can't handle the -lgfortran switch, while gcc can. I think it is the fault of my Linux distribution (http://nixos.org), but it was an easier solution to use gcc instead of g++ than fixing g++. This probably means that I can't compile any R packages using C++ and fortran at the same time. I will investigate further in this error. This was the error: g++ -shared -L/usr/local/lib -o Matrix.so CHMfactor.o Csparse.o TMatrix_as.o Tsparse.o init.o Mutils.o chm_common.o cs.o cs_utils.o dense.o dgCMa trix.o dgTMatrix.o dgeMatrix.o dpoMatrix.o dppMatrix.o dsCMatrix.o dsyMatrix.o dspMatrix.o dtCMatrix.o dtTMatrix.o dtrMatrix.o dtpMatrix.o factor izations.o ldense.o lgCMatrix.o sparseQR.o abIndex.o CHOLMOD.a COLAMD.a AMD.a -L/tmp/nix-build-l8rd1zk5f2fslzm7w1zygwz376br9nlw-r-lang.drv-0/R-2. 12.0/lib -lRlapack -L/tmp/nix-build-l8rd1zk5f2fslzm7w1zygwz376br9nlw-r-lang.drv-0/R-2.12.0/lib -lRblas -lgfortran -lm /nix/store/bwwd0qz5ar7afhxdb26bjglql86hcw6b-binutils-2.20/bin/ld: cannot find -lgfortran collect2: ld returned 1 exit status Best regards, Ambrus Kaposi __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
Re: [Rd] package matrix dummy.cpp
On Mon, 29 Nov 2010, Ambrus Kaposi wrote: Thank you for the help. yes. Though, as Brian mentions below it's strange that you can't compile the package (how?) with the file present. I'd guess that this would mean you cannot (easily) install any CRAN packages that use C++ ? I think this will preclude you from using very fine R extensions! My g++ compiler can't handle the -lgfortran switch, while gcc can. I think it is the fault of my Linux distribution (http://nixos.org), but it was an easier solution to use gcc instead of g++ than fixing g++. This probably means that I can't compile any R packages using C++ and fortran at the same time. I will investigate further in this error. Yes, there is no guarantee that you can mix any two languages except C and Fortran. But this is not the way a Linux system is usually set up, and you may be able to resolve it by including the path to libgfortran in LD_LIBRARY_PATH, or editing FLIBS in R_HOME/etc/Makeconf to be something like "-L /path/to/gfortran -rpath=/path/to/gfortran -lgfortran" This was the error: g++ -shared -L/usr/local/lib -o Matrix.so CHMfactor.o Csparse.o TMatrix_as.o Tsparse.o init.o Mutils.o chm_common.o cs.o cs_utils.o dense.o dgCMa trix.o dgTMatrix.o dgeMatrix.o dpoMatrix.o dppMatrix.o dsCMatrix.o dsyMatrix.o dspMatrix.o dtCMatrix.o dtTMatrix.o dtrMatrix.o dtpMatrix.o factor izations.o ldense.o lgCMatrix.o sparseQR.o abIndex.o CHOLMOD.a COLAMD.a AMD.a -L/tmp/nix-build-l8rd1zk5f2fslzm7w1zygwz376br9nlw-r-lang.drv-0/R-2. 12.0/lib -lRlapack -L/tmp/nix-build-l8rd1zk5f2fslzm7w1zygwz376br9nlw-r-lang.drv-0/R-2.12.0/lib -lRblas -lgfortran -lm /nix/store/bwwd0qz5ar7afhxdb26bjglql86hcw6b-binutils-2.20/bin/ld: cannot find -lgfortran collect2: ld returned 1 exit status Best regards, Ambrus Kaposi -- Brian D. Ripley, rip...@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 272866 (PA) Oxford OX1 3TG, UKFax: +44 1865 272595__ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel