qemacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemacs-devel] [PATCH] Haiku gcc5 fixes (was: Re: [PATCH] C89)


From: François Revol
Subject: [Qemacs-devel] [PATCH] Haiku gcc5 fixes (was: Re: [PATCH] C89)
Date: Tue, 28 Mar 2017 13:48:34 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0

On 28/03/2017 13:37, François Revol wrote:
On 28/03/2017 13:16, François Revol wrote:
On 28/03/2017 12:29, François Revol wrote:
Anyway, I'll just switch the recipe to gcc5.


But now I need to fix the gcc5 warnings in the Haiku code :D

For some reason GCC5 doesn't like qe_free() when used with a
pointer-to-void in C++ code:

In file included from haiku.cpp:24:0:
haiku.cpp: In function 'void haiku_close(QEditScreen*)':
qe.h:100:41: error: 'void*' is not a pointer-to-object type
 #define qe_free(pp)    do { typeof(**(pp)) **__ = (pp); (free)(*__);
*__ = NULL; } while (0)


Obviously it tries to create an object of type void. I'm surprised it
actually works in the C code...

There you go, this fixes the Haiku build with gcc5:
- force type in qe_free,
- link to C++ runtime as it's not automatic anymore.


François.

Attachment: qemacs-haiku-gcc5-fixes-20170329.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]