Commit Graph

38 Commits

Author SHA1 Message Date
Evan Miller
f99c5539e7 Add --version option to the CLI tools
See #232
2021-01-19 20:37:25 -05:00
Evan Miller
0e3a627ee6
Make command-line arguments locale-aware (#237)
GLib will automatically convert command line options to UTF-8 provided that setlocale(LC_TYPE, "") is called first, and the argument type is STRING (but not FILENAME). Update the CLI tools to take advantage of this behavior, and likewise implement it in fakeglib.

GLib does not automatically convert non-option arguments (i.e. everything remaining in argv after option processing), so manually call g_locale_to_utf8 on these arguments when they represent table names. This should fix the CLI tools when processing non-ASCII table names in non-UTF-8 locales. Also update fakeglib to implement a fast and loose version of g_locale_to_utf8, and factor out some of the code page => iconv name logic in iconv.c so it can be used in our fake g_locale_to_utf8. This adds a new symbol mdb_iconv_name_from_code_page that is not advertised in the main header file. I did not want to include mdbtools.h from fakeglib.c, but maybe that's not important.
2021-01-14 17:34:50 -05:00
Evan Miller
20842c642a mdb-schema: Exit with code 1 if the requested table is not found 2021-01-12 14:08:25 -05:00
Evan Miller
90ee7bfcb5 Remove references to dmalloc
There are more modern tools for memory debugging, get rid of DMALLOC
crap in the source code.

I've left one reference in backend.c to prevent a merge conflict but
this can be removed later.
2020-08-20 08:59:08 -04:00
Nirgal Vourgère
13e339c1a4 Clarify usage of --no-comments in mdb-schema 2015-01-12 18:17:50 +01:00
Nirgal Vourgère
072f7c6518 Decrease POSIX required level to 1
One can now compile with CFLAGS="-std=c99 -D_POSIX_C_SOURCE=1 -pedantic"

Trade getopt.h function for glib equivalents:
This mean all utilities now have long option names.
Adjust manuals and bash_completion accordingly.

Added missing manual and bash_completion for mdb-import.
2014-12-29 13:12:23 +01:00
Nirgal Vourgère
7841d30d43 Revert use of config.h
Revert
7162e8db74
088493d499

And drop AC_CONFIG_HEADERS so that config goes though the command line.
No longer generating config.h, update .gitignore
2013-07-15 02:42:12 +02:00
Nirgal Vourgère
7162e8db74 Include config.h in all .c files
Need to be the first file since it may define large files support
and other options.
2013-07-04 10:53:13 +02:00
Nirgal Vourgère
f6cd70494c Automatically init/exit libmdb code
mdb_init() and mdb_exit() are now deprecated.
2012-07-22 02:29:04 +02:00
Nirgal Vourgre
dd0f4c3819 Patch docs.diff from Nirgal 2011-08-28 19:53:29 -04:00
Nirgal Vourgre
aee657f603 Patch warnings.diff from Nirgal 2011-08-28 19:48:44 -04:00
Nirgal Vourgre
8ef50c444e Patch nosanitize.diff form Nirgal 2011-08-28 18:56:03 -04:00
Brian Bruns
d794c6e2a1 patch default_values from Nirgal Vourgère 2011-02-16 18:59:25 -05:00
Brian Bruns
39277312d4 patch 'schema2' from Nirgal Vourgère 2011-02-16 18:58:22 -05:00
Brian Bruns
0eea4c148f patch schema-indexes from Nirgal Vourgère 2011-02-16 18:57:05 -05:00
Brian Bruns
4f73e1b295 patch from Terry Brown <terry_n_brown at yahoo.com> to not sanitize the schema in mdb-schema 2010-08-03 20:04:29 -04:00
Brian Bruns
87af69a15e Debian patch 170-sequences from Nirgal Vourgère 2010-06-20 16:30:47 -04:00
Brian Bruns
30e5a6f4bb Debian patch 150-backend-quote from Nirgal Vourgère 2010-06-20 16:27:42 -04:00
whydoubt
e6c4050c74 Handle 'file not found' case 2005-06-17 02:39:45 +00:00
whydoubt
dd99bd0a68 Use 'Flags' field in MSysObjects to recognize system tables 2004-09-16 04:00:39 +00:00
whydoubt
e121a82946 Lots more gcc warnings fixes 2004-07-09 12:47:04 +00:00
whydoubt
7e4a7bc113 Fix a memory leak 2004-06-23 03:03:06 +00:00
whydoubt
c99ce9815d Fix a bug and a typo in mdb-schema 2004-06-18 05:13:16 +00:00
whydoubt
402e6be097 Major revisions to 'backend' code 2004-06-11 13:56:39 +00:00
whydoubt
a5afa5c9e4 better utilize glib functions, fix memory leaks 2004-05-30 07:19:22 +00:00
whydoubt
0baed7b268 Use mdb_close to match mdb_open instead of mdb_free_handle 2004-04-14 05:58:52 +00:00
brianb
4953cee0af signature change to mdb_open() 2004-04-13 20:06:04 +00:00
brianb
df8bf09aa7 patch #856724/856342 and odds and ends. 2004-02-09 20:38:45 +00:00
brianb
8c68edba1f Basic checks on file to ensure it's an mdb database. bug # 587739 2004-01-10 21:46:14 +00:00
brianb
278cf8ef42 fix compiler warnings in libmdb/ util/ sql/ 2004-01-10 01:52:56 +00:00
brianb
11b43644dc patches 00-14 from David Mansfield 2004-01-06 00:42:07 +00:00
brianb
75216d7a90 index work
dmalloc headers
mem leak fixes
start on i18n
2003-01-28 23:51:06 +00:00
brianb
092e2b79af query planner stuff
some gcc -Wall fixes
added suport for _ in identifier names in SQL
gmdb2 manual additions
2003-01-20 16:04:24 +00:00
brianb
3c0d61076d lots more gmdb2 stuff, converted table export to glade, added schema export, toolbars, properties window to glade, et al. 2002-12-30 16:38:47 +00:00
brianb
16735470a7 port of gmdb to gnome2. lots o other stuff 2002-12-27 15:09:02 +00:00
trewitt
5346c79e8c Add exit(0) to the end of all programs. 2002-08-12 17:37:04 +00:00
brianb
9b8285d937 change catalogentry to GPtrArray, documentation fixes, add ifdef wrapper to mdbsql.h 2002-03-27 13:00:00 +00:00
brianb
12d830dc62 restructing...automake now used sql stuff working 2001-04-11 23:33:19 +00:00