Error Building wxscintilla module

Discussion about CodeLite development process and patches
sigzegv
CodeLite Curious
Posts: 3
Joined: Tue Nov 09, 2010 10:33 pm
Genuine User: Yes
IDE Question: c++
Contact:

Error Building wxscintilla module

Post by sigzegv »

I am getting this compilation fail with last revision

Code: Select all

g++ -Wall -D__WX__=1 -DSCI_LEXER -DLINK_LEXERS -D__WXMSW__ -Iinclude -Isrc/scintilla/include -Isrc/ -Isrc/scintilla/lexlib/ -Isrc/scintilla/src/ -I..\..\libs\wx-2.8.10\include -c -o build/ScintillaWX.o src/ScintillaWX.cpp
src/ScintillaWX.cpp: In member function `virtual void ScintillaWX::Paste()':
src/ScintillaWX.cpp:543: error: request for member `data' in `buf', which is of non-class type `wxChar*'
I am compiling with wxwidgets 2.8.10, is that version the issue ?

I am also surprised to see there is no more makefile on this module.
User avatar
eranif
CodeLite Plugin
Posts: 6373
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Error Building wxscintilla module

Post by eranif »

Which OS are you using? (I can see the __WXMSW__ in the compilation line... but this line looks like nothing as it should)
And how are you building it?

Eran
Make sure you have read the HOW TO POST thread
sigzegv
CodeLite Curious
Posts: 3
Joined: Tue Nov 09, 2010 10:33 pm
Genuine User: Yes
IDE Question: c++
Contact:

Re: Error Building wxscintilla module

Post by sigzegv »

oops sorry for the miss, I am building with mingw ( gcc 3.4.5 ) on windows seven 64, I have not tried yet to compile under linux ( also with wx2.8.10 )
I am building this module alone ( only wxscintilla, without codelite ), by own makefile, scanning folders "scintilla, lexer, lexlid and src" for cpp and cxx, and my wx libs are not in unicode
User avatar
eranif
CodeLite Plugin
Posts: 6373
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Error Building wxscintilla module

Post by eranif »

sigzegv wrote:oops sorry for the miss, I am building with mingw ( gcc 3.4.5 ) on windows seven 64, I have not tried yet to compile under linux ( also with wx2.8.10 )
I am building this module alone ( only wxscintilla, without codelite ), by own makefile, scanning folders "scintilla, lexer, lexlid and src" for cpp and cxx, and my wx libs are not in unicode
Well, there is no separate makefile for this. under Windows, codelite is built using codelite itself.

Eran
Make sure you have read the HOW TO POST thread
sigzegv
CodeLite Curious
Posts: 3
Joined: Tue Nov 09, 2010 10:33 pm
Genuine User: Yes
IDE Question: c++
Contact:

Re: Error Building wxscintilla module

Post by sigzegv »

i'm just saying this because there was a makefile in previous revision.

I think I fixed this part of code, int file ScintillaWX.cpp line 543, in replaced the line :

Code: Select all

if(len > 0 && buf.data()[len-1] == '\n')
by

Code: Select all

if(len > 0 && buf[len-1] == '\n')
This compiled fine..
But I don't know why a wxWX2MBbuf object was calling an inexistant "data" member ?

I could provide the Makefile for mingw32 ( if usefull ) but I don't really know if I am missing some defines for a good and optimized build of the wxscintilla.
User avatar
eranif
CodeLite Plugin
Posts: 6373
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Error Building wxscintilla module

Post by eranif »

sigzegv wrote:i'm just saying this because there was a makefile in previous revision.
those were un-maintained files which I removed
sigzegv wrote:But I don't know why a wxWX2MBbuf object was calling an inexistant "data" member ?
In unicode build it probably returns wxCharBuff while in ANSI build it returns wxChar*
wxCharBuff as a memebr named data()
sigzegv wrote:I could provide the Makefile for mingw32 ( if usefull ) but I don't really know if I am missing some defines for a good and optimized build of the wxscintilla.
There is no need for a "fixed" Makefile. Under Linux/Mac the makefile is generated from the main configure script, while under Windows you simply open the workspace LiteEditor.workspace, double click on the 'wxscintilla' project and click F7 (you can also right click it and select 'Export Makefile' this will generate the wxscintilla.mk makefile to compile wxscintilla.

Eran
Make sure you have read the HOW TO POST thread
Post Reply