mirror of
https://github.com/mdbtools/mdbtools.git
synced 2026-02-27 06:12:43 +08:00
Don't distribute mdbprivate.h and mdbodbc.h
mdbprivate is.... private. mdbodbc.h has no reason to be public: People who want to use the plugin should use the public odbc.h headers. And having this private will permit hdbc cleanup.
This commit is contained in:
@@ -1,8 +1,7 @@
|
||||
include_HEADERS = connectparams.h # Should we really install that file?
|
||||
noinst_PROGRAMS = unittest
|
||||
noinst_PROGRAMS = unittest
|
||||
lib_LTLIBRARIES = libmdbodbc.la
|
||||
AM_CPPFLAGS = -I$(top_srcdir)/include $(GLIB_CFLAGS) $(ODBC_CFLAGS)
|
||||
libmdbodbc_la_SOURCES= odbc.c connectparams.c
|
||||
libmdbodbc_la_SOURCES= odbc.c connectparams.c mdbodbc.h connectparams.h
|
||||
libmdbodbc_la_LIBADD= ../libmdb/libmdb.la ../sql/libmdbsql.la
|
||||
libmdbodbc_la_LDFLAGS = -version-info 1:1:0 -export-symbols-regex '^(SQL|ODBCINST)'
|
||||
LIBS = @LEXLIB@ $(GLIB_LIBS) $(ODBC_LIBS)
|
||||
|
||||
68
src/odbc/mdbodbc.h
Normal file
68
src/odbc/mdbodbc.h
Normal file
@@ -0,0 +1,68 @@
|
||||
/* MDB Tools - A library for reading MS Access database file
|
||||
* Copyright (C) 2000 Brian Bruns
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Library General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Library General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Library General Public
|
||||
* License along with this library; if not, write to the
|
||||
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
* Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
#ifndef _mdbodbc_h_
|
||||
#define _mdbodbc_h_
|
||||
|
||||
#include <mdbtools.h>
|
||||
#include <mdbsql.h>
|
||||
|
||||
#include <sql.h>
|
||||
#include <sqlext.h>
|
||||
#if defined(UNIXODBC)
|
||||
# include <odbcinst.h>
|
||||
#elif defined(IODBC)
|
||||
# include <iodbcinst.h>
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
struct _henv {
|
||||
MdbSQL *sql;
|
||||
};
|
||||
struct _hdbc {
|
||||
struct _henv *henv;
|
||||
};
|
||||
struct _hstmt {
|
||||
struct _hdbc *hdbc;
|
||||
/* reminder to self: the following is here for testing purposes.
|
||||
* please make dynamic before checking in
|
||||
*/
|
||||
char query[4096];
|
||||
struct _sql_bind_info *bind_head;
|
||||
int rows_affected;
|
||||
int icol; /* SQLGetData: last column */
|
||||
int pos; /* SQLGetData: last position (truncated result) */
|
||||
};
|
||||
|
||||
struct _sql_bind_info {
|
||||
int column_number;
|
||||
int column_bindtype;
|
||||
int column_bindlen;
|
||||
int *column_lenbind;
|
||||
char *varaddr;
|
||||
struct _sql_bind_info *next;
|
||||
};
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
@@ -28,12 +28,9 @@
|
||||
|
||||
#include <sql.h>
|
||||
#include <sqlext.h>
|
||||
|
||||
#include <mdbodbc.h>
|
||||
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
|
||||
#include "mdbodbc.h"
|
||||
#include "connectparams.h"
|
||||
|
||||
//#define TRACE(x) fprintf(stderr,"Function %s\n", x);
|
||||
|
||||
Reference in New Issue
Block a user