# Anyone use CodeBlocks as C++ IDE?



## Deleted member 63539 (Sep 4, 2020)

The choice of C++ IDE on Linux is plenty but it's not much on BSDs. As I learned basic C++ on Windows using CodeBlocks, I tried to use it on BSDs. But it sucks! Code completion is just barely working (not much better than a normal text editor!) and completely not work with modern C++ features like containers. It failed to provide the functions suggestion, when you type "." you expects to see the list of functions/methods of it but you will see nothing, even if you use Ctrl+Space. I tried all of the suggestions on the internet without any improvements. I tried to go to their forum to seek for help only to find out they they blocked the Firefox browser. Firefox users will not able to register or login. Do you think I will change browser just to suite them? No way! What is the point of using an IDE without code completion? I uninstalled it and very disappointed. After so many years I didn't improve anything. The last time I tried it, code completion sucks. Today I tried it, code completion still sucks. There is no progress at all. What a waste of time spending with such software!

p/s: Given the way how disrespect their developers reacted to the users, I think even if I could access their forum, it's still a waste of time talking with them! CodeBlocks sucks!


----------



## a6h (Sep 4, 2020)

sysctl said:


> The choice of C++ IDE on Linux is plenty but it's not much on BSDs.


What sort of IDE do you have in mind? If you want a full-feature IDE, working on FreeBSD and Windows, I suggest you try Visual Studio Code (VSCode).


sysctl said:


> As I learned basic C++ on Windows using CodeBlocks, I tried to use it on BSDs. But it sucks!


If you want to write program on Windows, you have two beautiful options. First Visual Studio community edition with one or two of its related workloads. e.g. "_Desktop/dev with C++_" and/or "_Linux/dev with C++_". Then there's VSCode with _C/C++ extension_ and it works beautifully on FreeBSD too. I've never liked CodeBlocks. I've tried it, only for a few hours, and that was it. Of course running CodeBlocks is not the worst idea someone can come out with. Reminds me of a story. Long time ago, somebody pointed me out to a video, recorded by a random dude, a typical YouTube tech-guru on the internet. Apparently he was trying to educate crowd to install and program in Turbo C 2.0 on a Windows 10 machine. The title of the video was written in English, but I couldn't understand a word of the lecture! Yes, he was referring to his artwork as lecture!. I'm sure he was trying to explain, the rationale behind his hard work, shoehorning Turbo C 2.0 on a windows 10 machine, in the current era. Beside compiler and OS, everything else sounded /LEGIT/! The presence of an unshaved face with a big head, decorated with a pair of aviator sunglasses, on a well-produced thumbnail. Pity language was a barrier.


----------



## unitrunker (Sep 4, 2020)

The trick with codeblocks is to set the include path to /usr/local/include and library path to /usr/local/lib. Not much else is needed.


----------



## 20-100-2fe (Sep 4, 2020)

Have you tried Anjuta? Or kdevelop?


----------



## 20-100-2fe (Sep 4, 2020)

Codelite is also a potential solution.
I have tried Eclipse and do not recommend it for anything else than Java development.

If no IDE fits your needs, I'd recommend Geany: it will give your the same level of functionality as VS Code (a good editor and a shell window) and is way much lighter.


----------



## Deleted member 63539 (Sep 4, 2020)

20-100-2fe said:


> I have tried Eclipse and do not recommend it for anything else than Java development.


I'm using Eclipse CDT as C++ IDE


----------



## kpedersen (Sep 4, 2020)

We tend to use Code::Blocks as the IDE to start the students off with in the first year. Learning the language as well as some of the more complex command line tools is a little too much to take in I feel.

In second year we do get them to progress onto $EDITOR, clang, cmake and svn from the command line which they like but getting them confident with gdb *is* difficult. I have yet to find a GUI debugger front end I am happy to point them towards that works on both Windows and Linux. The current trend is these weird python based web GDBs which are a little silly IMO. I am disappointed DDD hasn't been maintained well on Windows.

I even tried the standalone Eclipse CDT debugger but even just that component was far too heavy to boot up each time you quickly want to get a stack trace.

