[SOLVED] (opensuse) gnc-backend-dbi.c:2105:56: error: 'dbi_data_t' has no member named 'd_datetime'
Frank H. Ellenberger
frank.h.ellenberger at gmail.com
Thu Apr 2 07:23:00 EDT 2015
Am 01.10.2014 um 22:34 schrieb Dimstar / Dominique Leuenberger:
> On Wed, 2014-10-01 at 22:29 +0200, Frank H. Ellenberger wrote:
>> Hi Dominique,
>>
>> Am 01.10.2014 um 21:50 schrieb Dimstar / Dominique Leuenberger:
>>> For reference,
>>>
>>> gnucash built for openSUSE Factory and 13.2 (which comes with libdbi3,
>>> we carry this patch for now:
>>>
>>> Index: gnucash-2.6.3/src/backend/dbi/gnc-backend-dbi.c
>>> ===================================================================
>>> --- gnucash-2.6.3.orig/src/backend/dbi/gnc-backend-dbi.c
>>> +++ gnucash-2.6.3/src/backend/dbi/gnc-backend-dbi.c
>>> @@ -2039,7 +2039,7 @@ row_get_value_at_col_name( GncSqlRow* ro
>>> dbi_result_t *result = (dbi_result_t*)(dbi_row->result);
>>> guint64 row = dbi_result_get_currow (result);
>>> guint idx = dbi_result_get_field_idx (result, col_name) - 1;
>>> - time64 time = result->rows[row]->field_values[idx].d_datetime;
>>> + time64 time =
>>> _dbi_make_datetime(result->rows[row]->field_values[idx].d_datetimex);
>>> (void)g_value_init( value, G_TYPE_INT64 );
>>> g_value_set_int64 (value, time);
>>> }
>>>
>>
>> If we would have different -devel packages, which should report
>> different versions, the patch could be generalized. I assume, the
>> problem will appear in other distros earlier or later, too.
>>
>> What do you think?
>
> It should not matter about parallel installation of the -devel or not:
> configure should simply identify which of the two variants are there and
> 'do the right thing' out of it (I don't think libdbi exports usable
> version info in the headers).
> I'd go with some test compile of one function, if fails do the other..
> then you know which version is there.
>
> IF there is interest in this, I am willing to work on that in the next
> couple days (probably tomorrow afternoon)
>
>
In libdbi commit ac482c2b4e478898d1b78afc62972c78c211d6d9 the function
is changed, And in configure.ac the version is pushed:
dnl set up libtool library versioning
-LIB_CURRENT=2
+LIB_CURRENT=3
LIB_REVISION=0
-LIB_AGE=1
+LIB_AGE=0
resulting in include/dbi/dbi.h:
/* definitions of the libtool library interface versions */
#define LIBDBI_LIB_CURRENT 3
#define LIBDBI_LIB_REVISION 0
#define LIBDBI_LIB_AGE 0
Don't confound it with:
/* definition of the libdbi version */
#define LIBDBI_VERSION ((2 * 10000) + (8 * 100) + (0))
HTH
Frank
More information about the gnucash-devel
mailing list