Questions tagged [codeblocks]

This tag is for Code::Blocks, an open-source C++ IDE. Do not use this tag for code blocks which define scope (e.g. curly braces).

Code::Blocks is a free, open-source and cross-platform IDE which supports many languages, see the list of supported compilers.

This tag shall not be used for code blocks that define scope, e.g. variable declarations like

{
    // code block
    int i=0;
}
4312 questions
38
votes
2 answers

making a constant array in c++

Is there any reason why codeblocks is telling me that I can't make an array? I'm simply trying to do: const unsigned int ARRAY[10] = {0,1,2,3,4,5,6,7,8,9}; and it's giving me error: a brace-enclosed initializer is not allowed here before '{'…
hotdiggadydang
  • 381
  • 1
  • 3
  • 3
38
votes
5 answers

Enable compiler output pane in Codeblocks

This is probably a really noob question, but the fact of the matter is that my Code::blocks wouldn't show me errors when it compiles - it only shows a red bar next to the offending line as shown in screenshot. Also, when my code does run and has…
Bad Request
  • 3,990
  • 5
  • 33
  • 37
38
votes
5 answers

How do you install GTK+ 3.0 on Windows?

Trying to setup GTK+ 3.0 on Codeblocks Win7. Having some trouble finding exactly how to do this. The GTK website directs you to msys2. It seems there was once a direct download on the GTK site for an all-in-one Windows bundle that is no longer…
NOP da CALL
  • 851
  • 2
  • 8
  • 15
37
votes
5 answers

the procedure entry point __gxx_personality_v0 could not be located

Editor's Note: Error messages similar to "The procedure error point _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1EPKcRKS3_ could not be located in the dynamic link library libstdc++-6.dll" have the same cause and the same solutions…
Niklas
  • 23,674
  • 33
  • 131
  • 170
35
votes
4 answers

Why is MinGW very slow?

I'm using the Code::Blocks IDE with GCC/MinGW on Windows, and I'm trying to build a wxWidgets application which has ca. 20k lines and 40 source modules. And it builds very very slow. Compiling a C++ module lasts 2-5 seconds, and linking lasts even…
Calmarius
  • 18,570
  • 18
  • 110
  • 157
32
votes
1 answer

Program can't find libgcc_s_dw2-1.dll

Possible Duplicate: The program can't start because libgcc_s_dw2-1.dll is missing I'm using Code::Blocks and MinGW 4.4 (I think) compiler to create a C++ project. I get this system error if I run it from its directory, but not from within…
Greg Treleaven
  • 8,124
  • 7
  • 30
  • 30
31
votes
2 answers

Is there any shortcut for CodeBlocks to format the code?

Is there any shortcut for CodeBlocks to format the code? I haven't find any tip in google. I found only "format use AStyle", but it come up with right mouse button only...
Twi
  • 765
  • 3
  • 13
  • 29
31
votes
9 answers

Cannot open include file with Visual Studio

I have recently gone from Code::Blocks to Visual Studio, and in Code::Blocks one could just add a class and then include it straight away. However, whenever I do the same in Visual Studio with the following statement: #include…
user2853108
  • 1,291
  • 3
  • 12
  • 15
31
votes
1 answer

jni.h: no such file or directory

I'm using Code::Blocks in windows. I created a dll project trying to get some JNI practice. In my .h file generated by javah, there's #include jni.h, but when I try to compile it, it keeps saying jni.h: no such file or directory. I think it has…
Leshi Wang
  • 313
  • 1
  • 3
  • 8
26
votes
2 answers

Export a makefile from codeblocks

Is it possible to export a makefile from a C++ codeblocks project? If so, how is it done?
miki
26
votes
2 answers

Is it possible to rename a file in CodeBlocks?

Is there a "rename file" option in codeblocks, instead of renaming it through Explorer? I tried right-clicking the tab, but there didn't seem to be one.
user81055
  • 441
  • 2
  • 5
  • 5
26
votes
2 answers

How do I compile a .cpp file just to object file without calling linker

I am trying to compile a single .cpp file separately from the build process. If I do a full build then the compile step outputs to the directory configured when creating the project. However if I just ask for a compile I end up with the object file…
Peter Nimmo
  • 1,045
  • 2
  • 12
  • 25
25
votes
6 answers

Does C# support if codeblocks without braces?

How would C# compile this? if (info == 8) info = 4; otherStuff(); Would it include subsequent lines in the codeblock? if (info == 8) { info = 4; otherStuff(); } Or would it take only the next line? if (info == 8) { info =…
Kevin Boyd
  • 12,121
  • 28
  • 86
  • 128
23
votes
7 answers

How to debug standalone file in Code::Blocks?

I'm programming using Code::Blocks. I set some breakpoints, but Code::Blocks seems to ignore them when I run the program. By 'start the program' I mean simply clicking (Build and run). I checked under Debug and saw that F8 isn't available (Start /…
Alaa M.
  • 4,961
  • 10
  • 54
  • 95
23
votes
2 answers

Boost "no such file or directory"

I'm trying to set up my Code::Blocks work environment on a new computer and I'm having some problems. It's been a long time since I first did this, and now when I open my major project Boost is causing me problems. I'm fairly new to C++ still and…
Matthew
  • 451
  • 1
  • 6
  • 14