Skip to content

Commit

Permalink
New release that fixes building on WIN64, plus manual page edits to s…
Browse files Browse the repository at this point in the history
…atisfy new parser.

git-svn-id: https://hedgehog.fhcrc.org/compbio/r-dbi@451 dcde13d4-9b1b-0410-ac9e-ef07de68c835
  • Loading branch information
j.horner committed Jul 13, 2010
1 parent 4e873c1 commit 294263a
Show file tree
Hide file tree
Showing 11 changed files with 24 additions and 23 deletions.
6 changes: 3 additions & 3 deletions DESCRIPTION
@@ -1,9 +1,9 @@
Package: RMySQL
Version: 0.7-4
Date: 2009-04-07
Version: 0.7-5
Date: 2010-07-13
Title: R interface to the MySQL database
Author: David A. James and Saikat DebRoy
Maintainer: Jeffrey Horner <jeff.horner@vanderbilt.edu>
Maintainer: Jeffrey Horner <jeffrey.horner@gmail.com>
Description: Database interface and MySQL driver for R.
This version complies with the database interface
definition as implemented in the package DBI 0.2-2.
Expand Down
11 changes: 7 additions & 4 deletions configure.win
@@ -1,10 +1,8 @@
echo "configure.win:"
echo ""
echo -n "checking for \$MYSQL_HOME... "
if test -z "$MYSQL_HOME" ; then
echo "not found... searching registry..."
echo ""
${R_HOME}/bin${R_ARCH_BIN}/Rscript < inst/FindMySQLhome.R
"${R_HOME}/bin${R_ARCH_BIN}/Rscript" inst/FindMySQLhome.R
echo ""
exit 1
else
Expand All @@ -14,4 +12,9 @@ else
exit 2
fi
fi
echo ""
x86=`"${R_HOME}/bin${R_ARCH_BIN}/Rscript" -e 'cat(.Machine$sizeof.pointer==4)'`
if test $x86 = "TRUE"; then
cp src/Makevars.win32 src/Makevars.win
else
cp src/Makevars.win64 src/Makevars.win
fi
1 change: 0 additions & 1 deletion man/MySQL.Rd
Expand Up @@ -148,7 +148,6 @@ On meta-data:
\code{\link[DBI]{dbGetStatement}}
\code{\link[DBI]{dbHasCompleted}}
\code{\link[DBI]{dbGetRowCount}}
\code{\link[DBI]{dbGetAffectedRows}}
}
\examples{\dontrun{
# create a MySQL instance and create one connection.
Expand Down
2 changes: 0 additions & 2 deletions man/RMySQL-package.Rd
Expand Up @@ -173,7 +173,6 @@ See the documentation at the MySQL Web site
\seealso{
On database managers:

\code{\link[DBI:DBI-package]{DBI}}
\code{\link[DBI]{dbDriver}}
\code{\link[DBI]{dbUnloadDriver}}

Expand Down Expand Up @@ -204,7 +203,6 @@ On meta-data:
\code{\link[DBI]{dbGetStatement}}
\code{\link[DBI]{dbHasCompleted}}
\code{\link[DBI]{dbGetRowCount}}
\code{\link[DBI]{dbGetAffectedRows}}
}
\examples{\dontrun{
# create a MySQL instance and create one connection.
Expand Down
2 changes: 1 addition & 1 deletion man/dbEscapeStrings-methods.Rd
Expand Up @@ -28,7 +28,7 @@
\code{\link[DBI]{dbSendQuery}},
\code{\link[DBI]{dbGetQuery}},
\code{\link[DBI]{fetch}},
\code{\link[DBI]{dbNextResult}},
\code{\link{dbNextResult}},
\code{\link[DBI]{dbCommit}},
\code{\link[DBI]{dbGetInfo}},
\code{\link[DBI]{dbReadTable}}.
Expand Down
4 changes: 2 additions & 2 deletions man/dbReadTable-methods.Rd
Expand Up @@ -68,13 +68,13 @@

\code{header} is a logical indicating whether the first data line
(but see \code{skip}) has a header or not. If missing, it value
is determined following \code{\link[base]{read.table}} convention,
is determined following \code{\link{read.table}} convention,
namely, it is set to TRUE if and only if the first row has one
fewer field that the number of columns.

\code{row.names} is a logical to specify whether the first column
is a set of row names. If missing its default follows the
\code{\link[base]{read.table}} convention.
\code{\link{read.table}} convention.

\code{col.names} a character vector with column names (these names
will be filtered with \code{\link[DBI]{make.db.names}} to
Expand Down
4 changes: 2 additions & 2 deletions man/safe.write.Rd
Expand Up @@ -16,7 +16,7 @@ safe.write(value, file, batch, ...)
\item{\dots}{any other arguments are passed to \code{write.table}.}
}
\details{
The function has a while loop invoking \code{\link[base]{write.table}}
The function has a while loop invoking \code{\link{write.table}}
for subsets of \code{batch} rows of \code{value}. Since this is
a helper function for \code{\link[RMySQL]{mysqlWriteTable}}, it has
hardcoded other arguments to \code{write.table}.
Expand All @@ -26,7 +26,7 @@ safe.write(value, file, batch, ...)
}
\note{No error checking whatsoever is done.}

\seealso{\code{\link[base]{write.table}}}
\seealso{\code{\link{write.table}}}

\examples{\dontrun{
ctr.file <- file("dump.sqloader", "w")
Expand Down
File renamed without changes.
2 changes: 2 additions & 0 deletions src/Makevars.win64
@@ -0,0 +1,2 @@
PKG_CPPFLAGS = -I"${MYSQL_HOME}"/include
PKG_LIBS = "${MYSQL_HOME}"/bin/libmySQL.dll
13 changes: 6 additions & 7 deletions src/RS-DBI.h
Expand Up @@ -31,17 +31,16 @@ extern "C" {

#include "S4R.h"

/* Microsoft Visual C++ uses int _getpid() */
#ifdef MSVC
/* WIN32 uses int _getpid() */
#if defined WIN32
#include <process.h>
#define getpid _getpid
#define pid_t int
/* #define getpid _getpid */
#include <ctype.h>
/* #define pid_t int */
#else
#include <unistd.h>
#endif

pid_t getpid();

/* We now define 4 important data structures:
* RS_DBI_manager, RS_DBI_connection, RS_DBI_resultSet, and
* RS_DBI_fields, corresponding to dbManager, dbConnection,
Expand Down Expand Up @@ -260,7 +259,7 @@ void RS_na_set(void *ptr, Stype type);
int RS_is_na(void *ptr, Stype type);
extern const struct data_types RS_dataTypeTable[];

int isalpha(int c);
/* int isalpha(int c); */

#ifdef __cplusplus
}
Expand Down
2 changes: 1 addition & 1 deletion src/RS-MySQL.h
Expand Up @@ -24,7 +24,7 @@
extern "C" {
#endif

#ifdef WIN32
#if defined WIN32
# include <windows.h>
# undef ERROR
#endif
Expand Down

0 comments on commit 294263a

Please sign in to comment.