[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [lmi] fixing "type attributes are honored only at type definition" w
From: |
Greg Chicares |
Subject: |
Re: [lmi] fixing "type attributes are honored only at type definition" warning |
Date: |
Sun, 09 Mar 2008 13:48:08 +0000 |
User-agent: |
Thunderbird 2.0.0.12 (Windows/20080213) |
On 2008-03-07 21:33Z, Vaclav Slavik wrote:
>
> now that wx-2.8.7 is used for MSW builds, can we change forward
> declarations of wx classes to use WXDLLIMPEXP_FWD_CORE instead
> of WXDLLEXPORT? It will fix gcc4's "type attributes are honored
> only at type definition" warning in code using forward declaration
> of wx classes.
Committed 20080309T1213Z, following your exact instructions.
> The change is probably better described by a sed script than a patch:
Yes, good idea. [script snipped]
> Additionally, -Wno-attributes is no longer needed and can be removed from
> workhorse.make
I applied your 'workhorse.make' patch at the same time.
> (assuming there are no forgotten places in wx headers
> themselves that would cause problems in 2.8.7 -- I couldn't test it, I don't
> know how to setup MSW makefiles to use gcc 4.2
It should be as easy as changing a Cygwin mount. Here's what we
use for production (MinGW gcc-3.4.4):
mount -f -s -b "C:/MinGW-20050827" "/MinGW_"
This would use Cygwin's own gcc (with '-mno-cygwin') instead:
mount -f -s -b "C:/cygwin" "/MinGW_"
I actually built lmi that way, and it seems to run, though IIRC
it would use Cygwin's filesystem, which would be a problem for
our end users. This (depending on where you install it):
mount -f -s -b "C:/cygwin/MinGW-20070825-sjlj" "/MinGW_"
would use MinGW gcc-4.x; it finds issues with boost (which you
might be able to override with
treat_warnings_as_errors='' make any_lmi_target
but I didn't try that), and of course it requires building wx
with the same compiler (which I didn't do). I'm not putting any
time into moving to MinGW gcc-4.x myself because
- some boost issues would need to be fixed
- I'm not sure its shared libstdc++ really works
- IIRC, its '-dw2' version doesn't handle C++ exceptions thrown
across dll boundaries (but the '-sjlj' version should)
- I don't have a compelling need to stop using gcc-3.x
but you're welcome to try.