News:

The new Release 25.03 is out! You can download binaries for Windows and many major Linux distros here .

Main Menu

Problem building SVN revision 3810

Started by kelo81, April 04, 2007, 12:18:00 AM

Previous topic - Next topic

kelo81

Hello everybody. I'm trying to compile SVN 3810 from zero under slackware 11 and wxGTK 2.6.4 and all seems to be OK, but at the end of the compiling task I'm getting this error:

g++ -DHAVE_CONFIG_H -I. -I. -I../../../../src/include -I/usr/lib/wx/include/gtk2-unicode-release-2.6 -I/usr/include/wx-2.6 -DGTK_NO_CHECK_CASTS -D__WXGTK__ -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D_LARGEFILE_SOURCE=1 -I../../../../src/include -I../../../../src/include/wxscintilla/include -Ulinux -Uunix -O2 -ffast-math -g -O2 -DCB_PRECOMP -Winvalid-pch -fPIC -DPIC -fexceptions -MT codesnippets.lo -MD -MP -MF .deps/codesnippets.Tpo -c codesnippets.cpp  -fPIC -DPIC -o .libs/codesnippets.o
In file included from codesnippetswindow.h:31,
                 from codesnippets.cpp:38:
snippetsconfig.h:42: error: new declaration `wxCharBuffer cbU2C(const wxString&)'
./globals.h:146: error: ambiguates old declaration `const wxCharBuffer cbU2C(const wxString&)'
make[5]: *** [codesnippets.lo] Error 1
make[5]: Leaving directory `/sdk/codeblocks/src/plugins/contrib/codesnippets'
make[4]: *** [all-recursive] Error 1
make[4]: Leaving directory `/sdk/codeblocks/src/plugins/contrib/codesnippets'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/sdk/codeblocks/src/plugins/contrib'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/sdk/codeblocks/src/plugins'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/sdk/codeblocks/src'
make: *** [all-recursive] Error 1


Wha't could be happening?  :(

Thanks in advance!
Ezequiel Ruiz
Tango/04 consultant
www.tango04.com

TDragon

#1
Quote from: Pecan on April 03, 2007, 11:17:35 PM
CodeSnippets Version 1.1.53 2007/04/3
...
Note: Killerbot believes this commit has broken the Linux build.
Until we can figure this out, Linux users using "make" should wait to update.
Apparently Killerbot is correct. Let me take a minute to look up a good revision to revert to.

-----

Yep, 3810 is the breaking one. Try 3809 ("svn update -r 3809"). Alternatively, reconfiguring with --disable-contrib and rebuilding should work too, I think.
[url="https://jmeubank.github.io/tdm-gcc/"]https://jmeubank.github.io/tdm-gcc/[/url] - TDM-GCC compiler suite for Windows (GCC 9.2.0 2020-03-08, 32/64-bit, no extra DLLs)

Pecan

Ok, I think I know the problem. Somebody stuck a const onto


const wxWX2MBbuf cbU2C(const wxString& str);


since I updated via SVN giving linux const(ipation).

I'll update and correct.

thanks
pecan

kelo81

Well, thank you  :D

Now I'm able to compile the revision 3809, but after running the make install command, if I try to start Codeblocks I get this error:

Fatal Error: Mismatch between the program and library build versions detected.
The library used 2.6 (no debug,Unicode,compiler with C++ ABI 102,wx containers,compatible with 2.4),
and your program used 2.6 (no debug,Unicode,compiler with C++ ABI 1002,wx containers,compatible with 2.4).
Aborted

Rememeber that I used wxGTK 2.6.4 and I'm using Slackware 11 (with a  recompiled 2.6 kernel). I've just followed the WIKI instructions to make CB from sources...

Any Idea?
Ezequiel Ruiz
Tango/04 consultant
www.tango04.com

TDragon

#4
Seems like your wxGTK library may have been compiled with a different compiler (== different version of GCC) than the one you're using. Your options in that case are to downgrade to whichever version it was, or (a better choice) compile wxGTK from sources with your current compiler.

The fact that you're using a different kernel build might have something to do with it, though I doubt it.

Note: Before trying these more drastic measures, I'd make absolutely sure that a fresh checkout and build from scratch really doesn't work. Stranger things have happened...
[url="https://jmeubank.github.io/tdm-gcc/"]https://jmeubank.github.io/tdm-gcc/[/url] - TDM-GCC compiler suite for Windows (GCC 9.2.0 2020-03-08, 32/64-bit, no extra DLLs)

Pecan

#5
Quote from: Pecan on April 04, 2007, 12:37:40 AM
Ok, I think I know the problem. Somebody stuck a const onto


const wxWX2MBbuf cbU2C(const wxString& str);


since I updated via SVN giving linux const(ipation).

I'll update and correct.

thanks
pecan


I added the const to: "wxWX2MBbuf cbU2C(const wxString& str);"
and re-commited (SVN 3811) but I was never able to duplicate the error with either the newest or my older SVN revisions.

I don't understand why the error didn't happen to my andLinux system in the first place.

Thanks for reporting it.

kelo81

OK, I was using a precompiled wxGTK package. I just recompiled it again and I didn't have anymore this problem. And regarding the 3811 commit, It's working OK now!, thanks!!

Kind regards,

Ezequiel
Ezequiel Ruiz
Tango/04 consultant
www.tango04.com

Biplab

Quote from: Pecan on April 04, 2007, 12:37:40 AM
Ok, I think I know the problem. Somebody stuck a const onto


const wxWX2MBbuf cbU2C(const wxString& str);


Please read the following bug-report for more details on why it was added. This has been fixed recently. :)

Quotehttps://developer.berlios.de/bugs/?func=detailbug&bug_id=10669&group_id=5358

Regards,

Biplab
Be a part of the solution, not a part of the problem.

killerbot


thomas

This may seem like a stupid question, but is there an urgent reason why the CodeSnippets plugin has to shadow a SDK function at all? Why not use the one that's there?
"We should forget about small efficiencies, say about 97% of the time: Premature quotation is the root of public humiliation."

Pecan

Quote from: thomas on April 05, 2007, 03:13:30 PM
This may seem like a stupid question, but is there an urgent reason why the CodeSnippets plugin has to shadow a SDK function at all? Why not use the one that's there?

I have my own convertion routines, but had copied the header etc from globals.h

I should have changed the names, but since I've never gotten  the problem on my linux setup, I didn't know the compile error would happen.

I don't know why it IS happening to other systems, but not to mine.

Next time around, I'll change the names.

thomas

But what is wrong with just using the identical SDK functions?
Is there a problem with them, don't they work correctly? If they don't work correctly, we need to fix them...
"We should forget about small efficiencies, say about 97% of the time: Premature quotation is the root of public humiliation."