ports/databases/recutils/files/patch-utils_mdb2rec.c
Alexey Dokuchaev 83af15b7f9 - Unbreak the build with MDB support after r561652 and enable it
by default to help catch API breakages in the future
- Enable CURL option because it is very common dependency anyway
- Add an option to build the recutils bash(1) builtins
2021-03-06 06:48:36 +00:00

30 lines
747 B
C

--- utils/mdb2rec.c.orig 2019-01-03 08:47:43 UTC
+++ utils/mdb2rec.c
@@ -33,7 +33,7 @@
#include <gettext.h>
#define _(str) gettext (str)
-#include <glib.h>
+#define HAVE_GLIB
#include <mdbtools.h>
#include <rec.h>
@@ -472,16 +472,14 @@ process_mdb (void)
if (!db)
recutl_out_of_memory ();
- /* Initialize libmdb and open the input file. */
- mdb_init();
- mdb_set_date_fmt ("%Y-%m-%dT%H:%M:%S%z"); /* ISO 8601 */
-
mdb = mdb_open (mdb2rec_mdb_file, MDB_NOFLAGS);
if (!mdb)
{
recutl_fatal (_("could not open file %s\n"),
mdb2rec_mdb_file);
}
+
+ mdb_set_date_fmt (mdb, "%Y-%m-%dT%H:%M:%S%z"); /* ISO 8601 */
/* Read the catalog. */
if (!mdb_read_catalog (mdb, MDB_TABLE))