News:

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

Main Menu

Building CodeBlocks source

Started by sorinev, July 20, 2013, 09:59:34 PM

Previous topic - Next topic

Jenna

You need to add the folder where the zip.exe resides to your systems (windows I guess) search path.

BlueHazzard

i have updated the wiki a little bit. Can someone please  check it?

greetings

ollydbg

Quote from: BlueHazzard on July 21, 2013, 05:24:16 PM
i have updated the wiki a little bit. Can someone please  check it?

greetings
Good work, I think all your changes recently are OK, thanks.
If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.

sorinev

Between google, the wiki, and this thread, I've been messing around with it for two days trying to get it to work and it's just not having it. I solve one thing, and another problem pops up. I solve that one, and the one I solved before comes back. Rinse and repeat.

I'm going to have to give up on this for now and come back when I'm more experienced with large projects and can actually figure out what the hell I'm doing and what needs to be done, through experience, and without tons of searching. Again, I appreciate the speedy replies and help you guys have offered.

LETARTARE

@BlueHazzard
Okay, very good job.

Maybe we could replace
QuoteCFLAGS ?= -fno-keep-inline-dllexport
QuoteCXXFLAGS ?= -fno-keep-inline-dllexport
by
QuoteCPPFLAGS ?= -fno-keep-inline-dllexport
I checked the Makefile, but we still control ...

and add after
or
mingw32-make -fmakefile.gcc SHARED=1 MONOLITHIC=1 BUILD=release UNICODE=1 CPPFLAGS=-fno-keep-inline-dllexport


Thank you again
CB-13834, plugins-sdk-2.25.0 : Collector-2.6.5, AddOnForQt-5.1.2
1- Win7 Business Pack1 64bits : wx-3.2.8, gcc-15.2.0,
2- OpenSuse::Leap-15.6-64bits : wx-3.2.8;gtk3-u, gcc-15.2.0,
=> !! The messages are translated by 'Deepl'

stahta01

Quote from: LETARTARE on July 22, 2013, 05:49:40 PM
@BlueHazzard
Okay, very good job.

Maybe we could replace
QuoteCFLAGS ?= -fno-keep-inline-dllexport
QuoteCXXFLAGS ?= -fno-keep-inline-dllexport
by
QuoteCPPFLAGS ?= -fno-keep-inline-dllexport
I checked the Makefile, but we still control ...

and add after
or
mingw32-make -fmakefile.gcc SHARED=1 MONOLITHIC=1 BUILD=release UNICODE=1 CPPFLAGS=-fno-keep-inline-dllexport


Thank you again

Feel free to post that on the wxWidgets forum; it will likely be ignored.

FYI: This is NOT a CB Makefile; if you think I am wrong please say why you think it is a CB Makefile.

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]

LETARTARE

#21
hello @stahta01

by BlueHazard
Quotei have updated the wiki a little bit. Can someone please  check it?
I read the excellent work BlueHazard on WIKI.
http://wiki.codeblocks.org/index.php?title=Installing_Code::Blocks_from_source_on_Windows
where the two lines is, and I just wanted to show him a simplification.
But you're right, I should have done on the wiki !
Thanks.
CB-13834, plugins-sdk-2.25.0 : Collector-2.6.5, AddOnForQt-5.1.2
1- Win7 Business Pack1 64bits : wx-3.2.8, gcc-15.2.0,
2- OpenSuse::Leap-15.6-64bits : wx-3.2.8;gtk3-u, gcc-15.2.0,
=> !! The messages are translated by 'Deepl'

sorinev



I finally did it. 6 days later. Minor issue with the contrib plugins when trying to build the Nassi Shneiderman diagram tool/plugin - it looks I need to download AND build boost myself, then set up the global variable editor for "boost"? Other than that, it works.

Next step. Do you guys have some kind of overall system architecture view for the Code::Blocks source that generally shows how the parts/files work and flow and go together? I don't think I'll get very far just poking around in source files trying to follow things at this point in my knowledge.

ollydbg

Quote from: sorinev on July 26, 2013, 10:21:40 AM


I finally did it. 6 days later. Minor issue with the contrib plugins when trying to build the Nassi Shneiderman diagram tool/plugin - it looks I need to download AND build boost myself, then set up the global variable editor for "boost"? Other than that, it works.
Yes, that need boost library, only this plugin is depend on the boost library. I think you can download some prebuild boost library some internet, for me, I never build Nassi Shneiderman myself, I just skip building this cbp in the contributes plugins ;).

