aMule Forum
English => Compilation problems => Topic started by: Menion on December 21, 2006, 11:08:03 PM
-
Hi I upgraded my MinGW32 env to WxMSW 2.8.0. I compiled WxMSW with:
./configure --enable-unicode --disable-shared --without-checklistbox
WxMSW compiled fine and I installed them. But when I tried to compile amule-cvs (21-12-2006 SVN) after a correct ./configure I have:
$ make
make all-recursive
make[1]: Entering directory `/home/Menion/amule-cvs'
Making all in m4
make[2]: Entering directory `/home/Menion/amule-cvs/m4'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/Menion/amule-cvs/m4'
Making all in docs
make[2]: Entering directory `/home/Menion/amule-cvs/docs'
Making all in man
make[3]: Entering directory `/home/Menion/amule-cvs/docs/man'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/Menion/amule-cvs/docs/man'
make[3]: Entering directory `/home/Menion/amule-cvs/docs'
make[3]: Nothing to be done for `all-am'.
make[3]: Leaving directory `/home/Menion/amule-cvs/docs'
make[2]: Leaving directory `/home/Menion/amule-cvs/docs'
Making all in src
make[2]: Entering directory `/home/Menion/amule-cvs/src'
Making all in libs
make[3]: Entering directory `/home/Menion/amule-cvs/src/libs'
Making all in ec
make[4]: Entering directory `/home/Menion/amule-cvs/src/libs/ec'
make all-am
make[5]: Entering directory `/home/Menion/amule-cvs/src/libs/ec'
make[5]: Nothing to be done for `all-am'.
make[5]: Leaving directory `/home/Menion/amule-cvs/src/libs/ec'
make[4]: Leaving directory `/home/Menion/amule-cvs/src/libs/ec'
Making all in common
make[4]: Entering directory `/home/Menion/amule-cvs/src/libs/common'
make[4]: Nothing to be done for `all'.
make[4]: Leaving directory `/home/Menion/amule-cvs/src/libs/common'
make[4]: Entering directory `/home/Menion/amule-cvs/src/libs'
make[4]: Nothing to be done for `all-am'.
make[4]: Leaving directory `/home/Menion/amule-cvs/src/libs'
make[3]: Leaving directory `/home/Menion/amule-cvs/src/libs'
Making all in utils
make[3]: Entering directory `/home/Menion/amule-cvs/src/utils'
Making all in xas
make[4]: Entering directory `/home/Menion/amule-cvs/src/utils/xas'
Making all in docs
make[5]: Entering directory `/home/Menion/amule-cvs/src/utils/xas/docs'
make[5]: Nothing to be done for `all'.
make[5]: Leaving directory `/home/Menion/amule-cvs/src/utils/xas/docs'
make[5]: Entering directory `/home/Menion/amule-cvs/src/utils/xas'
make[5]: Nothing to be done for `all-am'.
make[5]: Leaving directory `/home/Menion/amule-cvs/src/utils/xas'
make[4]: Leaving directory `/home/Menion/amule-cvs/src/utils/xas'
make[4]: Entering directory `/home/Menion/amule-cvs/src/utils'
make[4]: Nothing to be done for `all-am'.
make[4]: Leaving directory `/home/Menion/amule-cvs/src/utils'
make[3]: Leaving directory `/home/Menion/amule-cvs/src/utils'
Making all in pixmaps
make[3]: Entering directory `/home/Menion/amule-cvs/src/pixmaps'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/Menion/amule-cvs/src/pixmaps'
Making all in kademlia
make[3]: Entering directory `/home/Menion/amule-cvs/src/kademlia'
Making all in kademlia
make[4]: Entering directory `/home/Menion/amule-cvs/src/kademlia/kademlia'
make[4]: Nothing to be done for `all'.
make[4]: Leaving directory `/home/Menion/amule-cvs/src/kademlia/kademlia'
Making all in net
make[4]: Entering directory `/home/Menion/amule-cvs/src/kademlia/net'
make[4]: Nothing to be done for `all'.
make[4]: Leaving directory `/home/Menion/amule-cvs/src/kademlia/net'
Making all in routing
make[4]: Entering directory `/home/Menion/amule-cvs/src/kademlia/routing'
make[4]: Nothing to be done for `all'.
make[4]: Leaving directory `/home/Menion/amule-cvs/src/kademlia/routing'
Making all in utils
make[2]: Entering directory `/home/Menion/amule-cvs/src/utils'
Making all in xas
make[3]: Entering directory `/home/Menion/amule-cvs/src/utils/xas'
Making all in docs
make[4]: Entering directory `/home/Menion/amule-cvs/src/utils/xas/docs'
make[4]: Nothing to be done for `all'.
make[4]: Leaving directory `/home/Menion/amule-cvs/src/utils/xas/docs'
make[4]: Entering directory `/home/Menion/amule-cvs/src/utils/xas'
make[4]: Nothing to be done for `all-am'.
make[4]: Leaving directory `/home/Menion/amule-cvs/src/utils/xas'
make[3]: Leaving directory `/home/Menion/amule-cvs/src/utils/xas'
make[3]: Entering directory `/home/Menion/amule-cvs/src/utils'
make[3]: Nothing to be done for `all-am'.
make[3]: Leaving directory `/home/Menion/amule-cvs/src/utils'
make[2]: Leaving directory `/home/Menion/amule-cvs/src/utils'
Making all in pixmaps
make[2]: Entering directory `/home/Menion/amule-cvs/src/pixmaps'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/Menion/amule-cvs/src/pixmaps'
Making all in kademlia
make[2]: Entering directory `/home/Menion/amule-cvs/src/kademlia'
Making all in kademlia
make[3]: Entering directory `/home/Menion/amule-cvs/src/kademlia/kademlia'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/Menion/amule-cvs/src/kademlia/kademlia'
Making all in net
make[3]: Entering directory `/home/Menion/amule-cvs/src/kademlia/net'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/Menion/amule-cvs/src/kademlia/net'
Making all in routing
make[3]: Entering directory `/home/Menion/amule-cvs/src/kademlia/routing'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/Menion/amule-cvs/src/kademlia/routing'
Making all in utils
make[3]: Entering directory `/home/Menion/amule-cvs/src/kademlia/utils'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/Menion/amule-cvs/src/kademlia/utils'
make[3]: Entering directory `/home/Menion/amule-cvs/src/kademlia'
make[3]: Nothing to be done for `all-am'.
make[3]: Leaving directory `/home/Menion/amule-cvs/src/kademlia'
make[2]: Leaving directory `/home/Menion/amule-cvs/src/kademlia'
make[2]: Entering directory `/home/Menion/amule-cvs/src'
if g++ -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/local/lib/wx/include/msw-unicode-release-static-2.8 -I/usr/local/include/wx-2.8 -D__WXMSW__ -mthreads -I./libs -DNOMINMAX -DUSE_EMBEDDED_CRYPTO -W -Wall -Wshadow -Wundef -DUSE_WX_EXTENSIONS -MT libmuleappgui_a-BarShader.o -MD -MP -MF ".deps/libmuleappgui_a-BarShader.Tpo" -c -o libmuleappgui_a-BarShader.o `test -f 'BarShader.cpp' || echo './'`BarShader.cpp; \
then mv -f ".deps/libmuleappgui_a-BarShader.Tpo" ".deps/libmuleappgui_a-BarShader.Po"; else rm -f ".deps/libmuleappgui_a-BarShader.Tpo"; exit 1; fi
In file included from C:/msys/1.0/local/include/wx-2.8/wx/msw/gdiimage.h:20,
from C:/msys/1.0/local/include/wx-2.8/wx/msw/cursor.h:15,
from C:/msys/1.0/local/include/wx-2.8/wx/cursor.h:20,
from C:/msys/1.0/local/include/wx-2.8/wx/dc.h:22,
from BarShader.cpp:26:
C:/msys/1.0/local/include/wx-2.8/wx/gdicmn.h: In member function `bool wxRect::Inside(int, int) const':
C:/msys/1.0/local/include/wx-2.8/wx/gdicmn.h:486: warning: declaration of 'y' shadows a member of 'this'
C:/msys/1.0/local/include/wx-2.8/wx/gdicmn.h:486: warning: declaration of 'x' shadows a member of 'this'
In file included from BarShader.cpp:27:
Color.h: At global scope:
Color.h:74: error: `COLORREF' does not name a type
In file included from BarShader.cpp:27:
Color.h:94: error: `WxColourFromCr' declared as an `inline' variable
Color.h:94: error: `COLORREF' was not declared in this scope
Color.h:95: error: expected `,' or `;' before '{' token
Color.h:100: error: `COLORREF' does not name a type
BarShader.cpp: In member function `void CBarShader::FillRect(wxDC*, const wxRect&, uint32, bool)':
BarShader.cpp:255: error: no match for call to `(wxColour) (uint32&)'
make[2]: *** [libmuleappgui_a-BarShader.o] Error 1
make[2]: Leaving directory `/home/Menion/amule-cvs/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/Menion/amule-cvs/src'
make: *** [all-recursive] Error 1
Before, with WxMSW 2.6.3 I was able to compile amuleGUI correctly. Bye!
-
Same config and same problem here....
-
I'll put a patch up soon. Probably this weekend.
-
Any news about this compilation problem?
-
Yes. I didn't do it yet.
-
In file included from BarShader.cpp:27:
Color.h: In function `COLORREF DarkenColour(COLORREF, int)':
Color.h:78: error: `GetRValue' undeclared (first use this function)
Color.h:78: error: (Each undeclared identifier is reported only once for each function it appears in.)
Color.h:78: error: `GetGValue' undeclared (first use this function)
Color.h:78: error: `GetBValue' undeclared (first use this function)
Color.h:78: error: `RGB' undeclared (first use this function)
In file included from BarShader.cpp:27:
Color.h: In function `wxColour WxColourFromCr(COLORREF)':
Color.h:98: error: `GetRValue' undeclared (first use this function)
Color.h:98: error: `GetGValue' undeclared (first use this function)
Color.h:98: error: `GetBValue' undeclared (first use this function)
Color.h: In function `COLORREF CrFromWxColour(wxColour)':
Color.h:104: error: `RGB' undeclared (first use this function)
make[3]: *** [libmuleappgui_a-BarShader.o] Error 1
make[3]: Leaving directory `/home/Menion/amule-cvs/src'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/Menion/amule-cvs/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/Menion/amule-cvs'
make: *** [all] Error 2
Still unable to compile under Win32. Please don't forget windows user :(
-
Hmm.. Did you try the latest SVN? Maybe they still haven't fixed it in the sources..
To get around this problem, edit the src/color.h file and put "include <Types.h>" after the #define COLOR_H line so it looks like this: #ifndef COLOR_H
#define COLOR_H
#include <Types.h>
#if !defined(__WXPM__) && !defined(__WXMSW__) // Otherwise already defined in wx/defs.h.
#include <inttypes.h> // Do_not_auto_remove (old gcc)
I have a feeling that you will hit another issue after fixing this one.. (I did.) Post back that error so the developers would have something sticking in their face :)
-
I tried the latest SVN source (aMule-CVS-20070414.tar.bz2). Compiling with WxWidgets 2.6.3 is ok.
-
I did the following:
#ifndef COLOR_H
#define COLOR_H
#if !defined(__WXPM__) && !defined(__WXMSW__) // Otherwise already defined in wx/defs.h.
#include <inttypes.h> // Do_not_auto_remove (old gcc)
typedef uint32_t COLORREF;
#else
#include "Types.h" // Do_not_auto_remove (Needed for windows compilation)
typedef unsigned long COLORREF;
#endif
This will be on tomorrow cvs tarball. Tell me how it compiles now.
Thanks for your support!
-
Win32 compile stops at PartFileConvert.cpp, I'll have a look at the code.
if g++ -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/local/include -I/usr/local/lib/wx/include/msw-unicode-release-static-2.8 -I/usr/local/include/wx-2.8 -__WXMSW__ -mthreads -I./libs -Ilibs -DAMULE_INSTALL_PREFIX="\"/usr/local\"" -DAMULE_LOCALEDIR="\"/usr/local/share/locale\"" -DNOMINMAX -DUSE_EMBEDDED_CRYPTO -W -Wall -Wshadow -Wundef -O2 -DUSE_WX_EXTENSIONS -MT amule-PartFileConvert.o -MD -MP -MF ".deps/amule-PartFileConvert.Tpo" -c -o amule-PartFileConvert.o `test -f 'PartFileConvert.cpp' || echo './'`PartFileConvert.cpp; \
then mv -f ".deps/amule-PartFileConvert.Tpo" ".deps/amule-PartFileConvert.Po"; else rm -f ".deps/amule-PartFileConvert.Tpo"; exit 1; fi
In file included from CFile.h:29,
from PartFile.h:31,
from PartFileConvert.cpp:50:
SafeFile.h:201:2: warning: #warning DOCS
PartFileConvert.cpp: In static member function `static void CPartFileConvert::ConvertToeMule(wxString, bool)':
PartFileConvert.cpp:140: error: 'class CPartFileConvertDlg' has no member named 'AddJobW'
PartFileConvert.cpp: In static member function `static void CPartFileConvert::ShowGUI(wxWindow*)':
PartFileConvert.cpp:562: error: 'class CPartFileConvertDlg' has no member named 'AddJobW'
PartFileConvert.cpp: At global scope:
PartFileConvert.cpp:766: error: no `void CPartFileConvertDlg::AddJobW(ConvertJob*)' member function declared in class `CPartFileConvertDlg'
make[3]: *** [amule-PartFileConvert.o] Error 1
Edit: OK, way behind my logic. The method name is in both - the source file and the header file - "AddJob", but the name is changed to AddJobW while compiling. I tried to define a new wrapper function AddJobW, but it complains about overloading the function "AddJobW", although one is named "AddJob" and my function only is named "AddJobW".
Code example:
void CPartFileConvertDlg::AddJobW(ConvertJob* job)
{
AddJob(job);
}
void CPartFileConvertDlg::AddJob(ConvertJob* job)
{
long ix = m_joblist->InsertItem(m_joblist->GetItemCount(), job->folder);
if (ix != -1) {
m_joblist->SetItemData(ix, (long)job);
m_joblist->SetItem(ix, 1, CPartFileConvert::GetReturncodeText(job->state));
}
}
g++ error:
PartFileConvert.cpp:64: error: redefinition of `void CPartFileConvertDlg::AddJobW(ConvertJob*)'
PartFileConvert.cpp:59: error: `void CPartFileConvertDlg::AddJobW(ConvertJob*)' previously defined here
gcc-bug?
$ g++ -v
Reading specs from c:/devel/mingw/bin/../lib/gcc/mingw32/3.4.2/specs
Configured with: ../gcc/configure --with-gcc --with-gnu-ld --with-gnu-as --host=mingw32 --target=mingw32 --prefix=/mingw --enable-threads --disable-nls --enable-languages=c,c++,f77,ada,objc,java --disable-win32-registry --disable-shared --enable-sjlj-exceptions --enable-libgcj --disable-java-awt --without-x --enable-java-gc=boehm --disable-libgcj-debug --enable-interpreter --enable-hash-synchronization --enable-libstdcxx-debug
Thread model: win32
gcc version 3.4.2 (mingw-special)
-
Hum, really very strange...
IIRC, there is gcc 3.4.5, maybe you could try with that one. But I think that the problem is something else.
-
Same with 3.4.5.
-
The *W and *A functions should be generated automatically.. Windows uses the W version for unicode, A version for older ANSI programs.
Today's SVN compiles just fine here (GCC 3.4.2, wxMSW 2.8.3) once I get around theif g++ -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/local/lib/wx/include/msw-unicode-release-static-2.8 -I/usr/local/include/wx-2.8 -D__WXMSW__ -mthreads -I./libs -Ilibs -DAMULE_INSTALL_PREFIX="\"/usr/local\"" -DAMULE_LOCALEDIR="\"/usr/local/share/locale\"" -DCLIENT_GUI -DEC_REMOTE -DNOMINMAX -DUSE_EMBEDDED_CRYPTO -W -Wall -Wshadow -Wundef -O2 -DUSE_WX_EXTENSIONS -MT amulegui-TransferWnd.o -MD -MP -MF ".deps/amulegui-TransferWnd.Tpo" -c -o amulegui-TransferWnd.o `test -f 'TransferWnd.cpp' || echo './'`TransferWnd.cpp; \
then mv -f ".deps/amulegui-TransferWnd.Tpo" ".deps/amulegui-TransferWnd.Po"; else rm -f ".deps/amulegui-TransferWnd.Tpo"; exit 1; fi
In file included from C:/msys/1.0/local/include/wx-2.8/wx/toplevel.h:317,
from C:/msys/1.0/local/include/wx-2.8/wx/frame.h:19,
from amuleDlg.h:30,
from TransferWnd.cpp:32:
C:/msys/1.0/local/include/wx-2.8/wx/msw/toplevel.h:122: error: expected identifier before numeric constant
C:/msys/1.0/local/include/wx-2.8/wx/msw/toplevel.h:122: error: expected `,' or `...' before numeric constant
C:/msys/1.0/local/include/wx-2.8/wx/msw/toplevel.h:122: error: ISO C++ forbids declaration of `parameter' with no type
In file included from KnownFile.h:37,
from PartFile.h:30,
from TransferWnd.cpp:33:
./libs/ec/cpp/ECSpecialTags.h:28:2: warning: #warning Kry - Preferences packet derived from packet, and that's ok, but shouldn't be here because this is a tag file and forces a stupid include
In file included from CFile.h:29,
from PartFile.h:31,
from TransferWnd.cpp:33:
SafeFile.h:201:2: warning: #warning DOCS
In file included from amule-remote-gui.h:29,
from amule.h:349,
from TransferWnd.cpp:38:
./libs/ec/cpp/RemoteConnect.h:45:2: warning: #warning Kry TODO - move to abstract layer.
make[3]: *** [amulegui-TransferWnd.o] Error 1
make[3]: Leaving directory `/src/amule-cvs/src'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/src/amule-cvs/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/src/amule-cvs'
Edit by Wuischke: Removed gaps and changed to quote tags for proper line break.
-
Makes no sense to me, that would mean that wx headers are broken for msw, I don't think this is the case.
Nodsu, how did you get around this, can you post a patch?
-
I just used the dirtiest trick in the book.. I commented out the faulting function declaration :)
I don't think this as a patch would make it to any kind of releases :p
-
lol, you mean you patched wx? :D
-
I just used the dirtiest trick in the book.. I commented out the faulting function declaration :)
I don't think this as a patch would make it to any kind of releases :p
AddJob conflicts with winspool.h. Ain't pretty either, but one can add something like
#ifdef __WXMSW__
#define _WINSPOOL_H
#endif
to PartFileConvert.cpp.
There was that TransferWnd.cpp error then. You can get pass it by including wxmsw windows.h wrapper (winwrap.h or wrapwin.h, I ain't at my pc now, can't tell).
In the end it compiled but when runned amule (monolithic app) plain won't connect to anyone (sees no sources) and crashes when you press prefs button.
-
Hi (long time no see)!
I used a slightly different workaround for this issue in PartFileConvert.cpp: I placed the line#undef AddJob
after the section with the includes. The problem is the definition#define AddJob AddJobW
in mingw/include/winspool.h, which is included by mingw/include/windows.h. Seems to be needed for the functions AddJobA() and AddJobW() in winspool.dll.
Neither my workaround nor Nodsu's is very pretty, I think :(
The only other solution would be to rename the method AddJob() to anything else, for example AddThisJob(). But the approach of the Mingw include-files with their macro definitions might be a source of further fun to come...
TranferWnd.cpp:
Either wrapwin.h or winundef.h (which is included by wrapwin.h) help getting around this trap. I didn't make any further investigations yet#ifdef __WXMSW__
//#include <wx/msw/wrapwin.h>
#include <wx/msw/winundef.h>
#endif
My next (and last) problem with today's SVN was an error in OtherFunctions.cpp, which was caused by wrong case-constants in GetMaxConnections() (starting in line 348). I changed the switch statement to switch ( os ) {
//20070506/Radek - Values for OS-IDs from wx/platinfo.h (wxWidgets 2.9)
// case wxWIN95: return 50; // This includes all Win9x versions
case wxOS_WINDOWS_9X: return 50; // This includes all Win9x versions
// case wxWINDOWS_NT: return 500; // This includes NT based windows
case wxOS_WINDOWS_NT: return 500; // This includes NT based windows
default: return -1; // Anything else. Let aMule decide...
}
After these three little changes (and the aforementioned perl-script issue with switch, of course) I could compile today's SVN! It's the first time since October, 28th 2006, that I was able to do so (also being the first time since that date, that I had time to take a more than cursory glance into the compilation errors ;))
BTW: I use wxWindows (wxMSW) 2.9 (CVS).
Now a little testing and I will upload the binaries on my FTP-Server (further information here (http://forum.amule.org/index.php?topic=8895.msg49060#msg49060))
-
Very nice :)
-
Hi Radek,
There seems to be a bug in this switch code, I think that the break's are missing.
Anyway, I have included your three suggestions in tomorrow's tarball, so please, would you test it for me? You know, I have no windows box here to test it.
Cheers!
-
@phoenix
I'll test the changes, of course. Right now the compilation for the daily wxWidgets-checkout is in progress. This takes quite some time in MingW...
Concerning the switch in OtherParts.cpp: the cases had a return as last (and only) statement. I didn't see that on first glance, either ;) But I like it better, the way you changed it in today's SVN. It's more code (text), but easier to read/scan, at least for me.
-- Edit
While compiling today's SVN-Snapshot, I ran into the following error (unrelated to your changes):if g++ -DHAVE_CONFIG_H -I. -I/home/rb/src/amule-cvs/src -I.. -I/mingw/lib/wx/include/msw-unicode-release-static-2.9 -I/mingw/include/wx-2.9 -D__WXMSW__ -mthreads -I/home/rb/src/amule-cvs/src/libs -DNOMINMAX -DUSE_EMBEDDED_CRYPTO -W -Wall -Wshadow -Wundef -g -ggdb -fno-inline -D__DEBUG__ -fmessage-length=0 -D_GLIBCXX_DEBUG -D_GLIBCXX_DEBUG_PEDANTIC -DUSE_WX_EXTENSIONS -MT libmuleappgui_a-MuleGifCtrl.o -MD -MP -MF ".deps/libmuleappgui_a-MuleGifCtrl.Tpo" -c -o libmuleappgui_a-MuleGifCtrl.o `test -f 'MuleGifCtrl.cpp' || echo '/home/rb/src/amule-cvs/src/'`MuleGifCtrl.cpp; \
then mv -f ".deps/libmuleappgui_a-MuleGifCtrl.Tpo" ".deps/libmuleappgui_a-MuleGifCtrl.Po"; else rm -f ".deps/libmuleappgui_a-MuleGifCtrl.Tpo"; exit 1; fi
In file included from p:/sources/amule-cvs/src/MuleGifCtrl.cpp:26:
e:/msys/mingw/include/wx-2.9/wx/mstream.h: In copy constructor `wxMemoryInputStream::wxMemoryInputStream(wxMemoryInputStream&)':
e:/msys/mingw/include/wx-2.9/wx/mstream.h:34: warning: base class `class wxInputStream' should be explicitly initialized in the copy constructor
p:/sources/amule-cvs/src/MuleGifCtrl.cpp: In member function `void MuleGifCtrl::Start()':
p:/sources/amule-cvs/src/MuleGifCtrl.cpp:120: error: no matching function for call to `wxTimerEvent::wxTimerEvent()'
e:/msys/mingw/include/wx-2.9/wx/timer.h:167: note: candidates are: wxTimerEvent::wxTimerEvent(const wxTimerEvent&)
e:/msys/mingw/include/wx-2.9/wx/timer.h:156: note: wxTimerEvent::wxTimerEvent(wxTimer&)
make[3]: *** [libmuleappgui_a-MuleGifCtrl.o] Error 1
For that I made this quick and dirty patch, which got me around this little obstacle// wxTimerEvent evt;
// OnTimer(evt);
wxTimerEvent *pevt;
OnTimer(*pevt);
But:
your modification in TransferWnd.cpp again leads to the same curious error as before. The #include for winundef.h needs to be somewhere before the inclusion of amuleDlg.h. After moving it to lines 32ff, it compiles well.
Next little obstacle is in OtherFunctions.cpp, GetMaxConnections(), line 360: <wxString>.ToLong() wants a Ptr to long, so I made a temporary variable to get around this long lTemp;
//value.ToLong(&maxconn);
value.ToLong(&lTemp);
maxconn = (int)lTemp;
Also, a break (or at least an empty) statement is needed after the default case, otherwise gcc complains about missing ';'
No further problems...
-
Radek,
Please, do not use wx-CVS to build it. You don't know if this new interface is stable. And it certainly breaks compatibility will everithing that came before without a warning, so I would say that by now, wxTimerEvent is broken in wxCVS. Please use wx-2.8.3 and this is a non-issue. wxDevelopers never break an API without a "deprecation" release in the middle.
As for the rest, you can try tomorrow CVS and see if we have a go now.
Cheers!
-
@Phoenix
Ok, I'll do so!
Compilation of the desired version of wxWidgets is in progress on my WIN$ box (veeery slow - sometimes MSys/MingW shows unexplainable bad attitudes: configure alone took more than 2 hours :(). Afterwards, I'll try to compile today's SVN snapshot again.
-- Edit
You were of course right: the issue with the nonexistent wxTimerEvent constructor is not there with wxWidget 2.8 branch. So, I'll stick to that...
Cheers...
-
Hi, Phoenix!
With today's snapshot I get this for OtherFunctions.cppif g++ -DHAVE_CONFIG_H -I. -I/home/rb/src/amule-cvs/src -I.. -I/mingw/lib/wx/include/msw-unicode-release-static-2.8 -I/mingw/include/wx-2.8 -D__WXMSW__ -mthreads -I/home/rb/src/amule-cvs/src/libs -Ilibs -DNOMINMAX -DUSE_EMBEDDED_CRYPTO -W -Wall -Wshadow -Wundef -g -ggdb -fno-inline -D__DEBUG__ -fmessage-length=0 -D_GLIBCXX_DEBUG -D_GLIBCXX_DEBUG_PEDANTIC -DUSE_WX_EXTENSIONS -MT amule-OtherFunctions.o -MD -MP -MF ".deps/amule-OtherFunctions.Tpo" -c -o amule-OtherFunctions.o `test -f 'OtherFunctions.cpp' || echo '/home/rb/src/amule-cvs/src/'`OtherFunctions.cpp; \
then mv -f ".deps/amule-OtherFunctions.Tpo" ".deps/amule-OtherFunctions.Po"; else rm -f ".deps/amule-OtherFunctions.Tpo"; exit 1; fi
p:/sources/amule-cvs/src/OtherFunctions.cpp: In function `int GetMaxConnections()':
p:/sources/amule-cvs/src/OtherFunctions.cpp:376: error: expected primary-expression before '}' token
p:/sources/amule-cvs/src/OtherFunctions.cpp:376: error: expected `;' before '}' token
make[3]: *** [amule-OtherFunctions.o] Error 1
This is the same error as described for yesterday's snapshot: gcc (at least the MingW version) wants to have some statement after 'default:', or, to be precise, before the closing '}'. So I added a 'break;': default:
// Anything else. Let aMule decide...
break; //#2070508/Radek - compiler throws error without break (or at least ';')
}
No other problems encountered!
Cheers...
-
Committed.
-
Works fine now.
Cheers