I have compiled wxWidgets with MinGW (g++) in Windows XP. (I am now able to compile all samples with its associated makefiles.)
I have written an own program with C++ and wxWidgets. In Linux it works to compile this program with my own makefile (and I use wx-config --cxxflags and wx-config --libs in my makefile). But when I tried to compile it in Windows with MinGW serveral errors have occured.
Here is an extract of these errors (all errors are from the same type):
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
In file included from e:/Editoren/wxMSW-2.8.7/include/wx/string.h:55,
from e:/Editoren/wxMSW-2.8.7/include/wx/memory.h:16,
from e:/Editoren/wxMSW-2.8.7/include/wx/object.h:20,
from e:/Editoren/wxMSW-2.8.7/include/wx/wx.h:16,
from main.cpp:16:
e:/Editoren/wxMSW-2.8.7/include/wx/buffer.h: In constructor `wxCharBuffer::wxCharBuffer(constchar*)':
e:/Editoren/wxMSW-2.8.7/include/wx/buffer.h:127: error: `strdup' was not declared in this scope
e:/Editoren/wxMSW-2.8.7/include/wx/buffer.h:127: warning: unused variable 'strdup'
e:/Editoren/wxMSW-2.8.7/include/wx/buffer.h: In member function `wxCharBuffer& wxCharBuffer:operator=(constchar*)':
e:/Editoren/wxMSW-2.8.7/include/wx/buffer.h:127: error: `strdup' was not declared in this scope
e:/Editoren/wxMSW-2.8.7/include/wx/buffer.h:127: warning: unused variable 'strdup'
e:/Editoren/wxMSW-2.8.7/include/wx/buffer.h: In constructor `wxWCharBuffer::wxWCharBuffer(constwchar_t*)':
e:/Editoren/wxMSW-2.8.7/include/wx/buffer.h:134: error: `_wcsdup' was not declared in this scope
e:/Editoren/wxMSW-2.8.7/include/wx/buffer.h:134: warning: unused variable '_wcsdup'
e:/Editoren/wxMSW-2.8.7/include/wx/buffer.h: In member function `wxWCharBuffer& wxWCharBuffer:operator=(constwchar_t*)':
e:/Editoren/wxMSW-2.8.7/include/wx/buffer.h:134: error: `_wcsdup' was not declared in this scope
e:/Editoren/wxMSW-2.8.7/include/wx/buffer.h:134: warning: unused variable '_wcsdup'
It would be nice if someone can help me to compile my program under Windows.
But because of your reply I tried to do it. I moved setup.h. But the result was the same.
But on executing wx-config --cxxflags I get the same paths as in the makefiles associated to the samples. ThereforeI didn't have an idea how to compile my own program.