News:

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

Main Menu

Compiling C::B 8.02 from sources

Started by schtroumpfette, June 05, 2009, 05:07:00 PM

Previous topic - Next topic

schtroumpfette

Hello !

I run on Linux and i want to compile C::B from sources: http://www.codeblocks.org/downloads/6

I run first ./configure --prefix=/usr
make -j3

And here is the problem:

g++ -DHAVE_CONFIG_H -I. -I../../src/include -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -pthread -I../../src/include/wxscintilla/include -I../../src/include -I../../src/include/scripting/include -I../../src/include/scripting/sqplus -I../../src/include/wxFlatNotebook/include -I../../src/src/wxAUI -DENABLE_BINRELOC -DAPP_PREFIX="\"/usr\"" -Ulinux -Uunix  -O2 -ffast-math -g -O2 -DCB_PRECOMP -Winvalid-pch -fPIC -DPIC -fexceptions -MT prefix.o -MD -MP -MF .deps/prefix.Tpo -c -o prefix.o prefix.cpp
prefix.cpp: In function 'char* br_extract_dir(const char*)':
prefix.cpp:396: erreur: invalid conversion from 'const char*' to 'char*'
prefix.cpp: In function 'char* br_extract_prefix(const char*)':
prefix.cpp:432: erreur: invalid conversion from 'const char*' to 'char*'


How can i do ?

Thanks.

Jenna

You use gcc-4.4 ?

In this case you have to patch the code (see this post: http://forums.next.codeblocks.org/index.php/topic,10621.0.html ).

Or use subversion to download the actual sources, or use the tar-ball from my repo.

schtroumpfette

I'll try this patch, thanks ^^

But, what is the problem with GCC 4.4 ? It's because it's a prerelease ?

stahta01

Quote from: schtroumpfette on June 05, 2009, 11:45:49 PM
I'll try this patch, thanks ^^

But, what is the problem with GCC 4.4 ? It's because it's a prerelease ?

It is because the changed the function prototype for a function and it raises an compiler error where it used used with incorrect const-ness.
The change looked correct to me; but, can not remmember the function that was change ar current time.

Tim S
C Programmer working to learn more about C++.
On Windows 10 64 bit and Windows 11 64 bit.
--
When in doubt, read the CB WiKi FAQ. [url="http://wiki.codeblocks.org"]http://wiki.codeblocks.org[/url]

schtroumpfette

It's ok !

CodeBlocks runs faster than ever now !

Thanks for explanations ^^