But yes, as you have experienced, actually setting up the IDE to work with your compiler of choice so that the intellisense and things works is fairly awkward. Especially if you use slightly more exotic compilers like Emscripten or console SDKs.

In any case check out: https://sanctum.geek.nz/arabesque/unix-as-ide-introduction/
Basically UNIX *is* an IDE. A very good one at that if you can learn the command line effectively.


----------



## Lamia (Sep 5, 2020)

I'm beginning to like https://www.freshports.org/devel/geany

But Codeblocks has its place. It metamorphosized into an Embedded systems IDE <can't remember its name now.> I would like to have it if only it's free.


----------



## a6h (Sep 5, 2020)

Lamia said:


> But Codeblocks has its place. It metamorphosized into an Embedded systems IDE


STM32 MCUs ?


----------



## Lamia (Sep 5, 2020)

vigole said:


> STM32 MCUs ?


Pretty close.
The professional package - http://www2.keil.com/mdk5
And preferably, all-in-one for all other or any boards, etc.


----------



## a6h (Sep 5, 2020)

Lamia: Keil products are very nice but they are too expensive for my little projects. I occasionally works on tiny PIC/8b-based projects, and MPLAB/XC8 is enough for me. Anyway thanks for link and info.


----------



## Bobi B. (Sep 5, 2020)

Lately I've been using Visual Studio 2019 Community (at work, Windows-hosted, of course) to write FreeBSD and Linux code; not perfect, but works pretty well, including auto-complete, function prototypes, go-to-definition and debugging (with some funny quirks); besides my fingers "know" Visual Studio shortcuts. Never managed to run Visual Studio Code on macOS/Windows (at home) and to remote shell to FreeBSD. Is that even possible?


----------



## unitrunker (Sep 5, 2020)

juci++ works for me.





__





						FreshPorts -- editors/jucipp: Lightweight C++-IDE with support for C++11, C++14 and C++17
					

juCI++, is a platform independent and lightweight C++ IDE designed towards libclang with speed, stability, and ease of use in mind.  It supports syntax highlighting for more than 100 different file types. Furthermore, it supports CMake and Meson as build systems. juCI++ implements Git support...




					www.freshports.org
				




If you use cmake and clang, you're all set. It has a few quirks but is very functional. You don't need to adopt someone else's project / solution file format.

That said, there's nothing wrong with tmux with a text based editor like vi or micro. If you're used to 'screen', just type control-B instead of control-A.


----------



## ekvz (Sep 5, 2020)

20-100-2fe said:


> If no IDE fits your needs, I'd recommend Geany: it will give your the same level of functionality as VS Code (a good editor and a shell window) and is way much lighter.



I can second that. Geany is what i have been mostly using for years now and i am pretty happy with it. Of course it does not have a lot of integration but being able to customize the compile and run shortcuts is usually more than enough for me. Mostly i just build and test in a standalone terminal anyways. Geany somewhat reminds me of what UltraEdit used to be many years ago before it became a slow and useless bloatfest.


----------



## Matlib (Sep 5, 2020)

20-100-2fe said:


> If no IDE fits your needs, I'd recommend Geany...





ekvz said:


> I can second that. Geany is what i have been mostly using for years now and i am pretty happy with it. ...



+ it (still) compiles against Gtk2, is really fast, has some git support, basic symbol lookup, and it generally just works.


----------



## 20-100-2fe (Sep 5, 2020)

And it can handle really large files (hundreds of megabytes) when needed wihtout making your machine unresponsive.


----------



## Lamia (Sep 5, 2020)

Bobi B. said:


> Lately I've been using Visual Studio 2019 Community (at work, Windows-hosted, of course) to write FreeBSD and Linux code; not perfect, but works pretty well, including auto-complete, function prototypes, go-to-definition and debugging (with some funny quirks); besides my fingers "know" Visual Studio shortcuts. Never managed to run Visual Studio Code on macOS/Windows (at home) and to remote shell to FreeBSD. Is that even possible?


Most people I know use Visual studio but that is not available on Linux/Unix. This is what I like to use - http://www.emide.org/ - for now.


----------



## Lamia (Sep 5, 2020)

And https://www.segger.com/products/development-tools/embedded-studio/.


----------

