[R] RS-MySQL.h:32:19: fatal error: mysql.h: No such file or directory

sagarnikam123 sagarnikam123 at gmail.com
Sat Oct 13 05:07:24 CEST 2012


i m installing RMySQL under windows -7 64bit,
i have wamp server(which has  mysql5.5.16)
i have given MYSQL_HOME path in environment variable as
MYSQL_HOME=C:\wamp\bin\mysql\mysql5.5.16\bin  ,
& also create Renviron.site file in   C:\Program Files\R\R-2.15.0\etc  
giving MYSQL_HOME=C:/wamp/bin/mysql/mysql5.5.16/bin as path
i install c connector "MySQL Connector C 6.0.2" version  also,  which has
mysql.h file


Question:-
In which folder should I include mysql.h file ?
i dont know how to put mysql.h  in RMySQL_0.9-3.tar.gz f, if yes how can i
do it ?


> install.packages("RMySQL",type="source")
Installing package(s) into ‘C:/Users/trendwise/Documents/R/win-library/2.15’
(as ‘lib’ is unspecified)
trying URL 'http://ftp.iitm.ac.in/cran/src/contrib/RMySQL_0.9-3.tar.gz'
Content type 'application/x-gzip' length 165363 bytes (161 Kb)
opened URL
downloaded 161 Kb

* installing *source* package 'RMySQL' ...
** package 'RMySQL' successfully unpacked and MD5 sums checked
checking for $MYSQL_HOME... C:\wamp\bin\mysql\mysql5.5.16\bin
cygwin warning:
  MS-DOS style path detected: C:\wamp\bin\mysql\mysql5.5.16\bin
  Preferred POSIX equivalent is: /cygdrive/c/wamp/bin/mysql/mysql5.5.16/bin
  CYGWIN environment variable option "nodosfilewarning" turns off this
warning.
  Consult the user's guide for more details about POSIX paths:
    http://cygwin.com/cygwin-ug-net/using.html#using-pathnames
** libs
Warning: this package has a non-empty 'configure.win' file,
so building only the main architecture

cygwin warning:
  MS-DOS style path detected: C:/PROGRA~1/R/R-215~1.0/etc/x64/Makeconf
  Preferred POSIX equivalent is:
/cygdrive/c/PROGRA~1/R/R-215~1.0/etc/x64/Makeconf
  CYGWIN environment variable option "nodosfilewarning" turns off this
warning.
  Consult the user's guide for more details about POSIX paths:
    http://cygwin.com/cygwin-ug-net/using.html#using-pathnames
gcc -m64 -I"C:/PROGRA~1/R/R-215~1.0/include" -DNDEBUG
-I"C:\wamp\bin\mysql\mysql5.5.16\bin"/include   
-I"d:/RCompile/CRANpkg/extralibs64/local/include"     -O2 -Wall  -std=gnu99
-mtune=core2 -c RS-DBI.c -o RS-DBI.o
RS-DBI.c: In function 'RS_na_set':
RS-DBI.c:1219:11: warning: variable 'c' set but not used
[-Wunused-but-set-variable]
gcc -m64 -I"C:/PROGRA~1/R/R-215~1.0/include" -DNDEBUG
-I"C:\wamp\bin\mysql\mysql5.5.16\bin"/include   
-I"d:/RCompile/CRANpkg/extralibs64/local/include"     -O2 -Wall  -std=gnu99
-mtune=core2 -c RS-MySQL.c -o RS-MySQL.o
In file included from RS-MySQL.c:22:0:
RS-MySQL.h:32:19: fatal error: mysql.h: No such file or directory
compilation terminated.
make: *** [RS-MySQL.o] Error 1
ERROR: compilation failed for package 'RMySQL'
* removing 'C:/Users/trendwise/Documents/R/win-library/2.15/RMySQL'
* restoring previous
'C:/Users/trendwise/Documents/R/win-library/2.15/RMySQL'
Warning in install.packages :
  running command 'C:/PROGRA~1/R/R-215~1.0/bin/x64/R CMD INSTALL -l
"C:/Users/trendwise/Documents/R/win-library/2.15"  
C:\Users\TRENDW~1\AppData\Local\Temp\RtmpshWgve/downloaded_packages/RMySQL_0.9-3.tar.gz'
had status 1
Warning in install.packages :
 installation of package ‘RMySQL’ had non-zero exit status






-----
Sagar Nikam 
B.Pharm, M.Sc(Bioinformatics)
Software Engineer (Data Research Analyst )
Trendwise Analytics,Bangalore 
India
--
View this message in context: http://r.789695.n4.nabble.com/RS-MySQL-h-32-19-fatal-error-mysql-h-No-such-file-or-directory-tp4646060.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list