Author Topic: Building Codeblocks with project file for Linux/Unix (hv some problem)  (Read 5051 times)

Offline cyberkoa

  • Plugin developer
  • Almost regular
  • ****
  • Posts: 145
    • http://
Feeling a bit not satisfy that Codeblocks cannot be built under Codeblocks now , I hv referred to the current windows's codeblocks project file , and modify the existing codeblocks-unix-2.6.0.cbp, and I manage to compile current SVN with Codeblocks now : )

My environment :

Ubuntu 5.10 Breezy
Build with RC2

Note :
1. The current codeblocks read the path APP_PREFIX/codeblocks to get the resources.zip etc , and the folder name have a case sensitive problem , therefore , you need to rename the APP_PREFIX/CodeBlocks -> APP_PREFIX/codeblocks (which is under output/codeblocks) in order to run codeblocks

2. To run codeblocks in codeblocks , you need to modify the profile script , in my case /etc/bash.bash_rc to add the APP_PREFIX before LD_LIBRARY_PATH
In my case , the following code is added
Code
PATH=$PATH:/opt/wx/2.6/bin
APP_DIR=/home/super/projects/codeblocks-svn/src/output

if [ -z ${LD_LIBRARY_PATH} ];then
 LD_LIBRARY_PATH=$APP_DIR:/opt/wx/2.6/lib
else
 LD_LIBRARY_PATH=$APP_DIR:/opt/wx/2.6/lib:"${LD_LIBRARY_PATH}"
fi

export LD_LIBRARY_PATH
export PATH

3. For Ubuntu , since the default user do not have authority in /usr , the auto-detect compiler will fail and keep asking for the compiler (never ended, seems like a bug here) , you have to run the codeblocks with "sudo codeblocks" (under APP_PREFIX/output/ )for one time to auto update the compiler settings, later you can run as normal using the normal user .

4. The SVN should be put in home directory to avoid any authority problem.


Hope that others can try at their Linux distro , FreeBSD etc , it should be good if an IDE should be compiled in itself because it shows that IDE can do anything :)

p/s : the attachment is a tar.gz file , but the forum do not allow this file type , I rename it.



EDIT :  sorry , I hv made mistake, the compilation output does not seems to run well , it seems that this project file need to be modified again.

The error is
Quote
super@ubuntu:~/projects/codeblocks-svn/src/output$ ./codeblocks.exe --prefix=`pwd`

** (codeblocks.exe:13558): CRITICAL **: draw_box: assertion `width < 32768' failed

** (codeblocks.exe:13558): CRITICAL **: draw_box: assertion `width < 32768' failed

** (codeblocks.exe:13558): CRITICAL **: draw_box: assertion `width < 32768' failed

** (codeblocks.exe:13558): CRITICAL **: draw_box: assertion `width < 32768' failed

** (codeblocks.exe:13558): CRITICAL **: draw_box: assertion `width < 32768' failed

** (codeblocks.exe:13558): CRITICAL **: draw_box: assertion `width < 32768' failed
Segmentation fault

A splash screen appear , and the main windows created but very small , then terminated immediately.

Anybody knows what happen ?

[attachment deleted by admin]
« Last Edit: December 12, 2005, 08:25:03 am by cyberkoa »