Quote
Next step. Do you guys have some kind of overall system architecture view for the Code::Blocks source that generally shows how the parts/files work and flow and go together? I don't think I'll get very far just poking around in source files trying to follow things at this point in my knowledge.
I'm not sure that there are some document about this, but here I can explain all what I know:

src/src -> this contains code for building "codeblocks.exe"
src/sdk -> codeblocks.dll
src/base -> some base library needed for sdk, like tinyxml
src/include -> all the header files of sdk
plugins-> all the plugins, there are two kind of plugins, the core plugins and the contribute pluings (in a contrib subfolder)
src/devel -> all the build output (mainly binaries containing debug information)
src/output ->when you run "update.bat", it will copy from devel folder, but strip all the debug information
src/templates and src/scripts contains project wizard scripts

Is that enough? If not, just ask here.
If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.

sorinev

Quote from: ollydbg on July 26, 2013, 11:29:44 AM
Yes, that need boost library, only this plugin is depend on the boost library. I think you can download some prebuild boost library some internet, for me, I never build Nassi Shneiderman myself, I just skip building this cbp in the contributes plugins ;).

Alright, since I'm trying to build everything else under the sun (wxwidgets, codeblocks, qt, getting qt5 to work with codeblocks), I may as well throw some boost building in there too. I built everything in the workspace for the sake of thoroughness, as that's just how I am. I'm probably not going to actually use 95% of that stuff, at least in the foreseeable future, but I like knowing it's there.

Quote from: ollydbg on July 26, 2013, 11:29:44 AM
I'm not sure that there are some document about this, but here I can explain all what I know:

src/src -> this contains code for building "codeblocks.exe"
src/sdk -> codeblocks.dll
src/base -> some base library needed for sdk, like tinyxml
src/include -> all the header files of sdk
plugins-> all the plugins, there are two kind of plugins, the core plugins and the contribute pluings (in a contrib subfolder)
src/devel -> all the build output (mainly binaries containing debug information)
src/output ->when you run "update.bat", it will copy from devel folder, but strip all the debug information
src/templates and src/scripts contains project wizard scripts

Is that enough? If not, just ask here.

Thanks, and that is indeed useful. But what I actually meant was when looking at the IDE itself, how am I going to know, filewise, where something else? For example, if I'm looking at xyz area of the IDE, which source file do I find xyz in? What I'm really looking for is some kind of structure chart, organizational chart, etc. that I can get a good overall view of everything from. Even a written tree or outline would work.

Also, I've never built such a large project before. My biggest project is a win32/c++ project that I wrote with about 11k lines. I can just put a breakpoint in it, hit F8, and that's that. Is that really possible with projects as big as codeblocks?

Jenna

To make it clear: you do not need a prebuild boost library, the headers are enough.
At least I never compiled anything of boost and building C::B it works fine on windows.
About setting up the global boost-variable: http://forums.next.codeblocks.org/index.php/topic,15817.msg106443.html#msg106443 .

sorinev

Quote from: jens on July 27, 2013, 07:24:02 AM
To make it clear: you do not need a prebuild boost library, the headers are enough.
At least I never compiled anything of boost and building C::B it works fine on windows.
About setting up the global boost-variable: http://forums.next.codeblocks.org/index.php/topic,15817.msg106443.html#msg106443 .

Thanks, that did it. I already had the global variable set up right. I tried looking around for the file that the output log told me it couldn't find myself last night, but I didn't find it. So I'm glad that adding the $(#boost) bit to the compiler search path automagically did the trick for me.

sorinev

Well, I've got the Windows + TDM-GCC build process for Code::Blocks down to three easy steps. SVN Update; Build; Update.bat; done.

But now I've got a new problem! I've got another system that I'm running Kubuntu 12.10 64-bit on (it's actually a VMware guest on my Windows system), and I'm trying to build from source. I've got it to the point where it starts compiling, but partway through, it stops. The error is:


notebookstyles.h:13:25: fatal error: gtk/gtk.h: No such file or directory


I do have GTK install. I've never really gotten familiar with Linux, just tooled around a bit here and there, so I'm not sure what steps to take to resolve it. I googled around and found this issue as it relates to building gtk projects from within codeblocks, but I couldn't find anything involving the gtk header error for building codeblocks itself.

stahta01

Quote from: sorinev on August 05, 2013, 01:56:37 AM

notebookstyles.h:13:25: fatal error: gtk/gtk.h: No such file or directory


Make sure you install the dev packages for GTK.

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]

sorinev

I've now installed libgtk2.0-dev and libgtk-3-dev, but still stopping at the same spot. Was there anything else I was supposed to get? My searches really only turned up those two.