C C editor with clang integration

Hi,
i am looking for a small editor which supports clang and lldb integration. I don't need any fancy feature, i just need an editor to write, compile, test and debug relatively simple ansi c programs. I have already searched the forum but most of the users recommend vim like editors which i do not really like.
Thank you in advance,
MathematicsStudent
 
Good luck with finding an editor on FreeBSD or Linux that can be used for debugging. The best I managed is to use gdb in TUI mode.
 
lldb got a ncurses based GUI mode which I found much more intuitive than gdb’s TUI mode, and which works pretty well for me. For an example see the following post (scroll to the very bottom):
 
I'm not sure I understand your problem. For example, emacs can do all that: You write your source code in it (file test.C). You write your make file in it (in whatever make system you prefer, could be old-fashioned make, or today perhaps bazel). Then you use the emacs command "compile", and it will compile and link your code using the make system and file you specified. If there are compile errors, you can see the compile log in one window, and use the command "next-error" to find the corresponding source line. Once your program has been compiled, you can use the command "shell" to run your program, and see the output. I do this all day long. I don't know how to run a debugger (like lldb or gdb) under emacs, but a little web search should find that. There are lots of programming-language specific tools for emacs available, which allow for example finding the definition of a function from the place where it is called.

There are also GUI-based tools that can do the same thing: Edit, compile run, debug, and have lots of . I think Eclipse has the highest market share among Unix users, while MS Visual Studio probably leads among Windows users. Personally, I've used Eclipse about 5 years ago (and hated it), and Visual Studio about 15 years ago (and loved it then, but only after replacing their built-in editor with an emacs clone).

I'm sure vim can accomplish the same thing. Why does this not answer your question?
 

Above integrates with clang and cmake. This is an actual GUI that runs on X.
 
If you're looking for a text-mode editor, but you don't like modal editors like vi / nvi / vim, and emacs is too big, then joe might be worth a look (port editors/joe). It is highly configurable and supports almost everything you expect from a modern editor: syntax highlighting, macros, multiple buffers and windows, UTF-8 support, hex mode, rectangular and stream blocks, mouse support, and so on. There's only one thing missing: it doesn't support function folding (yet).

It doesn't require X11, but of course it also runs well within an xterm or other X11 terminal emulator.
 
Last time I was looking for a text-mode IDE for C programming, I tried many editors too. Then finally settled with motor, you will find under devel/. It resembles the Borland-C or Turbo Pascal IDE. You may want to give it a try.
 
Tried devel/motor but it crashes because it depends on gcc and GNU stuff that i don't want to install. editors/jucipp has too many dependencies so i didn't try ir yet but i'll keep it in my mind if the other options turn out to not suit my needs. editors/joe instead seems to be a nice little editor with some useful features and no dependencies which is great! I just need to dive into the documentation to learn how to use it at its full potential. I also appreciate the lldb built-in gui!
 
Now you're just being picky :)
Haha, maybe I am just tainted. I use Plan 9 quite a lot for my research and I really did try to get on with Acme but I was weak and had to fall back on the Vim port ;). Might try again some day.

Also to add to my pickyness (though this can be fixed quite easily):- Acme by default uses a non-fixed width font. Daring!

I actually quite liked sam. Felt a little bit like using Borland Turbo C++.
 
Sorry to bring this old thread up. But, I feel the non of the answers delivered the justice as there is a decent IDE in FreeBSD ports with an excellent level of support for LLDB. devel/qtcreator does just that (although you require Qt as a dependency). I have done plenty of debugging using it on huge codebases such as Unreal Engine 4.
 
We had a similar thread recently:

Could be useful.
 
I use Visual Studio Code with Clangd. Generating a compile_commands.json file can be a pain, but the plugin works nicely if you manage to.

Its strange, I am happy to spend hours a day fiddling and perfecting Makefiles and even CMakeFiles and yet I took one look at VSCode's Json files and thought "sod that!".

I don't know why either. In theory json is more organised. Perhaps I am just projecting my dislike of Microsoft. Who knows? XD
 
I don't know why either. In theory json is more organised. Perhaps I am just projecting my dislike of Microsoft. Who knows? XD
You have the right feeling. The problem is with the structure of vscode setting file itself. There's no rationale behind the setting arrangement. That's why vscode users have to heavily rely on Web Search Engines to find their way in vscode setting. It's not intuitive.
 
Back
Top