[R] Installing RMySQL on Debian

Sarah Goslee sarah.goslee at gmail.com
Thu Jul 10 21:58:38 CEST 2014


Hi,

On Thu, Jul 10, 2014 at 3:34 PM, Federico Razzoli <santec at riseup.net> wrote:
> Hello. I am trying to install RMySQL. My Os is Debian and I have MariaDB
> installed from the tar package (not deb). After downloading RMySQL, I ran
> the following commands, and I see DONE. Hoewever, I don't think that the
> package is installed, because the dbConnect() function cannot be found.
> Probably I'm not passing R the correct paths, but then what paths should I
> pass?

Just to check, are you loading the package using

library(RMySQL)

before trying to use it?

If so, is it giving you any errors?

Sarah

>
>
> root at this:/tmp# export PKG_CPPFLAGS="-I/usr/local/mysql/include/mysql"
> root at this:/tmp# export PKG_LIBS="-L/usr/local/mysql/lib -lmysqlclient"
> root at this:/tmp# R CMD INSTALL /tmp/RMySQL_0.9-3.tar.gz
> * installing to library ‘/usr/local/lib/R/site-library’
> * installing *source* package ‘RMySQL’ ...
> ** package ‘RMySQL’ successfully unpacked and MD5 sums checked
> checking for gcc... gcc
> checking for C compiler default output file name... a.out
> checking whether the C compiler works... yes
> checking whether we are cross compiling... no
> checking for suffix of executables...
> checking for suffix of object files... o
> checking whether we are using the GNU C compiler... yes
> checking whether gcc accepts -g... yes
> checking for gcc option to accept ANSI C... none needed
> checking how to run the C preprocessor... gcc -E
> checking for compress in -lz... yes
> checking for getopt_long in -lc... yes
> checking for mysql_init in -lmysqlclient... no
> checking for egrep... grep -E
> checking for ANSI C header files... yes
> checking for sys/types.h... yes
> checking for sys/stat.h... yes
> checking for stdlib.h... yes
> checking for string.h... yes
> checking for memory.h... yes
> checking for strings.h... yes
> checking for inttypes.h... yes
> checking for stdint.h... yes
> checking for unistd.h... yes
> checking mysql.h usability... no
> checking mysql.h presence... no
> checking for mysql.h... no
> configure: creating ./config.status
> config.status: creating src/Makevars
> ** libs
> gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG
> -I/usr/local/mysql/include/mysql     -fpic  -O2 -pipe -g  -c RS-DBI.c -o
> RS-DBI.o
> gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG
> -I/usr/local/mysql/include/mysql     -fpic  -O2 -pipe -g  -c RS-MySQL.c -o
> RS-MySQL.o
> gcc -std=gnu99 -shared -o RMySQL.so RS-DBI.o RS-MySQL.o
> -L/usr/local/mysql/lib -lmysqlclient -lz -L/usr/lib/R/lib -lR
> installing to /usr/local/lib/R/site-library/RMySQL/libs
> ** R
> ** inst
> ** preparing package for lazy loading
> Creating a generic function for ‘format’ from package ‘base’ in package
> ‘RMySQL’
> Creating a generic function for ‘print’ from package ‘base’ in package
> ‘RMySQL’
> ** help
> *** installing help indices
> ** building package indices
> ** installing vignettes
> ** testing if installed package can be loaded
>
> * DONE (RMySQL)
>
>
> Thank you in advance
> Federico
>


-- 
Sarah Goslee
http://www.functionaldiversity.org



More information about the R-help mailing list