Re: complie error in current trunk

2012-12-21 Thread Herbert Thoma
Am 21.12.2012 10:43, schrieb Geert Janssens:
> On 21-12-12 07:45, Mike Alexander wrote:
>> --On December 20, 2012 5:00:56 PM +0100 Geert Janssens 
>>  wrote:
>>
>>> This may be a side effect of my efforts to make GnuCash build and run
>>> with guile 2. I'm not sure why I didn't get these warnings on my
>>> system.
>>>
>>> Anyway, just to test, can you alter src/base-typemaps.i as follows:
>>> on line 19, there is
>>> %typemap (out) char * {
>>>
>>> Can you just below this line insert this:
>>>$result = SCM_UNSPECIFIED;
>>>
>>> And then compile again ?
>>
>> I'll have to admit that I got this error too and didn't fix or report it.  I 
>> just turned off the warning so I could finish what else I was doing and then 
>> forgot about it.
>>
>> The error is probably dependent on exactly what compiler you are using since 
>> it depends on the flow analysis done during optimization.  In my case I was 
>> using gcc 4.6.3 when I got the error.
>>
>> I tried the fix you suggest above and it seems to solve, or at least avoid, 
>> the problem.
>>
>>  Mike
>>
> Thanks for the feedback. I have committed the change.
> 
> FWIW, my compiler is gcc 4.7.2 on Fedora 17. I'm compiling with -Werror but 
> it doesn't produce the warning reported. It think it's a valid warning in 
> this case though.

I confirm that the fix fixes the error on my system as well.

Thank you!

 Herbert.

> Geert
> ___
> gnucash-devel mailing list
> gnucash-devel@gnucash.org
> https://lists.gnucash.org/mailman/listinfo/gnucash-devel
> 
___
gnucash-devel mailing list
gnucash-devel@gnucash.org
https://lists.gnucash.org/mailman/listinfo/gnucash-devel


Re: complie error in current trunk

2012-12-21 Thread Geert Janssens

On 21-12-12 07:45, Mike Alexander wrote:
--On December 20, 2012 5:00:56 PM +0100 Geert Janssens 
 wrote:



This may be a side effect of my efforts to make GnuCash build and run
with guile 2. I'm not sure why I didn't get these warnings on my
system.

Anyway, just to test, can you alter src/base-typemaps.i as follows:
on line 19, there is
%typemap (out) char * {

Can you just below this line insert this:
   $result = SCM_UNSPECIFIED;

And then compile again ?


I'll have to admit that I got this error too and didn't fix or report 
it.  I just turned off the warning so I could finish what else I was 
doing and then forgot about it.


The error is probably dependent on exactly what compiler you are using 
since it depends on the flow analysis done during optimization.  In my 
case I was using gcc 4.6.3 when I got the error.


I tried the fix you suggest above and it seems to solve, or at least 
avoid, the problem.


 Mike


Thanks for the feedback. I have committed the change.

FWIW, my compiler is gcc 4.7.2 on Fedora 17. I'm compiling with -Werror 
but it doesn't produce the warning reported. It think it's a valid 
warning in this case though.


Geert
___
gnucash-devel mailing list
gnucash-devel@gnucash.org
https://lists.gnucash.org/mailman/listinfo/gnucash-devel


Re: complie error in current trunk

2012-12-20 Thread Mike Alexander
--On December 20, 2012 5:00:56 PM +0100 Geert Janssens 
 wrote:



This may be a side effect of my efforts to make GnuCash build and run
with guile 2. I'm not sure why I didn't get these warnings on my
system.

Anyway, just to test, can you alter src/base-typemaps.i as follows:
on line 19, there is
%typemap (out) char * {

Can you just below this line insert this:
   $result = SCM_UNSPECIFIED;

And then compile again ?


I'll have to admit that I got this error too and didn't fix or report 
it.  I just turned off the warning so I could finish what else I was 
doing and then forgot about it.


The error is probably dependent on exactly what compiler you are using 
since it depends on the flow analysis done during optimization.  In my 
case I was using gcc 4.6.3 when I got the error.


I tried the fix you suggest above and it seems to solve, or at least 
avoid, the problem.


 Mike

___
gnucash-devel mailing list
gnucash-devel@gnucash.org
https://lists.gnucash.org/mailman/listinfo/gnucash-devel


Re: complie error in current trunk

2012-12-20 Thread Geert Janssens

Hi Herbert,

This may be a side effect of my efforts to make GnuCash build and run 
with guile 2. I'm not sure why I didn't get these warnings on my system.


Anyway, just to test, can you alter src/base-typemaps.i as follows:
on line 19, there is
%typemap (out) char * {

Can you just below this line insert this:
  $result = SCM_UNSPECIFIED;

And then compile again ?

Geert

On 20-12-12 12:06, Herbert Thoma wrote:

Hi!

I get the following errors:
(If I run configure with --disable-error-on-warning the build
completes successfully.)

cc1: warnings being treated as errors
swig-unittest-support-guile.c: In function 
‘_wrap_TestErrorStruct_log_domain_get’:
swig-unittest-support-guile.c:1367:7: error: ‘gswig_result’ may be used 
uninitialized in this function
swig-unittest-support-guile.c: In function ‘_wrap_TestErrorStruct_msg_get’:
swig-unittest-support-guile.c:1430:7: error: ‘gswig_result’ may be used 
uninitialized in this function
make[3]: *** [libtest_core_guile_la-swig-unittest-support-guile.lo] Fehler 1
make[3]: Leaving directory 
`/home/tma/gnucash/gnucash_cvs/gnucash_work/src/test-core'
make[2]: *** [all-recursive] Fehler 1
make[2]: Leaving directory `/home/tma/gnucash/gnucash_cvs/gnucash_work/src'
make[1]: *** [all-recursive] Fehler 1
make[1]: Leaving directory `/home/tma/gnucash/gnucash_cvs/gnucash_work'
make: *** [all] Fehler 2


cc1: warnings being treated as errors
swig-engine.c: In function ‘_wrap_gncTaxIncludedTypeToString’:
swig-engine.c:32596:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gncAmountTypeToString’:
swig-engine.c:32541:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gncEntryPaymentTypeToString’:
swig-engine.c:25533:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gncEntryDiscountHowToString’:
swig-engine.c:25478:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_num_dbg_to_string’:
swig-engine.c:17125:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_numeric_to_string’:
swig-engine.c:17099:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_numeric_errorCode_to_string’:
swig-engine.c:17016:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_print_date’:
swig-engine.c:13247:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccAccountGetTypeStr’:
swig-engine.c:6643:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccAccountTypeEnumAsString’:
swig-engine.c:6563:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_get_account_separator_string’:
swig-engine.c:4333:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_build_book_path’:
swig-engine.c:17726:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_hook_create’:
swig-engine.c:20874:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccSplitGetMemo’:
swig-engine.c:2313:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccSplitGetAction’:
swig-engine.c:2368:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccSplitGetType’:
swig-engine.c:2888:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccSplitGetCorrAccountFullName’:
swig-engine.c:3104:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccSplitGetCorrAccountName’:
swig-engine.c:3132:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccSplitGetCorrAccountCode’:
swig-engine.c:3160:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_account_name_violations_errmsg’:
swig-engine.c:4477:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccAccountGetName’:
swig-engine.c:5030:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccAccountGetCode’:
swig-engine.c:5058:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccAccountGetDescription’:
swig-engine.c:5086:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccAccountGetColor’:
swig-engine.c:5114:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xacc

Re: complie error in current trunk

2012-12-20 Thread Herbert Thoma
Am 20.12.2012 16:01, schrieb John Ralls:
> 
> On Dec 20, 2012, at 3:06 AM, Herbert Thoma  
> wrote:
> 
>> Hi!
>>
>> I get the following errors:
>> (If I run configure with --disable-error-on-warning the build
>> completes successfully.)
>>
>> cc1: warnings being treated as errors
>> swig-unittest-support-guile.c: In function 
>> ‘_wrap_TestErrorStruct_log_domain_get’:
>> swig-unittest-support-guile.c:1367:7: error: ‘gswig_result’ may be used 
>> uninitialized in this function
>> swig-unittest-support-guile.c: In function ‘_wrap_TestErrorStruct_msg_get’:
>> swig-unittest-support-guile.c:1430:7: error: ‘gswig_result’ may be used 
>> uninitialized in this function
>>
>>
>> cc1: warnings being treated as errors
> 
> [SNIP]
> 
>>
>> openSUSE 11.4 (x86_64)
>> SWIG Version 1.3.40
>> Guile 1.8.7
>> gcc (SUSE Linux) 4.5.1 20101208 [gcc-4_5-branch revision 167585]
> 
> Did you do a make maintainer-clean, autogen, and configure? That usually 
> fixes swig problems.

I used a fresh, clean checkout from SVN, so no leftovers from previous 
revisions should spoil the build.

I noticed that my version of swig is 1.3.40 which was released in 2009. The 
current
version seems to be 2.0.9. However, there is no native package of swig-2.0 
available
for openSUSE 11.4 (which was released early 2011). Which version of swig do yo 
use?

 Herbert.

> Regards,
> John Ralls
> 
> 
___
gnucash-devel mailing list
gnucash-devel@gnucash.org
https://lists.gnucash.org/mailman/listinfo/gnucash-devel


Re: complie error in current trunk

2012-12-20 Thread John Ralls

On Dec 20, 2012, at 3:06 AM, Herbert Thoma  
wrote:

> Hi!
> 
> I get the following errors:
> (If I run configure with --disable-error-on-warning the build
> completes successfully.)
> 
> cc1: warnings being treated as errors
> swig-unittest-support-guile.c: In function 
> ‘_wrap_TestErrorStruct_log_domain_get’:
> swig-unittest-support-guile.c:1367:7: error: ‘gswig_result’ may be used 
> uninitialized in this function
> swig-unittest-support-guile.c: In function ‘_wrap_TestErrorStruct_msg_get’:
> swig-unittest-support-guile.c:1430:7: error: ‘gswig_result’ may be used 
> uninitialized in this function
> make[3]: *** [libtest_core_guile_la-swig-unittest-support-guile.lo] Fehler 1
> make[3]: Leaving directory 
> `/home/tma/gnucash/gnucash_cvs/gnucash_work/src/test-core'
> make[2]: *** [all-recursive] Fehler 1
> make[2]: Leaving directory `/home/tma/gnucash/gnucash_cvs/gnucash_work/src'
> make[1]: *** [all-recursive] Fehler 1
> make[1]: Leaving directory `/home/tma/gnucash/gnucash_cvs/gnucash_work'
> make: *** [all] Fehler 2
> 
> 
> cc1: warnings being treated as errors

[SNIP]

> 
> openSUSE 11.4 (x86_64)
> SWIG Version 1.3.40
> Guile 1.8.7
> gcc (SUSE Linux) 4.5.1 20101208 [gcc-4_5-branch revision 167585]

Did you do a make maintainer-clean, autogen, and configure? That usually fixes 
swig problems.

Regards,
John Ralls


___
gnucash-devel mailing list
gnucash-devel@gnucash.org
https://lists.gnucash.org/mailman/listinfo/gnucash-devel


complie error in current trunk

2012-12-20 Thread Herbert Thoma
Hi!

I get the following errors:
(If I run configure with --disable-error-on-warning the build
completes successfully.)

cc1: warnings being treated as errors
swig-unittest-support-guile.c: In function 
‘_wrap_TestErrorStruct_log_domain_get’:
swig-unittest-support-guile.c:1367:7: error: ‘gswig_result’ may be used 
uninitialized in this function
swig-unittest-support-guile.c: In function ‘_wrap_TestErrorStruct_msg_get’:
swig-unittest-support-guile.c:1430:7: error: ‘gswig_result’ may be used 
uninitialized in this function
make[3]: *** [libtest_core_guile_la-swig-unittest-support-guile.lo] Fehler 1
make[3]: Leaving directory 
`/home/tma/gnucash/gnucash_cvs/gnucash_work/src/test-core'
make[2]: *** [all-recursive] Fehler 1
make[2]: Leaving directory `/home/tma/gnucash/gnucash_cvs/gnucash_work/src'
make[1]: *** [all-recursive] Fehler 1
make[1]: Leaving directory `/home/tma/gnucash/gnucash_cvs/gnucash_work'
make: *** [all] Fehler 2


cc1: warnings being treated as errors
swig-engine.c: In function ‘_wrap_gncTaxIncludedTypeToString’:
swig-engine.c:32596:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gncAmountTypeToString’:
swig-engine.c:32541:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gncEntryPaymentTypeToString’:
swig-engine.c:25533:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gncEntryDiscountHowToString’:
swig-engine.c:25478:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_num_dbg_to_string’:
swig-engine.c:17125:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_numeric_to_string’:
swig-engine.c:17099:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_numeric_errorCode_to_string’:
swig-engine.c:17016:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_print_date’:
swig-engine.c:13247:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccAccountGetTypeStr’:
swig-engine.c:6643:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccAccountTypeEnumAsString’:
swig-engine.c:6563:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_get_account_separator_string’:
swig-engine.c:4333:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_build_book_path’:
swig-engine.c:17726:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_hook_create’:
swig-engine.c:20874:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccSplitGetMemo’:
swig-engine.c:2313:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccSplitGetAction’:
swig-engine.c:2368:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccSplitGetType’:
swig-engine.c:2888:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccSplitGetCorrAccountFullName’:
swig-engine.c:3104:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccSplitGetCorrAccountName’:
swig-engine.c:3132:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccSplitGetCorrAccountCode’:
swig-engine.c:3160:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_gnc_account_name_violations_errmsg’:
swig-engine.c:4477:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccAccountGetName’:
swig-engine.c:5030:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccAccountGetCode’:
swig-engine.c:5058:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccAccountGetDescription’:
swig-engine.c:5086:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccAccountGetColor’:
swig-engine.c:5114:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccAccountGetFilter’:
swig-engine.c:5142:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccAccountGetSortOrder’:
swig-engine.c:5170:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In function ‘_wrap_xaccAccountGetNotes’:
swig-engine.c:5198:7: error: ‘gswig_result’ may be used uninitialized in this 
function
swig-engine.c: In fun